本文整理汇总了C#中Dicom.Data.DicomTag类的典型用法代码示例。如果您正苦于以下问题:C# DicomTag类的具体用法?C# DicomTag怎么用?C# DicomTag使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
DicomTag类属于Dicom.Data命名空间,在下文中一共展示了DicomTag类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: DcmItem
public DcmItem(DicomTag tag, DicomVR vr, long pos, Endian endian)
{
_tag = tag;
_vr = vr;
_streamPosition = pos;
_endian = endian;
}
开发者ID:gogorrr,项目名称:mdcm,代码行数:7,代码来源:DcmItem.cs
示例2: ConstructorPrivateCreator
public void ConstructorPrivateCreator()
{
var t = new DicomTag(0x2000, 0x2001, "TEST CREATOR");
Assert.AreEqual(0x2000, t.Group);
Assert.AreEqual(0x2001, t.Element);
Assert.AreEqual("TEST CREATOR", t.PrivateCreator);
}
开发者ID:fo-dicom,项目名称:mdcm,代码行数:7,代码来源:DicomTagTest.cs
示例3: ConstructorSimple
public void ConstructorSimple()
{
var t = new DicomTag(0x0028, 0x1203);
Assert.AreEqual(t.Group, 0x0028);
Assert.AreEqual(t.Element, 0x1203);
Assert.IsEmpty(t.PrivateCreator);
}
开发者ID:fo-dicom,项目名称:mdcm,代码行数:7,代码来源:DicomTagTest.cs
示例4: Equals
public void Equals()
{
var a = new DicomTag(0x0028, 0x9145);
var b = new DicomTag(0x0028, 0x9146);
var c = new DicomTag(0x0028, 0x9146);
var z = default(DicomTag);
Assert.IsFalse(a.Equals(b));
Assert.IsFalse(b.Equals(a));
Assert.IsTrue(b.Equals(c));
Assert.IsTrue(c.Equals(b));
Assert.IsFalse(a.Equals(z));
Assert.IsFalse(b.Equals(z));
}
开发者ID:fo-dicom,项目名称:mdcm,代码行数:13,代码来源:DicomTagTest.cs
示例5: EqualsObject
public void EqualsObject()
{
var a = new DicomTag(0x0028, 0x9145);
var b = new DicomTag(0x0028, 0x9146);
var c = new DicomTag(0x0028, 0x9146);
var z = default(DicomTag);
Assert.IsFalse(a.Equals((object)b));
Assert.IsFalse(b.Equals((object)a));
Assert.IsTrue(b.Equals((object)c));
Assert.IsTrue(c.Equals((object)b));
Assert.IsFalse(a.Equals((object)z));
Assert.IsFalse(b.Equals((object)z));
}
开发者ID:fo-dicom,项目名称:mdcm,代码行数:13,代码来源:DicomTagTest.cs
示例6: OpNEq
public void OpNEq()
{
var a = new DicomTag(0x0028, 0x9145);
var b = new DicomTag(0x0028, 0x9146);
var c = new DicomTag(0x0028, 0x9146);
var z = default(DicomTag);
Assert.IsTrue(a != b);
Assert.IsTrue(b != a);
Assert.IsFalse(b != c);
Assert.IsFalse(c != b);
Assert.IsTrue(z != a);
Assert.IsTrue(a != z);
Assert.IsTrue(z != b);
Assert.IsTrue(b != z);
}
开发者ID:fo-dicom,项目名称:mdcm,代码行数:15,代码来源:DicomTagTest.cs
示例7: OpEq
public void OpEq()
{
var a = new DicomTag(0x0028, 0x9145);
var b = new DicomTag(0x0028, 0x9146);
var c = new DicomTag(0x0028, 0x9146);
var z = default(DicomTag);
Assert.IsFalse(a == b);
Assert.IsFalse(b == a);
Assert.IsTrue(b == c);
Assert.IsTrue(c == b);
Assert.IsFalse(z == a);
Assert.IsFalse(a == z);
Assert.IsFalse(z == b);
Assert.IsFalse(b == z);
}
开发者ID:fo-dicom,项目名称:mdcm,代码行数:15,代码来源:DicomTagTest.cs
示例8: GetUL
public DcmUnsignedLong GetUL(DicomTag tag)
{
DcmElement elem = GetElement(tag);
if (elem is DcmUnsignedLong)
return elem as DcmUnsignedLong;
if (elem != null)
throw new DicomDataException("Tried to access element with incorrect VR");
return null;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:9,代码来源:DcmDataset.cs
示例9: GetUInt16
public ushort GetUInt16(DicomTag tag, ushort deflt)
{
DcmUnsignedShort us = GetUS(tag);
if (us != null && us.Length > 0)
return us.GetValue();
return deflt;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:7,代码来源:DcmDataset.cs
示例10: GetUID
public DicomUID GetUID(DicomTag tag)
{
DcmUniqueIdentifier ui = GetUI(tag);
if (ui != null && ui.Length > 0)
return ui.GetUID();
return null;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:7,代码来源:DcmDataset.cs
示例11: GetUI
public DcmUniqueIdentifier GetUI(DicomTag tag)
{
DcmElement elem = GetElement(tag);
if (elem is DcmUniqueIdentifier)
return elem as DcmUniqueIdentifier;
if (elem != null)
throw new DicomDataException("Tried to access element with incorrect VR");
return null;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:9,代码来源:DcmDataset.cs
示例12: GetInt16
public short GetInt16(DicomTag tag, short deflt)
{
DcmSignedShort ss = GetSS(tag);
if (ss != null && ss.Length > 0)
return ss.GetValue();
return deflt;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:7,代码来源:DcmDataset.cs
示例13: OnReceiveNGetRequest
protected virtual void OnReceiveNGetRequest(byte presentationID, ushort messageID, DicomUID requestedClass, DicomUID requestedInstance, DicomTag[] attributes)
{
SendAbort(DcmAbortSource.ServiceProvider, DcmAbortReason.NotSpecified);
}
开发者ID:JeanLedesma,项目名称:mdcm,代码行数:4,代码来源:DcmNetworkBase.cs
示例14: GetVR
public DicomVR GetVR(DicomTag tag)
{
DcmElement elem = GetElement(tag);
if (elem == null)
return null;
return elem.VR;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:7,代码来源:DcmDataset.cs
示例15: GetString
public string GetString(DicomTag tag, string deflt)
{
return GetString(tag, 0, deflt);
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:4,代码来源:DcmDataset.cs
示例16: GetSS
public DcmSignedShort GetSS(DicomTag tag)
{
DcmElement elem = GetElement(tag);
if (elem is DcmSignedShort)
return elem as DcmSignedShort;
if (elem != null)
throw new DicomDataException("Tried to access element with incorrect VR");
return null;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:9,代码来源:DcmDataset.cs
示例17: GetSQ
public DcmItemSequence GetSQ(DicomTag tag)
{
DcmItem item = GetItem(tag);
if (item is DcmItemSequence)
return item as DcmItemSequence;
if (item != null)
throw new DicomDataException("Tried to access element with incorrect VR");
return null;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:9,代码来源:DcmDataset.cs
示例18: GetOW
public DcmOtherWord GetOW(DicomTag tag)
{
DcmElement elem = GetElement(tag);
if (elem is DcmOtherWord)
return elem as DcmOtherWord;
if (elem != null)
throw new DicomDataException("Tried to access element with incorrect VR");
return null;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:9,代码来源:DcmDataset.cs
示例19: GetItem
public DcmItem GetItem(DicomTag tag)
{
DcmItem item = null;
if (!_items.TryGetValue(tag, out item))
return null;
return item;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:7,代码来源:DcmDataset.cs
示例20: GetInt32
public int GetInt32(DicomTag tag, int deflt)
{
DcmElement elem = GetElement(tag);
if (elem != null && elem.Length > 0) {
if (elem.VR == DicomVR.IS)
return (elem as DcmIntegerString).GetInt32();
else if (elem.VR == DicomVR.SL)
return (elem as DcmSignedLong).GetValue();
else
throw new DicomDataException("Tried to access element " + tag.ToString() + " with incorrect VR");
}
return deflt;
}
开发者ID:karanbajaj,项目名称:mdcm,代码行数:13,代码来源:DcmDataset.cs
注:本文中的Dicom.Data.DicomTag类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论