com.pixelmed.network

## Class PresentationContextListFactory

- java.lang.Object
- - com.pixelmed.network.PresentationContextListFactory

    public class PresentationContextListFactory
    extends java.lang.Object

A factory object of static methods that can create lists of presentation contexts for initiating associations, from lists of DICOM files based on SOP Class (abstract syntax) and supported transfer syntaxes.

### Constructor Summary

Constructors
Constructor and Description
`PresentationContextListFactory()`

### Method Summary

Methods
`static java.util.LinkedList` `createNewPresentationContextList(java.util.Set setOfSOPClassUIDs, int compressionLevel)` Create lists of presentation contexts for initiating associations, from a set of SOP Class UIDs.
`static java.util.LinkedList` `createNewPresentationContextList(java.util.Set setOfSOPClassUIDs, int compressionLevel, boolean theirChoice, boolean ourChoice, boolean asEncoded)` Create lists of presentation contexts for initiating associations, from a set of SOP Class UIDs.
`static java.util.LinkedList` `createNewPresentationContextList(SetOfDicomFiles dicomFiles, int compressionLevel)` Create lists of presentation contexts for initiating associations, from the abstract syntax and transfer syntax as well as all supported transfer syntaxes for all the files in the specified set of Dicom files.
`static java.util.LinkedList` `createNewPresentationContextList(SetOfDicomFiles dicomFiles, int compressionLevel, boolean theirChoice, boolean ourChoice, boolean asEncoded)` Create lists of presentation contexts for initiating associations, from the abstract syntax and transfer syntax as well as all supported transfer syntaxes for all the files in the specified set of Dicom files.
`static java.util.LinkedList` `createNewPresentationContextList(java.lang.String abstractSyntax, java.lang.String transferSyntax, int compressionLevel)` Create lists of presentation contexts for initiating associations, from the specified abstract syntax and transfer syntax as well as all supported transfer syntaxes.
`static java.util.LinkedList` `createNewPresentationContextList(java.lang.String abstractSyntax, java.lang.String transferSyntax, int compressionLevel, boolean theirChoice, boolean ourChoice, boolean asEncoded)` Create lists of presentation contexts for initiating associations, from the specified abstract syntax and transfer syntax as well as all supported transfer syntaxes.
`static boolean` `haveBzip2Support()`

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

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

### Constructor Detail

#### PresentationContextListFactory

    public PresentationContextListFactory()

### Method Detail

#### haveBzip2Support

    public static boolean haveBzip2Support()

Returns:
  true if bzip2 codec available

#### createNewPresentationContextList

    public static java.util.LinkedList createNewPresentationContextList(java.lang.String abstractSyntax,
                                                        java.lang.String transferSyntax,
                                                        int compressionLevel,
                                                        boolean theirChoice,
                                                        boolean ourChoice,
                                                        boolean asEncoded)
                                                                 throws DicomNetworkException

Create lists of presentation contexts for initiating associations, from the specified abstract syntax and transfer syntax as well as all supported transfer syntaxes.

Parameters:
  `abstractSyntax` - the SOP Class UID of the data set to be transmitted
  `transferSyntax` - the Transfer Syntax UID in which the data set to be transmitted is encoded, or null if unknown
  `compressionLevel` - 0=none,1=propose deflate,2=propose deflate and bzip2
  `theirChoice` - propose a single presentation context with all transfer syntaxes to allow them to choose
  `ourChoice` - propose separate presentation contexts for each transfer syntax to allow us to choose
  `asEncoded` - propose a separate presentation context for the specified transfer syntax in which the data set is known to be encoded
Returns:
  a LinkedList of PresentationContext
Throws:
  `DicomNetworkException` - if too many presentation contexts

#### createNewPresentationContextList

    public static java.util.LinkedList createNewPresentationContextList(java.lang.String abstractSyntax,
                                                        java.lang.String transferSyntax,
                                                        int compressionLevel)
                                                                 throws DicomNetworkException

