Table of Contents

Class ComplexAmplitudeView

Namespace
VirtualLabAPI.Core.FieldRepresentations
Assembly
VirtualLabAPI.dll

Class which combines a complex amplitude with view settings.

[Serializable]
public class ComplexAmplitudeView : ManualSerialization, IEquatable<IObjectBase>, ISerializable, IDeserializationCallback, IDisposable, ICloneable
Inheritance
ObjectBase
SerializableObjectBase
ManualSerialization
ComplexAmplitudeView
Implements
IEquatable<IObjectBase>
Inherited Members

Constructors

ComplexAmplitudeView(ComplexAmplitude)

Constructor using default view settings.

public ComplexAmplitudeView(ComplexAmplitude complexAmplitude)

Parameters

complexAmplitude ComplexAmplitude

The complex amplitude with which the class shall be initialized.

ComplexAmplitudeView(ComplexAmplitude, ViewProperties)

Default constructor

public ComplexAmplitudeView(ComplexAmplitude complexAmplitude, ViewProperties viewSettings)

Parameters

complexAmplitude ComplexAmplitude

The complex amplitude with which the class shall be initialized.

viewSettings ViewProperties

The view properties with which the class shall be initialized.

ComplexAmplitudeView(ComplexAmplitude, ViewProperties, string)

Default constructor

public ComplexAmplitudeView(ComplexAmplitude complexAmplitude, ViewProperties viewSettings, string comment)

Parameters

complexAmplitude ComplexAmplitude

The complex amplitude with which the class shall be initialized.

viewSettings ViewProperties

The view properties with which the class shall be initialized.

comment string

Comment being displayed in parameter run (subdetector)

Fields

Comment

Comment to be displayed.

public string Comment

Field Value

string

ComplexAmplitude

The underlying complex amplitude.

public ComplexAmplitude ComplexAmplitude

Field Value

ComplexAmplitude

Properties

ViewSettings

Gets and sets the view settings which shall be applied to the complex amplitude.

public ViewProperties ViewSettings { get; set; }

Property Value

ViewProperties

Methods

Clone()

Creates a new object that is a copy of the current instance.

public override object Clone()

Returns

object

A new object that is a copy of this instance.

Dispose()

Dispose functionality

public void Dispose()

Equals(object, EqualityIntent)

Determines whether the specified object is equal to this instance.

public override bool Equals(object otherObject, EqualityIntent equalityIntent)

Parameters

otherObject object

The object to compare with this instance.

equalityIntent EqualityIntent

Defines what kind of equality you want to check when comparing two objects, for example all values or just physical equality.

Returns

bool

true if the specified object is equal to this instance; otherwise, false.

ManualSerializationExceptionHandling(SerializationInfo, StreamingContext, FieldInfo)

This method normally has to be overridden by derived classes by their own exception handling. Especially version problems due to late changes on a VL class has to be handled THERE by

  1. check if fInfo.DeclaringType == typeof({Classname}), if so : 2a. proper handling of the missing or spare or renamed value, (sometimes (for PROTECTED variables?) you have to add the class name as a prefix: "classname+variablename") if not: 2b. call of the base class implementation of this method.
public override void ManualSerializationExceptionHandling(SerializationInfo sInfo, StreamingContext context, FieldInfo fInfo)

Parameters

sInfo SerializationInfo

Serialization info containing the data.(see also .Net documentation)

context StreamingContext

Serialization context (see also .Net documentation).

fInfo FieldInfo

Field that failed during deserialization.

Show(string, bool, Action<FormDocument>)

Shows the complex amplitude with the corresponding view settings.

public void Show(string caption, bool cloneDocument = true, Action<FormDocument> changeFormAfterShow = null)

Parameters

caption string

The caption of the shown document.

cloneDocument bool

If set this optional parameter is set to false this document is shown. Otherwise a cloned copy of this document is shown.

changeFormAfterShow Action<FormDocument>

Optional method which is called after the document window is shown. In this way you can change view settings of the form if required.

ToString()

overridden ToString() function. Used for parameter run.

public override string ToString()

Returns

string

The name of the object as string.