Package com.xebialabs.xlrelease.serialization.json.xltype

## Class CiJson2Writer

- java.lang.Object
- - com.xebialabs.xlrelease.serialization.json.xltype.CiJson2Writer

- All Implemented Interfaces:
    `com.xebialabs.xltype.serialization.CiWriter`, `java.lang.AutoCloseable`

      public class CiJson2Writer
      extends java.lang.Object
      implements com.xebialabs.xltype.serialization.CiWriter, java.lang.AutoCloseable

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `protected javax.json.stream.JsonGenerator` | `json` |
    `protected java.io.Writer` | `writer` |

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `CiJson2Writer()` |
    `CiJson2Writer​(java.io.Writer writer)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `void` | `ciAttributes​(CiAttributes ciAttributes)` |
    `void` | `ciFileAttribute​(java.lang.String file)` |
    `void` | `ciReference​(java.lang.String reference)` |
    `void` | `ciReferences​(java.util.Collection<java.lang.String> references)` |
    `void` | `close()` |
    `void` | `endCi()` |
    `void` | `endList()` |
    `void` | `endProperty()` |
    `void` | `externalProperties​(java.util.Map<java.lang.String,​ExternalProperty> externalProperties)` |
    `java.io.Writer` | `getWriter()` |
    `void` | `mapAsStrings​(java.util.Map<?,​?> map)` |
    `void` | `startCi​(java.lang.String type, java.lang.String id)` |
    `void` | `startList()` |
    `void` | `startProperty​(java.lang.String name)` |
    `void` | `token​(java.lang.String token)` |
    `java.lang.String` | `toString()` |
    `void` | `typedCiReference​(com.xebialabs.deployit.engine.api.dto.ConfigurationItemId ci)` |
    `void` | `typedCiReferences​(java.util.Collection<? extends com.xebialabs.deployit.engine.api.dto.ConfigurationItemId> references)` |
    `void` | `validationMessages​(java.util.List<ValidationMessage> validations)` |
    `void` | `valueAsString​(java.lang.Object value)` |
    `void` | `valuesAsStrings​(java.util.Collection<?> values)` |

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

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

- - ### Field Detail

    - #### writer

          protected final java.io.Writer writer

    - #### json

          protected final javax.json.stream.JsonGenerator json

  - ### Constructor Detail

    - #### CiJson2Writer

          public CiJson2Writer()

    - #### CiJson2Writer

          public CiJson2Writer​(java.io.Writer writer)

  - ### Method Detail

    - #### getWriter

          public java.io.Writer getWriter()

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`

    - #### startList

          public void startList()

      Specified by:
        `startList` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### endList

          public void endList()

      Specified by:
        `endList` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### startCi

          public void startCi​(java.lang.String type,
                              java.lang.String id)

      Specified by:
        `startCi` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### endCi

          public void endCi()

      Specified by:
        `endCi` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### token

          public void token​(java.lang.String token)

      Specified by:
        `token` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### ciAttributes

          public void ciAttributes​(CiAttributes ciAttributes)

      Specified by:
        `ciAttributes` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### ciFileAttribute

          public void ciFileAttribute​(java.lang.String file)

      Specified by:
        `ciFileAttribute` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### startProperty

          public void startProperty​(java.lang.String name)

      Specified by:
        `startProperty` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### endProperty

          public void endProperty()

      Specified by:
        `endProperty` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### valueAsString

          public void valueAsString​(java.lang.Object value)

      Specified by:
        `valueAsString` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### valuesAsStrings

          public void valuesAsStrings​(java.util.Collection<?> values)

      Specified by:
        `valuesAsStrings` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### mapAsStrings

          public void mapAsStrings​(java.util.Map<?,​?> map)

      Specified by:
        `mapAsStrings` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### ciReference

          public void ciReference​(java.lang.String reference)

      Specified by:
        `ciReference` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### ciReferences

          public void ciReferences​(java.util.Collection<java.lang.String> references)

      Specified by:
        `ciReferences` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### typedCiReference

          public void typedCiReference​(com.xebialabs.deployit.engine.api.dto.ConfigurationItemId ci)

      Specified by:
        `typedCiReference` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### typedCiReferences

          public void typedCiReferences​(java.util.Collection<? extends com.xebialabs.deployit.engine.api.dto.ConfigurationItemId> references)

      Specified by:
        `typedCiReferences` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### validationMessages

          public void validationMessages​(java.util.List<ValidationMessage> validations)

      Specified by:
        `validationMessages` in interface `com.xebialabs.xltype.serialization.CiWriter`

    - #### close

          public void close()
                     throws java.io.IOException

      Specified by:
        `close` in interface `java.lang.AutoCloseable`
      Throws:
        `java.io.IOException`

    - #### externalProperties

          public void externalProperties​(java.util.Map<java.lang.String,​ExternalProperty> externalProperties)

      Specified by:
        `externalProperties` in interface `com.xebialabs.xltype.serialization.CiWriter`