Create lists of presentation contexts for initiating associations, from the specified abstract syntax and transfer syntax as well as all supported transfer syntaxes.

Parameters:
  `abstractSyntax` - the SOP Class UID of the data set to be transmitted
  `transferSyntax` - the Transfer Syntax UID in which the data set to be transmitted is encoded, or null if unknown
  `compressionLevel` - 0=none,1=propose deflate,2=propose deflate and bzip2
Returns:
  a LinkedList of PresentationContext
Throws:
  `DicomNetworkException` - if too many presentation contexts

#### createNewPresentationContextList

    public static java.util.LinkedList createNewPresentationContextList(java.util.Set setOfSOPClassUIDs,
                                                        int compressionLevel,
                                                        boolean theirChoice,
                                                        boolean ourChoice,
                                                        boolean asEncoded)
                                                                 throws DicomNetworkException

Create lists of presentation contexts for initiating associations, from a set of SOP Class UIDs.

Parameters:
  `setOfSOPClassUIDs` - the set of `String` SOP Class UIDs
  `compressionLevel` - 0=none,1=propose deflate,2=propose deflate and bzip2
  `theirChoice` - propose a single presentation context with all transfer syntaxes to allow them to choose
  `ourChoice` - propose separate presentation contexts for each transfer syntax to allow us to choose
  `asEncoded` - propose a separate presentation context for the specified transfer syntax in which the data set is known to be encoded
Returns:
  a LinkedList of PresentationContext
Throws:
  `DicomNetworkException` - if too many presentation contexts

#### createNewPresentationContextList

    public static java.util.LinkedList createNewPresentationContextList(java.util.Set setOfSOPClassUIDs,
                                                        int compressionLevel)
                                                                 throws DicomNetworkException

Create lists of presentation contexts for initiating associations, from a set of SOP Class UIDs.

Parameters:
  `setOfSOPClassUIDs` - the set of `String` SOP Class UIDs
  `compressionLevel` - 0=none,1=propose deflate,2=propose deflate and bzip2
Returns:
  a LinkedList of PresentationContext
Throws:
  `DicomNetworkException` - if too many presentation contexts

#### createNewPresentationContextList

    public static java.util.LinkedList createNewPresentationContextList(SetOfDicomFiles dicomFiles,
                                                        int compressionLevel,
                                                        boolean theirChoice,
                                                        boolean ourChoice,
                                                        boolean asEncoded)
                                                                 throws DicomNetworkException

Create lists of presentation contexts for initiating associations, from the abstract syntax and transfer syntax as well as all supported transfer syntaxes for all the files in the specified set of Dicom files.

Parameters:
  `dicomFiles` - the set of files with their SOP Class UIDs and the Transfer Syntax UIDs
  `compressionLevel` - 0=none,1=propose deflate,2=propose deflate and bzip2
  `theirChoice` - propose a single presentation context with all transfer syntaxes to allow them to choose
  `ourChoice` - propose separate presentation contexts for each transfer syntax to allow us to choose
  `asEncoded` - propose a separate presentation context for the specified transfer syntax in which the data set is known to be encoded
Returns:
  a LinkedList of PresentationContext
Throws:
  `DicomNetworkException` - if too many presentation contexts

#### createNewPresentationContextList

    public static java.util.LinkedList createNewPresentationContextList(SetOfDicomFiles dicomFiles,
                                                        int compressionLevel)
                                                                 throws DicomNetworkException

Create lists of presentation contexts for initiating associations, from the abstract syntax and transfer syntax as well as all supported transfer syntaxes for all the files in the specified set of Dicom files.

Parameters:
  `dicomFiles` - the set of files with their SOP Class UIDs and the Transfer Syntax UIDs
  `compressionLevel` - 0=none,1=propose deflate,2=propose deflate and bzip2
Returns:
  a LinkedList of PresentationContext
Throws:
  `DicomNetworkException` - if too many presentation contexts