com.pixelmed.validate
Class DicomInstanceValidator

java.lang.Object
  extended by com.pixelmed.validate.DicomInstanceValidator

public class DicomInstanceValidator
extends Object

The DicomInstanceValidator class is for validating composite storage SOP instances against the standard IOD for the corresponding storage SOP Class.

Typically used by reading the list of attributes that comprise an object, validating them and displaying the resulting string results to the user on the standard output, in a dialog box or whatever. The basic implementation of the main method (that may be useful as a command line utility in its own right) is as follows:

        AttributeList list = new AttributeList();
        list.read(arg[0],null,true,true);
        DicomInstanceValidator validator = new DicomInstanceValidator();
        System.err.print(validator.validate(list));
 

See Also:
AttributeList

Constructor Summary
DicomInstanceValidator()
          Create an instance of validator.
 
Method Summary
static void main(String[] arg)
          Read the DICOM file specified on the command line and validate it against the standard IOD for the appropriate storage SOP Class.
 String validate(AttributeList list)
          Validate a DICOM composite storage instance against the standard IOD for the appropriate storage SOP Class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DicomInstanceValidator

public DicomInstanceValidator()
                       throws TransformerConfigurationException

Create an instance of validator.

Once created, a validator may be reused for as many validations as desired.

Throws:
TransformerConfigurationException
Method Detail

validate

public String validate(AttributeList list)
                throws ParserConfigurationException,
                       TransformerException,
                       UnsupportedEncodingException

Validate a DICOM composite storage instance against the standard IOD for the appropriate storage SOP Class.

Parameters:
list - the list of attributes comprising the DICOM composite storage instance to be validated
Returns:
a string describing the results of the validation
Throws:
ParserConfigurationException
TransformerException
UnsupportedEncodingException

main

public static void main(String[] arg)

Read the DICOM file specified on the command line and validate it against the standard IOD for the appropriate storage SOP Class.

The result of the validation is printed to the standard output.

Parameters:
arg - the name of the file containing the DICOM composite storage instance to be validated