Package javax.json

Interface JsonBuilderFactory


  • public interface JsonBuilderFactory
    • Method Detail

      • createObjectBuilder

        JsonObjectBuilder createObjectBuilder()
        Returns:
        a new empty JsonObjectBuilder
      • createArrayBuilder

        JsonArrayBuilder createArrayBuilder()
        Returns:
        a new empty JsonArrayBuilder
      • getConfigInUse

        java.util.Map<java.lang.String,​?> getConfigInUse()
        Returns:
        the config which got used when creating this builder factory.
      • createObjectBuilder

        default JsonObjectBuilder createObjectBuilder​(JsonObject initialData)
        Create a JsonObjectBuilder filled with the given initial data.
        Returns:
        a new pre initialised JsonObjectBuilder
        Throws:
        java.lang.NullPointerException - if initialData is null
        Since:
        1.1
      • createObjectBuilder

        default JsonObjectBuilder createObjectBuilder​(java.util.Map<java.lang.String,​java.lang.Object> initialData)
        Create a JsonObjectBuilder filled with the given initial data.
        Returns:
        a new pre initialised JsonObjectBuilder
        Throws:
        java.lang.NullPointerException - if initialData is null
        Since:
        1.1
      • createArrayBuilder

        default JsonArrayBuilder createArrayBuilder​(JsonArray initialData)
        Create a JsonArrayBuilder filled with the given initial data.
        Returns:
        a new pre initialised JsonArrayBuilder
        Throws:
        java.lang.NullPointerException - if initialData is null
        Since:
        1.1
      • createArrayBuilder

        default JsonArrayBuilder createArrayBuilder​(java.util.Collection<?> initialData)
        Create a JsonArrayBuilder which is filled with the given initial content.
        Parameters:
        initialData - the content to immediately add to the JsonArrayBuilder
        Returns:
        a new pre initialised JsonArrayBuilder
        Throws:
        java.lang.NullPointerException - if initialData is null
        Since:
        1.1