java.lang.Object | +----com.ibm.connector2.ims.ico.IMSConnectionSpec
public class IMSConnectionSpec
extends Object
An IMSConnectionSpec instance is used by an application component to pass information to the getConnection method. One example of this is an application using component-managed EIS sign-on. In this case, the application uses an IMSConnectionSpec instance to pass security information such as user name, password and group name to be used for that connection.
Connection connection = null; // Populate an IMSConnectionSpec object IMSConnectionSpec aCSpec = new IMSConnectionSpec(); aCSpec.setUserName("myUserName"); aCSpec.setPassword("myPassword"); aCSpec.setGroupName("myGroupName"); // Obtain a connection handle connection = connectionFactory.getConnection(aCSpec);
Another example is an application using a dedicated persistent socket connection to IMS Connect. In this case, the application uses an IMSConnectionSpec instance to provide the clientID to be used for the connection. This form is used, even when the application uses container-managed sign-on.
Connection connection = null; // Populate an IMSConnectionSpec object IMSConnectionSpec aCSpec = new IMSConnectionSpec(); aCSpec.setClientID("CLIENT01"); // Obtain a connection handle connection = connectionFactory.getConnection(aCSpec);
Field | Description |
propertyChange | Property change support |
Constructor | Description |
IMSConnectionSpec() | Creates an IMSConnectionSpec instance. |
Method | Description |
void addPropertyChangeListener(PropertyChangeListener) | Adds a PropertyChangeListener for all the properties. |
void addPropertyChangeListener(String, PropertyChangeListener) | Adds a PropertyChangeListener for a property. |
boolean equals(Object) | Determines if the passed instance is equal to this IMSConnectionSpec instance. |
void firePropertyChange(PropertyChangeEvent) | The firePropertyChange method was generated to support the propertyChange field. |
void firePropertyChange(String, Object, Object) | The firePropertyChange method was generated to support the propertyChange field. |
String getClientID() | Returns the value of the clientID property. |
String getGroupName() | Returns the value of the groupName property. |
String getPassword() | Returns the value of the password property. |
PropertyChangeSupport getPropertyChange() | Accessor for the propertyChange field. |
String getUserName() | Returns the value of the userName property. |
int hashCode() | Returns a hash code representation of the user name, password, and group name. |
void removePropertyChangeListener(PropertyChangeListener) | Removes a PropertyChangeListener from the listener list. |
void removePropertyChangeListener(String, PropertyChangeListener) | Removes a PropertyChangeListener for a specific property. |
void setClientID(String) | Sets the value of the clientID property. |
void setGroupName(String) | Sets the value of the groupName property. |
void setPassword(String) | Sets the value of the password property. |
void setUserName(String) | Sets the value of the userName property. |
public transient java.beans.PropertyChangeSupport propertyChangeProperty change support
public IMSConnectionSpec()Creates an IMSConnectionSpec instance.
public synchronized void addPropertyChangeListener(PropertyChangeListener listener)Adds a PropertyChangeListener for all the properties.
- Parameters
- listener - The PropertyChangeListener to be added.
public synchronized void addPropertyChangeListener(String propertyName, PropertyChangeListener listener)Adds a PropertyChangeListener for a property.
- Parameters
- listener - The PropertyChangeListener to be added.
- propertyName - The name of the property to listen on.
public boolean equals(Object other)Determines if the passed instance is equal to this IMSConnectionSpec instance.
- Parameters
- Object - The instance to check.
- Returns
- boolean A value of true is returned if the instances are equivalent; false otherwise.
- Overrides
- equals in class Object
public void firePropertyChange(PropertyChangeEvent evt)The firePropertyChange method was generated to support the propertyChange field.
public void firePropertyChange(String propertyName, Object oldValue, Object newValue)The firePropertyChange method was generated to support the propertyChange field.
public final String getClientID()Returns the value of the clientID property.
- Returns
- The clientID value.
- See Also
public final String getGroupName()Returns the value of the groupName property.
- Returns
- The groupName value.
- See Also
public final String getPassword()Returns the value of the password property.
- Returns
- The password value.
- See Also
public PropertyChangeSupport getPropertyChange()Accessor for the propertyChange field.
public final String getUserName()Returns the value of the userName property.
- Returns
- The userName value.
- See Also
public int hashCode()Returns a hash code representation of the user name, password, and group name.
- Returns
- int The hash code representation.
- Overrides
- hashCode in class Object
public synchronized void removePropertyChangeListener(PropertyChangeListener listener)Removes a PropertyChangeListener from the listener list.
- Parameters
- listener - The PropertyChangeListener to be removed.
public synchronized void removePropertyChangeListener(String propertyName, PropertyChangeListener listener)Removes a PropertyChangeListener for a specific property.
- Parameters
- propertyName - The name of the property that was listened on.
- listener - The PropertyChangeListener to be removed.
public void setClientID(String newClientID)Sets the value of the clientID property. A value for this property is provided when an application component is using a dedicated persistent socket connection to IMS Connect. The value identifies the client to which the socket connection is dedicated. A dedicated persistent socket connection can only be used for Commit Mode 0 interactions with interactionVerb SYNC_SEND_RECEIVE and SYNC_RECEIVE_ASYNCOUTPUT.
- Parameters
- newClientID - The clientID value.
- See Also
public void setGroupName(String newGroupName) throws ResourceExceptionSets the value of the groupName property. If provided, this property will be used by IMS OTMA during authorization of the user.
- Parameters
- newGroupName - The new groupName value.
- Throws
javax.resource.ResourceException
If newGroupName contains more than the maximum number of characters (8).
- See Also
public void setPassword(String newPassword) throws ResourceExceptionSets the value of the password property. This property contains the password to be used by the Security Access Facility (for example, RACF) to authenticate the user identified by the userName property.
- Parameters
- newPassword - The new password value.
- Throws
javax.resource.ResourceException
If newPassword contains more than the maximum number of characters (8).
- See Also
public void setUserName(String newUserName) throws ResourceExceptionSets the value of the userName property. This property contains the user name to be authenticated by the Security Access Facility (for example, RACF).
- Parameters
- newUserName - The new userName value.
- Throws
javax.resource.ResourceException
If newUserName contains more than the maximum number of characters (8).
- See Also