Class ReaderParserSession
java.lang.Object
org.apache.juneau.marshall.ContextSession
org.apache.juneau.marshall.MarshallingSession
org.apache.juneau.marshall.parser.ParserSession
org.apache.juneau.marshall.parser.ReaderParserSession
- All Implemented Interfaces:
BeanSession,ConverterSession
- Direct Known Subclasses:
CsvParserSession,HjsonParserSession,HoconParserSession,IniParserSession,JsonParserSession,MarkdownParserSession,PlainTextParserSession,RdfParserSession,SseParserSession,TomlParserSession,UonParserSession,XmlParserSession,YamlParserSession
Subclass of parser session objects for character-based parsers.
Notes:
- This class is not thread safe and is typically discarded after one use.
See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classBuilder class.static final classConcrete default builder leaf for the non-subclassedcreate()path (CRTP terminal). -
Field Summary
Fields inherited from class org.apache.juneau.marshall.parser.ParserSession
DEFAULT_MAX_PARSE_DEPTHFields inherited from class org.apache.juneau.marshall.MarshallingSession
NAME_PROPERTY_NAME -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedReaderParserSession(ReaderParserSession.Builder<?> builder) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionstatic ReaderParserSession.Builder<?>create(ReaderParser ctx) Creates a new builder for this object.final ParserPipecreatePipe(Object input) Wraps the specified input object into aParserPipeobject so that it can be easily converted into a stream or reader.Returns the stream charset defined on this session.final booleanReturnstrue if this parser subclasses fromReaderParser.Returns the properties on this bean as a map for debugging.Methods inherited from class org.apache.juneau.marshall.parser.ParserSession
allocateLocal, cast, checkRequired, convertAttrToType, create, doRead, doReadIntoCollection, doReadIntoMap, doReadToBeanConsumer, enterParseDepth, exitParseDepth, getCalendarFormat, getClassMeta, getDateFormat, getDebugOutputLines, getDurationFormat, getInputAsString, getJavaMethod, getLastLocation, getListener, getListener, getListenerClass, getLocaleFormat, getNulls, getOuter, getPeriodFormat, getPosition, getSchema, getStringBuilder, getTemporalFormat, getTimeZoneFormat, isAutoCloseStreams, isTrimStrings, isUnbuffered, mark, onBeanSetterException, onUnknownProperty, parentBean, read, read, read, read, read, read, readArgs, readCalendar, readDate, readDuration, readIntoCollection, readIntoMap, readPeriod, readTemporal, readToBeanConsumer, returnStringBuilder, setCurrentClass, setCurrentProperty, setName, setParent, setPipe, swapParentBean, trim, trim, unmark, unswapMethods inherited from class org.apache.juneau.marshall.MarshallingSession
addWarning, convertToMemberType, convertToMemberType, convertToMemberType, convertToType, convertToType, convertToType, convertToType, create, get, getActiveView, getAnnotationProvider, getArgsClassMeta, getBeanClassVisibility, getBeanConstructorVisibility, getBeanDictionary, getBeanFieldVisibility, getBeanMeta, getBeanMethodVisibility, getBeanRegistry, getBeanTypePropertyName, getBeanTypePropertyName, getClassLoader, getClassMeta, getClassMeta, getClassMetaForObject, getClassMetaForObject, getLocale, getMarshallingContext, getMediaType, getNotBeanClasses, getNotBeanPackagesNames, getPropertyNamer, getSwaps, getTimeZone, getTimeZoneId, isBean, isBean, isBeanMapPutReturnsOldValue, isBeansRequireDefaultConstructor, isBeansRequireSerializable, isBeansRequireSettersForGetters, isBeansRequireSomeProperties, isFindFluentSetters, isIgnoreInvocationExceptionsOnGetters, isIgnoreInvocationExceptionsOnSetters, isIgnoreMissingSetters, isIgnoreUnknownBeanProperties, isIgnoreUnknownNullBeanProperties, isPropertyInActiveView, isRecordComponentOrder, isUnsortedProperties, isUseInterfaceProxies, isUseJavaBeanIntrospector, isValidateSchema, newBean, newBean, newBeanMap, newBeanMap, newGenericList, newGenericMap, newGenericMap, object, parseToList, parseToMap, string, toArray, toBeanMap, toBeanMap, toBeanMapMethods inherited from class org.apache.juneau.marshall.ContextSession
checkForWarnings, getContext, getSessionProperties, getWarnings, isDebug, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.juneau.commons.conversion.ConverterSession
get
-
Constructor Details
-
ReaderParserSession
Constructor.- Parameters:
builder- The builder for this object.
Cannot benull .
-
-
Method Details
-
create
Creates a new builder for this object.- Parameters:
ctx- The context creating this session.
Cannot benull .- Returns:
- A new builder.
-
createPipe
Wraps the specified input object into aParserPipeobject so that it can be easily converted into a stream or reader.- Overrides:
createPipein classParserSession- Parameters:
input- The input.
This can be any of the following types:null ReaderCharSequenceInputStreamcontaining UTF-8 encoded text (or whatever the encoding specified byReaderParser.Builder.streamCharset(Charset)).containing UTF-8 encoded text (or whatever the encoding specified bybyte []ReaderParser.Builder.streamCharset(Charset)).
- Returns:
- A new
ParserPipewrapper around the specified input object.
-
getStreamCharset
Returns the stream charset defined on this session.- Returns:
- the stream charset defined on this session.
-
isReaderParser
Description copied from class:ParserSessionReturnstrue if this parser subclasses fromReaderParser.- Overrides:
isReaderParserin classParserSession- Returns:
true if this parser subclasses fromReaderParser.
-
properties
Description copied from class:ContextSessionReturns the properties on this bean as a map for debugging.- Overrides:
propertiesin classParserSession- Returns:
- The properties on this bean as a map for debugging.
-