|
BEA Systems, Inc. | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--weblogic.db.jdbc.DataSet
DataSet is the abstract parent class of TableDataSet and QueryDataSet. A DataSet manages record caching details.
Each DataSet is bound to a Schema, which holds metadata such as the name, datatype, and size of each record in the DataSet. Records in a DataSet are accessible by index position (0-based).
For implementation and usage, see the Developers Guide and tutorials.
Record
,
Schema
,
QueryDataSet
,
TableDataSet
, Serialized FormField Summary | |
protected boolean |
cached
|
protected boolean |
resetable
|
protected java.sql.ResultSet |
resultval
|
protected java.sql.Statement |
stmt
|
Constructor Summary | |
DataSet()
Internal use only. |
Method Summary | |
Record |
addRecord()
Adds a new Record to a DataSet. |
boolean |
allRecordsRetrieved()
Determines whether all records for a DataSet have been retrieved. |
DataSet |
clearRecords()
Clears all Records from a DataSet. |
void |
close()
Closes all the resources associated with a DataSet. |
java.sql.Connection |
connection()
Returns the Connection object of a DataSet. |
boolean |
containsRecord(int pos)
Determines whether a Record exists at the specified position. |
void |
destroy()
Internal use only. |
DataSet |
fetchRecords()
Fetches all records. |
DataSet |
fetchRecords(int maxrecs)
Fetches at most the specified number of records. |
DataSet |
fetchRecords(int start,
int maxrecs)
Fetches at most the specified number of records starting at the specified record. |
Record |
getRecord(int pos)
Gets a Record at the specified 0-based index position in a DataSet. |
java.sql.ResultSet |
getResultSet()
Gets the java.sql.ResultSet used to create a DataSet. |
abstract java.lang.String |
getSelectString()
Gets the SelectStatement associated with a DataSet. |
void |
initialize()
Internal use only. |
int |
lastFetchSize()
Returns the number of records fetched in the previous fetch action. |
int[] |
maxColumnWidths(boolean with_heading)
Calculates the maximum widths of the columns in a DataSet. |
void |
readExternal(java.io.ObjectInput in)
Internal use only. |
DataSet |
releaseRecords()
Closes the DataSet and releases all Records from it but does not nullify them. |
Record |
removeRecord(Record rec)
Removes the specified Record object from a DataSet. |
DataSet |
reset()
Clears the current contents of a DataSet. |
abstract java.sql.ResultSet |
resultSet()
Returns the java.sql.ResultSet associated with a DataSet. |
Schema |
schema()
Returns the Schema object of a DataSet. |
int |
size()
Returns the number of Records in a DataSet. |
java.lang.String |
toString()
Returns the string representation of all the Records of a DataSet. |
void |
writeExternal(java.io.ObjectOutput out)
Internal use only. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
protected boolean resetable
protected boolean cached
protected transient java.sql.Statement stmt
protected transient java.sql.ResultSet resultval
Constructor Detail |
public DataSet()
Method Detail |
public abstract java.sql.ResultSet resultSet() throws java.sql.SQLException, DataSetException
public java.sql.ResultSet getResultSet()
public java.sql.Connection connection()
public Schema schema() throws java.sql.SQLException, DataSetException
public int size()
public boolean allRecordsRetrieved()
public DataSet reset() throws DataSetException, java.sql.SQLException
public DataSet clearRecords()
public DataSet releaseRecords() throws java.sql.SQLException, DataSetException
public Record getRecord(int pos) throws DataSetException
pos
- 0-based index in the DataSetpublic int lastFetchSize()
public DataSet fetchRecords() throws java.sql.SQLException, DataSetException
public DataSet fetchRecords(int maxrecs) throws java.sql.SQLException, DataSetException
maxrecs
- Maximum number of records to fetchpublic DataSet fetchRecords(int start, int maxrecs) throws java.sql.SQLException, DataSetException
start
- Position of first record to fetchmaxrecs
- Maximum number of records to fetchpublic void close() throws java.sql.SQLException, DataSetException
public Record addRecord() throws DataSetException, java.sql.SQLException
public Record removeRecord(Record rec) throws DataSetException
rec
- Record to be removedpublic abstract java.lang.String getSelectString()
public boolean containsRecord(int pos)
pos
- Index into the DataSetpublic java.lang.String toString()
public int[] maxColumnWidths(boolean with_heading) throws DataSetException, java.sql.SQLException
with_heading
- True if width of column headings
should be included in calculationpublic void initialize()
public void destroy()
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
|
Documentation is available at http://download.oracle.com/docs/cd/E13222_01/wls/docs61 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |