Qore jni Module  1.0.1
org.qore.lang.tablemapper.AbstractSqlStatementOutboundMapper Class Reference

Java wrapper for the TableMapper::AbstractSqlStatementOutboundMapper class in Qore. More...

Inheritance diagram for org.qore.lang.tablemapper.AbstractSqlStatementOutboundMapper:
org.qore.lang.mapper.Mapper org.qore.jni.QoreObjectWrapper org.qore.lang.tablemapper.RawSqlStatementOutboundMapper org.qore.lang.tablemapper.SqlStatementOutboundMapper

Public Member Methods

 AbstractSqlStatementOutboundMapper (QoreObject obj)
 creates the object as a wrapper for the Qore object
 
void commit () throws Throwable
 commits the transaction and frees the Qore::SQL::AbstractDatasource transaction thread resource
 
void rollback () throws Throwable
 rolls the transaction back and frees the Qore::SQL::AbstractDatasource transaction thread resource
 
HashMap< String, Object > getData () throws Throwable
 Retrieve mapped data as a hash of lists. More...
 
HashMap< String, Object > [] getDataRows () throws Throwable
 Retrieve mapped data as a list of hashes. More...
 
- Public Member Methods inherited from org.qore.lang.mapper.Mapper
 Mapper (QoreObject obj)
 creates the object as a wrapper for the Qore object
 
Object getRuntime (String key) throws Throwable
 get current runtime option value for a key More...
 
String getFieldName (String fname) throws Throwable
 returns a descriptive name of the given field if possible, otherwise returns the field name itself
 
HashMap< String, Object > validKeys () throws Throwable
 returns a list of valid field keys for this class (can be overridden in subclasses) More...
 
HashMap< String, Object > validTypes () throws Throwable
 returns a list of valid field types for this class (can be overridden in subclasses) More...
 
HashMap< String, Object > optionKeys () throws Throwable
 returns a list of valid constructor options for this class (can be overridden in subclasses) More...
 
HashMap< String, Object > getInputRecord () throws Throwable
 returns the value of the "input" option More...
 
HashMap< String, Object > getOutputRecord () throws Throwable
 returns the value of the "output" option More...
 
HashMap< String, Object > [] mapAll (Map< String, Object >[] recs) throws Throwable
 maps all input records and returns the mapped data as a list of output records More...
 
HashMap< String, Object > [] mapAll (Map< String, Object > recs) throws Throwable
 maps all input records and returns the mapped data as a list of output records More...
 
HashMap< String, Object > mapData (Map< String, Object > rec) throws Throwable
 processes the input record and returns a Map<String, Object> of the mapped values where the keys in the Map<String, Object> returned are the target field names; the order of the fields in the Map<String, Object> returned is the same order as the keys in the map hash. More...
 
- Public Member Methods inherited from org.qore.jni.QoreObjectWrapper
 QoreObjectWrapper (QoreObject obj)
 creates the wrapper object with the Qore object
 
void release ()
 releases the Qore object; do not call any further methods on the object after this call
 
QoreObject getQoreObject ()
 returns the Qore object
 
String className ()
 returns the class name for the Qore object
 
boolean instanceOf (String class_name)
 returns true if the object is an instance of the given class
 

Additional Inherited Members

- Private Attributes inherited from org.qore.jni.QoreObjectWrapper
QoreObject obj
 the wrapper Qore object
 

Detailed Description

Java wrapper for the TableMapper::AbstractSqlStatementOutboundMapper class in Qore.

Note
Loads and initializes the Qore library and the jni module in static initialization if necessary

Member Function Documentation

◆ getData()

HashMap<String, Object> org.qore.lang.tablemapper.AbstractSqlStatementOutboundMapper.getData ( ) throws Throwable
inline

Retrieve mapped data as a hash of lists.

Returns
*hash with data or null in case there are no more data available.

The size of the batch is driven by the select_block option passed in the constructor.

The hash is in Qore::SQL::AbstractDatasource::select() form - meaning it is a hash with column names as keys. Values are lists of column values. This data structure is used for Qore::context statement or BulksSqlUtil operations.

◆ getDataRows()

HashMap<String, Object> [] org.qore.lang.tablemapper.AbstractSqlStatementOutboundMapper.getDataRows ( ) throws Throwable
inline

Retrieve mapped data as a list of hashes.

Returns
list with data or null in case there are no more data available.

Size of the batch is driven by the select_block option passed in the constructor.

List is in Qore::SQL::AbstractDatasource::selectRows() form - meaning it is a list with hashes, where every hash has column names as keys with single values as hash values.


The documentation for this class was generated from the following file: