本文整理汇总了C#中ICloningContext类的典型用法代码示例。如果您正苦于以下问题:C# ICloningContext类的具体用法?C# ICloningContext怎么用?C# ICloningContext使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ICloningContext类属于命名空间,在下文中一共展示了ICloningContext类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: MammographyImageSpatialTransform
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected MammographyImageSpatialTransform(MammographyImageSpatialTransform source, ICloningContext context)
: base(source, context)
{
context.CloneFields(source, this);
_imagePosterior = new Vector3D(source._imagePosterior);
}
开发者ID:nhannd,项目名称:Xian,代码行数:12,代码来源:MammographyImageSpatialTransform.cs
示例2: SimpleDataModalityLut
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected SimpleDataModalityLut(SimpleDataModalityLut source, ICloningContext context)
{
context.CloneFields(source, this);
//clone the actual buffer
_data = (double[]) source._data.Clone();
}
开发者ID:m-berkani,项目名称:ClearCanvas,代码行数:12,代码来源:SimpleDataModalityLut.cs
示例3: MammogramAnnotationLayoutProxy
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected MammogramAnnotationLayoutProxy(MammogramAnnotationLayoutProxy source, ICloningContext context)
{
context.CloneFields(source, this);
// clone the annotation boxes with their state!
if (source._annotationBoxes != null)
{
var annotationBoxes = new Dictionary<object, AnnotationBox>();
foreach (var sourceBox in source._annotationBoxes.Values)
{
var cloneBox = (AnnotationBox) CloneBuilder.Clone(sourceBox);
// if the box has an item, use the item's identifier as the key
object key = cloneBox;
if (cloneBox.AnnotationItem != null)
{
key = cloneBox.AnnotationItem.GetIdentifier();
// if for some reason the key is a duplicate, use the box as the key (but keep it as part of the layout!)
if (annotationBoxes.ContainsKey(key))
key = cloneBox;
}
annotationBoxes.Add(key, cloneBox);
}
_annotationBoxes = annotationBoxes;
}
}
开发者ID:m-berkani,项目名称:ClearCanvas,代码行数:32,代码来源:MammogramAnnotationLayoutProxy.cs
示例4: ColorMapManagerProxy
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected ColorMapManagerProxy(ColorMapManagerProxy source, ICloningContext context)
{
context.CloneFields(source, this);
_placeholderColorMapManager = new ColorMapManager(_placeholderColorMapInstaller = source._placeholderColorMapInstaller.Clone());
_layerOpacityManager = new XLayerOpacityManager(this);
}
开发者ID:m-berkani,项目名称:ClearCanvas,代码行数:12,代码来源:ColorMapManagerProxy.cs
示例5: FusionOverlayCompositeGraphic
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected FusionOverlayCompositeGraphic(FusionOverlayCompositeGraphic source, ICloningContext context)
{
context.CloneFields(source, this);
_overlayFrameDataReference = source._overlayFrameDataReference.Clone();
_overlayFrameDataReference.FusionOverlayFrameData.Unloaded += HandleOverlayFrameDataUnloaded;
}
开发者ID:m-berkani,项目名称:ClearCanvas,代码行数:12,代码来源:FusionOverlayCompositeGraphic.cs
示例6: FusionPresentationImage
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected FusionPresentationImage(FusionPresentationImage source, ICloningContext context) : base(source, context)
{
context.CloneFields(source, this);
_baseFrameReference = source._baseFrameReference.Clone();
_overlayFrameDataReference = source._overlayFrameDataReference.Clone();
}
开发者ID:nhannd,项目名称:Xian,代码行数:12,代码来源:FusionPresentationImage.cs
示例7: AsyncDicomGrayscalePresentationImage
protected AsyncDicomGrayscalePresentationImage(DicomGrayscalePresentationImage source, ICloningContext context)
: base(source, context)
{
context.CloneFields(source, this);
Initialize();
}
开发者ID:UIKit0,项目名称:ClearCanvas,代码行数:7,代码来源:AsyncDicomGrayscalePresentationImage.cs
示例8: RoiCalloutGraphic
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected RoiCalloutGraphic(RoiCalloutGraphic source, ICloningContext context)
: base(source, context)
{
context.CloneFields(source, this);
_roiAnalyzers.AddRange(source._roiAnalyzers);
foreach(var analyzer in _roiAnalyzers)
{
analyzer.SetRoiAnalyzerUpdateCallback(Refresh);
}
}
开发者ID:nhannd,项目名称:Xian,代码行数:15,代码来源:RoiCalloutGraphic.cs
示例9: RootModelSpatialTransform
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected RootModelSpatialTransform(RootModelSpatialTransform source, ICloningContext context)
: base(source, context)
{
context.CloneFields(source, this);
_rootTransform3D.ParentTransform = this;
if (source._cumulativeTransform3D != null)
_cumulativeTransform3D = source._cumulativeTransform3D.Clone();
}
开发者ID:m-berkani,项目名称:ClearCanvas,代码行数:15,代码来源:RootModelSpatialTransform.cs
示例10: ExtensionData
/// <summary>
/// Cloning constructor.
/// </summary>
private ExtensionData(ExtensionData source, ICloningContext context)
{
_data = new Dictionary<Type, object>();
foreach (var sourceData in source._data)
{
var valueClone = CloneBuilder.Clone(sourceData.Value);
if (valueClone != null)
_data[sourceData.Key] = valueClone;
}
}
开发者ID:UIKit0,项目名称:ClearCanvas,代码行数:13,代码来源:ExtensionData.cs
示例11: SpatialTransform
/// <summary>
/// Cloning constructor.
/// </summary>
protected SpatialTransform(SpatialTransform source, ICloningContext context)
{
context.CloneFields(source, this);
if (source._cumulativeTransform != null)
_cumulativeTransform = source._cumulativeTransform.Clone();
if (source._transform != null)
_transform = source._transform.Clone();
}
开发者ID:m-berkani,项目名称:ClearCanvas,代码行数:13,代码来源:SpatialTransform.cs
示例12: GeometricShuttersGraphic
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected GeometricShuttersGraphic(GeometricShuttersGraphic source, ICloningContext context)
: this(source._imageRectangle.Height, source._imageRectangle.Width)
{
context.CloneFields(source, this);
foreach (GeometricShutter shutter in source._customShutters)
_customShutters.Add(shutter.Clone());
foreach (GeometricShutter shutter in source._dicomShutters)
_dicomShutters.Add(shutter.Clone());
}
开发者ID:nhannd,项目名称:Xian,代码行数:16,代码来源:GeometricShuttersGraphic.cs
示例13: StoredAnnotationLayout
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">This parameter is unused.</param>
private StoredAnnotationLayout(StoredAnnotationLayout source, ICloningContext context)
{
this._identifier = source._identifier;
this._visible = source._visible;
foreach (StoredAnnotationBoxGroup group in source._annotationBoxGroups)
{
if (group == null)
continue;
this._annotationBoxGroups.Add(group.Clone());
}
}
开发者ID:nhannd,项目名称:Xian,代码行数:16,代码来源:StoredAnnotationLayout.cs
示例14: MultiplexedConstructor
/// <summary>
/// Creates a new <see cref="MultiplexedConstructor"/>.
/// </summary>
/// <param name="cloningContext">cloning context.</param>
/// <param name="constructor">Constructor to multiplex.</param>
private MultiplexedConstructor(ICloningContext cloningContext, MethodDefinition constructor)
{
Contract.Requires(cloningContext != null);
Contract.Requires(constructor != null);
Contract.Ensures(this.CloningContext != null);
Contract.Ensures(this.Constructor != null);
Contract.Ensures(this.Variables != null);
this.CloningContext = cloningContext;
this.Constructor = constructor;
this.ThisParameter = constructor.Body.ThisParameter;
this.Variables = new List<VariableDefinition>(constructor.Body.Variables);
}
开发者ID:rileywhite,项目名称:Cilador,代码行数:19,代码来源:MultiplexedConstructor.cs
示例15: MammogramAnnotationLayoutProxy
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected MammogramAnnotationLayoutProxy(MammogramAnnotationLayoutProxy source, ICloningContext context)
{
context.CloneFields(source, this);
// clone the annotation boxes with their state!
if (source._annotationBoxes != null)
{
var annotationBoxes = new Dictionary<object, AnnotationBox>();
foreach (var sourceBox in source._annotationBoxes.Values)
{
var cloneBox = (AnnotationBox) CloneBuilder.Clone(sourceBox);
if (cloneBox.AnnotationItem != null)
annotationBoxes.Add(cloneBox.AnnotationItem.GetIdentifier(), cloneBox);
else
annotationBoxes.Add(cloneBox, cloneBox);
}
_annotationBoxes = annotationBoxes;
}
}
开发者ID:UIKit0,项目名称:ClearCanvas,代码行数:24,代码来源:MammogramAnnotationLayoutProxy.cs
示例16: DicomColorPresentationImage
/// <summary>
/// Cloning constructor.
/// </summary>
protected DicomColorPresentationImage(DicomColorPresentationImage source, ICloningContext context)
: base(source, context)
{
Frame frame = source.Frame;
_frameReference = frame.CreateTransientReference();
}
开发者ID:nhannd,项目名称:Xian,代码行数:9,代码来源:DicomColorPresentationImage.cs
示例17: OverlayPlaneGraphic
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected OverlayPlaneGraphic(OverlayPlaneGraphic source, ICloningContext context) : base()
{
context.CloneFields(source, this);
}
开发者ID:UIKit0,项目名称:ClearCanvas,代码行数:9,代码来源:OverlayPlaneGraphic.cs
示例18: ColorBarGraphic
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected ColorBarGraphic(ColorBarGraphic source, ICloningContext context)
{
context.CloneFields(source, this);
_colorMapManagerProxy = new ColorMapManager(new ColorMapInstallerProxy());
if (source._colorMapManagerProxy.ColorMap != null)
_colorMapManagerProxy.SetMemento(source._colorMapManagerProxy.CreateMemento());
if (source._gradientPixelData != null)
_gradientPixelData = source._gradientPixelData.Clone();
}
开发者ID:m-berkani,项目名称:ClearCanvas,代码行数:16,代码来源:ColorBarGraphic.cs
示例19: SeriesDisplaySetDescriptor
protected SeriesDisplaySetDescriptor(SeriesDisplaySetDescriptor source, ICloningContext context)
: base(source, context)
{
}
开发者ID:UIKit0,项目名称:ClearCanvas,代码行数:4,代码来源:DisplaySetFactories.cs
示例20: AdjustableDataLut
/// <summary>
/// Cloning constructor.
/// </summary>
/// <param name="source">The source object from which to clone.</param>
/// <param name="context">The cloning context object.</param>
protected AdjustableDataLut(AdjustableDataLut source, ICloningContext context)
{
context.CloneFields(source, this);
Platform.CheckForNullReference(_dataLut, "_dataLut");
Platform.CheckForNullReference(_linearLut, "_linearLut");
_linearLut.LutChanged += OnLinearLutChanged;
_dataLut.LutChanged += OnDataLutChanged;
}
开发者ID:UIKit0,项目名称:ClearCanvas,代码行数:15,代码来源:AdjustableDataLut.cs
注:本文中的ICloningContext类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论