public abstract class AbstractTempTable extends HandleChain implements TempTable
Modifier and Type | Class and Description |
---|---|
protected static class |
AbstractTempTable.CallingFunction
Enumeration which represents some temp-table functions.
|
TempTable.BeforeType
Modifier and Type | Field and Description |
---|---|
protected character |
admData
Corresponds ADM-DATA attribute.
|
private java.util.Set<Buffer> |
allBuffers
The set of child buffers, in registration order.
|
protected TempTable.BeforeType |
beforeTableType
Is this an AFTER-TABLE or BEFORE-TABLE? Cached after value is computed.
|
private java.util.Set<TempTable> |
changesTables
Set of tables that contain the changes of this table.
|
private boolean |
dataSourceModified
Current value of the
DATA-SOURCE-MODIFIED attribute. |
protected static java.lang.String |
DEFAULT_COPY_TEMP_TABLE_PREFIX
Default prefix for the name of a temp-table copied with COPY-TEMP-TABLE.
|
protected handle |
defaultBufferHandle
Default buffer handle.
|
protected logical |
error
Corresponds ERROR attribute.
|
protected character |
errorString
Corresponds ERROR-STRING attribute.
|
private java.lang.String |
namespacePrefix
The NAMESPACE-PREFIX of the XML node for serialized data of this
TEMP-TABLE . |
private java.lang.String |
namespaceURI
The NAMESPACE-URI of the XML node for serialized data of this
TEMP-TABLE . |
private TempTable |
originTable
The current value resource of the
ORIGIN-HANDLE attribute. |
protected TempTable |
peerTable
The cached peer buffer.
|
private boolean |
rejected
The current value of boolean
REJECTED attribute: indicates whether a change to the
data of this DataSet is rejected. |
private int |
schemaMarshal
The current value of the
SCHEMA-MARSHAL attribute. |
private java.lang.String |
serializeName
The current value of the
SERIALIZE-NAME attribute. |
static int |
SM_DEFAULT
The default
SCHEMA-MARSHAL level. |
static int |
SM_FULL
Encodes the
MIN SCHEMA-MARSHAL level. |
static int |
SM_MIN
Encodes the
MIN SCHEMA-MARSHAL level. |
static int |
SM_NONE
Encodes the
NONE SCHEMA-MARSHAL level. |
private boolean |
trackingChanges
The current value of
TRACKING-CHANGES attribute. |
protected boolean |
undoable
true if changes made to the records the temporary table can be undone. |
private integer |
uniqueId
Corresponds UNIQUE-ID attribute.
|
private java.lang.String |
xmlNodeName
The name of the XML node for serialized data of this
TEMP-TABLE . |
name, nextSibling, prevSibling
instProc
SCHEMA_MARSHAL_FULL, SCHEMA_MARSHAL_MIN, SCHEMA_MARSHAL_NONE
Constructor and Description |
---|
AbstractTempTable(boolean dynamic)
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
abstract boolean |
_clear()
Check whether this TEMP-TABLE is in CLEAR state: I.e.
|
protected boolean |
_hasRecords()
Worker for
hasRecords . |
abstract boolean |
_prepared()
Returns
true if this temp-table is in prepared state (after a successful call to
TempTable.tempTablePrepare(java.lang.String) ). |
protected abstract boolean |
addFunctionWasCalled()
Determine if an ADD-* function was called for the table (CLEAR function resets the state).
|
logical |
canUndo()
Obtain the current UNDO attribute of 4GL temp-table.
|
void |
changeErrorString(character errStr)
Sets the ERROR-STRING attribute of 4GL temp-table.
|
private TempTable.BeforeType |
computeTableType()
Computes the temp-table type and if it is an
AFTER_TABLE or a BEFORE_TABLE
the peer (complementary) buffer is also stored in peerTable . |
logical |
copyTempTable(handle other)
Copies the other temp-table.
|
logical |
copyTempTable(handle other,
boolean append)
Copies the other temp-table.
|
logical |
copyTempTable(handle other,
boolean append,
boolean replace)
Copies the other temp-table.
|
logical |
copyTempTable(handle other,
boolean append,
boolean replace,
boolean looseCopy)
Copies the other temp-table.
|
logical |
copyTempTable(handle other,
boolean append,
boolean replace,
boolean looseCopy,
java.lang.String prefix)
Copies the other temp-table.
|
logical |
copyTempTable(handle other,
logical append)
Copies the other temp-table.
|
logical |
copyTempTable(handle other,
logical append,
logical replace)
Copies the other temp-table.
|
logical |
copyTempTable(handle other,
logical append,
logical replace,
logical looseCopy)
Copies the other temp-table.
|
logical |
copyTempTable(handle other,
logical append,
logical replace,
logical looseCopy,
character prefix)
Copies the other temp-table.
|
(package private) TemporaryBuffer |
defaultBuffer()
Get default buffer for the static temp-table.
|
logical |
deleteAll()
Bulk delete all records associated with the
TempTable . |
protected void |
deleteAllBuffers()
Delete all the buffers (master and slave) associated with this temporary table (static or
dynamic).
|
(package private) void |
deleteAllImpl()
Implementation of bulk delete all records associated with the
TempTable . |
<T extends BaseDataType> |
dereference(java.lang.Class<T> type,
java.lang.String memberName)
All kind of temp-tables can be dereferenced.
|
BaseDataType |
dereference(java.lang.String memberName)
All kind of temp-tables can be dereferenced.
|
void |
dereference(java.lang.String memberName,
java.lang.Object value)
All kind of temp-tables can be dereferenced.
|
(package private) void |
deregisterBuffer(Buffer buf)
Deregister a buffer which has gone out of scope.
|
protected void |
displayCannotClear()
Display "CLEAR method may not be called on a static temp-table object, nor on a dynamic one
with records; use buffer:EMPTY-TEMP-TABLE" error message.
|
protected void |
displayCopyTempTableHalfDefined()
Display "COPY-TEMP-TABLE target temp-table must be either PREPARED or CLEAR, but not
half-defined" error message.
|
protected void |
displayCopyTempTableInvalidFirstArg()
Display "COPY-TEMP-TABLE must have valid buffer/temp-table handle as first argument" error
message.
|
protected void |
displayCouldNotFindLikeTableFromHandle()
Display "TEMP-TABLE method could not find LIKE table from BUFFER handle" error message.
|
protected void |
displayCreateLikeNotFirst()
Display "CREATE-LIKE must be the first method on a newly CREATEd TEMP-TABLE, or a newly
CLEARed one" error message.
|
protected void |
displayNotPrepared()
Display "TEMP-TABLE must be PREPARED before referencing NAME/DEFAULT-BUFFER-HANDLE etc"
error message.
|
protected void |
displayPrepared()
Display "Definitional TEMP-TABLE methods (ADD-NEW/LIKE) may not be called after
TEMP-TABLE-PREPARE has been called unless a CLEAR is done first, and may never be called on
a DEFINED static table" error message.
|
protected void |
displayPreparedIgnoring()
Display "TEMP-TABLE is already prepared--ignoring" error message.
|
protected void |
displayUnableAddFieldsFrom()
Display "Unable to ADD-FIELDS-FROM for TEMP-TABLE" error message.
|
protected void |
displayUnableAssignUnknownUndo()
Display "Unable to assign UNKNOWN value to attribute UNDO on TEMP-TABLE widget" error
message.
|
protected void |
displayUnableCreateLike()
Display "Unable to CREATE-LIKE for TEMP-TABLE--try using a smaller source table" error
message.
|
protected void |
displayUninitialized()
Display "Attempt to reference uninitialized temp-table" error message.
|
logical |
error()
Returns the state of the ERROR attribute
|
void |
error(boolean value)
Setter for ERROR attribute.
|
void |
error(logical value)
Setter for ERROR attribute.
|
character |
errorString()
Obtain the current ERROR-STRING attribute of 4GL temp-table.
|
character |
getADMData()
Get the value of the ADM-DATA attribute.
|
handle |
getAfterTable()
Get the handle of the after-image table that corresponds to the before-image table
currently associated with this temp-table handle.
|
handle |
getBeforeTable()
Get the handle of the before-image table that corresponds to the after-image table
currently associated with this temp-table handle.
|
handle |
getOriginHandle()
Get the handle of the TEMP-TABLE in the original source
DataSet object that
corresponds to the TEMP-TABLE currently associated with this TEMP-TABLE handle. |
protected RecordBuffer |
getRecordBufferByHandle(handle hbuf,
AbstractTempTable.CallingFunction callingFunction)
Get record buffer by buffer or temp-table handle.
|
character |
getSchemaMarshal()
Obtain the current value of
SCHEMA-MARSHAL attribute. |
int |
getSchemaMarshalLevel()
Obtain the current
SCHEMA-MARSHAL level. |
character |
getSerializeName()
Implementation of the read access of the
SERIALIZE-NAME attribute. |
integer |
getUniqueID()
Gets the the unique ID number associated to this object by the
underlying system.
|
character |
getXmlDataType()
Obtain the XML Schema data type for the buffer-field object.
|
character |
getXmlNodeName()
Obtain the name of the XML element or attribute representing the target object (a
TEMP-TABLE )
name in an XML document. |
character |
getXmlNodeType()
Obtain the XML node type of this object.
|
logical |
hasRecords()
Checks whether this temp-table contains any records.
|
logical |
isDataSourceModified()
Checks whether the data in the data source has been modified.
|
logical |
isMinSchemaMarshal()
Implements the
MIN-SCHEMA-MARSHAL attribute getter. |
logical |
isNoSchemaMarshal()
Implements the
NO-SCHEMA-MARSHAL attribute getter. |
logical |
isTrackingChanges()
Checks whether changes in this temp-table is enabled for a
DataSet . |
boolean |
isUndoable()
Get the current value of UNDO attribute of this temp-table.
|
character |
namespacePrefix()
Returns the value of the NAMESPACE-PREFIX attribute.
|
void |
namespacePrefix(character prefix)
Setter for NAMESPACE-PREFIX attribute.
|
void |
namespacePrefix(java.lang.String prefix)
Setter for NAMESPACE-PREFIX attribute.
|
character |
namespaceURI()
Returns the value of the NAMESPACE-URI attribute.
|
void |
namespaceURI(character uri)
Setter for NAMESPACE-URI attribute.
|
void |
namespaceURI(java.lang.String uri)
Setter for NAMESPACE-URI attribute.
|
logical |
prepared()
Returns
true if this temp-table is in prepared state (after a successful call
to TempTable.tempTablePrepare(java.lang.String) ). |
logical |
readJson(SourceData source)
Implementation of the READ-JSON method.
|
logical |
readJson(SourceData source,
character readMode)
Implementation of the READ-JSON method.
|
logical |
readXml(SourceData source,
character readMode,
character schemaLocation,
logical overrideDefaultMapping)
Implementation of the READ-XML method.
|
logical |
readXml(SourceData source,
character readMode,
character schemaLocation,
logical overrideDefaultMapping,
character fieldTypeMapping)
Implementation of the READ-XML method.
|
logical |
readXml(SourceData source,
character readMode,
character schemaLocation,
logical overrideDefaultMapping,
character fieldTypeMapping,
character verifySchemaMode)
Implementation of the READ-XML method.
|
logical |
readXmlSchema(SourceData source,
logical override)
Reads XML Schema from an XML document and uses that schema to either create a schema for a
TempTable or TempTable or verify existing schema in a TempTable ,
TempTable or temp-table Buffer object. |
logical |
readXmlSchema(SourceData source,
logical override,
Text mapping)
Reads XML Schema from an XML document and uses that schema to either create a schema for a
TempTable or TempTable or verify existing schema in a TempTable ,
TempTable or temp-table Buffer object. |
logical |
readXmlSchema(SourceData source,
logical override,
Text strMapping,
Text verifyMode)
Reads XML Schema from an XML document and uses that schema to either create a schema for a
TempTable or TempTable or verify existing schema in a TempTable ,
TempTable or temp-table Buffer object. |
(package private) void |
registerBuffer(Buffer buf)
Register a new buffer with this table.
|
logical |
rejected()
Returns the state of the REJECTED attribute
|
void |
rejected(boolean value)
Setter for REJECTED attribute.
|
void |
rejected(logical value)
Setter for REJECTED attribute.
|
void |
setADMData(character value)
Set the value of the ADM-DATA attribute.
|
void |
setADMData(java.lang.String value)
Set the value of the ADM-DATA attribute.
|
void |
setCanUndo(logical undo)
Sets the UNDO attribute of 4GL temp-table.
|
void |
setDataSourceModified(boolean mod)
Manually mark the data in the target structure as modified.
|
void |
setDataSourceModified(logical mod)
Manually mark the data in the target structure as modified.
|
void |
setMinSchemaMarshal(boolean on)
Sets the
SCHEMA-MARSHAL attribute to "MIN" value when on = true or
back to default value on = false . |
void |
setMinSchemaMarshal(logical on)
Sets the
SCHEMA-MARSHAL attribute to "MIN" value when on = true or
back to default value on = false . |
void |
setNoSchemaMarshal(boolean on)
Sets the
SCHEMA-MARSHAL attribute to "NO" value when on = true or
back to default value on = false . |
void |
setNoSchemaMarshal(logical on)
Sets the
SCHEMA-MARSHAL attribute to "NO" value when on = true or
back to default value on = false . |
(package private) void |
setOriginTable(TempTable origin)
Sets the origin table.
|
void |
setSchemaMarshal(java.lang.String level)
Sets a new value for
SCHEMA-MARSHAL attribute. |
void |
setSchemaMarshal(Text level)
Sets a new value for
SCHEMA-MARSHAL attribute. |
void |
setSerializeName(java.lang.String sName)
Implementation of the write access of the
SERIALIZE-NAME attribute. |
void |
setSerializeName(Text sName)
Implementation of the write access of the
SERIALIZE-NAME attribute. |
void |
setTrackingChanges(boolean on)
Enable or disable changes tracking this temp-table is enabled for a
DataSet . |
void |
setTrackingChanges(logical val)
Enable or disable changes tracking this temp-table is enabled for a
DataSet . |
void |
setXmlDataType(java.lang.String newType)
Configures the XML Schema data type for the buffer-field object.
|
void |
setXmlDataType(Text newType)
Configures the XML Schema data type for the buffer-field object.
|
void |
setXmlNodeName(java.lang.String name)
Sets the name of the XML element or attribute representing the target object (either a
DataSet ,
a TempTable , a TemporaryBuffer , or a temp-table BufferField ) name in an XML
document. |
void |
setXmlNodeName(Text name)
Sets the name of the XML element or attribute representing the target object (either a
DataSet ,
a TempTable , a TemporaryBuffer , or a temp-table BufferField ) name in an XML
document. |
void |
setXmlNodeType(java.lang.String newType)
Allows specifying how this object will be represented in XML and XML Schema.
|
void |
setXmlNodeType(Text newType)
Allows specifying how this object will be represented in XML and XML Schema.
|
java.lang.String |
tableDefinition()
Constructs and returns a string containing the P4GL schema definition of the table.
|
boolean |
validateAllBuffers()
Validate all buffers from this table, in the reverse order they were created.
|
logical |
writeJson(TargetData target)
Implementation of the WRITE-JSON method.
|
logical |
writeJson(TargetData target,
logical formatted)
Implementation of the WRITE-JSON method.
|
logical |
writeJson(TargetData target,
logical formatted,
character encoding)
Implementation of the WRITE-JSON method.
|
logical |
writeJson(TargetData target,
logical formatted,
character encoding,
logical omitInitialValues)
Implementation of the WRITE-JSON method.
|
logical |
writeJson(TargetData target,
logical formatted,
character encoding,
logical omitInitialValues,
logical omitOuterObject)
Implementation of the WRITE-JSON method.
|
logical |
writeJson(TargetData target,
logical formatted,
character encoding,
logical omitInitialValues,
logical omitOuterObject,
logical writeBeforeImage)
Implementation of the WRITE-JSON method.
|
logical |
writeXml(TargetData target)
Implementation of the WRITE-XML method.
|
logical |
writeXml(TargetData target,
logical formatted)
Implementation of the WRITE-XML method.
|
logical |
writeXml(TargetData target,
logical formatted,
character encoding)
Implementation of the WRITE-XML method.
|
logical |
writeXml(TargetData target,
logical formatted,
character encoding,
character schemaLocation)
Implementation of the WRITE-XML method.
|
logical |
writeXml(TargetData target,
logical formatted,
character encoding,
character schemaLocation,
logical writeXmlSchema)
Implementation of the WRITE-XML method.
|
logical |
writeXml(TargetData target,
logical formatted,
character encoding,
character schemaLocation,
logical writeXmlSchema,
logical minXmlSchema)
Implementation of the WRITE-XML method.
|
logical |
writeXml(TargetData target,
logical formatted,
character encoding,
character schemaLocation,
logical writeXmlSchema,
logical minXmlSchema,
logical writeBeforeImage)
Implementation of the WRITE-XML method.
|
logical |
writeXml(TargetData target,
logical formatted,
character encoding,
character schemaLocation,
logical writeXmlSchema,
logical minXmlSchema,
logical beforeImage,
logical noInitialVals)
Implementation of the WRITE-XML method.
|
logical |
writeXmlSchema(TargetData target)
Writes an XML representation of the definition of this
TempTable . |
logical |
writeXmlSchema(TargetData target,
logical formatted)
Writes an XML representation of the definition of this
TempTable . |
logical |
writeXmlSchema(TargetData target,
logical formatted,
Text encoding)
Writes an XML representation of the definition of this
TempTable . |
logical |
writeXmlSchema(TargetData target,
logical formatted,
Text encoding,
logical minXmlSchema)
Writes an XML representation of the definition of this
TempTable . |
logical |
writeXmlSchema(TargetData target,
logical formatted,
Text encoding,
logical minXmlSchema,
logical omitInitVal)
Writes an XML representation of the definition of this
TempTable . |
delete, firstResource, firstResource, getHead, getNextSibling, getNextSibling, getPrevSibling, getPrevSibling, getPrivateData, getTail, hasName, hasNameConstraints, hasNameReadOnly, hasNextSibling, hasParent, hasPrevSibling, hasPrivateData, interlink, isChained, lastResource, lastResource, moveInChain, name, name, name, readOnlyError, readOnlyError, setHead, setNextSibling, setNextSibling, setPrevSibling, setPrevSibling, setPrivateData, setPrivateData, setPrivateData, validateName
doDelete, getResourceType, id, id, implicitDeletion, incrementTrigger, instantiatingProcedure, invalidAttribute, processResource, registerResource, resourceDelete, setInstantiatingProcedure, toString, type, unableToAssignUnknown, unknown
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addFieldLike, addFieldLike, addFieldLike, addFieldLike, addFieldsFrom, addFieldsFrom, addFieldsFrom, addFieldsFrom, addFieldsFrom, addFieldsFrom, addFieldsFrom, addFieldsFrom, addFieldToIndex, addFieldToIndex, addFieldToIndex, addFieldToIndex, addFieldToIndex, addFieldToIndex, addFieldToIndex, addFieldToIndex, addFieldToIndex, addFieldToIndex, addFieldToIndex, addFieldToIndex, addIndexLike, addIndexLike, addIndexLike, addIndexLike, addNewField, addNewField, addNewField, addNewField, addNewField, addNewField, addNewIndex, addNewIndex, addNewIndex, addNewIndex, getCodePage, getCodePageSupplier, getDMOBufInterface, getDMOClass, getDMOInterface, getDmoMeta, setCodePage, setCodePageSupplier, tempTablePrepare, tempTablePrepare, tempTablePrepare, tempTablePrepare, tempTablePrepare, tempTablePrepare
defaultBufferHandle
getNextSibling, getPrevSibling, getPrivateData, setPrivateData, setPrivateData
getResourceType, readOnlyError, readOnlyError
id, id, unknown, valid
createLike, createLike, createLike, createLike, createLike, createLike, createLike
isDataSourceModified
dereference, dereference, dereference, dereference
_dynamic, dynamic
instantiatingProcedure
public static final int SM_DEFAULT
SCHEMA-MARSHAL
level. Encodes the unknown
value of the attribute. It is
semantically equivalent to SM_FULL
.public static final int SM_NONE
NONE
SCHEMA-MARSHAL
level. No attributes are marshaled.public static final int SM_MIN
MIN
SCHEMA-MARSHAL
level. The marshaled schema is minimized. At this level
the following data will still BE marshaled:
public static final int SM_FULL
MIN
SCHEMA-MARSHAL
level. The full schema is marshalled.protected static final java.lang.String DEFAULT_COPY_TEMP_TABLE_PREFIX
protected handle defaultBufferHandle
protected final character errorString
protected final logical error
protected final character admData
protected boolean undoable
true
if changes made to the records the temporary table can be undone.private java.lang.String xmlNodeName
TEMP-TABLE
.private java.lang.String namespaceURI
TEMP-TABLE
.private java.lang.String namespacePrefix
TEMP-TABLE
.private java.lang.String serializeName
SERIALIZE-NAME
attribute.private int schemaMarshal
SCHEMA-MARSHAL
attribute.
The following encoding is used internally: 0 = unknown, 1: NONE, 2: MIN, 3: FULL (see above, the SM_* static constants).
private boolean rejected
REJECTED
attribute: indicates whether a change to the
data of this DataSet
is rejected. The attribute is writable.private final java.util.Set<Buffer> allBuffers
private final integer uniqueId
private boolean trackingChanges
TRACKING-CHANGES
attribute.private TempTable originTable
ORIGIN-HANDLE
attribute.private final java.util.Set<TempTable> changesTables
protected TempTable.BeforeType beforeTableType
protected TempTable peerTable
private boolean dataSourceModified
DATA-SOURCE-MODIFIED
attribute.public AbstractTempTable(boolean dynamic)
dynamic
- Flag indicating if this is a static or a dynamic temp-table.public integer getUniqueID()
getUniqueID
in interface UniqueID
public logical copyTempTable(handle other)
copyTempTable
in interface TempTableDuplicator
other
- Some other temp-table to copy from.public logical copyTempTable(handle other, logical append)
copyTempTable
in interface TempTableDuplicator
other
- Some other temp-table to copy from.append
- Append mode.public logical copyTempTable(handle other, logical append, logical replace)
copyTempTable
in interface TempTableDuplicator
other
- Some other temp-table to copy from.append
- Append mode.replace
- Replace mode.public logical copyTempTable(handle other, logical append, logical replace, logical looseCopy)
copyTempTable
in interface TempTableDuplicator
other
- Some other temp-table to copy from.append
- Append mode.replace
- Replace mode.looseCopy
- Loose copy mode.public logical copyTempTable(handle other, boolean append)
copyTempTable
in interface TempTableDuplicator
other
- Some other temp-table to copy from.append
- Append mode.public logical copyTempTable(handle other, boolean append, boolean replace)
copyTempTable
in interface TempTableDuplicator
other
- Some other temp-table to copy from.append
- Append mode.replace
- Replace mode.public logical copyTempTable(handle other, boolean append, boolean replace, boolean looseCopy)
copyTempTable
in interface TempTableDuplicator
other
- Some other temp-table to copy from.append
- Append mode.replace
- Replace mode.looseCopy
- Loose copy mode.public logical copyTempTable(handle other, boolean append, boolean replace, boolean looseCopy, java.lang.String prefix)
copyTempTable
in interface TempTableDuplicator
other
- Some other temp-table to copy from.append
- Append mode.replace
- Replace mode.looseCopy
- Loose copy mode.prefix
- Prefix for naming the copied temp-table.public logical copyTempTable(handle other, logical append, logical replace, logical looseCopy, character prefix)
copyTempTable
in interface TempTableDuplicator
other
- Some other temp-table to copy from.append
- Append mode.replace
- Replace mode.looseCopy
- Loose copy mode.prefix
- Prefix for naming the copied temp-table.public BaseDataType dereference(java.lang.String memberName)
defaultBufferHandle
if not null. Otherwise, the table was not prepared
(for dynamic temp-tables).dereference
in interface Dereferenceable
memberName
- The name of the member to be extracted.defaultBufferHandle
.public <T extends BaseDataType> T dereference(java.lang.Class<T> type, java.lang.String memberName)
defaultBufferHandle
if not null. Otherwise, the table was not prepared
(for dynamic temp-tables).dereference
in interface Dereferenceable
type
- The expected type of the returned value.memberName
- The name of the member to be extracted.defaultBufferHandle
.public void dereference(java.lang.String memberName, java.lang.Object value)
defaultBufferHandle
if not null. Otherwise, the table was not prepared
(for dynamic temp-tables) and the uninitialized error should be displayed.dereference
in interface Dereferenceable
memberName
- The name of the member to be extracted.value
- The new value that will be assigned to the extracted field.public logical prepared()
true
if this temp-table is in prepared state (after a successful call
to TempTable.tempTablePrepare(java.lang.String)
).
This method implements the read-only PREPARED attribute from 4GL.public void changeErrorString(character errStr)
changeErrorString
in interface ErrorString
errStr
- The new value for the ERROR-STRING attribute.public character errorString()
errorString
in interface ErrorString
public character getADMData()
getADMData
in interface ADMData
public void setADMData(java.lang.String value)
setADMData
in interface ADMData
value
- The new value.public void setADMData(character value)
setADMData
in interface ADMData
value
- The new value.public logical error()
public void error(boolean value)
public void error(logical value)
public void setCanUndo(logical undo)
setCanUndo
in interface TempTable
undo
- The new value for the attribute.public logical canUndo()
public logical hasRecords()
hasRecords
in interface TempTable
public final boolean isUndoable()
isUndoable
in interface UndoStateProvider
public logical deleteAll()
TempTable
.deleteAll
in interface EmptyTempTable
true
if the delete was possible.ErrorConditionException
- If an error occurs performing the bulk delete operation.public int getSchemaMarshalLevel()
SCHEMA-MARSHAL
level. Refer to SM_DEFAULT
, SM_NONE
,
SM_MIN
, and SM_FULL
static constants for details.SCHEMA-MARSHAL
level.public logical isNoSchemaMarshal()
NO-SCHEMA-MARSHAL
attribute getter.isNoSchemaMarshal
in interface TempTable
true
when SCHEMA-MARSHAL
attribute is set to "NONE"
.public void setNoSchemaMarshal(boolean on)
SCHEMA-MARSHAL
attribute to "NO"
value when on = true
or
back to default value on = false
.setNoSchemaMarshal
in interface TempTable
on
- The new value of SCHEMA-MARSHAL
attribute.public void setNoSchemaMarshal(logical on)
SCHEMA-MARSHAL
attribute to "NO"
value when on = true
or
back to default value on = false
.setNoSchemaMarshal
in interface TempTable
on
- The new value of SCHEMA-MARSHAL
attribute.public logical isMinSchemaMarshal()
MIN-SCHEMA-MARSHAL
attribute getter.isMinSchemaMarshal
in interface TempTable
true
when SCHEMA-MARSHAL
attribute is set to "MIN"
.public void setMinSchemaMarshal(boolean on)
SCHEMA-MARSHAL
attribute to "MIN"
value when on = true
or
back to default value on = false
.setMinSchemaMarshal
in interface TempTable
on
- The new value of SCHEMA-MARSHAL
attribute.public void setMinSchemaMarshal(logical on)
SCHEMA-MARSHAL
attribute to "MIN"
value when on = true
or
back to default value on = false
.setMinSchemaMarshal
in interface TempTable
on
- The new value of SCHEMA-MARSHAL
attribute.public character getSchemaMarshal()
SCHEMA-MARSHAL
attribute.getSchemaMarshal
in interface TempTable
SCHEMA-MARSHAL
attribute.public void setSchemaMarshal(java.lang.String level)
SCHEMA-MARSHAL
attribute.setSchemaMarshal
in interface TempTable
level
- the new value or SCHEMA-MARSHAL
attribute.public void setSchemaMarshal(Text level)
SCHEMA-MARSHAL
attribute.setSchemaMarshal
in interface TempTable
level
- the new value or SCHEMA-MARSHAL
attribute.public logical isTrackingChanges()
DataSet
.isTrackingChanges
in interface TempTable
TRACKING-CHANGES
as described above.public logical rejected()
rejected
in interface Rejectable
public void rejected(boolean value)
rejected
in interface Rejectable
value
- The new value of REJECTED attribute.public void rejected(logical value)
rejected
in interface Rejectable
value
- The new value of REJECTED attribute.public void setTrackingChanges(logical val)
DataSet
.setTrackingChanges
in interface TempTable
val
- The new value for TRACKING-CHANGES
attribute.public void setTrackingChanges(boolean on)
DataSet
.setTrackingChanges
in interface TempTable
on
- The new value for TRACKING-CHANGES
attribute.public handle getBeforeTable()
getBeforeTable
in interface TempTable
BEFORE-TABLE
as described above.public handle getAfterTable()
getAfterTable
in interface TempTable
AFTER-TABLE
as described above.public handle getOriginHandle()
DataSet
object that
corresponds to the TEMP-TABLE currently associated with this TEMP-TABLE handle.getOriginHandle
in interface TempTable
ORIGIN-HANDLE
attribute.public logical readXml(SourceData source, character readMode, character schemaLocation, logical overrideDefaultMapping)
Defaults applied:
readXml
in interface XmlData
source
- Data source.readMode
- Mode in which data is read into buffer. Must evaluate to APPEND
,
EMPTY
, MERGE
, or REPLACE
.schemaLocation
- Name of an external XML schema file, or empty string or unknown value to use the
xsi:noNamespaceSchemaLocation
value set in the XML data, if any.overrideDefaultMapping
- true
to override the default string-to-binary data type mappings when
creating a temp-table schema from an XML schema.true
if the operation completed successfully, else false
.public logical readXml(SourceData source, character readMode, character schemaLocation, logical overrideDefaultMapping, character fieldTypeMapping)
readXml
in interface XmlData
source
- Data source.readMode
- Mode in which data is read into buffer. Must evaluate to APPEND
, EMPTY
, MERGE
, or REPLACE
.schemaLocation
- Name of an external XML schema file, or empty string or unknown value to use the
xsi:noNamespaceSchemaLocation
value set in the XML data, if any.overrideDefaultMapping
- True
to override the default string-to-binary data type mappings when
creating a temp-table schema from an XML schema.fieldTypeMapping
- Comma-delimited list of field name and data type name pairs to use to override
data type mappings of specific fields. Specify unknown value to use default
mappings.True
if the operation completed successfully, else false
.public logical readXml(SourceData source, character readMode, character schemaLocation, logical overrideDefaultMapping, character fieldTypeMapping, character verifySchemaMode)
readXml
in interface XmlData
source
- Data source.readMode
- Mode in which data is read into buffer. Must evaluate to APPEND
, EMPTY
, MERGE
, or REPLACE
.schemaLocation
- Name of an external XML schema file, or empty string or unknown value to use the
xsi:noNamespaceSchemaLocation
value set in the XML data, if any.overrideDefaultMapping
- True
to override the default string-to-binary data type mappings when
creating a temp-table schema from an XML schema.fieldTypeMapping
- Comma-delimited list of field name and data type name pairs to use to override
data type mappings of specific fields. Specify unknown value to use default
mappings.verifySchemaMode
- Schema verification mode. Must evaluate to IGNORE
, LOOSE
, or
STRICT
. Default is LOOSE
.True
if the operation completed successfully, else false
.public logical writeXml(TargetData target)
Defaults applied:
public logical writeXml(TargetData target, logical formatted)
Defaults applied:
public logical writeXml(TargetData target, logical formatted, character encoding)
Defaults applied:
writeXml
in interface XmlData
target
- Data target.formatted
- True
to format the XML to make it more readable; false
to write it
as unformatted text. Unknown value is treated as false
.encoding
- Name of the character encoding to use.True
if the operation completed successfully, else false
.public logical writeXml(TargetData target, logical formatted, character encoding, character schemaLocation)
Defaults applied:
writeXml
in interface XmlData
target
- Data target.formatted
- True
to format the XML to make it more readable; false
to write it
as unformatted text. Unknown value is treated as false
.encoding
- Name of the character encoding to use.schemaLocation
- Name of an external XML schema file, or empty string or unknown value to set the
xsi:noNamespaceSchemaLocation
to empty string or unknown value.True
if the operation completed successfully, else false
.public logical writeXml(TargetData target, logical formatted, character encoding, character schemaLocation, logical writeXmlSchema)
Defaults applied:
writeXml
in interface XmlData
target
- Data target.formatted
- True
to format the XML to make it more readable; false
to write it
as unformatted text. Unknown value is treated as false
.encoding
- Name of the character encoding to use.schemaLocation
- Name of an external XML schema file, or empty string or unknown value to set the
xsi:noNamespaceSchemaLocation
to empty string or unknown value.writeXmlSchema
- True
to write XML schema information, else false
.True
if the operation completed successfully, else false
.public logical writeXml(TargetData target, logical formatted, character encoding, character schemaLocation, logical writeXmlSchema, logical minXmlSchema)
Defaults applied:
writeXml
in interface XmlData
target
- Data target.formatted
- True
to format the XML to make it more readable; false
to write it
as unformatted text. Unknown value is treated as false
.encoding
- Name of the character encoding to use.schemaLocation
- Name of an external XML schema file, or empty string or unknown value to set the
xsi:noNamespaceSchemaLocation
to empty string or unknown value.writeXmlSchema
- True
to write XML schema information, else false
.minXmlSchema
- True
to write minimal XML schema information, else false
. Must be
false
if writeXmlSchema
is false
.True
if the operation completed successfully, else false
.public logical writeXml(TargetData target, logical formatted, character encoding, character schemaLocation, logical writeXmlSchema, logical minXmlSchema, logical writeBeforeImage)
Defaults applied:
writeXml
in interface XmlData
target
- Data target.formatted
- True
to format the XML to make it more readable; false
to write it
as unformatted text. Unknown value is treated as false
.encoding
- Name of the character encoding to use.schemaLocation
- Name of an external XML schema file, or empty string or unknown value to set the
xsi:noNamespaceSchemaLocation
to empty string or unknown value.writeXmlSchema
- True
to write XML schema information, else false
.minXmlSchema
- True
to write minimal XML schema information, else false
. Must be
false
if writeXmlSchema
is false
.writeBeforeImage
- True
to write before-image data and error information, else false
.True
if the operation completed successfully, else false
.public logical writeXml(TargetData target, logical formatted, character encoding, character schemaLocation, logical writeXmlSchema, logical minXmlSchema, logical beforeImage, logical noInitialVals)
writeXml
in interface XmlData
target
- Data target.formatted
- True
to format the XML to make it more readable; false
to write it
as unformatted text. Unknown value is treated as false
.encoding
- Name of the character encoding to use.schemaLocation
- Name of an external XML schema file, or empty string or unknown value to set the
xsi:noNamespaceSchemaLocation
to empty string or unknown value.writeXmlSchema
- True
to write XML schema information, else false
.minXmlSchema
- True
to write minimal XML schema information, else false
. Must be
false
if writeXmlSchema
is false
.beforeImage
- True
to write before-image data and error information, else false
.noInitialVals
- True
to omit data for fields whose values match their initial values.True
if the operation completed successfully, else false
.public logical writeXmlSchema(TargetData target)
TempTable
.writeXmlSchema
in interface XmlData
target
- Data target.true
if operation is successful.public logical writeXmlSchema(TargetData target, logical formatted)
TempTable
.writeXmlSchema
in interface XmlData
target
- Data target.formatted
- Use true
for a more human-readable document.true
if operation is successful.public logical writeXmlSchema(TargetData target, logical formatted, Text encoding)
TempTable
.writeXmlSchema
in interface XmlData
target
- Data target.formatted
- Use true
for a more human-readable document.encoding
- The character encoding. The default is UTF-8.true
if operation is successful.public logical writeXmlSchema(TargetData target, logical formatted, Text encoding, logical minXmlSchema)
TempTable
.writeXmlSchema
in interface XmlData
target
- Data target.formatted
- Use true
for a more human-readable document.encoding
- The character encoding. The default is UTF-8.minXmlSchema
- If true
, the minimum amount of schema for the object will be written.true
if operation is successful.public logical writeXmlSchema(TargetData target, logical formatted, Text encoding, logical minXmlSchema, logical omitInitVal)
TempTable
.writeXmlSchema
in interface XmlData
target
- Data target.formatted
- Use true
for a more human-readable document.encoding
- The character encoding. The default is UTF-8.minXmlSchema
- If true
, the minimum amount of schema for the object will be written.omitInitVal
- Use true
to omit the initial values.true
if operation is successful.public logical readXmlSchema(SourceData source, logical override)
TempTable
or TempTable
or verify existing schema in a TempTable
,
TempTable
or temp-table Buffer
object.readXmlSchema
in interface XmlData
source
- Data source.override
- If true
the default mapping between XML Schema string and binary data types
and ABL data types when creating an ABL temp-table schema from an XML Schema will
be overwritten.true
if operation is successful.public logical readXmlSchema(SourceData source, logical override, Text mapping)
TempTable
or TempTable
or verify existing schema in a TempTable
,
TempTable
or temp-table Buffer
object.readXmlSchema
in interface XmlData
source
- Data source.override
- If true
the default mapping between XML Schema string and binary data types
and ABL data types when creating an ABL temp-table schema from an XML Schema will
be overwritten.mapping
- A comma-delimited list of field name, data type pairs. This allows to specify the
data type for a specific field.true
if operation is successful.public logical readXmlSchema(SourceData source, logical override, Text strMapping, Text verifyMode)
TempTable
or TempTable
or verify existing schema in a TempTable
,
TempTable
or temp-table Buffer
object.readXmlSchema
in interface XmlData
source
- Data source.override
- If true
the default mapping between XML Schema string and binary data types
and ABL data types when creating an ABL temp-table schema from an XML Schema will
be overwritten.strMapping
- A comma-delimited list of field name, data type pairs. This allows to specify the
data type for a specific field.verifyMode
- Specifies how the XML will be verified against the schema. Valid values: "LOOSE" or
"STRICT".true
if operation is successful.public logical readJson(SourceData source)
Defaults applied:
MERGE
read modepublic logical readJson(SourceData source, character readMode)
public logical writeJson(TargetData target)
Defaults applied:
target
represents a JsonArray
object.
public logical writeJson(TargetData target, logical formatted)
Defaults applied:
target
represents a JsonArray
object.
public logical writeJson(TargetData target, logical formatted, character encoding)
Defaults applied:
target
represents a JsonArray
object.
writeJson
in interface JsonData
target
- Data target.formatted
- True
to format the JSON to make it more readable; false
to write it
as unformatted text. Unknown value is treated as false
.encoding
- Name of the character encoding to use.True
if the operation completed successfully, else false
.public logical writeJson(TargetData target, logical formatted, character encoding, logical omitInitialValues)
Defaults applied:
target
represents a JsonArray
object.
writeJson
in interface JsonData
target
- Data target.formatted
- True
to format the JSON to make it more readable; false
to write it
as unformatted text. Unknown value is treated as false
.encoding
- Name of the character encoding to use.omitInitialValues
- True
to omit data for fields whose values match their initial values.True
if the operation completed successfully, else false
.public logical writeJson(TargetData target, logical formatted, character encoding, logical omitInitialValues, logical omitOuterObject)
Defaults applied:
writeJson
in interface JsonData
target
- Data target.formatted
- True
to format the JSON to make it more readable; false
to write it
as unformatted text. Unknown value is treated as false
.encoding
- Name of the character encoding to use.omitInitialValues
- True
to omit data for fields whose values match their initial values.omitOuterObject
- True
to omit data for the outermost object from the output.True
if the operation completed successfully, else false
.public logical writeJson(TargetData target, logical formatted, character encoding, logical omitInitialValues, logical omitOuterObject, logical writeBeforeImage)
writeJson
in interface JsonData
target
- Data target.formatted
- True
to format the JSON to make it more readable; false
to write it
as unformatted text. Unknown value is treated as false
.encoding
- Name of the character encoding to use.omitInitialValues
- True
to omit data for fields whose values match their initial values.omitOuterObject
- True
to omit data for the outermost object from the output.writeBeforeImage
- True
to write before-image data and error information, else false
.True
if the operation completed successfully, else false
.public character getXmlNodeName()
TEMP-TABLE
)
name in an XML document. If not set the name
is returned.getXmlNodeName
in interface XmlNode
public void setXmlNodeName(java.lang.String name)
DataSet
,
a TempTable
, a TemporaryBuffer
, or a temp-table BufferField
) name in an XML
document.setXmlNodeName
in interface XmlNode
name
- The new name of the XML element for this object.public void setXmlNodeName(Text name)
DataSet
,
a TempTable
, a TemporaryBuffer
, or a temp-table BufferField
) name in an XML
document.setXmlNodeName
in interface XmlNode
name
- The new name of the XML element for this object.public character getXmlDataType()
getXmlDataType
in interface XmlNode
public void setXmlDataType(java.lang.String newType)
setXmlDataType
in interface XmlNode
newType
- the new XML Schema data type for the buffer-field object.public void setXmlDataType(Text newType)
setXmlDataType
in interface XmlNode
newType
- the new XML Schema data type for the buffer-field object.public character getXmlNodeType()
XML-NODE-TYPE
ABL
attribute.getXmlNodeType
in interface XmlNode
public void setXmlNodeType(java.lang.String newType)
XML-NODE-TYPE
ABL
attribute.setXmlNodeType
in interface XmlNode
newType
- The new type.public void setXmlNodeType(Text newType)
XML-NODE-TYPE
ABL
attribute.setXmlNodeType
in interface XmlNode
newType
- The new type.public character namespaceURI()
namespaceURI
in interface NamespaceURI
public void namespaceURI(java.lang.String uri)
namespaceURI
in interface NamespaceURI
uri
- The new value of the NAMESPACE-URI attribute.public void namespaceURI(character uri)
namespaceURI
in interface NamespaceURI
uri
- The new value of the NAMESPACE-URI attribute.public character namespacePrefix()
namespacePrefix
in interface NamespaceURI
public void namespacePrefix(java.lang.String prefix)
namespacePrefix
in interface NamespaceURI
prefix
- The new value of the NAMESPACE-PREFIX attribute.public void namespacePrefix(character prefix)
namespacePrefix
in interface NamespaceURI
prefix
- The new value of the NAMESPACE-PREFIX attribute.public logical isDataSourceModified()
isDataSourceModified
in interface DataSourceModifiable
true
when the data has been modified.public void setDataSourceModified(logical mod)
setDataSourceModified
in interface DataSourceModifiable
mod
- true
when the data is marked as modified and false
otherwise.public void setDataSourceModified(boolean mod)
setDataSourceModified
in interface DataSourceModifiable
mod
- true
when the data is marked as modified and false
otherwise.public character getSerializeName()
SERIALIZE-NAME
attribute.getSerializeName
in interface NamedSerializable
SERIALIZE-NAME
attribute.public void setSerializeName(Text sName)
SERIALIZE-NAME
attribute.setSerializeName
in interface NamedSerializable
sName
- the new value for the SERIALIZE-NAME
attribute.public void setSerializeName(java.lang.String sName)
SERIALIZE-NAME
attribute.setSerializeName
in interface NamedSerializable
sName
- the new value for the SERIALIZE-NAME
attribute.public java.lang.String tableDefinition()
public boolean validateAllBuffers()
true
on success.ErrorConditionException
- If any of the buffer fails validation.void registerBuffer(Buffer buf)
buf
- The buffer to be registered. Must not be null
.void deregisterBuffer(Buffer buf)
buf
- The buffer to be deregistered. Must not be null
.TemporaryBuffer defaultBuffer()
protected abstract boolean addFunctionWasCalled()
true
if an ADD-* function was called for the table.protected void deleteAllBuffers()
protected boolean _hasRecords()
hasRecords
. Checks whether this temp-table contains any records.protected void displayCreateLikeNotFirst()
protected void displayPrepared()
protected void displayPreparedIgnoring()
protected void displayUnableAssignUnknownUndo()
protected void displayCannotClear()
protected void displayNotPrepared()
protected void displayUninitialized()
protected void displayUnableCreateLike()
protected void displayUnableAddFieldsFrom()
protected void displayCouldNotFindLikeTableFromHandle()
protected void displayCopyTempTableInvalidFirstArg()
protected void displayCopyTempTableHalfDefined()
protected RecordBuffer getRecordBufferByHandle(handle hbuf, AbstractTempTable.CallingFunction callingFunction)
hbuf
- Buffer or temp-table handle.callingFunction
- Calling function. Affects error messaging.null
if the case of error.public abstract boolean _prepared()
true
if this temp-table is in prepared state (after a successful call to
TempTable.tempTablePrepare(java.lang.String)
).
This method implements the read-only PREPARED getter attribute from 4GL.true
if table is in PREPARED state.public abstract boolean _clear()
This method is FWD-internal. The programmer can check whether the temp-table is in an UNPREPARED or PREPARED state by checking the PREPARED attribute, but the CLEAR state is transparent.
true
if this table is in CLEAR state.void setOriginTable(TempTable origin)
GET-CHANGES method
).origin
- The origin table.private TempTable.BeforeType computeTableType()
AFTER_TABLE
or a BEFORE_TABLE
the peer (complementary) buffer is also stored in peerTable
.beforeTableType
).void deleteAllImpl()
TempTable
.ErrorConditionException
- If an error occurs performing the bulk delete operation.