Package com.pixelmed.dicom

# Class TransferSyntax

java.lang.Object
com.pixelmed.dicom.TransferSyntax

public class TransferSyntax extends Object

A class to represent the characteristics of a DICOM Transfer Syntax, which may be instantiated from a UID or from basic characteristics, as well as static UID strings for known Transfer Syntaxes, and static methods for extracting the characteristics of known Transfer Syntaxes.

## Field Summary

Fields
Modifier and Type
Field
Description
`protected boolean`
`bigEndian`
`static final String`
`Default`
`static final String`
`DeflatedExplicitVRLittleEndian`
`protected String`
`description`
`protected boolean`
`encapsulatedPixelData`
`protected boolean`
`explicitVR`
`static final String`
`ExplicitVRBigEndian`
`static final String`
`ExplicitVRLittleEndian`
`protected String`
`fileNameExtension`
`static final String`
`ImplicitVRLittleEndian`
`static final String`
`JPEG2000`
`static final String`
`JPEG2000Lossless`
`static final String`
`JPEGBaseline`
`static final String`
`JPEGExtended`
`protected boolean`
`jpegFamily`
`static final String`
`JPEGFullProgressionNonHierarchical1012`
`static final String`
`JPEGLossless`
`static final String`
`JPEGLosslessSV1`
`static final String`
`JPEGLS`
`static final String`
`JPEGNLS`
`protected boolean`
`lossy`
`static final String`
`MPEG2MPHL`
`static final String`
`MPEG2MPML`
`static final String`
`MPEG4HP41`
`static final String`
`MPEG4HP41BD`
`static final String`
`MPEG4HP422D`
`static final String`
`MPEG4HP423D`
`static final String`
`MPEG4HP42ST`
`static final String`
`Papyrus3ImplicitVRLittleEndian`
`static final String`
`PixelMedBzip2ExplicitVRLittleEndian`
`static final String`
`PixelMedEncapsulatedRawLittleEndian`
`protected boolean`
`recognized`
`static final String`
`RLE`
`protected String`
`transferSyntaxUID`

## Constructor Summary

Constructors
Constructor
Description
`TransferSyntax(String uid)`
Construct a Transfer Syntax using the specified UID, automatically determining its characteristics.
`TransferSyntax(String transferSyntaxUID, String description, boolean explicitVR, boolean bigEndian, boolean encapsulatedPixelData, boolean lossy)`
Construct a Transfer Syntax using the specified UID and characteristics.
`TransferSyntax(String transferSyntaxUID, String description, boolean explicitVR, boolean bigEndian, boolean encapsulatedPixelData, boolean lossy, String fileNameExtension)`
Construct a Transfer Syntax using the specified UID and characteristics.
`TransferSyntax(String transferSyntaxUID, String description, boolean explicitVR, boolean bigEndian, boolean encapsulatedPixelData, boolean lossy, String fileNameExtension, boolean jpegFamily)`
Construct a Transfer Syntax using the specified UID and characteristics.

## Method Summary

Modifier and Type
Method
Description
`String`
`dump()`
Describe the characteristics of Transfer Syntax.
`String`
`getDescription()`
Get a human-readable description of the Transfer Syntax.
`String`
`getFileNameExtension()`
Get the file name extension appropriate for the Transfer Syntax.
`String`
`getUID()`
Get the UID of the Transfer Syntax.
`boolean`
`isBigEndian()`
Is the Transfer Syntax big endian ?
`static boolean`
`isBigEndian(String uid)`
Is the Transfer Syntax with the specified UID big endian ?
`boolean`
`isBzip2ed()`
Does the Transfer Syntax use bzip2 compression ?
`boolean`
`isDeflated()`
Does the Transfer Syntax use deflate compression ?
`boolean`
`isEncapsulated()`
Does the Transfer Syntax encapsulate the pixel data ?
`static boolean`
`isEncapsulated(String uid)`
Does the Transfer Syntax encapsulate the pixel data ?
`boolean`
`isExplicitVR()`
Is the Transfer Syntax explicit VR ?
`static boolean`
`isExplicitVR(String uid)`
Is the Transfer Syntax with the specified UID explicit VR ?
`boolean`
`isImplicitVR()`
Is the Transfer Syntax implicit VR ?
`static boolean`
`isImplicitVR(String uid)`
Is the Transfer Syntax with the specified UID implicit VR ?
`boolean`
`isJPEGFamily()`
Is the Transfer Syntax part of the JPEG family of Transfer Syntaxes?
`boolean`
`isLittleEndian()`
Is the Transfer Syntax little endian ?
`static boolean`
`isLittleEndian(String uid)`
Is the Transfer Syntax with the specified UID little endian ?
`boolean`
`isLossy()`
Is the Transfer Syntax potentially lossy ?
`boolean`
`isNotEncapsulated()`
Does the Transfer Syntax encode the pixel data without encapsulation?
`static boolean`
`isNotEncapsulated(String uid)`
Does the Transfer Syntax encode the pixel data without encapsulation?
`boolean`
`isRecognized()`
Is the Transfer Syntax recognized ?
`String`
`toString()`
Get the Transfer Syntax as a string.

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

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

