Package generalDatabase.pamCursor
Class PamCursorManager
java.lang.Object
generalDatabase.pamCursor.PamCursorManager
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
Underlying database does not support updateable cursors, so the functionality is implemented using more simple SQL update statementsstatic final int
The underlying database does support updateable cursors, so most functionality can be simply passed straight through to the underlying database. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic PamCursor
createCursor
(EmptyTableDefinition tableDefinition) Create a cursor using the connection to the main databasestatic PamCursor
createCursor
(PamConnection connection, EmptyTableDefinition tableDefinition) Create a cursor using any connection to a database.static int
static void
setCursorType
(int cursorType) Set the cursor type, SCROLLABLE or NON_SCROLLABLE
-
Field Details
-
NON_SCROLLABLE
public static final int NON_SCROLLABLEUnderlying database does not support updateable cursors, so the functionality is implemented using more simple SQL update statements- See Also:
-
SCROLLABLE
public static final int SCROLLABLEThe underlying database does support updateable cursors, so most functionality can be simply passed straight through to the underlying database.- See Also:
-
-
Constructor Details
-
PamCursorManager
public PamCursorManager()
-
-
Method Details
-
setCursorType
public static void setCursorType(int cursorType) Set the cursor type, SCROLLABLE or NON_SCROLLABLE- Parameters:
cursorType
- cursor type
-
getCursorType
public static int getCursorType()- Returns:
- the cursor type of the underlying database
-
createCursor
Create a cursor using the connection to the main database- Parameters:
tableDefinition
- table definition for cursor- Returns:
- PamCursor object.
-
createCursor
public static PamCursor createCursor(PamConnection connection, EmptyTableDefinition tableDefinition) Create a cursor using any connection to a database.- Parameters:
connection
- database connectiontableDefinition
- table definition for cursor- Returns:
- PamCursor object
-