public class clob extends longchar
BaseDataType.Type, BaseDataType.WrapperHandler| Modifier and Type | Field and Description |
|---|---|
private boolean |
customCP
Flags this field if it was constructed with a custom CODEPAGE specified in the field definition.
|
private java.lang.String |
fieldName
The field name used with current field reference.
|
private FieldReference |
fRef
The parent buffer field where this object was obtained by dereferenciation, if this is the case.
|
private java.sql.Clob |
sqlClob
SQL CLOB object
|
| Constructor and Description |
|---|
clob()
Default constructor.
|
clob(BaseDataType value)
Constructor which initializes an instance from the given data.
|
clob(character value)
Constructor which initializes an instance from the given data.
|
clob(clob value)
Copy constructor.
|
clob(java.sql.Clob sqlClob)
Constructor which is initialized from a database record.
|
clob(longchar value)
Constructor which initializes an instance from the given data.
|
clob(java.lang.String value)
Constructor which initializes an instance from the given data.
|
clob(java.lang.String value,
java.lang.String codepage)
Constructor which initializes an instance from the given data.
|
| Modifier and Type | Method and Description |
|---|---|
void |
assign(longchar value)
Assigns the value represented by
value to this object. |
void |
assign(Text value)
Assigns the value represented by
value to this object. |
clob |
duplicate()
Does the same as standard
clone() method but returns an
instance of BaseDataType and doesn't throw the
CloneNotSupportedException. |
java.lang.String |
getFieldName()
Gets the filed name associated with current
FieldReference reference, if any. |
FieldReference |
getFieldReference()
Obtain the
FieldReference reference, if any. |
BaseDataType.Type |
getType()
Get the type.
|
BaseDataType |
instantiateDefault()
Creates a new instance of the same type that represents the default initialized value.
|
BaseDataType |
instantiateUnknown()
Creates a new instance of the same type that represents the
unknown value. |
boolean |
isCodePageFixed()
Return the value codepage fixed status.
|
static logical |
isColumnCodepage(BaseDataType value)
Implementation of
IS-COLUMN-CODEPAGE ABL function. |
void |
readData()
Read data from the SQL CLOB used to initialize this object.
|
void |
readExternal(java.io.ObjectInput in)
Replacement for the default object reading method.
|
void |
setFieldReference(FieldReference fr)
Sets the
FieldReference reference. |
java.lang.String |
toStringExport()
Creates a string representation of the instance data using the 'export'
format.
|
void |
write(boolean overlay,
java.lang.String data,
int offset,
boolean trim)
Write the given character data into the data managed by this object, overwriting the data
that are at the given location, if any.
|
void |
writeExternal(java.io.ObjectOutput out)
Replacement for the default object writing method.
|
_getCodePage, asByteArray, compareTo, defaultFormatString, fixCodePage, fixCodePage, fixCodePage, fixCodePage, fixCodePage, fixCodePage, fixCodePage, forceCharacterType, getCodePage, getCodePage, getCodePage, getSize, instantiateDefaultExtent, isCharacterData, isCodePageFixed, isEmbeddedNullAllowed, isIncompatibleTypesOnConversion, lengthInt, lengthOf, setOverrideLength, toString, toStringMessageassign, assign, assign, assign, assign, caseSensitiveHashCode, deepAssign, equalsCaseSensitively, getValue, hashCode, isCaseSensitive, isUnknown, javaSpacifyNull, javaTruncateNull, maximum, minimum, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, overlay, progressSpacifyNull, readChar, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replace, replaceEntry, replaceEntry, replaceEntry, replaceEntry, replaceEntry, replaceEntry, replaceEntry, replaceEntry, replaceEntry, replaceEntry, replaceEntry, replaceEntry, replaceEntry, setCaseSensitive, setCaseSensitive, setTemporaryCaseSensitive, setUnknown, setValue, toJavaTypeassign, assign, calcFormatLength, createProxy, createProxy, deepCopy, elementsOfType, equals, fallback, formatLength, fromTypeName, generateDefault, generateUnknown, getAssigner, getTypeName, incompatibleTypesOnConversion, initialize, initializeDefaultExtent, invalidInitializer, isAllKnown, isAllKnown, isAssignDirect, isProxy, isUnknownValue, maximum, minimum, notUnknownValue, sameType, val, variablechanged, checkUndoable, checkUndoable, checkUndoable, getTransLevel, isGlobal, isUndoable, markUndoable, popBlock, rollback, setGlobalclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitbinaryEquals, isUnknown, readBytes, readChars, writeprivate java.sql.Clob sqlClob
private FieldReference fRef
private boolean customCP
private java.lang.String fieldName
public clob()
public clob(clob value)
value - Clob to be copied.public clob(java.sql.Clob sqlClob)
throws java.sql.SQLException
sqlClob - SQL CLOB from which data is read.java.sql.SQLException - if there is an error reading data.public clob(java.lang.String value)
value - Data.public clob(java.lang.String value,
java.lang.String codepage)
value - Data.codepage - The codepage.public clob(character value)
value - Data.public clob(longchar value)
value - Data.public clob(BaseDataType value)
value - Data.public BaseDataType.Type getType()
public void readData()
throws java.sql.SQLException
java.sql.SQLException - if there is an error reading data.public boolean isCodePageFixed()
isCodePageFixed in class longchartrue. The codepage for clob-s cannot be changed.public static logical isColumnCodepage(BaseDataType value)
IS-COLUMN-CODEPAGE ABL function.value - The data to be tested.YES only when value is a CLOB field defined with
IS-COLUMN-CODEPAGE attribute.public clob duplicate()
longcharclone() method but returns an
instance of BaseDataType and doesn't throw the
CloneNotSupportedException.duplicate in class longcharThis class is not undoable, so return a reference to this object.public BaseDataType instantiateUnknown()
unknown value.instantiateUnknown in class longcharunknown value.public BaseDataType instantiateDefault()
instantiateDefault in class longcharpublic void write(boolean overlay,
java.lang.String data,
int offset,
boolean trim)
This implementation:
trim option (i.e., any existing characters beyond the end of the
write are left in place if trim is false or truncated if trim
is true);write in interface LargeObjectwrite in class longcharoverlay - Flag indicating if the OVERLAY option is used.data - Data to be assigned to this object.offset - Offset position (in characters) in the target large object.trim - true to truncate any remaining data in the target large object; false to leave remaining data alone. Ignored.public void setFieldReference(FieldReference fr)
FieldReference reference. This is only used when the object is obtained by a
dereferenciation (::) operation.fr - The source of this LOB.public FieldReference getFieldReference()
FieldReference reference, if any.FieldReference from which this LOB was obtained by dereferenciation.public java.lang.String getFieldName()
FieldReference reference, if any.public void writeExternal(java.io.ObjectOutput out)
throws java.io.IOException
writeExternal in interface java.io.ExternalizablewriteExternal in class Textout - The output destination to which fields will be saved.java.io.IOException - In case of I/O errors.public void readExternal(java.io.ObjectInput in)
throws java.io.IOException,
java.lang.ClassNotFoundException
readExternal in interface java.io.ExternalizablereadExternal in class Textin - The input source from which fields will be restored.java.io.IOException - In case of I/O errors.java.lang.ClassNotFoundException - If payload can't be instantiated.public void assign(Text value)
value to this object. If needed (the source value has
a different codepage), a codepage conversion is performed.public void assign(longchar value)
value to this object. Since all clob fields have a
fixed codepage, a codepage conversion will occur.public java.lang.String toStringExport()
unknown value, a '?' will be returned. Any instances of
double quotes inside the string will be doubled up on output.toStringExport in class longchar