## Field Details

### ImplicitVRLittleEndian

public static final String ImplicitVRLittleEndian

See Also:
  - Constant Field Values

### ExplicitVRLittleEndian

public static final String ExplicitVRLittleEndian

See Also:
  - Constant Field Values

### ExplicitVRBigEndian

public static final String ExplicitVRBigEndian

See Also:
  - Constant Field Values

### Default

public static final String Default

See Also:
  - Constant Field Values

### DeflatedExplicitVRLittleEndian

public static final String DeflatedExplicitVRLittleEndian

See Also:
  - Constant Field Values

### JPEGBaseline

public static final String JPEGBaseline

See Also:
  - Constant Field Values

### JPEGExtended

public static final String JPEGExtended

See Also:
  - Constant Field Values

### JPEGFullProgressionNonHierarchical1012

public static final String JPEGFullProgressionNonHierarchical1012

See Also:
  - Constant Field Values

### JPEGLossless

public static final String JPEGLossless

See Also:
  - Constant Field Values

### JPEGLosslessSV1

public static final String JPEGLosslessSV1

See Also:
  - Constant Field Values

### JPEGLS

public static final String JPEGLS

See Also:
  - Constant Field Values

### JPEGNLS

public static final String JPEGNLS

See Also:
  - Constant Field Values

### JPEG2000Lossless

public static final String JPEG2000Lossless

See Also:
  - Constant Field Values

### JPEG2000

public static final String JPEG2000

See Also:
  - Constant Field Values

### MPEG2MPML

public static final String MPEG2MPML

See Also:
  - Constant Field Values

### MPEG2MPHL

public static final String MPEG2MPHL

See Also:
  - Constant Field Values

### MPEG4HP41

public static final String MPEG4HP41

See Also:
  - Constant Field Values

### MPEG4HP41BD

public static final String MPEG4HP41BD

See Also:
  - Constant Field Values

### MPEG4HP422D

public static final String MPEG4HP422D

See Also:
  - Constant Field Values

### MPEG4HP423D

public static final String MPEG4HP423D

See Also:
  - Constant Field Values

### MPEG4HP42ST

public static final String MPEG4HP42ST

See Also:
  - Constant Field Values

### RLE

public static final String RLE

See Also:
  - Constant Field Values

### PixelMedBzip2ExplicitVRLittleEndian

public static final String PixelMedBzip2ExplicitVRLittleEndian

See Also:
  - Constant Field Values

### PixelMedEncapsulatedRawLittleEndian

public static final String PixelMedEncapsulatedRawLittleEndian

See Also:
  - Constant Field Values

### Papyrus3ImplicitVRLittleEndian

public static final String Papyrus3ImplicitVRLittleEndian

See Also:
  - Constant Field Values

### transferSyntaxUID

protected String transferSyntaxUID

### description

protected String description

### bigEndian

protected boolean bigEndian

### explicitVR

protected boolean explicitVR

### encapsulatedPixelData

protected boolean encapsulatedPixelData

### lossy

protected boolean lossy

### recognized

protected boolean recognized

### jpegFamily

protected boolean jpegFamily

### fileNameExtension

protected String fileNameExtension

## Constructor Details

### TransferSyntax

public TransferSyntax(String uid)

Construct a Transfer Syntax using the specified UID, automatically determining its characteristics.

Parameters:
  `uid` - the UID to use to refer to this transfer syntax

### TransferSyntax

public TransferSyntax(String transferSyntaxUID, String description, boolean explicitVR, boolean bigEndian, boolean encapsulatedPixelData, boolean lossy)

Construct a Transfer Syntax using the specified UID and characteristics.

Parameters:
  `transferSyntaxUID` - the UID to use to refer to this transfer syntax
  `description` - the description of this transfer syntax
  `explicitVR` - true if an explicit VR transfer syntax
  `bigEndian` - true if big-endian transfer syntax
  `encapsulatedPixelData` - true if a pixel data encapsulated transfer syntax
  `lossy` - true if lossy compression

### TransferSyntax

public TransferSyntax(String transferSyntaxUID, String description, boolean explicitVR, boolean bigEndian, boolean encapsulatedPixelData, boolean lossy, String fileNameExtension)

Construct a Transfer Syntax using the specified UID and characteristics.

