org.dcm4che2.data
Class VR

java.lang.Object
  extended by org.dcm4che2.data.VR

public abstract class VR
extends java.lang.Object

This class provides enumaration of DICOM Value Representation.

Version:
$Revision: 14367 $ $Date: 2010-11-23 10:15:51 +0100 (Tue, 23 Nov 2010) $
Author:
Gunter Zeilinger
See Also:
PS3.5 2006 Table 6.2-1

Nested Class Summary
protected static interface VR.CharOut
           
static interface VR.Fragment
          Fragments are used for encapsulation of an encoded (=compressed) pixel data stream into the Pixel Data (7FE0,0010) portion of the DICOM Data Set.
 
Field Summary
static VR AE
          Application Entity (<= 16 chars)
static VR AS
          Age String
static VR AT
          Attribute Tag
protected  int code
           
static VR CS
          Code String (<= 16 chars)
static VR DA
          Date
static VR DS
          Decimal String (=> float)
static VR DT
          Date Time
static VR FD
          Floating Point Double (=> double)
static VR FL
          Floating Point Single (=> float)
protected  int headerLength
           
static VR IS
          Integer String (=> int)
static VR LO
          Long String (<= 64 chars)
static VR LT
          Long Text (<= 10240 chars)
static VR OB
          Other Byte String
static VR OF
          Other Float String
static VR OW
          Other Word String
protected  int padding
           
static VR PN
          Person Name (component group <= 64 chars)
static VR SH
          Short String (<= 16 chars)
static VR SL
          Signed Long (-2147483648..+2147483647)
static VR SQ
          Sequence of Items
static VR SS
          Signed Short (-32768..+32767)
static VR ST
          Short Text (<= 1024 chars)
static VR TM
          Time
static VR UI
          Unique Identifier (UID) (<= 64 chars)
static VR UL
          Unsigned Long (0..4294967295)
static VR UN
          Unkown
static VR UN_SIEMENS
          Illegal VR='??' used by old SIEMENS Modalities
static VR US
          Unsigned Short (0..65535)
static VR UT
          Unlimited Text (<= 4294967294 chars)
 
Method Summary
 int code()
           
 boolean containsSingleValues(java.lang.String[] vals)
           
 int explicitVRHeaderLength()
           
static void float2chars(byte[] b, boolean bigEndian, VR.CharOut ch, char[] cbuf, int maxLen)
           
 void formatXMLValue(byte[] bs, boolean bigEndian, SpecificCharacterSet cs, char[] cbuf, org.xml.sax.ContentHandler out)
           
 boolean isSingleValue(java.lang.String val)
           
 int padding()
           
 byte[] parseXMLValue(java.lang.StringBuffer sb, java.io.ByteArrayOutputStream out, boolean last, SpecificCharacterSet cs)
           
 void promptValue(byte[] bs, boolean bigEndian, SpecificCharacterSet cs, char[] cbuf, int maxLen, java.lang.StringBuffer out)
           
 byte[] toBytes(java.util.Date val)
           
 byte[] toBytes(java.util.Date[] val)
           
 byte[] toBytes(DateRange val)
           
 byte[] toBytes(double[] val, boolean bigEndian)
           
 byte[] toBytes(double val, boolean bigEndian)
           
 byte[] toBytes(float[] val, boolean bigEndian)
           
 byte[] toBytes(float val, boolean bigEndian)
           
 byte[] toBytes(int[] val, boolean bigEndian)
           
 byte[] toBytes(int val, boolean bigEndian)
           
 byte[] toBytes(short[] val, boolean bigEndian)
           
 byte[] toBytes(java.lang.String[] val, boolean bigEndian, SpecificCharacterSet cs)
           
 byte[] toBytes(java.lang.String val, boolean bigEndian, SpecificCharacterSet cs)
           
protected  void toChars(byte[] bs, boolean bigEndian, SpecificCharacterSet cs, char[] cbuf, int maxLen, VR.CharOut out)
           
 java.util.Date toDate(byte[] val)
           
 DateRange toDateRange(byte[] val)
           
 java.util.Date[] toDates(byte[] val)
           
 double toDouble(byte[] val, boolean bigEndian)
           
 double[] toDoubles(byte[] val, boolean bigEndian)
           
 float toFloat(byte[] val, boolean bigEndian)
           
 float[] toFloats(byte[] val, boolean bigEndian)
           
 void toggleEndian(byte[] val)
           
 void toggleEndian(byte[] val, int off, int len)
           
 int toInt(byte[] val, boolean bigEndian)
           
 int[] toInts(byte[] val, boolean bigEndian)
           
 java.util.regex.Pattern toPattern(byte[] bs, boolean bigEndian, SpecificCharacterSet cs, boolean ignoreCase)
           
 short[] toShorts(byte[] val, boolean bigEndian)
           
 java.lang.String toString()
           
 java.lang.String toString(byte[] val, boolean bigEndian, SpecificCharacterSet cs)
           
 java.lang.String[] toStrings(byte[] val, boolean bigEndian, SpecificCharacterSet cs)
           
static VR valueOf(int code)
           
 int vm(byte[] bs, SpecificCharacterSet cs)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

UN_SIEMENS

public static final VR UN_SIEMENS
Illegal VR='??' used by old SIEMENS Modalities


AE

public static final VR AE
Application Entity (<= 16 chars)


AS

public static final VR AS
Age String


AT

public static final VR AT
Attribute Tag


