Package gov.nih.mipav.model.dicomcomm
Class DICOM_CRequest
- java.lang.Object
-
- gov.nih.mipav.model.dicomcomm.DICOM_CRequest
-
- Direct Known Subclasses:
DICOM_CResponse
public class DICOM_CRequest extends java.lang.Object
DIMSE-C service implementations. Most DIMSE C Service messaging classes only require setting an appropriate DICOM command field.
This DICOM communication package was originally based on the Java Dicom Package, whose license is below:Java Dicom Package (com.zmed.dicom) Copyright (c) 1996-1997 Z Medical Imaging Systems, Inc. This software is provided, as is, for non-commercial educational purposes only. Use or incorporation of this software or derivative works in commercial applications requires written consent from Z Medical Imaging Systems, Inc. Z MEDICAL IMAGING SYSTEMS MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NON-INFRINGEMENT, OR CONFORMANCE TO ANY SPECIFICATION OR STANDARD. Z MEDICAL IMAGING SYSTEMS SHALL NOT BE LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF USING OR MODIFYING THIS SOFTWARE OR ITS DERIVATIVES. ============================================================================= This software package is implemented similarly to the UC Davis public domain C++ DICOM implementation which contains the following copyright notice: Copyright (C) 1995, University of California, Davis THIS SOFTWARE IS MADE AVAILABLE, AS IS, AND THE UNIVERSITY OF CALIFORNIA DOES NOT MAKE ANY WARRANTY ABOUT THE SOFTWARE, ITS PERFORMANCE, ITS MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR USE, FREEDOM FROM ANY COMPUTER DISEASES OR ITS CONFORMITY TO ANY SPECIFICATION. THE ENTIRE RISK AS TO QUALITY AND PERFORMANCE OF THE SOFTWARE IS WITH THE USER. Copyright of the software and supporting documentation is owned by the University of California, and free access is hereby granted as a license to use this software, copy this software and prepare derivative works based upon this software. However, any distribution of this software source code or supporting documentation or derivative works (source code and supporting documentation) must include this copyright notice. The UC Davis C++ source code is publicly available from the following anonymous ftp site: ftp://imrad.ucdmc.ucdavis.edu/pub/dicom/UCDMC/
-
-
Field Summary
Fields Modifier and Type Field Description (package private) int
COMMAND
This field distinguishes the DIMSE-C operation conveyed by this message.protected static int
HIGH
Flag indicating high priority transfer.protected static int
LOW
Flag indicating low priority transfer.protected static int
MEDIUM
Flag indicating medium priority transfer.private int
MSG_ID
Message ID - Used to distinguish this message from other messages.
-
Constructor Summary
Constructors Constructor Description DICOM_CRequest(int commandType)
Creates a new DICOM_CRequest object.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static java.lang.String
fixMoveDestString(java.lang.String str)
This is used to fix the padding (even length) of move destinations for some GE DICOM implementations.int
getMsgID()
Accessor to the the message ID.void
read(DICOM_Object dco)
A simplified read if no info is necessary.void
read(DICOM_PDUService pdu, DICOM_Object dco, DICOM_Object ddo)
Reads a DIMSE-C message.void
readCResponseAlias(DICOM_PDUService pdu, DICOM_Object dco, DICOM_Object ddo)
Reads a DIMSE-C message.void
setMsgID(int msgID)
Sets the message ID to the value given.void
write(DICOM_PDUService pdu, java.lang.String transferSyntax, java.lang.String classUID, java.lang.String instanceUID, DICOM_Object ddo, byte[] AETitle)
Writes a DIMSE-C message.
-
-
-
Field Detail
-
LOW
protected static int LOW
Flag indicating low priority transfer.
-
MEDIUM
protected static int MEDIUM
Flag indicating medium priority transfer.
-
HIGH
protected static int HIGH
Flag indicating high priority transfer.
-
COMMAND
int COMMAND
This field distinguishes the DIMSE-C operation conveyed by this message.
-
MSG_ID
private int MSG_ID
Message ID - Used to distinguish this message from other messages.
-
-
Method Detail
-
fixMoveDestString
public static final java.lang.String fixMoveDestString(java.lang.String str)
This is used to fix the padding (even length) of move destinations for some GE DICOM implementations.- Parameters:
str
- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
getMsgID
public final int getMsgID()
Accessor to the the message ID.- Returns:
- this objects message ID
-
read
public void read(DICOM_Object dco) throws DICOM_Exception
A simplified read if no info is necessary.- Parameters:
dco
- the incoming DICOM command message- Throws:
DICOM_Exception
- DOCUMENT ME!
-
read
public void read(DICOM_PDUService pdu, DICOM_Object dco, DICOM_Object ddo) throws DICOM_Exception
Reads a DIMSE-C message.- Parameters:
pdu
- the context pdudco
- the incoming DICOM messageddo
- store the incoming DICOM data object in this object- Throws:
DICOM_Exception
- DOCUMENT ME!
-
readCResponseAlias
public void readCResponseAlias(DICOM_PDUService pdu, DICOM_Object dco, DICOM_Object ddo) throws DICOM_Exception
Reads a DIMSE-C message.- Parameters:
pdu
- the context pdu DICOMClientServerdco
- the incoming DICOM messageddo
- a place to store the incoming DICOM data object or null if not required- Throws:
DICOM_Exception
- DOCUMENT ME!
-
setMsgID
public final void setMsgID(int msgID)
Sets the message ID to the value given. ID is used to distinguish messages from one another.- Parameters:
msgID
- the new message ID
-
write
public void write(DICOM_PDUService pdu, java.lang.String transferSyntax, java.lang.String classUID, java.lang.String instanceUID, DICOM_Object ddo, byte[] AETitle) throws DICOM_Exception
Writes a DIMSE-C message.- Parameters:
pdu
- the context pdu DICOMClientServertransferSyntax
- transfer syntax.classUID
- the SOP Class UID.instanceUID
- DOCUMENT ME!ddo
- the outgoing DICOM data object (null if none required)AETitle
- byte array to store the destination Application Entity title for C-Moves- Throws:
DICOM_Exception
- DOCUMENT ME!
-
-