Package com.pixelmed.dicom

## Class OtherByteAttributeMultipleCompressedFrames

- java.lang.Object
- - com.pixelmed.dicom.Attribute
  - - com.pixelmed.dicom.OtherByteAttributeMultipleCompressedFrames

-     public class OtherByteAttributeMultipleCompressedFrames
      extends Attribute

  A concrete class specializing `Attribute` for Other Byte (OB) attributes whose values are memory or file resident compressed pixel data frames.

  See Also:
    `Attribute`, `AttributeList`

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `protected byte[]` | `allframes` |
    `protected java.io.File[]` | `files` |
    `protected byte[][]` | `frames` |
    `protected static AttributeTag` | `itemTag` |
    `protected static AttributeTag` | `sequenceDelimitationItemTag` |

    - ### Fields inherited from class com.pixelmed.dicom.Attribute

      `valueLength, valueMultiplicity`

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `OtherByteAttributeMultipleCompressedFrames​(AttributeTag t, byte[] allframes)` | Construct an attribute from a single byte array containing all compressed frames.
    `OtherByteAttributeMultipleCompressedFrames​(AttributeTag t, byte[][] frames)` | Construct an attribute from a set of compressed frames.
    `OtherByteAttributeMultipleCompressedFrames​(AttributeTag t, java.io.File[] files)` | Construct an attribute from a set of compressed frames.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `byte[][]` | `getFrames()` | Get the byte arrays for each frame.
    `byte[]` | `getVR()` | Get the value representation of this attribute (OB).
    `void` | `removeValues()` | Remove any existing values, making the attribute empty (zero length).
    `java.lang.String` | `toString​(DicomDictionary dictionary)` | Dump the contents of the attribute as a human-readable string.
    `void` | `write​(DicomOutputStream o)` | Write the entire attribute (including values) to the output stream.
    `protected void` | `writeItemTag​(DicomOutputStream o, long length)` |
    `protected void` | `writeSequenceDelimitationItemTag​(DicomOutputStream o)` |

    - ### Methods inherited from class com.pixelmed.dicom.Attribute

      `addValue, addValue, addValue, addValue, addValue, addValue, addValue, getByteValues, getDelimitedStringValuesOrDefault, getDelimitedStringValuesOrDefault, getDelimitedStringValuesOrDefault, getDelimitedStringValuesOrDefault, getDelimitedStringValuesOrDefault, getDelimitedStringValuesOrDefault, getDelimitedStringValuesOrEmptyString, getDelimitedStringValuesOrEmptyString, getDelimitedStringValuesOrEmptyString, getDelimitedStringValuesOrEmptyString, getDelimitedStringValuesOrEmptyString, getDelimitedStringValuesOrEmptyString, getDelimitedStringValuesOrNull, getDelimitedStringValuesOrNull, getDelimitedStringValuesOrNull, getDelimitedStringValuesOrNull, getDelimitedStringValuesOrNull, getDelimitedStringValuesOrNull, getDoubleValues, getDoubleValues, getDoubleValues, getElement, getFloatValues, getFloatValues, getFloatValues, getGroup, getIntegerValues, getIntegerValues, getIntegerValues, getLongValues, getLongValues, getLongValues, getOriginalStringValues, getPaddedVL, getShortValues, getSingleDoubleValueOrDefault, getSingleDoubleValueOrDefault, getSingleDoubleValueOrDefault, getSingleFloatValueOrDefault, getSingleFloatValueOrDefault, getSingleFloatValueOrDefault, getSingleIntegerValueOrDefault, getSingleIntegerValueOrDefault, getSingleIntegerValueOrDefault, getSingleLongValueOrDefault, getSingleLongValueOrDefault, getSingleLongValueOrDefault, getSingleStringValueOrDefault, getSingleStringValueOrDefault, getSingleStringValueOrDefault, getSingleStringValueOrDefault, getSingleStringValueOrDefault, getSingleStringValueOrDefault, getSingleStringValueOrEmptyString, getSingleStringValueOrEmptyString, getSingleStringValueOrEmptyString, getSingleStringValueOrEmptyString, getSingleStringValueOrEmptyString, getSingleStringValueOrEmptyString, getSingleStringValueOrNull, getSingleStringValueOrNull, getSingleStringValueOrNull, getSingleStringValueOrNull, getSingleStringValueOrNull, getSingleStringValueOrNull, getStringValues, getStringValues, getStringValues, getStringValues, getStringValues, getStringValues, getTag, getVL, getVM, getVRAsString, isValid, repairValues, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValues, setValues, setValues, setValues, toString, writeBase`

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

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