CS

public static final VR CS
Code String (<= 16 chars)


DA

public static final VR DA
Date


DS

public static final VR DS
Decimal String (=> float)


DT

public static final VR DT
Date Time


FL

public static final VR FL
Floating Point Single (=> float)


FD

public static final VR FD
Floating Point Double (=> double)


IS

public static final VR IS
Integer String (=> int)


LO

public static final VR LO
Long String (<= 64 chars)


LT

public static final VR LT
Long Text (<= 10240 chars)


OB

public static final VR OB
Other Byte String


OF

public static final VR OF
Other Float String


OW

public static final VR OW
Other Word String


PN

public static final VR PN
Person Name (component group <= 64 chars)


SH

public static final VR SH
Short String (<= 16 chars)


SL

public static final VR SL
Signed Long (-2147483648..+2147483647)


SQ

public static final VR SQ
Sequence of Items


SS

public static final VR SS
Signed Short (-32768..+32767)


ST

public static final VR ST
Short Text (<= 1024 chars)


TM

public static final VR TM
Time


UI

public static final VR UI
Unique Identifier (UID) (<= 64 chars)


UL

public static final VR UL
Unsigned Long (0..4294967295)


UN

public static final VR UN
Unkown


US

public static final VR US
Unsigned Short (0..65535)


UT

public static final VR UT
Unlimited Text (<= 4294967294 chars)


code

protected final int code

headerLength

protected final int headerLength

padding

protected final int padding
Method Detail

float2chars

public static void float2chars(byte[] b,
                               boolean bigEndian,
                               VR.CharOut ch,
                               char[] cbuf,
                               int maxLen)

valueOf

public static VR valueOf(int code)

toString

public final java.lang.String toString()
Overrides:
toString in class java.lang.Object

code

public final int code()

padding

public final int padding()

explicitVRHeaderLength

public final int explicitVRHeaderLength()

toBytes

public byte[] toBytes(int val,
                      boolean bigEndian)

toBytes

public byte[] toBytes(int[] val,
                      boolean bigEndian)

toBytes

public byte[] toBytes(short[] val,
                      boolean bigEndian)

toBytes

public byte[] toBytes(float val,
                      boolean bigEndian)

toBytes

public byte[] toBytes(float[] val,
                      boolean bigEndian)

toBytes

public byte[] toBytes(double val,
                      boolean bigEndian)

toBytes

public byte[] toBytes(double[] val,
                      boolean bigEndian)

toBytes

public byte[] toBytes(java.lang.String val,
                      boolean bigEndian,
                      SpecificCharacterSet cs)

toBytes

public byte[] toBytes(java.lang.String[] val,
                      boolean bigEndian,
                      SpecificCharacterSet cs)

toBytes

public byte[] toBytes(java.util.Date val)

toBytes

public byte[] toBytes(java.util.Date[] val)

toBytes

public byte[] toBytes(DateRange val)

toShorts

public short[] toShorts(byte[] val,
                        boolean bigEndian)

toInt

public int toInt(byte[] val,
                 boolean bigEndian)

toInts

public int[] toInts(byte[] val,
                    boolean bigEndian)

toFloat

public float toFloat(byte[] val,
                     boolean bigEndian)

toFloats

public float[] toFloats(byte[] val,
                        boolean bigEndian)

toDouble

public double toDouble(byte[] val,
                       boolean bigEndian)

toDoubles

public double[] toDoubles(byte[] val,
                          boolean bigEndian)

toString

public java.lang.String toString(byte[] val,
                                 boolean bigEndian,
                                 SpecificCharacterSet cs)

toStrings

public java.lang.String[] toStrings(byte[] val,
                                    boolean bigEndian,
                                    SpecificCharacterSet cs)

toDate

public java.util.Date toDate(byte[] val)

toDates

public java.util.Date[] toDates(byte[] val)

toDateRange

public DateRange toDateRange(byte[] val)

toPattern

public java.util.regex.Pattern toPattern(byte[] bs,
                                         boolean bigEndian,
                                         SpecificCharacterSet cs,
                                         boolean ignoreCase)

toChars

protected void toChars(byte[] bs,
                       boolean bigEndian,
                       SpecificCharacterSet cs,
                       char[] cbuf,
                       int maxLen,
                       VR.CharOut out)

formatXMLValue

public void formatXMLValue(byte[] bs,
                           boolean bigEndian,
                           SpecificCharacterSet cs,
                           char[] cbuf,
                           org.xml.sax.ContentHandler out)
                    throws org.xml.sax.SAXException
Throws:
org.xml.sax.SAXException

promptValue

public void promptValue(byte[] bs,
                        boolean bigEndian,
                        SpecificCharacterSet cs,
                        char[] cbuf,
                        int maxLen,
                        java.lang.StringBuffer out)

parseXMLValue

public byte[] parseXMLValue(java.lang.StringBuffer sb,
                            java.io.ByteArrayOutputStream out,
                            boolean last,
                            SpecificCharacterSet cs)

vm

public int vm(byte[] bs,
              SpecificCharacterSet cs)

toggleEndian

public void toggleEndian(byte[] val)

toggleEndian

public void toggleEndian(byte[] val,
                         int off,
                         int len)

isSingleValue

public boolean isSingleValue(java.lang.String val)

containsSingleValues

public boolean containsSingleValues(java.lang.String[] vals)


Copyright © 2011 dcm4che. All Rights Reserved.