com.hazelcast.org.snakeyaml.engine.v1.api

## Class Load

- java.lang.Object
- - com.hazelcast.org.snakeyaml.engine.v1.api.Load

-     public class Load
      extends Object

  Common way to load Java instance(s)

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Load(LoadSettings settings)` Create instance to parse the incoming YAML data and create Java instances
    `Load(LoadSettings settings, BaseConstructor constructor)` Create instance to parse the incoming YAML data and create Java instances

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected Composer` | `createComposer(LoadSettings settings, StreamReader streamReader)`
    `Iterable<Object>` | `loadAllFromInputStream(InputStream yamlStream)` Parse all YAML documents in a stream and produce corresponding Java objects.
    `Iterable<Object>` | `loadAllFromReader(Reader yamlReader)` Parse all YAML documents in a String and produce corresponding Java objects.
    `Iterable<Object>` | `loadAllFromString(String yaml)` Parse all YAML documents in a String and produce corresponding Java objects.
    `Object` | `loadFromInputStream(InputStream yamlStream)` Parse the only YAML document in a stream and produce the corresponding Java object.
    `Object` | `loadFromReader(Reader yamlReader)` Parse a YAML document and create a Java instance
    `Object` | `loadFromString(String yaml)` Parse a YAML document and create a Java instance

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### Load

          public Load(LoadSettings settings)

      Create instance to parse the incoming YAML data and create Java instances
      Parameters:
        `settings` - - configuration

    - #### Load

          public Load(LoadSettings settings,
                      BaseConstructor constructor)

      Create instance to parse the incoming YAML data and create Java instances
      Parameters:
        `settings` - - configuration
        `constructor` - - custom YAML constructor

  - ### Method Detail

    - #### createComposer

          protected Composer createComposer(LoadSettings settings,
                                            StreamReader streamReader)

    - #### loadFromInputStream

          public Object loadFromInputStream(InputStream yamlStream)

      Parse the only YAML document in a stream and produce the corresponding Java object.
      Parameters:
        `yamlStream` - - data to load from (BOM is respected to detect encoding and removed from the data)
      Returns:
        parsed Java instance

    - #### loadFromReader

          public Object loadFromReader(Reader yamlReader)

      Parse a YAML document and create a Java instance
      Parameters:
        `yamlReader` - - data to load from (BOM must not be present)
      Returns:
        parsed Java instance

    - #### loadFromString

          public Object loadFromString(String yaml)

      Parse a YAML document and create a Java instance
      Parameters:
        `yaml` - - YAML data to load from (BOM must not be present)
      Returns:
        parsed Java instance
      Throws:
        `YamlEngineException` - if the YAML is not valid

    - #### loadAllFromInputStream

          public Iterable<Object> loadAllFromInputStream(InputStream yamlStream)

      Parse all YAML documents in a stream and produce corresponding Java objects. The documents are parsed only when the iterator is invoked.
      Parameters:
        `yamlStream` - - YAML data to load from (BOM is respected to detect encoding and removed from the data)
      Returns:
        an Iterable over the parsed Java objects in this stream in proper sequence

    - #### loadAllFromReader

          public Iterable<Object> loadAllFromReader(Reader yamlReader)

      Parse all YAML documents in a String and produce corresponding Java objects. The documents are parsed only when the iterator is invoked.
      Parameters:
        `yamlReader` - - YAML data to load from (BOM must not be present)
      Returns:
        an Iterable over the parsed Java objects in this stream in proper sequence

    - #### loadAllFromString

          public Iterable<Object> loadAllFromString(String yaml)

      Parse all YAML documents in a String and produce corresponding Java objects. (Because the encoding in known BOM is not respected.) The documents are parsed only when the iterator is invoked.
      Parameters:
        `yaml` - - YAML data to load from (BOM must not be present)
      Returns:
        an Iterable over the parsed Java objects in this stream in proper sequence

Copyright © 2020. All rights reserved.