- - ### Field Detail

    - #### allframes

          protected byte[] allframes

    - #### frames

          protected byte[][] frames

    - #### files

          protected java.io.File[] files

    - #### itemTag

          protected static final AttributeTag itemTag

    - #### sequenceDelimitationItemTag

          protected static final AttributeTag sequenceDelimitationItemTag

  - ### Constructor Detail

    - #### OtherByteAttributeMultipleCompressedFrames

          public OtherByteAttributeMultipleCompressedFrames​(AttributeTag t,
                                                            byte[] allframes)

      Construct an attribute from a single byte array containing all compressed frames.

      The VL is not required, since it is undefined by definition.

      Parameters:
        `t` - the tag of the attribute
        `allframes` - the frames

    - #### OtherByteAttributeMultipleCompressedFrames

          public OtherByteAttributeMultipleCompressedFrames​(AttributeTag t,
                                                            byte[][] frames)

      Construct an attribute from a set of compressed frames.

      The VL is not required, since it is undefined by definition.

      Parameters:
        `t` - the tag of the attribute
        `frames` - the frames

    - #### OtherByteAttributeMultipleCompressedFrames

          public OtherByteAttributeMultipleCompressedFrames​(AttributeTag t,
                                                            java.io.File[] files)

      Construct an attribute from a set of compressed frames.

      The VL is not required, since it is undefined by definition.

      Parameters:
        `t` - the tag of the attribute
        `files` - the files containing the compressed bit streams

  - ### Method Detail

    - #### writeItemTag

          protected void writeItemTag​(DicomOutputStream o,
                                      long length)
                               throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### writeSequenceDelimitationItemTag

          protected void writeSequenceDelimitationItemTag​(DicomOutputStream o)
                                                   throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### write

          public void write​(DicomOutputStream o)
                     throws DicomException,
                            java.io.IOException

      Description copied from class: `Attribute`

      Write the entire attribute (including values) to the output stream.

      Specified by:
        `write` in class `Attribute`
      Parameters:
        `o` -
      Throws:
        `java.io.IOException`
        `DicomException` - if no byte array or files containing the compressed bitstream have been supplied

    - #### getFrames

          public byte[][] getFrames()

      Get the byte arrays for each frame.

      Returns:
        an array of byte arrays for each frame

    - #### toString

          public java.lang.String toString​(DicomDictionary dictionary)

      Description copied from class: `Attribute`

      Dump the contents of the attribute as a human-readable string.

      No new line is appended.

      The result is of the form:

           (0xgggg,0xeeee) Name VR=<XX> VL=<0xnnnn> <...>

      For example:

           (0x0018,0x0020) ScanningSequence VR=<CS> VL=<0x2> <GR>

      Overrides:
        `toString` in class `Attribute`
      Parameters:
        `dictionary` - the dictionary to use to look up the name
      Returns:
        a single `String` value

    - #### removeValues

          public void removeValues()

      Description copied from class: `Attribute`

      Remove any existing values, making the attribute empty (zero length).

      Specified by:
        `removeValues` in class `Attribute`

    - #### getVR

          public byte[] getVR()

      Get the value representation of this attribute (OB).

      Overrides:
        `getVR` in class `Attribute`
      Returns:
        'O','B' in ASCII as a two byte array; see `ValueRepresentation`