open class JsonParser : ReadStream<JsonEvent>, Handler<Buffer>
A parser class which allows to incrementally parse json elements and emit json parse events instead of parsing a json element fully. This parser is convenient for parsing large json structures. The parser can also parse entire object or array when it is convenient, for instance a very large array of small objects can be parsed efficiently by handling array start/end and object events. Whenever the parser fails to parse or process the stream, the io.vertx.reactivex.core.parsetools.JsonParser#exceptionHandler is called with the cause of the failure and the current handling stops. After such event, the parser should not handle data anymore. NOTE: This class has been automatically generated from the io.vertx.core.parsetools.JsonParser non RX-ified interface using Vert.x codegen.
JsonParser(delegate: JsonParser) |
static val __TYPE_ARG: TypeArg<JsonParser> |
open fun arrayEventMode(): JsonParser
Flip the parser to emit a stream of events for each new json array. |
|
open fun arrayValueMode(): JsonParser
Flip the parser to emit a single value event for each new json array. Json array currently streamed won't be affected. |
|
open fun end(): Unit
End the stream, this must be called after all the json stream has been processed. |
|
open fun endHandler(endHandler: Handler<Void>): JsonParser |
|
open fun equals(other: Any?): Boolean |
|
open fun exceptionHandler(handler: Handler<Throwable>): JsonParser |
|
open fun getDelegate(): JsonParser |
|
open fun handle(event: Buffer): Unit
Something has happened, so handle it. |
|
open fun handler(handler: Handler<JsonEvent>): JsonParser |
|
open fun hashCode(): Int |
|
open static fun newInstance(arg: JsonParser): JsonParser |
|
open static fun newParser(): JsonParseropen static fun newParser(stream: ReadStream<Buffer>): JsonParseropen static fun newParser(stream: Flowable<Buffer>): JsonParseropen static fun newParser(stream: Observable<Buffer>): JsonParser
Create a new |
|
open fun objectEventMode(): JsonParser
Flip the parser to emit a stream of events for each new json object. |
|
open fun objectValueMode(): JsonParser
Flip the parser to emit a single value event for each new json object. Json object currently streamed won't be affected. |
|
open fun pause(): JsonParser |
|
open fun resume(): JsonParser |
|
open fun toFlowable(): Flowable<JsonEvent> |
|
open fun toObservable(): Observable<JsonEvent> |
|
open fun toString(): String |
|
open fun write(buffer: Buffer): JsonParser
Handle a |