public abstract class AbstractLongConverter extends Object implements LongConverter
LongConverter interface.
This class delegates the core conversion operations to an encapsulated LongConverter instance.
Subclasses can build upon this base while retaining or customizing the behavior of the underlying converter.
| Modifier and Type | Field and Description |
|---|---|
protected LongConverter |
converter
Encapsulated instance of
LongConverter that provides core conversion logic. |
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractLongConverter(LongConverter converter)
Constructs an
AbstractLongConverter with a specified converter. |
protected |
AbstractLongConverter(String chars)
Constructs an
AbstractLongConverter using a given set of characters. |
| Modifier and Type | Method and Description |
|---|---|
void |
append(net.openhft.chronicle.bytes.Bytes<?> bytes,
long value)
Appends the provided long value to the provided
Bytes<?> text. |
void |
append(StringBuilder text,
long value)
Appends the provided long value to the provided
StringBuilder text. |
int |
maxParseLength()
Retrieves the maximum number of characters that can be parsed by the underlying converter.
|
long |
parse(CharSequence text)
Parses the provided text using the underlying converter.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddEncode, allSafeChars, asString, asText, asText, forSymbols, lengthCheck, maxParseLengthprotected final LongConverter converter
LongConverter that provides core conversion logic.protected AbstractLongConverter(String chars)
AbstractLongConverter using a given set of characters.chars - set of characters to use for conversion.protected AbstractLongConverter(LongConverter converter)
AbstractLongConverter with a specified converter.converter - the underlying LongConverter to be used for conversions.public int maxParseLength()
maxParseLength in interface LongConverterpublic long parse(CharSequence text)
parse in interface LongConvertertext - the text to parse.public void append(StringBuilder text, long value)
StringBuilder text.append in interface LongConvertertext - the StringBuilder to append to.value - the long value to convert and append.public void append(net.openhft.chronicle.bytes.Bytes<?> bytes,
long value)
Bytes<?> text.append in interface LongConverterbytes - the Bytes object to append to.value - the long value to convert and append.Copyright © 2023. All rights reserved.