private void SendCreateFilmSessionRequest(DicomClient client, ClientAssociationParameters association)
        {
            DicomMessage message        = new DicomMessage(null, this._basicFilmSessionModuleIod.DicomAttributeCollection);
            byte         presentationID = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);

            this._nextRequestType = RequestType.FilmBox;
            client.SendNCreateRequest(null, presentationID, client.NextMessageID(), message, DicomUids.BasicFilmSession);
        }
        private void SendCreateFilmSessionRequest(DicomClient client, ClientAssociationParameters association)
        {
            DicomMessage newRequestMessage = new DicomMessage(null, (DicomAttributeCollection)_basicFilmSessionModuleIod.DicomAttributeProvider);

            byte pcid = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);

            _nextRequestType = RequestType.FilmBox;
            client.SendNCreateRequest(DicomUid.GenerateUid(), pcid, client.NextMessageID(), newRequestMessage, DicomUids.BasicFilmSession);
        }
        private void SendDeleteFilmSessionRequest(DicomClient client, ClientAssociationParameters association)
        {
            DicomMessage newRequestMessage = new DicomMessage(null, null);

            newRequestMessage.RequestedSopInstanceUid = _filmSessionUid;
            newRequestMessage.RequestedSopClassUid    = SopClass.BasicFilmSessionSopClassUid;

            _nextRequestType = RequestType.Close;
            byte pcid = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);

            client.SendNDeleteRequest(pcid, client.NextMessageID(), newRequestMessage);
        }
        private void SendDeleteFilmSessionRequest(DicomClient client, ClientAssociationParameters association, DicomMessage responseMessage)
        {
            DicomMessage message = new DicomMessage(null, null)
            {
                RequestedSopInstanceUid = this._filmSessionUid,
                RequestedSopClassUid    = SopClass.BasicFilmSessionSopClassUid
            };

            this._nextRequestType = RequestType.Close;
            byte presentationID = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);

            client.SendNDeleteRequest(presentationID, client.NextMessageID(), message);
        }
        private void SendCreateFilmBoxRequest(DicomClient client, ClientAssociationParameters association, DicomMessage responseMessage)
        {
            ReferencedInstanceSequenceIod referencedFilmSessionSequence = new ReferencedInstanceSequenceIod();

            referencedFilmSessionSequence.ReferencedSopClassUid    = SopClass.BasicFilmSessionSopClassUid;
            referencedFilmSessionSequence.ReferencedSopInstanceUid = responseMessage.AffectedSopInstanceUid;
            _basicFilmBoxModuleIod.ReferencedFilmSessionSequenceList.Add(referencedFilmSessionSequence);

            DicomMessage newRequestMessage = new DicomMessage(null, (DicomAttributeCollection)_basicFilmBoxModuleIod.DicomAttributeProvider);

            byte pcid = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);

            _nextRequestType = RequestType.ImageBox;
            client.SendNCreateRequest(DicomUid.GenerateUid(), pcid, client.NextMessageID(), newRequestMessage, DicomUids.BasicFilmBoxSOP);
        }
        private void SendCreateFilmBoxRequest(DicomClient client, ClientAssociationParameters association, DicomMessage responseMessage)
        {
            this._filmSessionUid = responseMessage.AffectedSopInstanceUid;
            ReferencedInstanceSequenceIod item = new ReferencedInstanceSequenceIod
            {
                ReferencedSopClassUid    = SopClass.BasicFilmSessionSopClassUid,
                ReferencedSopInstanceUid = responseMessage.AffectedSopInstanceUid
            };

            this._basicFilmBoxModuleIod.ReferencedFilmSessionSequenceList.Add(item);
            DicomMessage message        = new DicomMessage(null, this._basicFilmBoxModuleIod.DicomAttributeCollection);
            byte         presentationID = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);

            this._filmBoxUid      = DicomUid.GenerateUid();
            this._nextRequestType = RequestType.ImageBox;
            client.SendNCreateRequest(null, presentationID, client.NextMessageID(), message, DicomUids.BasicFilmBoxSOP);
        }
示例#7
0
        /// <summary>
        /// Sends the move request (called after the association is accepted).
        /// </summary>
        /// <param name="client">The client.</param>
        /// <param name="association">The association.</param>
        private void SendMoveRequest(DicomClient client, ClientAssociationParameters association)
        {
            byte pcid = association.FindAbstractSyntaxOrThrowException(MoveSopClass);

            var dicomMessage = new DicomMessage();

            foreach (DicomAttribute dicomAttribute in _dicomAttributeCollection)
            {
                // Need to do it this way in case the attribute is blank
                DicomAttribute dicomAttribute2 = dicomMessage.DataSet[dicomAttribute.Tag];
                if (dicomAttribute.Values != null)
                {
                    dicomAttribute2.Values = dicomAttribute.Values;
                }
            }
            _moveMessageId = client.NextMessageID();
            client.SendCMoveRequest(pcid, _moveMessageId, _destinationAe, dicomMessage);
        }
        private void SendDeleteFilmBoxRequest(DicomClient client, ClientAssociationParameters association, DicomMessage responseMessage)
        {
            if (_filmBoxUids.Count == 0)
            {
                // no more film boxes left to delete - so send delete film session
                SendDeleteFilmSessionRequest(client, association);
            }
            else
            {
                string currentFilmBoxUid = _filmBoxUids[0];
                _filmBoxUids.Remove(currentFilmBoxUid);

                DicomMessage newRequestMessage = new DicomMessage(null, null);
                newRequestMessage.RequestedSopInstanceUid = currentFilmBoxUid;
                newRequestMessage.RequestedSopClassUid    = SopClass.BasicFilmBoxSopClassUid;
                newRequestMessage.Priority = DicomPriority.Medium;

                _nextRequestType = RequestType.DeleteFilmBox;

                byte pcid = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);
                client.SendNDeleteRequest(pcid, client.NextMessageID(), newRequestMessage);
            }
        }
