/AcquisitionInterface/bin/Release/API-1.0.xml
XML | 2666 lines | 2612 code | 54 blank | 0 comment | 0 complexity | a8c9e0b0ae87ae6418833e672630a8b6 MD5 | raw file
Large files files are truncated, but you can click here to view the full file
- <?xml version="1.0"?>
- <doc>
- <assembly>
- <name>API-1.0</name>
- </assembly>
- <members>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.AnalogTracePointEventArgs">
- <summary>
- This implementation of EventArgs carries an <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTracePoint"/>.
- </summary>
- <remarks>
- See <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTraceContainer"/> for an example how this class can be used.
- <para>
- An instance of this class will be created by <see cref="E:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTraceContainer.AnalogTracePointArrived"/>.
- </para>
- </remarks>
- </member>
- <member name="M:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.AnalogTracePointEventArgs.#ctor">
- <summary>
- Create a new <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.AnalogTracePointEventArgs"/>.
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.AnalogTracePointEventArgs.TracePoint">
- <summary>
- Get access to the analog trace point that has just arrived from the instrument.
- It has replaced already the LastValue in the <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTraceContainer"/>.
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.Control.IParameterDescription">
- <summary>
- This interface has information about a possible Set argument for an <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.InstrumentValues.IValue"/> or
- a property in a Scan parameter set.
- </summary>
- <remarks>
- An instance of this class will be created by <see cref="P:Thermo.Interfaces.InstrumentAccess_V1.Control.InstrumentValues.IValue.SetParameterDescription"/> or by
- <see cref="P:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScans.PossibleParameters"/> or by
- IExactiveValue.Commands.
- </remarks>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.Control.IParameterDescription.Name">
- <summary>
- This is the name of the command/property this parameter description belongs to.
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.Control.IParameterDescription.Selection">
- <summary>
- The selection is a little bit complicated. It can have these values:
- <list type="table">
- <listheader><description>value/example</description><description>description</description></listheader>
- <item><description>empty</description><description>This empty string is allowed and doesn't allow the user any selection</description></item>
- <item><description>string</description><description>This special value (verbatim "string") allows the user to enter an arbitrary string</description></item>
- <item><description>num1-num2</description><description>Integer selection between num1 and num2 inclusively</description></item>
- <item><description>num1.frac-num2.frac</description><description>Floating point selection between num1.frac and num2.frac inclusively, frac may be "0"</description></item>
- <item><description>selection1,selection2,...</description><description>lets the user select one of the shown values</description></item>
- </list>
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.Control.IParameterDescription.DefaultValue">
- <summary>
- This value will be the default value for the argument or
- the empty string if it is unknown.
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.Control.IParameterDescription.Help">
- <summary>
- This returns the empty string or some help about the command/property.
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTraceContainer">
- <summary>
- All analog trace points of the instrument can be accessed by using this
- interface.
- <para>
- The last-seen value is accessible all the time but may change frequently.
- It is also possible to get notice of a new value as soon as it is accessible.
- </para>
- </summary>
- <remarks>
- An instance of this class will be created by <see cref="M:Thermo.Interfaces.InstrumentAccess_V1.IInstrumentAccess.GetAnalogTraceContainer(System.Int32)"/>.
- </remarks>
- <example>
- In the following example it is assumed that the instrument has two analog
- input devices as most Orbitrap systems and many other MS instruments have:
- <code>
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
-
- using Thermo.Interfaces.ExactiveAccess_V1;
- using Thermo.Interfaces.InstrumentAccess_V1;
- using Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer;
-
- namespace UserAccess
- {
- /// <summary>
- /// This class displays the output of the analog channels when they arrive.
- /// </summary>
- internal class AnalogOutput
- {
- /// <summary>
- /// Create a new <see cref="AnalogOutput"/> and make sure two analog channels are observed.
- /// </summary>
- /// <param name="instrument">the instrument instance</param>
- internal AnalogOutput(IInstrumentAccess instrument)
- {
- Analog1 = instrument.GetAnalogTraceContainer(0);
- Analog1.AnalogTracePointArrived += new EventHandler{AnalogTracePointEventArgs}(Instrument_AnalogTracePointArrived);
- Analog2 = instrument.GetAnalogTraceContainer(1);
- Analog2.AnalogTracePointArrived += new EventHandler{AnalogTracePointEventArgs}(Instrument_AnalogTracePointArrived);
- }
-
- /// <summary>
- /// Cleanup this instance.
- /// </summary>
- internal void CloseDown()
- {
- // Be tolerant to thread-switches
- IAnalogTraceContainer analogContainer;
-
- analogContainer = Analog1;
- Analog1 = null;
- if (analogContainer != null)
- {
- analogContainer.AnalogTracePointArrived -= new EventHandler{AnalogTracePointEventArgs}(Instrument_AnalogTracePointArrived);
- }
-
- analogContainer = Analog2;
- Analog2 = null;
- if (analogContainer != null)
- {
- analogContainer.AnalogTracePointArrived -= new EventHandler{AnalogTracePointEventArgs}(Instrument_AnalogTracePointArrived);
- }
- }
-
- /// <summary>
- /// Access to the first analog container.
- /// </summary>
- private IAnalogTraceContainer Analog1 { get; set; }
-
- /// <summary>
- /// Access to the second analog container.
- /// </summary>
- private IAnalogTraceContainer Analog2 { get; set; }
-
- /// <summary>
- /// When an analog event arrives we dump the content.
- /// </summary>
- /// <param name="sender">used to identify the channel</param>
- /// <param name="e">content will be dumped</param>
- private void Instrument_AnalogTracePointArrived(object sender, AnalogTracePointEventArgs e)
- {
- IAnalogTraceContainer analogTrace = sender as IAnalogTraceContainer;
- if (analogTrace != null)
- {
- Console.WriteLine("{0}: [{1} - {2}]: {3} at {4} s", analogTrace.DetectorClass, analogTrace.Minimum, analogTrace.Maximum, e.TracePoint.Value, e.TracePoint.Occurrence.TotalSeconds);
- }
- }
- }
- }
- </code>
- </example>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTraceContainer.DetectorClass">
- <summary>
- Get access to the detector class.
- <para>
- Example: The detector name may be "PDA", but "Analog Input Channel 1"
- or something similar is also possible.
- </para>
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTraceContainer.Minimum">
- <summary>
- Get access to the lowest possible value of the detector or analog input.
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTraceContainer.Maximum">
- <summary>
- Get access to the highest possible value of the detector or analog input.
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTraceContainer.UpdateFrequencyHz">
- <summary>
- Get access to acquisition frequency of the values. null is returned if the
- system has no specific frequency. The value is returned in 1/s (Hertz).
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTraceContainer.LastValue">
- <summary>
- Get access to the last value seen in the system.
- The value can be null initially.
- </summary>
- </member>
- <member name="E:Thermo.Interfaces.InstrumentAccess_V1.AnalogTraceContainer.IAnalogTraceContainer.AnalogTracePointArrived">
- <summary>
- This event will be fired when a new analog value has been emitted by the
- instrument. There may be no specific update frequency.
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.MsScanContainer.IMsScanContainer">
- <summary>
- All MS scans of the instrument can be accessed by using this
- interface.
- <para>
- The last-seen scan is accessible all the time but may change frequently.
- It is also possible to get notice of a new scan as soon as it is accessible.
- </para>
- </summary>
- <remarks>
- An instance of this class will be created by <see cref="M:Thermo.Interfaces.InstrumentAccess_V1.IInstrumentAccess.GetMsScanContainer(System.Int32)"/>.
- </remarks>
- <example>
- In the following example it is assumed that the instrument has at least one
- MS device. Most functions and classes of this namesspace are used.
- <code>
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
-
- using Thermo.Interfaces.InstrumentAccess_V1;
- using Thermo.Interfaces.InstrumentAccess_V1.MsScanContainer;
-
- namespace UserAccess
- {
- /// <summary>
- /// This class presents the output of the scans being acquired by the instrument.
- /// </summary>
- internal class ScansOutput
- {
- /// <summary>
- /// Crate a new <see cref="ScansOutput"/>
- /// </summary>
- /// <param name="instrument">the instrument instance</param>
- internal ScansOutput(IInstrumentAccess instrument)
- {
- ScanContainer = instrument.GetMsScanContainer(0);
- Console.WriteLine("Detector class: " + ScanContainer.DetectorClass);
-
- ScanContainer.AcquisitionStreamOpening += new EventHandler<MsAcquisitionOpeningEventArgs>(ScanContainer_AcquisitionStarted);
- ScanContainer.AcquisitionStreamClosing += new EventHandler(ScanContainer_AcquisitionEnded);
- ScanContainer.MsScanArrived += new EventHandler<MsScanEventArgs>(ScanContainer_ScanArrived);
- }
-
- /// <summary>
- /// Show the last acquired scan if that exists and cleanup.
- /// </summary>
- internal void CloseDown()
- {
- // Be tolerant to thread-switches
- IMsScanContainer scanContainer = ScanContainer;
- ScanContainer = null;
-
- if (scanContainer != null)
- {
- scanContainer.MsScanArrived -= new EventHandler<MsScanEventArgs>(ScanContainer_ScanArrived);
- scanContainer.AcquisitionStreamClosing -= new EventHandler(ScanContainer_AcquisitionEnded);
- scanContainer.AcquisitionStreamOpening -= new EventHandler<MsAcquisitionOpeningEventArgs>(ScanContainer_AcquisitionStarted);
- using (IMsScan scan = scanContainer.GetLastMsScan())
- {
- DumpScan("GetLastScan()", scan);
- }
- }
- }
-
- /// <summary>
- /// Access to the scan container hosted by this instance.
- /// </summary>
- private IMsScanContainer ScanContainer { get; set; }
-
- /// <summary>
- /// When a new acquisition starts we dump that information.
- /// </summary>
- /// <param name="sender">doesn't matter</param>
- /// <param name="e">doesn't matter</param>
- private void ScanContainer_AcquisitionStarted(object sender, EventArgs e)
- {
- Console.WriteLine("START OF ACQUISITION");
- }
-
- /// <summary>
- /// When an acquisitions ends we dump that information.
- /// </summary>
- /// <param name="sender">doesn't matter</param>
- /// <param name="e">doesn't matter</param>
- private void ScanContainer_AcquisitionEnded(object sender, EventArgs e)
- {
- Console.WriteLine("END OF ACQUISITION");
- }
-
- /// <summary>
- /// When a new scan arrives we dump that information in verbose mode.
- /// </summary>
- /// <param name="sender">doesn't matter</param>
- /// <param name="e">used to access the scan information</param>
- private void ScanContainer_ScanArrived(object sender, MsScanEventArgs e)
- {
- Console.WriteLine("Scan arrived");
- // As an example we access all centroids
- using (IMsScan scan = e.GetScan())
- {
- DumpScan("Scan arrived", scan);
- }
- }
-
- /// <summary>
- /// Dump a scan and prepend it with an intro string.
- /// </summary>
- /// <param name="intro">string to prepend</param>
- /// <param name="scan">thing to dump</param>
- private void DumpScan(string intro, IMsScan scan)
- {
- StringBuilder sb = new StringBuilder();
- sb.AppendFormat(Instrument.Now.ToString(Program.TimeFormat));
- sb.Append(": ");
- sb.Append(intro);
- sb.Append(", ");
- if (scan == null)
- {
- sb.Append("(empty scan)");
- Console.WriteLine(sb.ToString());
- return;
- }
- else
- {
- sb.Append("detector=");
- sb.Append(scan.DetectorName);
- string id;
- if (scan.SpecificInformation.TryGetValue("Access Id:", out id))
- {
- sb.Append(", id=");
- sb.Append(id);
- }
- Console.WriteLine(sb.ToString());
- }
-
- // This is rather noisy, dump all variables:
- DumpVars(scan);
-
- Console.Write(" Noise: ");
- foreach (INoiseNode noise in scan.NoiseBand)
- {
- Console.Write("[{0}, {1}], ", noise.Mz, noise.Intensity);
- }
- Console.WriteLine();
-
- // Not so useful:
- Console.WriteLine("{0} centroids, {1} profile peaks", scan.CentroidCount ?? 0, scan.ProfileCount ?? 0);
-
- // Iterate over all centroids and access dump all profile elements for each.
- foreach (ICentroid centroid in scan.Centroids)
- {
- Console.WriteLine(" {0,10:F5}, I={1:E5}, C={2}, E={3,-5} F={4,-5} M={5,-5} R={6,-5}",
- centroid.Mz, centroid.Intensity, centroid.Charge ?? -1, centroid.IsExceptional, centroid.IsFragmented, centroid.IsMerged, centroid.IsReferenced);
- Console.Write(" Profile:");
- try
- {
- foreach (IMassIntensity profilePeak in centroid.Profile)
- {
- Console.Write(" [{0,10:F5},{1:E5}] ", profilePeak.Mz, profilePeak.Intensity);
- }
- }
- catch
- {
- }
- Console.WriteLine();
- }
- }
-
- /// <summary>
- /// Dump all variables belonging to a scan
- /// </summary>
- /// <param name="scan">the scan for which to dump all variables</param>
- private void DumpVars(IMsScan scan)
- {
- Console.WriteLine(" COMMON");
- DumpVars(scan.CommonInformation);
- Console.WriteLine(" SPECIFIC");
- DumpVars(scan.SpecificInformation);
- }
-
- /// <summary>
- /// Dump all scan variables belonging to a specific container in a scan.
- /// </summary>
- /// <param name="container">container to dump all contained variables for</param>
- private void DumpVars(IInfoContainer container)
- {
- foreach (string s in container.Names)
- {
- DumpVar(container, s);
- }
- }
-
- /// <summary>
- /// Dump the content of a single variable to the console after testing the consistency.
- /// </summary>
- /// <param name="container">container that variable belongs to</param>
- /// <param name="name">name of the variable</param>
- /// <param name="sb">buffer to be reused for speed</param>
- private void DumpVar(IInfoContainer container, string name)
- {
- object o = null;
- string s = null;
- MsScanInformationSource i = MsScanInformationSource.Unknown;
-
- if (container.TryGetValue(name, out s, ref i))
- {
- // i should have a reasonable value now
- if (container.TryGetRawValue(name, out o, ref i))
- {
- Console.WriteLine(" {0}: type={1}, text='{2}', raw='{3}'",
- name, i, s, o);
- }
- }
- }
- }
- }
- </code>
- </example>
- </member>
- <member name="M:Thermo.Interfaces.InstrumentAccess_V1.MsScanContainer.IMsScanContainer.GetLastMsScan">
- <summary>
- Get access to the last scan seen in the system.
- The value can be null initially.
- <para>
- Note that accessing this property forces the consumer to dispose
- the item as soon as possible in order to free its shared memory resources.
- </para>
- </summary>
- <returns>The method returns the latest scan the framework is aware off. It may be null.</returns>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.MsScanContainer.IMsScanContainer.DetectorClass">
- <summary>
- Get access to the detector class. The class should include describe
- the instrument detector set precisely, although the individual
- detector type of a scan uses only a part of the instrument set.
- <para>
- Example: The instrument name may be "Thermo Orbitrap Velos Pro", the
- detector class may be "Hybrid LinearIonTrap Orbitrap" and the
- scan detector name may be "LinearIonTrap".
- </para>
- </summary>
- </member>
- <member name="E:Thermo.Interfaces.InstrumentAccess_V1.MsScanContainer.IMsScanContainer.MsScanArrived">
- <summary>
- This event will be fired when a new scan has been emitted by the
- instrument.
- <para>
- Any listener to this event must handle the event as fast as possible.
- It is good practice by analyzing tool to enqueue the scan into
- queue and process that queue in another thread.
- </para>
- </summary>
- </member>
- <member name="E:Thermo.Interfaces.InstrumentAccess_V1.MsScanContainer.IMsScanContainer.AcquisitionStreamOpening">
- <summary>
- This event will be fired when a new acquisition is started and the system
- is about to open rawfiles, etc.
- <para>
- Scans may be created without an explicite acquisition if the instrument is
- 'just' set to running. An acquisition is not necessarily bound to a
- rawfile, but it is in most cases.
- </para>
- <para>
- The specific information of a scan will reflect the information whether
- a scan belongs to an acquisition or not.
- </para>
- </summary>
- </member>
- <member name="E:Thermo.Interfaces.InstrumentAccess_V1.MsScanContainer.IMsScanContainer.AcquisitionStreamClosing">
- <summary>
- This event will be fired when the current acquisition ended.
- <para>
- Scans may be created without an explicite acquisition, so further scans may
- arrive after an acquisition stopped. It may even be possible that few scans
- belonging to the last acquisition may arrive and that an opened rawfile
- will gather them because of a flushing data queue on the transport layer.
- </para>
- <para>
- The specific information of a scan will reflect the information whether
- a scan belongs to an acquisition or not.
- </para>
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScanDefinition">
- <summary>
- This interface covers the functionality to define a custom or repeating scan.
- </summary>
- <remarks>
- This is a base interface of <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.ICustomScan"/> and <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IRepeatingScan"/>.
- </remarks>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScanDefinition.Values">
- <summary>
- Get access to the value set. Any value nor defined will be replaced by the
- value defined in the default scan.
- <para>
- Illegal values will be ignored, values out of range will not be accepted.
- </para>
- <para>
- The set of possible values can be queried by accessing PossibleParameters
- in <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScans"/>. The key must be an <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.IParameterDescription"/> Name,
- the value must match the Selection definition.
- </para>
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScanDefinition.RunningNumber">
- <summary>
- This number will be passed along with the scan job and can be used
- to identify it later when the acquired scan results arrive.
- 0 is a reserved value. The default value is 1.
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Methods.NamespaceDoc">
- <summary>
- This namespace covers the functionality that a user may have to manipulate methods of an instrument.
- These manipulations can be applied to the running acquisition.
- <para>
- Most functionality in this namespace is accessible offline.
- </para>
- <para>
- Obtain <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.IControl"/>.<see cref="P:Thermo.Interfaces.InstrumentAccess_V1.Control.IControl.Methods"/>
- to create the desired base class.
- </para>
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.StateChangedEventArgs">
- <summary>
- This implementation of EventArgs carries an <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.IState"/>.
- </summary>
- <remarks>
- See <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.IAcquisition"/> for an example how this class can be used.
- <para>
- An instance of this class will be created by <see cref="E:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.IAcquisition.StateChanged"/>.
- </para>
- </remarks>
- </member>
- <member name="M:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.StateChangedEventArgs.#ctor">
- <summary>
- Create a new <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.StateChangedEventArgs"/>.
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.StateChangedEventArgs.State">
- <summary>
- Get access to the current state of the instrument.
- It has replaced already the State in the <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.IAcquisition"/>.
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.Modes.IOnMode">
- <summary>
- This mode lets an instrument enter the On state or change the behaviour in the On state.
- The request may be rejected if the instrument is in a state that should not be disturbed. See <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.Modes.IForcedStandbyMode"/>.
- </summary>
- <remarks>
- See <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.IAcquisition"/> for an example how this interface can be used.
- <para>
- An instance of this class will be created by <see cref="M:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.IAcquisition.CreateOnMode"/>.
- </para>
- </remarks>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.Modes.IMode">
- <summary>
- A mode is a more or less complex information that selects a new operation mode of an instrument.
- </summary>
- </member>
- <member name="M:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.Modes.IMode.ToString">
- <summary>
- This is an informational description of the new mode.
- </summary>
- <returns>The returned string gives a short description of the mode.</returns>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.Modes.IMode.AdditionalValues">
- <summary>
- Get access to a collection of additional values. This will not be used in most cases.
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.Modes.IForcedOffMode">
- <summary>
- This mode lets an instrument enter the Off state. The request will be honoured even if the
- instrument is within an acquisition or another state where it is usually better to continue.
- See <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.Modes.IForcedOffMode"/>.
- </summary>
- <remarks>
- See <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.IAcquisition"/> for an example how this interface can be used.
- <para>
- An instance of this class will be created by <see cref="M:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.IAcquisition.CreateForcedOffMode"/>.
- </para>
- </remarks>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.ChangeResult">
- <summary>
- Defines the result of a requested instrument mode change.
- </summary>
- <remarks>
- See <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.IAcquisition"/> for an example how this enumeration can be used.
- </remarks>
- </member>
- <member name="F:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.ChangeResult.Submitted">
- <summary>
- This state change request has been submitted to the instrument. The instrument itself may dishonour this request
- if the needed condition to apply the state change request have changed between the submitting and the arrival
- in the instrument.
- </summary>
- </member>
- <member name="F:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.ChangeResult.InstrumentDisconnected">
- <summary>
- The instrument is disconnected.
- </summary>
- </member>
- <member name="F:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.ChangeResult.IllegalValues">
- <summary>
- The state change request has illegal values.
- </summary>
- </member>
- <member name="F:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.ChangeResult.UnknownRequestType">
- <summary>
- The state change request is of an unknown type. Use <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.IAcquisition"/> to generate a valid type.
- </summary>
- </member>
- <member name="F:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.ChangeResult.ForeignControl">
- <summary>
- The instrument is under exclusive use of a different component or software package.
- </summary>
- </member>
- <member name="F:Thermo.Interfaces.InstrumentAccess_V1.Control.Acquisition.ChangeResult.IllegalOperationState">
- <summary>
- The instrument is not in the proper condition to accept the state change request.
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.IError">
- <summary>
- An IError describes an error coming from the instrument during an acquisition.
- This interface will not be used for status reports or messages of the
- transport layer.
- </summary>
- <remarks>
- See <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.ErrorsArrivedEventArgs"/> for an example how this interface can be used.
- <para>
- An instance of this class will be created by <see cref="P:Thermo.Interfaces.InstrumentAccess_V1.ErrorsArrivedEventArgs.Errors"/>.
- </para>
- </remarks>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.IError.Content">
- <summary>
- The textual content of the error.
- </summary>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.IError.Occurrence">
- <summary>
- The time difference between acquisition start and this error occurred.
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.ICustomScan">
- <summary>
- This scan definition can be placed in the instrument's
- job queue with individual properties. A custom scan will
- be executed only once.
- </summary>
- <remarks>
- See <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScans"/> for an example how this interface can be used.
- <para>
- An instance of this class will be created by <see cref="M:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScans.CreateCustomScan"/>.
- </para>
- </remarks>
- </member>
- <member name="P:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.ICustomScan.SingleProcessingDelay">
- <summary>
- The instrument will not execute any further custom scan
- if this property is positive until the delay has expired
- or a new custom scan has been defined.
- <para>
- The unit of this property is seconds and possible values are
- between 0 and 600 inclusively. The default value is 0.
- </para>
- </summary>
- </member>
- <member name="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScans">
- <summary>
- This interface allows the control over the next scan to be performed by the
- instrument with or without a method.
- <para>
- Either this interface or the <see cref="T:Thermo.Interfaces.InstrumentAccess_V1.Control.Methods.IMethods"/> interface should be used.
- </para>
- </summary>
- <remarks>
- An instance of this class will be created by <see cref="M:Thermo.Interfaces.InstrumentAccess_V1.Control.IControl.GetScans(System.Boolean)"/>.
- <para>
- Using this interface allows one to insert some scans in the normal flow of
- operation. It has several three layers of execution.
- </para>
- <para>
- The lowest layer is defined by the instrument. It performs those steps that
- are defined elsewhere, this can be either method execution, tuning or other things.
- </para>
- <para>
- The next layer that has a higher priority is the repeated scans layer which are
- defined here. If they are set they will be executed instead of the previous layer.
- A further Set call replaces the previous repition. A Cancel call will stop
- the repetition and operation falls back one layer. A custom scan can still be
- defined, though. The repition can be switched on and off on demand as often
- as desired.
- </para>
- <para>
- The most prioritized layer is that of custom scans. They will be executed before
- any furcher scan defined in the other layers. However, a Set operation may result
- in undefined behaviour (but no system fault happens) if the previous scan has not been
- started yet. It is best to avoid this situation. The custom scan will be scheduled and
- the AcceptsNextScan event will be fired at the next possible point in time. If a
- custom scan has a delay time set the instrument will wait this additional time
- until it falls back to a lower layer; either the repetition scans if they are
- defined or the normal operation mode.
- </para>
- </remarks>
- <example>
- The following code illustrates the use of most functionality in this namespace.
- A running acquisition (Press "On" in Tune) will be modified so that the polarity
- will be toggled between each scan.
- <code>
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading;
- using System.Globalization;
-
- using Thermo.Interfaces.InstrumentAccess_V1;
- using Thermo.Interfaces.InstrumentAccess_V1.Control;
- using Thermo.Interfaces.InstrumentAccess_V1.Control.Scans;
-
- namespace UserAccess
- {
- /// <summary>
- /// This class demonstrates the use of the <see cref="IScans"/> interface.
- /// </summary>
- internal class ScansTest : IDisposable
- {
- private IScans m_scans;
- private bool m_startCustomScan = true;
- private object m_lock = new object();
- private int m_disposed;
- private long m_runningNumber = 12345; // start with an offset to make sure it's "us"
- private int m_polarity = 0;
-
- /// <summary>
- /// Create a new <see cref="ScansTest"/> and start the performance test immediately.
- /// </summary>
- /// <param name="instrument">the instrument instance</param>
- /// <param name="arguments">program arguments</param>
- internal ScansTest(IInstrumentAccess instrument)
- {
- m_scans = instrument.Control.GetScans(false);
- m_scans.CanAcceptNextCustomScan += new EventHandler(Scans_CanAcceptNextCustomScan);
- m_scans.PossibleParametersChanged += new EventHandler(Scans_PossibleParametersChanged);
-
- DumpPossibleParameters();
- bool startNewScan = false;
- lock (m_lock)
- {
- if (m_scans.PossibleParameters.Length > 0)
- {
- startNewScan = m_startCustomScan;
- m_startCustomScan = false;
- }
- }
-
- if (startNewScan)
- {
- StartNewScan();
- }
- }
-
- /// <summary>
- /// The final destructor releases allocated system resources.
- /// </summary>
- ~ScansTest()
- {
- // Let the GC dispose managed members itself.
- Dispose(false);
- }
-
- /// <summary>
- /// Clean up any resources being used.
- /// </summary>
- /// <param name="disposeEvenManagedStuff">true to dispose managed and unmanaged resources; false to dispose unmanaged resources</param>
- protected void Dispose(bool disposeEvenManagedStuff)
- {
- // prevent double disposing
- if (Interlocked.Exchange(ref m_disposed, 1) != 0)
- {
- return;
- }
-
- if (disposeEvenManagedStuff)
- {
- if (m_scans != null)
- {
- m_scans.CanAcceptNextCustomScan -= new EventHandler(Scans_CanAcceptNextCustomScan);
- m_scans.PossibleParametersChanged -= new EventHandler(Scans_PossibleParametersChanged);
- m_scans.Dispose();
- m_scans = null;
- }
- }
- }
-
- /// <summary>
- /// Clean up any resources being used.
- /// </summary>
- virtual public void Dispose()
- {
- // Dispose managed and unmanaged resources and tell GC we don't need the destructor getting called.
- Dispose(true);
- GC.SuppressFinalize(this);
- }
-
- /// <summary>
- /// Get access to the flag whether this object is disposed.
- /// </summary>
- internal bool Disposed { get { return m_disposed != 0; } }
-
- /// <summary>
- /// Dump the list of possible commands.
- /// </summary>
- private bool DumpPossibleParameters()
- {
- IParameterDescription[] parameters = m_scans.PossibleParameters;
- if (parameters.Length == 0)
- {
- Console.WriteLine("No possible IScans parameters known.");
- return false;
- }
-
- Console.WriteLine("IScans parameters:");
- foreach (IParameterDescription parameter in parameters)
- {
- StringBuilder sb = new StringBuilder();
- sb.AppendFormat(" '{0}' ", parameter.Name);
- if (parameter.Selection == "")
- {
- sb.AppendFormat("doesn't accept an argument, help: {0}", parameter.Help);
- }
- else
- {
- sb.AppendFormat("accepts '{0}', default='{1}', help: {2}", parameter.Selection, parameter.DefaultValue, parameter.Help);
- }
- Console.WriteLine(sb.ToString());
- }
- return true;
- }
-
- /// <summary>
- /// Start a new custom scan.
- /// </summary>
- private void StartNewScan()
- {
- ICustomScan cs = m_scans.CreateCustomScan();
- cs.RunningNumber = m_runningNumber++;
-
- // Allow an extra delay of 500 ms, we will answer as fast as possible, so this is a maximum value.
- cs.SingleProcessingDelay = 0.50D;
-
- // Toggle the polarity:
- m_polarity = (m_polarity == 0) ? 1 : 0;
- cs.Values["pol"] = m_polarity.ToString(NumberFormatInfo.InvariantInfo);
-
- try
- {
- DateTime now = Instrument.Now;
- if (!m_scans.SetCustomScan(cs))
- {
- Console.WriteLine("NEW CUSTOM SCAN HAS NOT BEEN PLACED, CONNECTION TO SERVICE BROKEN.");
- }
- Console.WriteLine(now.ToString(Program.TimeFormat) + ": Placed a new custom scan(" + cs.RunningNumber + ")");
- }
- catch (Exception e)
- {
- Console.WriteLine("PLACING A NEW SCAN: " + e.Message);
- }
- }
-
- /// <summary>
- /// Called when the current custom scan has been processed and the next custom scan can be accepted.
- /// We start a new scan.
- /// </summary>
- /// <param name="sender">doesn't matter</param>
- /// <param name="e">doesn't matter</param>
- private void Scans_CanAcceptNextCustomScan(object sender, EventArgs e)
- {
- Console.WriteLine(Instrument.Now.ToString(Program.TimeFormat) + ": CanAcceptNextCustomScan");
- if ((m_scans != null) && (m_scans.PossibleParameters.Length > 0))
- {
- // Assume we are able to place a new scan.
- StartNewScan();
- }
- }
-
- /// <summary>
- /// Called when the list of possible commands have changed we dump them.
- /// Additionally we start a new scan.
- /// </summary>
- /// <param name="sender">doesn't matter</param>
- /// <param name="e">doesn't matter</param>
- private void Scans_PossibleParametersChanged(object sender, EventArgs e)
- {
- if (!DumpPossibleParameters())
- {
- return;
- }
-
- bool startNewScan = false;
- lock (m_lock)
- {
- if (m_scans.PossibleParameters.Length > 0)
- {
- startNewScan = m_startCustomScan;
- m_startCustomScan = false;
- }
- }
-
- if (startNewScan)
- {
- StartNewScan();
- }
- }
- }
- }
- </code>
- </example>
- </member>
- <member name="M:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScans.SetRepetitionScan(Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IRepeatingScan)">
- <summary>
- Define or replace the repetition scan to be performed.
- <para>
- The scan may be partially defined in which case the properties of the previously
- executed scan will be used. At least one property needs to be specified.
- </para>
- </summary>
- <param name="scan">object containing new default scan definitions</param>
- <returns>true if the command has been sent to the instrument, false otherwise</returns>
- </member>
- <member name="M:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScans.CancelRepetition">
- <summary>
- Cancels any repetition of scans that have been defined by <see cref="M:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScans.SetRepetitionScan(Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IRepeatingScan)"/>.
- </summary>
- <returns>true if the command has been sent to the instrument, false otherwise</returns>
- </member>
- <member name="M:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScans.SetCustomScan(Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.ICustomScan)">
- <summary>
- Define a scan to be performed next. The current standard operation (method, prepetition scan, etc)
- will continue after this scan and maybe following custom scans have been acquired.
- <para>
- The operation on the instrument is undefined if several custom scans are set without having the
- instrument dealt with the previous custom scans. However, the instrument will not stop
- to run, choke or show any other fatal error.
- </para>
- <para>
- The event <see cref="E:Thermo.Interfaces.InstrumentAccess_V1.Control.Scans.IScans.CanAcceptNextCustomScan"/> is fired once after the instrument has processed a
- custom scan. The further custom scan can be set then or within the delay time that
- might have…
Large files files are truncated, but you can click here to view the full file