Top Fields Constructors Methods
com.amazon.ion.impl.lite

pack-priv final Class IonClobLite

extends IonLobLite
implements IonClob
Class Inheritance
All Implemented Interfaces
com.amazon.ion.IonClob, com.amazon.ion.IonLob, com.amazon.ion.IonValue, java.lang.Cloneable
Imports
com.amazon.ion.IonClob, .IonType, .IonWriter, .ValueVisitor, com.amazon.ion.impl._Private_Utils, java.io.IOException, .InputStream, .InputStreamReader, .Reader, java.nio.charset.Charset

Field Summary

Modifier and TypeField and Description
private static final int

Constructor Summary

AccessConstructor and Description
pack-priv
IonClobLite(ContainerlessContext context, boolean isNull)

Constructs a null.clob element.

pack-priv
IonClobLite(IonClobLite existing, IonContext context)

Method Summary

Modifier and TypeMethod and Description
public void
accept(ValueVisitor
will have one of its visit methods called.
visitor
)

Implements abstract com.amazon.ion.impl.lite.IonValueLite.accept.

Implements com.amazon.ion.IonValue.accept.

Entry point for visitor pattern.

public IonClobLite
clone()

Implements abstract com.amazon.ion.impl.lite.IonLobLite.clone.

Implements com.amazon.ion.IonClob.clone, com.amazon.ion.IonLob.clone, com.amazon.ion.IonValue.clone.

Creates a copy of this value and all of its children.

public IonType
pack-priv int
public Reader
newReader(Charset
must not be null.
cs
)

Implements com.amazon.ion.IonClob.newReader.

Creates a new Reader that provides the value of this clob as text, decoding the raw bytes using a given character set.

pack-priv int
scalarHashCode()

Implements abstract com.amazon.ion.impl.lite.IonValueLite.scalarHashCode.

Internal HashCode implementation to be overridden by scalar subclasses.

pack-priv IonValueLite
shallowClone(IonContext
the context applicable to the value's parent.
context
)

Implements abstract com.amazon.ion.impl.lite.IonValueLite.shallowClone.

Clones the value's annotations and field name (if any).

public String
stringValue(Charset
must not be null.
cs
)

Implements com.amazon.ion.IonClob.stringValue.

Gets the value of this clob as a Java String value, decoding the raw bytes using a given character set.

pack-priv final void
writeBodyTo(IonWriter
an IonWriter.
writer
,
_Private_IonValue.SymbolTableProvider
a SymbolTableProvider.
symbolTableProvider
)

Implements abstract com.amazon.ion.impl.lite.IonValueLite.writeBodyTo.

Writes a *non-null scalar* value to the given writer.

Inherited from com.amazon.ion.impl.lite.IonLobLite:
byteSizecopyBytesFromgetBytesgetBytesNoCopylobHashCodenewInputStreamsetBytessetBytes

Field Detail

HASH_SIGNATUREback to summary
private static final int HASH_SIGNATURE

Constructor Detail

IonClobLiteback to summary
pack-priv IonClobLite(ContainerlessContext context, boolean isNull)

Constructs a null.clob element.

IonClobLiteback to summary
pack-priv IonClobLite(IonClobLite existing, IonContext context)

Method Detail

acceptback to summary
public void accept(ValueVisitor visitor) throws Exception

Implements abstract com.amazon.ion.impl.lite.IonValueLite.accept.

Implements com.amazon.ion.IonValue.accept.

Doc from com.amazon.ion.IonValue.accept.

Entry point for visitor pattern. Implementations of this method by concrete classes will simply call the appropriate visit method on the visitor. For example, instances of IonBool will invoke ValueVisitor#visit(IonBool).

Parameters
visitor:ValueVisitor

will have one of its visit methods called.

Annotations
@Override
Exceptions
Exception:
any exception thrown by the visitor is propagated.
cloneback to summary
public IonClobLite clone()

Implements abstract com.amazon.ion.impl.lite.IonLobLite.clone.

Implements com.amazon.ion.IonClob.clone, com.amazon.ion.IonLob.clone, com.amazon.ion.IonValue.clone.

Doc from com.amazon.ion.IonValue.clone.

Creates a copy of this value and all of its children. The cloned value may use the same shared symbol tables, but it will have an independent local symbol table if necessary. The cloned value will be modifiable regardless of whether this instance isReadOnly().

The cloned value will be created in the context of the same ValueFactory as this instance; if you want a copy using a different factory, then use ValueFactory#clone(IonValue) instead.

Returns:IonClobLite

Doc from java.lang.Object.clone.

a clone of this instance.

Annotations
@Override
getTypeSlowback to summary
public IonType getTypeSlow()

Implements abstract com.amazon.ion.impl.lite.IonValueLite.getTypeSlow.

Returns:IonType

Doc from com.amazon.ion.impl.lite.IonValueLite.getTypeSlow.

the value's type.

Annotations
@Override
hashSignatureback to summary
pack-priv int hashSignature()

Implements abstract com.amazon.ion.impl.lite.IonValueLite.hashSignature.

Returns:int

Doc from com.amazon.ion.impl.lite.IonValueLite.hashSignature.

the constant hash signature unique to the value's type.

Annotations
@Override
newReaderback to summary
public Reader newReader(Charset cs)

Implements com.amazon.ion.IonClob.newReader.

Doc from com.amazon.ion.IonClob.newReader.

Creates a new Reader that provides the value of this clob as text, decoding the raw bytes using a given character set.

Parameters
cs:Charset

must not be null.

Returns:Reader

a new reader positioned at the start of the clob, or null if this.isNullValue().

scalarHashCodeback to summary
pack-priv int scalarHashCode()

Implements abstract com.amazon.ion.impl.lite.IonValueLite.scalarHashCode.

Doc from com.amazon.ion.impl.lite.IonValueLite.scalarHashCode.

Internal HashCode implementation to be overridden by scalar subclasses. Must only be called on non-null values.

Annotations
@Override
shallowCloneback to summary
pack-priv IonValueLite shallowClone(IonContext context)

Implements abstract com.amazon.ion.impl.lite.IonValueLite.shallowClone.

Doc from com.amazon.ion.impl.lite.IonValueLite.shallowClone.

Clones the value's annotations and field name (if any). For scalars, also clones the value. For containers, leaves the cloned container empty rather than cloning the children.

Parameters
context:IonContext

the context applicable to the value's parent.

Returns:IonValueLite

a shallow clone of this value.

Annotations
@Override
stringValueback to summary
public String stringValue(Charset cs)

Implements com.amazon.ion.IonClob.stringValue.

Doc from com.amazon.ion.IonClob.stringValue.

Gets the value of this clob as a Java String value, decoding the raw bytes using a given character set. This is a convenience wrapper around newReader(Charset).

The behavior of this method when the clob bytes are not valid in the given charset is unspecified.

Parameters
cs:Charset

must not be null.

Returns:String

the decoded text, or null if this.isNullValue().

writeBodyToback to summary
pack-priv final void writeBodyTo(IonWriter writer, _Private_IonValue.SymbolTableProvider symbolTableProvider) throws IOException

Implements abstract com.amazon.ion.impl.lite.IonValueLite.writeBodyTo.

Doc from com.amazon.ion.impl.lite.IonValueLite.writeBodyTo.

Writes a *non-null scalar* value to the given writer. It is incorrect to call this method on a container value.

Parameters
writer:IonWriter

an IonWriter.

symbolTableProvider:_Private_IonValue.SymbolTableProvider

a SymbolTableProvider.

Annotations
@Override
Exceptions
IOException:
if thrown when writing the value.