Parameters:
  `transferSyntaxUID` - the UID to use to refer to this transfer syntax
  `description` - the description of this transfer syntax
  `explicitVR` - true if an explicit VR transfer syntax
  `bigEndian` - true if big-endian transfer syntax
  `encapsulatedPixelData` - true if a pixel data encapsulated transfer syntax
  `lossy` - true if lossy compression
  `fileNameExtension` - fileNameExtension to use if bit stream is to be saved as a file

### TransferSyntax

public TransferSyntax(String transferSyntaxUID, String description, boolean explicitVR, boolean bigEndian, boolean encapsulatedPixelData, boolean lossy, String fileNameExtension, boolean jpegFamily)

Construct a Transfer Syntax using the specified UID and characteristics.

Parameters:
  `transferSyntaxUID` - the UID to use to refer to this transfer syntax
  `description` - the description of this transfer syntax
  `explicitVR` - true if an explicit VR transfer syntax
  `bigEndian` - true if big-endian transfer syntax
  `encapsulatedPixelData` - true if a pixel data encapsulated transfer syntax
  `lossy` - true if lossy compression
  `fileNameExtension` - fileNameExtension to use if bit stream is to be saved as a file
  `jpegFamily` - true if uses JPEG family marker segments

## Method Details

### getUID

public String getUID()

Get the UID of the Transfer Syntax.

Returns:
  the UID of the Transfer Syntax

### getDescription

public String getDescription()

Get a human-readable description of the Transfer Syntax.

Returns:
  the description of the Transfer Syntax

### isRecognized

public boolean isRecognized()

Is the Transfer Syntax recognized ?

Returns:
  true if recognized

### isBigEndian

public boolean isBigEndian()

Is the Transfer Syntax big endian ?

Returns:
  true if big endian

### isLittleEndian

public boolean isLittleEndian()

Is the Transfer Syntax little endian ?

Returns:
  true if little endian

### isExplicitVR

public boolean isExplicitVR()

Is the Transfer Syntax explicit VR ?

Returns:
  true if explicit VR

### isImplicitVR

public boolean isImplicitVR()

Is the Transfer Syntax implicit VR ?

Returns:
  true if implicit VR

### isEncapsulated

public boolean isEncapsulated()

Does the Transfer Syntax encapsulate the pixel data ?

Returns:
  true if encapsulate

### isNotEncapsulated

public boolean isNotEncapsulated()

Does the Transfer Syntax encode the pixel data without encapsulation?

Returns:
  true if not encapsulated

### isLossy

public boolean isLossy()

Is the Transfer Syntax potentially lossy ?

Returns:
  true if lossy

### getFileNameExtension

public String getFileNameExtension()

Get the file name extension appropriate for the Transfer Syntax.

Will be "unk" if unrecognized.

Returns:
  the fileNameExtension to use if bit stream is to be saved as a file

### isJPEGFamily

public boolean isJPEGFamily()

Is the Transfer Syntax part of the JPEG family of Transfer Syntaxes?

I.e., those that share the same marker segments, such as the EOI marker used for end of frame in fragment detection.

Returns:
  true if is JPEG family

### isDeflated

public boolean isDeflated()

Does the Transfer Syntax use deflate compression ?

Returns:
  true if deflated

### isBzip2ed

public boolean isBzip2ed()

Does the Transfer Syntax use bzip2 compression ?

Returns:
  true if bzip2

### toString

public String toString()

Get the Transfer Syntax as a string.

Overrides:
  `toString` in class `Object`
Returns:
  the UID of the Transfer Syntax

### dump

public String dump()

Describe the characteristics of Transfer Syntax.

Returns:
  a detailed description of the Transfer Syntax

### isExplicitVR

public static boolean isExplicitVR(String uid)

Is the Transfer Syntax with the specified UID explicit VR ?

Parameters:
  `uid` -
Returns:
  true if explicit VR

### isImplicitVR

public static boolean isImplicitVR(String uid)

Is the Transfer Syntax with the specified UID implicit VR ?

Parameters:
  `uid` -
Returns:
  true if explicit VR

### isBigEndian

public static boolean isBigEndian(String uid)

Is the Transfer Syntax with the specified UID big endian ?

Parameters:
  `uid` -
Returns:
  true if big endian

### isLittleEndian

public static boolean isLittleEndian(String uid)

Is the Transfer Syntax with the specified UID little endian ?

Parameters:
  `uid` -
Returns:
  true if little endian

### isEncapsulated

public static boolean isEncapsulated(String uid)

Does the Transfer Syntax encapsulate the pixel data ?

Parameters:
  `uid` -
Returns:
  true if encapsulate

### isNotEncapsulated

public static boolean isNotEncapsulated(String uid)

Does the Transfer Syntax encode the pixel data without encapsulation?

Parameters:
  `uid` -
Returns:
  true if not encapsulated