net.sf.okapi.common.filterwriter

## Class XLIFFWriterParameters

- java.lang.Object
- - net.sf.okapi.common.BaseParameters
  - - net.sf.okapi.common.StringParameters
    - - net.sf.okapi.common.filterwriter.XLIFFWriterParameters

- All Implemented Interfaces:
    IParameters

      public class XLIFFWriterParameters
      extends StringParameters

  Provides a way to access the parameters for `XLIFFWriter` in a single object.

- - ### Field Summary

    - ### Fields inherited from class net.sf.okapi.common.StringParameters

      `buffer`

    - ### Fields inherited from class net.sf.okapi.common.BaseParameters

      `path`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `XLIFFWriterParameters()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `getCopySource()`
    `boolean` | `getEscapeGt()`
    `boolean` | `getIncludeAltTrans()`
    `boolean` | `getIncludeCodeAttrs()`
    `boolean` | `getIncludeIts()` Gets the flag indicating if ITS markup should be output or not.
    `boolean` | `getIncludeNoTranslate()`
    `ParametersDescription` | `getParametersDescription()` Gets the description of the parameters.
    `boolean` | `getPlaceholderMode()` Gets the flag indicating if the inline code should use the place-holder notation (g and x elements).
    `boolean` | `getSetApprovedAsNoTranslate()`
    `java.lang.String` | `getToolCompany()`
    `java.lang.String` | `getToolId()`
    `java.lang.String` | `getToolName()`
    `java.lang.String` | `getToolVersion()`
    `java.lang.String` | `getToolXmlSnippet()`
    `boolean` | `getUseSourceForTranslated()`
    `void` | `reset()` Reset this parameters object to its default values.
    `void` | `setCopySource(boolean copySource)` Sets the copySource flag indicating to copy the source at the target spot if there is no target defined.
    `void` | `setEscapeGt(boolean escapeGt)` Sets the flag indicating if '>' should be escaped or not.
    `void` | `setIncludeAltTrans(boolean includeAltTrans)` Sets the flag indicating if alt-trans elements should be output or not.
    `void` | `setIncludeCodeAttrs(boolean includeCodeAttrs)` Sets the flag indicating if extended code attributes should be output or not.
    `void` | `setIncludeIts(boolean includeIts)` Sets the flag indicating if ITS markup should be output or not.
    `void` | `setIncludeNoTranslate(boolean includeNoTranslate)` Sets the flag indicating if non-translatable text units should be output or not.
    `void` | `setPlaceholderMode(boolean placeholderMode)` Sets the flag indicating if the inline code should use the place-holder notation (g and x elements).
    `void` | `setSetApprovedAsNoTranslate(boolean setApprovedAsNoTranslate)` Sets the flag indicating to mark as not translatable all entries that are approved.
    `void` | `setToolCompany(java.lang.String toolCompany)`
    `void` | `setToolId(java.lang.String toolId)`
    `void` | `setToolName(java.lang.String toolName)`
    `void` | `setToolVersion(java.lang.String toolVersion)`
    `void` | `setToolXmlSnippet(java.lang.String snippet)`
    `void` | `setUseSourceForTranslated(boolean useSourceForTranslated)` Sets the flag indicating if the source text is used in the target, even if a target is available.

    - ### Methods inherited from class net.sf.okapi.common.StringParameters

      `fromString, fromString, getBoolean, getGroup, getInteger, getString, setBoolean, setGroup, setInteger, setString, toString`

    - ### Methods inherited from class net.sf.okapi.common.BaseParameters

      `getPath, load, load, save, setPath`

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

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

- - ### Constructor Detail

    - #### XLIFFWriterParameters

          public XLIFFWriterParameters()

  - ### Method Detail

    - #### getUseSourceForTranslated

          public boolean getUseSourceForTranslated()

    - #### setUseSourceForTranslated

          public void setUseSourceForTranslated(boolean useSourceForTranslated)

      Sets the flag indicating if the source text is used in the target, even if a target is available.

      This is for the tools where we trust the target will be obtained by the tool from the TMX from original. This is to allow editing of pre-translated items in XLIFF editors that use directly the <target> element.

      Parameters:
        `useSourceForTranslated` - true to use the source in the target even if a target text is available.

    - #### getEscapeGt

          public boolean getEscapeGt()

    - #### setEscapeGt

          public void setEscapeGt(boolean escapeGt)

      Sets the flag indicating if '>' should be escaped or not.
      Parameters:
        `escapeGt` - true to always escape '>', false to not escape it.

    - #### getPlaceholderMode

          public boolean getPlaceholderMode()

      Gets the flag indicating if the inline code should use the place-holder notation (g and x elements).
      Returns:
        true if the inline code should use the place-holder notation.

    - #### setPlaceholderMode

          public void setPlaceholderMode(boolean placeholderMode)

      Sets the flag indicating if the inline code should use the place-holder notation (g and x elements).
      Parameters:
        `placeholderMode` - true if the inline code should use the place-holder notation.

    - #### getIncludeNoTranslate

          public boolean getIncludeNoTranslate()

    - #### setIncludeNoTranslate

          public void setIncludeNoTranslate(boolean includeNoTranslate)

      Sets the flag indicating if non-translatable text units should be output or not.
      Parameters:
        `includeNoTranslate` - true to include non-translatable text unit in the output.

    - #### getSetApprovedAsNoTranslate

          public boolean getSetApprovedAsNoTranslate()

    - #### setSetApprovedAsNoTranslate

          public void setSetApprovedAsNoTranslate(boolean setApprovedAsNoTranslate)

      Sets the flag indicating to mark as not translatable all entries that are approved.
      Parameters:
        `setApprovedAsNoTranslate` - true to mark approved entries as not translatable.

    - #### getCopySource

          public boolean getCopySource()

    - #### setCopySource

          public void setCopySource(boolean copySource)

      Sets the copySource flag indicating to copy the source at the target spot if there is no target defined.
      Parameters:
        `copySource` - true to copy the source at the target spot if there is no target defined.

    - #### getIncludeAltTrans

          public boolean getIncludeAltTrans()

    - #### setIncludeAltTrans

          public void setIncludeAltTrans(boolean includeAltTrans)

      Sets the flag indicating if alt-trans elements should be output or not.
      Parameters:
        `includeAltTrans` - true to include alt-trans element in the output.

    - #### getIncludeCodeAttrs

          public boolean getIncludeCodeAttrs()

    - #### setIncludeCodeAttrs

          public void setIncludeCodeAttrs(boolean includeCodeAttrs)

      Sets the flag indicating if extended code attributes should be output or not.
      Parameters:
        `includeCodeAttrs` - true to include extended code attributes in the output.

    - #### getIncludeIts

          public boolean getIncludeIts()

      Gets the flag indicating if ITS markup should be output or not.
      Returns:
        true if ITS markup should be output, false otherwise.

    - #### setIncludeIts

          public void setIncludeIts(boolean includeIts)

      Sets the flag indicating if ITS markup should be output or not.
      Parameters:
        `includeIts` - true to include ITS markup in the output.

    - #### getToolId

          public java.lang.String getToolId()

    - #### setToolId

          public void setToolId(java.lang.String toolId)

    - #### getToolName

          public java.lang.String getToolName()

    - #### setToolName

          public void setToolName(java.lang.String toolName)

    - #### getToolVersion

          public java.lang.String getToolVersion()

    - #### setToolVersion

          public void setToolVersion(java.lang.String toolVersion)

    - #### getToolCompany

          public java.lang.String getToolCompany()

    - #### setToolCompany

          public void setToolCompany(java.lang.String toolCompany)

    - #### getToolXmlSnippet

          public java.lang.String getToolXmlSnippet()

    - #### setToolXmlSnippet

          public void setToolXmlSnippet(java.lang.String snippet)

    - #### reset

          public void reset()

      Description copied from class: `StringParameters`
      Reset this parameters object to its default values.

      Subclasses should override this method to set any initial values and instantiate any objects that require allocation. It is recommended that subclasses also call `super.reset()` in the override to ensure that the buffer is empty.

      Specified by:
        `reset` in interface `IParameters`
      Overrides:
        `reset` in class `StringParameters`

    - #### getParametersDescription

          public ParametersDescription getParametersDescription()

      Description copied from interface: `IParameters`
      Gets the description of the parameters.
      Specified by:
        `getParametersDescription` in interface `IParameters`
      Overrides:
        `getParametersDescription` in class `BaseParameters`
      Returns:
        the ParametersDescription object for this set of parameters, or null if none is provided.