com.crystaldecisions.sdk.occa.report.data
Interface IConnectionInfo

All Superinterfaces:
IClone
All Known Implementing Classes:
ConnectionInfo

public interface IConnectionInfo
extends IClone

This interface enables you to get and set properties of a data source connection. The properties may include logon credentials, a connection type (such as SQL, database file, or Crystal Report Query Engine), the database DLL or a connection string, among others.

See Also:
IConnection.setConnectionInfo(IConnectionInfo)

Method Summary
 PropertyBag getAttributes()
          Gets additional properties of the data source connection.
 ConnectionInfoKind getKind()
          Returns the kind of connection.
 java.lang.String getPassword()
          Returns the password used to connect to the data source.
 java.lang.String getUserName()
          Returns the user name used to connect to the data source.
 boolean isMatch(IConnectionInfo info, boolean complateMatching)
          Checks to see if two IConnectionInfo objects match.
 void setAttributes(PropertyBag attributes)
          Sets additional properties for the data source connection.
 void setKind(ConnectionInfoKind kind)
          Sets the kind of connection.
 void setPassword(java.lang.String password)
          Sets the password used to connect to the data source.
 void setUserName(java.lang.String userName)
          Sets the user name used to connect to the data source.
 

Method Detail

getAttributes

PropertyBag getAttributes()
Gets additional properties of the data source connection. These properties may include the database DLL name, a database name or a connection string, among others.

Returns:
The properties as a PropertyBag object.
See Also:
PropertyBagHelper.CONNINFO_*

getKind

ConnectionInfoKind getKind()
Returns the kind of connection. For example, connection kinds include SQL, query, metadata, database file, and Crystal Report Query Engine (CRQE).

Returns:
The connection kind as a ConnectionInfoKind object.
See Also:
ConnectionInfoKind

getPassword

java.lang.String getPassword()
Returns the password used to connect to the data source.

Returns:
The password as a String.

getUserName

java.lang.String getUserName()
Returns the user name used to connect to the data source.

Returns:
The user name as a String.

isMatch

boolean isMatch(IConnectionInfo info,
                boolean complateMatching)

Checks to see if two IConnectionInfo objects match.

If complateMatching is true, all members of the object are compared. When all members of the object have been compared, a value of true is returned if all members are exactly the same. If set to false, all members of the object are compared and a value of true is returned if the mismatch is caused by one of the comparing members having an empty string and all of the remaining kinds of members match. If strings are being compared, the comparison is not case sensitive.

Parameters:
info - the IConnectionInfo object that is compared to the one you are using.
complateMatching - defaults to true
Returns:
dependent on conditions described above

setAttributes

void setAttributes(PropertyBag attributes)
Sets additional properties for the data source connection. These properties may include the database DLL name, a database name or a connection string, among others.

Parameters:
attributes - The properties as a PropertyBag object.
See Also:
PropertyBagHelper.CONNINFO_*

setKind

void setKind(ConnectionInfoKind kind)
Sets the kind of connection. For example, connection kinds include SQL, query, metadata, database file, and Crystal Report Query Engine (CRQE).

Parameters:
kind - The connection kind as a ConnectionInfoKind object.
See Also:
ConnectionInfoKind

setPassword

void setPassword(java.lang.String password)
Sets the password used to connect to the data source.

Parameters:
password - The password as a String.

setUserName

void setUserName(java.lang.String userName)
Sets the user name used to connect to the data source.

Parameters:
userName - The user name as a String.