示例#9
0
        /// <summary>
        /// Sends the move request (called after the association is accepted).
        /// </summary>
        /// <param name="client">The client.</param>
        /// <param name="association">The association.</param>
        private void SendMoveCancelRequest(DicomClient client, ClientAssociationParameters association)
        {
            byte pcid = association.FindAbstractSyntaxOrThrowException(MoveSopClass);

            client.SendCMoveCancelRequest(pcid, _moveMessageId);
        }
示例#10
0
        /// <summary>
        /// Sends the move request (called after the association is accepted).
        /// </summary>
        /// <param name="client">The client.</param>
        /// <param name="association">The association.</param>
        private void SendMoveRequest(DicomClient client, ClientAssociationParameters association)
        {
            byte pcid = association.FindAbstractSyntaxOrThrowException(MoveSopClass);

            DicomMessage dicomMessage = new DicomMessage();
            foreach (DicomAttribute dicomAttribute in _dicomAttributeCollection)
            {
                // Need to do it this way in case the attribute is blank
                DicomAttribute dicomAttribute2 = dicomMessage.DataSet[dicomAttribute.Tag];
                if (dicomAttribute.Values != null)
                    dicomAttribute2.Values = dicomAttribute.Values;
            }

            client.SendCMoveRequest(pcid, client.NextMessageID(), _destinationAe, dicomMessage);
        }
示例#11
0
        private void SendDeleteFilmSessionRequest(DicomClient client, ClientAssociationParameters association)
        {
            DicomMessage newRequestMessage = new DicomMessage(null, null);
            newRequestMessage.RequestedSopInstanceUid = _filmSessionUid;
            newRequestMessage.RequestedSopClassUid = SopClass.BasicFilmSessionSopClassUid;

            _nextRequestType = RequestType.Close;
            byte pcid = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);
            client.SendNDeleteRequest(pcid, client.NextMessageID(), newRequestMessage);
        }
示例#12
0
        private void SendDeleteFilmBoxRequest(DicomClient client, ClientAssociationParameters association, DicomMessage responseMessage)
        {
            if (_filmBoxUids.Count == 0)
            {
                // no more film boxes left to delete - so send delete film session
                SendDeleteFilmSessionRequest(client, association);
            }
            else
            {
                string currentFilmBoxUid = _filmBoxUids[0];
                _filmBoxUids.Remove(currentFilmBoxUid);

                DicomMessage newRequestMessage = new DicomMessage(null, null);
                newRequestMessage.RequestedSopInstanceUid = currentFilmBoxUid;
                newRequestMessage.RequestedSopClassUid = SopClass.BasicFilmBoxSopClassUid;
                newRequestMessage.Priority = DicomPriority.Medium;

                _nextRequestType = RequestType.DeleteFilmBox;

                byte pcid = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);
                client.SendNDeleteRequest(pcid, client.NextMessageID(), newRequestMessage);
            }
        }
示例#13
0
        private void SendCreateFilmBoxRequest(DicomClient client, ClientAssociationParameters association, DicomMessage responseMessage)
        {

            ReferencedInstanceSequenceIod referencedFilmSessionSequence = new ReferencedInstanceSequenceIod();
            referencedFilmSessionSequence.ReferencedSopClassUid = SopClass.BasicFilmSessionSopClassUid;
            referencedFilmSessionSequence.ReferencedSopInstanceUid = responseMessage.AffectedSopInstanceUid;
            _basicFilmBoxModuleIod.ReferencedFilmSessionSequenceList.Add(referencedFilmSessionSequence);

            DicomMessage newRequestMessage = new DicomMessage(null, (DicomAttributeCollection)_basicFilmBoxModuleIod.DicomAttributeProvider);

            byte pcid = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);

            _nextRequestType = RequestType.ImageBox;
            client.SendNCreateRequest(DicomUid.GenerateUid(), pcid, client.NextMessageID(), newRequestMessage, DicomUids.BasicFilmBoxSOP);
        }
示例#14
0
        private void SendCreateFilmSessionRequest(DicomClient client, ClientAssociationParameters association)
        {
            DicomMessage newRequestMessage = new DicomMessage(null, (DicomAttributeCollection)_basicFilmSessionModuleIod.DicomAttributeProvider);

            byte pcid = association.FindAbstractSyntaxOrThrowException(SopClass.BasicGrayscalePrintManagementMetaSopClass);
            _nextRequestType = RequestType.FilmBox;
            client.SendNCreateRequest(DicomUid.GenerateUid(), pcid, client.NextMessageID(), newRequestMessage, DicomUids.BasicFilmSession);
        }
示例#15
0
 /// <summary>
 /// Sends the move request (called after the association is accepted).
 /// </summary>
 /// <param name="client">The client.</param>
 /// <param name="association">The association.</param>
 private void SendMoveCancelRequest(DicomClient client, ClientAssociationParameters association)
 {
     byte pcid = association.FindAbstractSyntaxOrThrowException(MoveSopClass);
     client.SendCMoveCancelRequest(pcid, _moveMessageId);
 }