Пример #1
0
		/// <summary>
		/// Constructor.
		/// </summary>
		public SeriesData(ISeriesData sourceData)
		{
			if (sourceData != null)
			{
				_seriesDescription = sourceData.SeriesDescription;
				_seriesNumber = sourceData.SeriesNumber.ToString("d");
			}
		}
Пример #2
0
 private static string GetFusedDisplaySetName(ISeriesData baseSeries, ISeriesData petSeries, bool attenuationCorrection)
 {
     return(string.Format(SR.FormatPETFusionDisplaySet,
                          string.Format("{0} - {1}", baseSeries.SeriesNumber, baseSeries.SeriesDescription),
                          string.Format("{0} - {1}", petSeries.SeriesNumber, petSeries.SeriesDescription),
                          attenuationCorrection ? SR.LabelAttenuationCorrection : SR.LabelNoAttentuationCorrection
                          ));
 }
Пример #3
0
        public ISeriesData FetchSeriesData(Uri uri)
        {
            ISeriesData parsedContent = null;

            parsedContent = new SeriesData(Helpers.Downloader.Instance.DownloadString(uri));

            return(parsedContent);
        }
Пример #4
0
 /// <summary>
 /// Constructor.
 /// </summary>
 public SeriesData(ISeriesData sourceData)
 {
     if (sourceData != null)
     {
         _seriesDescription = sourceData.SeriesDescription;
         _seriesNumber      = sourceData.SeriesNumber.ToString("d");
     }
 }
Пример #5
0
		private void CopyFrom(ISeriesData other)
		{
			StudyInstanceUid = other.StudyInstanceUid;
			SeriesInstanceUid = other.SeriesInstanceUid;
			Modality = other.Modality;
			SeriesDescription = other.SeriesDescription;
			SeriesNumber = other.SeriesNumber;
			NumberOfSeriesRelatedInstances = other.NumberOfSeriesRelatedInstances;
		}
Пример #6
0
 private void CopyFrom(ISeriesData other)
 {
     StudyInstanceUid  = other.StudyInstanceUid;
     SeriesInstanceUid = other.SeriesInstanceUid;
     Modality          = other.Modality;
     SeriesDescription = other.SeriesDescription;
     SeriesNumber      = other.SeriesNumber;
     NumberOfSeriesRelatedInstances = other.NumberOfSeriesRelatedInstances;
 }
Пример #7
0
        private void PopulateSeries(DicomMessageBase request, DicomMessageBase response, IEnumerable <DicomTag> tagList,
                                    ISeriesData row)
        {
            DicomDataset dataSet = response.DataSet;

            dataSet[DicomTags.RetrieveAeTitle].SetStringValue(Partition.AeTitle);
            dataSet[DicomTags.InstanceAvailability].SetStringValue("ONLINE");

            var characterSet = GetPreferredCharacterSet();

            if (!string.IsNullOrEmpty(characterSet))
            {
                dataSet[DicomTags.SpecificCharacterSet].SetStringValue(characterSet);
                dataSet.SpecificCharacterSet = characterSet;
            }

            foreach (DicomTag tag in tagList)
            {
                try
                {
                    switch (tag.TagValue)
                    {
                    case DicomTags.PatientId:
                        dataSet[DicomTags.PatientId].SetStringValue(request.DataSet[DicomTags.PatientId].ToString());
                        break;

                    case DicomTags.StudyInstanceUid:
                        dataSet[DicomTags.StudyInstanceUid].SetStringValue(
                            request.DataSet[DicomTags.StudyInstanceUid].ToString());
                        break;

                    case DicomTags.SeriesInstanceUid:
                        dataSet[DicomTags.SeriesInstanceUid].SetStringValue(row.SeriesUid);
                        break;

                    case DicomTags.Modality:
                        dataSet[DicomTags.Modality].SetStringValue(row.Modality);
                        break;

                    case DicomTags.SeriesNumber:
                        dataSet[DicomTags.SeriesNumber].SetStringValue(row.SeriesNumber);
                        break;

                    case DicomTags.SeriesDescription:
                        dataSet[DicomTags.SeriesDescription].SetStringValue(row.SeriesDescription);
                        break;

                    case DicomTags.PerformedProcedureStepStartDate:
                        dataSet[DicomTags.PerformedProcedureStepStartDate].SetDateTime(0,
                                                                                       row.PerformedProcedureStepStartDate);
                        break;

                    case DicomTags.PerformedProcedureStepStartTime:
                        dataSet[DicomTags.PerformedProcedureStepStartTime].SetDateTime(0,
                                                                                       row.PerformedProcedureStepStartTime);
                        break;

                    case DicomTags.NumberOfSeriesRelatedInstances:
                        dataSet[DicomTags.NumberOfSeriesRelatedInstances].AppendInt32(row.NumberOfRelatedImage);
                        break;

                    case DicomTags.RequestAttributesSequence:
                        //LoadRequestAttributes(read, response, row);
                        break;

                    case DicomTags.QueryRetrieveLevel:
                        dataSet[DicomTags.QueryRetrieveLevel].SetStringValue("SERIES");
                        break;

                    // Meta tags that should have not been in the RQ, but we've already set
                    case DicomTags.RetrieveAeTitle:
                    case DicomTags.InstanceAvailability:
                    case DicomTags.SpecificCharacterSet:
                        break;

                    default:
                        if (!tag.IsPrivate)
                        {
                            dataSet[tag].SetNullValue();
                        }


                        break;
                    }
                }
                catch (Exception e)
                {
                    Log.Logger.Warn("Unexpected error setting tag {0} in C-FIND-RSP",
                                    dataSet[tag].Tag.ToString());
                    if (!tag.IsPrivate)
                    {
                        dataSet[tag].SetNullValue();
                    }
                }
            }
        }
Пример #8
0
 public SeriesIdentifier(ISeriesData other)
 {
     CopyFrom(other);
 }
Пример #9
0
 public SeriesIdentifier(ISeriesData other, IIdentifier identifier)
     : base(identifier)
 {
     CopyFrom(other);
 }
Пример #10
0
 /// <summary>
 /// Gets the string representation of the type of series defined in the ISeriesData object.
 /// </summary>
 /// <param name="data">The object from which the series type is to be obtained.</param>
 /// <returns></returns>
 public static string GetSeriesTypeAsString(ISeriesData data)
 {
     throw new NotImplementedException();
 }
Пример #11
0
 /// <summary>
 /// Formats the properties of SeriesData object in a generic manner.
 /// </summary>
 /// <param name="data">The series information to be formatted.</param>
 /// <returns>A string of the formatted series information. </returns>
 public static string PrintSeriesData(ISeriesData data)
 {
     // Todo: Implement.
     throw new NotImplementedException();
 }
 public SeriesIdentifier(ISeriesData other)
 {
     CopyFrom(other);
 }
 public SeriesIdentifier(ISeriesData other, IIdentifier identifier)
     : base(identifier)
 {
     CopyFrom(other);
 }
Пример #14
0
 public NotificationSeries(ISeriesData s)
     : base(s)
 {
 }
 public NotificationSeries(ISeriesData s)
     : base(s)
 { }