org.apache.uima.cas

## Interface StringArrayFS

- All Superinterfaces:
    Cloneable, CommonArrayFS<String>, FeatureStructure
  All Known Subinterfaces:
    StringArrayFSImpl
  All Known Implementing Classes:
    StringArray

      public interface StringArrayFS
      extends CommonArrayFS<String>

  String array interface. To create a string array object, use `CAS.createStringArrayFS(int)` or new StringArray(aJCas, length)

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `get(int i)` Get the i-th string from the array.
    `void` | `set(int i, String str)` Set the i-th value.
    `String[]` | `toArray()` Creates a new array the this array is copied to.

    - ### Methods inherited from interface org.apache.uima.cas.CommonArrayFS

      `copyFromArray, copyToArray, copyValuesFrom, getValuesAsCommaSeparatedString, isEmpty, size, toStringArray`

    - ### Methods inherited from interface org.apache.uima.cas.FeatureStructure

      `_getTypeCode, _id, clone, equals, getAddress, getBooleanValue, getByteValue, getCAS, getDoubleValue, getFeatureValue, getFeatureValueAsString, getFloatValue, getIntValue, getJCas, getLongValue, getShortValue, getStringValue, getType, hashCode, setBooleanValue, setByteValue, setDoubleValue, setFeatureValue, setFeatureValueFromString, setFloatValue, setIntValue, setLongValue, setShortValue, setStringValue`

- - ### Method Detail

    - #### get

          String get(int i)
              throws ArrayIndexOutOfBoundsException

      Get the i-th string from the array.
      Parameters:
        `i` - the index
      Returns:
        The i-th element.
      Throws:
        `ArrayIndexOutOfBoundsException` - If the index is out of bounds.

    - #### set

          void set(int i,
                   String str)
            throws ArrayIndexOutOfBoundsException

      Set the i-th value.
      Parameters:
        `i` - The index.
        `str` - The value.
      Throws:
        `ArrayIndexOutOfBoundsException` - If `i` is out of bounds.

    - #### toArray

          String[] toArray()

      Creates a new array the this array is copied to.
      Returns:
        A Java array copy of this FS array.

Copyright © 2006–2022 The Apache Software Foundation. All rights reserved.