001: /*
002: * The contents of this file are subject to the Sapient Public License
003: * Version 1.0 (the "License"); you may not use this file except in compliance
004: * with the License. You may obtain a copy of the License at
005: * http://carbon.sf.net/License.html.
006: *
007: * Software distributed under the License is distributed on an "AS IS" basis,
008: * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
009: * the specific language governing rights and limitations under the License.
010: *
011: * The Original Code is The Carbon Component Framework.
012: *
013: * The Initial Developer of the Original Code is Sapient Corporation
014: *
015: * Copyright (C) 2003 Sapient Corporation. All Rights Reserved.
016: */
017:
018: package org.sape.carbon.services.sql.connection;
019:
020: import org.sape.carbon.core.component.ComponentConfiguration;
021:
022: /**
023: * Configuration Interface for NamedDataSourceConnectionFactory.
024: * The <code>JndiUserId, JndiPassword, DataSourceUserId and
025: * DataSourcePassword</code> are all optional - but may be required by the
026: * Vendor's implementation, or your setup of JNDI + DataSource + JDBC.
027: *
028: * @since carbon 1.0
029: * @author Chris Herron, March 2002
030: * @version $Revision: 1.8 $($Author: dvoet $ / $Date: 2003/05/05 21:21:37 $)
031: * <br>Copyright 2002 Sapient
032: */
033: public interface NamedDataSourceConnectionFactoryConfiguration extends
034: ComponentConfiguration {
035:
036: /**
037: * Gets the JNDI name of the datasource to retreive.
038: *
039: * @return JNDI name of the datasource to retreive
040: */
041: String getJndiName();
042:
043: /**
044: * Sets the JNDI name of the datasource to retreive.
045: *
046: * @param jndiName JNDI name of the datasource to retreive
047: */
048: void setJndiName(String jndiName);
049:
050: /**
051: * Gets the name of the initial context factory used to retreive the
052: * datasource.
053: *
054: * @return name of the initial context factory
055: */
056: String getInitialContextFactory();
057:
058: /**
059: * Sets the name of the initial context factory used to retreive the
060: * datasource.
061: *
062: * @param initialContextFactory name of the initial context factory
063: */
064: void setInitialContextFactory(Class initialContextFactory);
065:
066: /**
067: * Gets the provider Url for the datasource.
068: *
069: * @return the provider Url
070: */
071: String getProviderUrl();
072:
073: /**
074: * Sets the provider Url for the datasource.
075: *
076: * @param providerUrl the provider Url
077: */
078: void setProviderUrl(String providerUrl);
079:
080: /**
081: * (Optional) Gets the name of the jndi user to authenticate with.
082: *
083: * @return name of the jndi user to authenticate with
084: */
085: String getJndiUserId();
086:
087: /**
088: * (Optional) Sets the name of the jndi user to authenticate with.
089: *
090: * @param jndiUserId name of the jndi user to authenticate with
091: */
092: void setJndiUserId(String jndiUserId);
093:
094: /**
095: * (Optional) Gets the name of the jndi password to authenticate with.
096: *
097: * @return name of the jndi password to authenticate with
098: */
099: String getJndiPassword();
100:
101: /**
102: * (Optional) Sets the name of the jndi password to authenticate with.
103: *
104: * @param jndiPassword name of the jndi password to authenticate with
105: */
106: void setJndiPassword(String jndiPassword);
107:
108: /**
109: * (Optional) Gets the name of the datasource id to authenticate with.
110: *
111: * @return name of the datasource id to authenticate with
112: */
113: String getDataSourceUserId();
114:
115: /**
116: * (Optional) Sets the name of the datasource id to authenticate with.
117: *
118: * @param dataSourceUserId name of the datasource id to authenticate with
119: */
120: void setDataSourceUserId(String dataSourceUserId);
121:
122: /**
123: * (Optional) Gets the name of the datasource password to
124: * authenticate with.
125: *
126: * @return name of the datasource password to authenticate with
127: */
128: String getDataSourcePassword();
129:
130: /**
131: * (Optional) Sets the name of the datasource password to
132: * authenticate with.
133: *
134: * @param dataSourcePassword name of the datasource password
135: * to authenticate with
136: */
137: void setDataSourcePassword(String dataSourcePassword);
138:
139: }
|