예제 #1
0
 /// <summary>
 /// Constructs a new <see cref="SeriesNode"/> using default values.
 /// </summary>
 public SeriesNode()
 {
     _images      = new SopInstanceNodeCollection(this);
     _instanceUid = StudyBuilder.NewUid();
     _description = "Untitled Series";
     _dateTime    = System.DateTime.Now;
 }
예제 #2
0
 /// <summary>
 /// Constructs a new <see cref="SeriesNode"/> using actual values from attributes from the given <see cref="DicomAttributeCollection"/>.
 /// </summary>
 /// <param name="dicomDataSet">The data set from which to initialize this node.</param>
 public SeriesNode(DicomAttributeCollection dicomDataSet)
 {
     _images      = new SopInstanceNodeCollection(this);
     _description = dicomDataSet[DicomTags.SeriesDescription].GetString(0, "");
     _dateTime    =
         DicomConverter.GetDateTime(dicomDataSet[DicomTags.SeriesDate].GetDateTime(0),
                                    dicomDataSet[DicomTags.SeriesTime].GetDateTime(0));
     _instanceUid = dicomDataSet[DicomTags.SeriesInstanceUid].GetString(0, "");
     if (_instanceUid == "")
     {
         _instanceUid = StudyBuilder.NewUid();
     }
 }
예제 #3
0
        /// <summary>
        /// Copy constructor
        /// </summary>
        /// <param name="source"></param>
        /// <param name="copyDescendants"></param>
        private SeriesNode(SeriesNode source, bool copyDescendants)
        {
            _images      = new SopInstanceNodeCollection(this);
            _instanceUid = StudyBuilder.NewUid();
            _description = source._description;
            _dateTime    = source._dateTime;

            if (copyDescendants)
            {
                foreach (SopInstanceNode sop in source._images)
                {
                    _images.Add(sop.Copy());
                }
            }
        }