org.firebirdsql.jca

Class FBConnectionRequestInfo

Implemented Interfaces:
ConnectionRequestInfo, ConnectionSpec, org.firebirdsql.gds.impl.DatabaseParameterBufferExtension, Serializable

public class FBConnectionRequestInfo
extends java.lang.Object
implements org.firebirdsql.gds.impl.DatabaseParameterBufferExtension, ConnectionRequestInfo, ConnectionSpec, Serializable

The class FBConnectionRequestInfo holds a clumplet that is used to store and transfer connection-specific information such as user, password, and other dpb information..
Version:
2.0
Authors:
David Jencks
Roman Rokytskyy

Fields inherited from interface org.firebirdsql.gds.impl.DatabaseParameterBufferExtension

BLOB_BUFFER_SIZE, FILENAME_CHARSET, LOCAL_ENCODING, MAPPING_PATH, NO_RESULT_SET_TRACKING, PARANOIA_MODE, RESULT_SET_HOLDABLE, SOCKET_BUFFER_SIZE, TIMESTAMP_USES_LOCAL_TIMEZONE, USE_STANDARD_UDF, USE_STREAM_BLOBS

Constructor Summary

FBConnectionRequestInfo(DatabaseParameterBuffer dpb)

Method Summary

void
addArgument(int argumentType)
Add argument with no parameters.
void
addArgument(int argumentType, String value)
Add string argument.
void
addArgument(int argumentType, byte[] content)
Add array of bytes.
void
addArgument(int argumentType, int value)
Add integer argument.
DatabaseParameterBuffer
deepCopy()
Perform a deep copy of this object, returning the copied instance.
boolean
equals(Object obj)
int
getArgumentAsInt(int argumentType)
Get argument as int.
String
getArgumentAsString(int argumentType)
Get argument as string.
DatabaseParameterBuffer
getDpb()
Get the underlying Database Parameter Buffer for this object.
boolean
hasArgument(int argumentType)
Check if this parameter buffer has specified argument.
int
hashCode()
void
removeArgument(int argumentType)
Remove specified argument.
DatabaseParameterBuffer
removeExtensionParams()
void
setPassword(String password)
void
setUserName(String userName)

Constructor Details

FBConnectionRequestInfo

public FBConnectionRequestInfo(DatabaseParameterBuffer dpb)

Method Details

addArgument

public void addArgument(int argumentType)
Add argument with no parameters.
Specified by:
addArgument in interface DatabaseParameterBuffer
Parameters:
argumentType - type of argument.

addArgument

public void addArgument(int argumentType,
                        String value)
Add string argument.
Specified by:
addArgument in interface DatabaseParameterBuffer
Parameters:
argumentType - type of argument.
value - string value to add.

addArgument

public void addArgument(int argumentType,
                        byte[] content)
Add array of bytes.
Specified by:
addArgument in interface DatabaseParameterBuffer
Parameters:
argumentType - type of argument.
content - content of argument.

addArgument

public void addArgument(int argumentType,
                        int value)
Add integer argument.
Specified by:
addArgument in interface DatabaseParameterBuffer
Parameters:
argumentType - type of argument.
value - integer value to add.

deepCopy

public DatabaseParameterBuffer deepCopy()
Perform a deep copy of this object, returning the copied instance.
Specified by:
deepCopy in interface DatabaseParameterBuffer
Returns:
A deep-copied copy of this FBConnectionRequestInfo object

equals

public boolean equals(Object obj)

getArgumentAsInt

public int getArgumentAsInt(int argumentType)
Get argument as int.
Specified by:
getArgumentAsInt in interface DatabaseParameterBuffer
Parameters:
argumentType - type of argument to find.
Returns:
argument as string or 0 if nothing found.

getArgumentAsString

public String getArgumentAsString(int argumentType)
Get argument as string.
Specified by:
getArgumentAsString in interface DatabaseParameterBuffer
Parameters:
argumentType - type of argument to find.
Returns:
argument as string or null if nothing found.

getDpb

public DatabaseParameterBuffer getDpb()
Get the underlying Database Parameter Buffer for this object.
Returns:
The underlying dpb for this object

hasArgument

public boolean hasArgument(int argumentType)
Check if this parameter buffer has specified argument.
Specified by:
hasArgument in interface DatabaseParameterBuffer
Parameters:
argumentType - type of argument to find.
Returns:
true if this buffer contains specified argument.

hashCode

public int hashCode()

removeArgument

public void removeArgument(int argumentType)
Remove specified argument.
Specified by:
removeArgument in interface DatabaseParameterBuffer
Parameters:
argumentType - type of argument to remove.

removeExtensionParams

public DatabaseParameterBuffer removeExtensionParams()
Specified by:
removeExtensionParams in interface org.firebirdsql.gds.impl.DatabaseParameterBufferExtension

setPassword

public void setPassword(String password)

setUserName

public void setUserName(String userName)

Copyright B) 2001 David Jencks and other authors. All rights reserved.