Chronos Plugins 5.9.0
This documentation covers the plugin interfaces definitions and an example implementation.
Loading...
Searching...
No Matches
AcquisitionInterfaces.cs
Go to the documentation of this file.
1using System;
2using System.Runtime.InteropServices;
3
5{
11 [Guid("F4CFA301-E8CD-478C-A6AC-6F84E83AFF4F")]
12 public interface IAcquisitionServiceBase
13 {
17 string Name { get; }
21 bool IsAvailable { get; }
26 bool Abort { set; }
27 }
28
37 [Guid("D64E4C4F-729A-489B-876D-09D176851B80")]
39 {
44 TimeSpan RetryInterval { get; }
45 }
46
54 {
58 string Details { get; }
59 }
60
61
66 public interface ISoftHandshakingAcquisitionService<TParam> : IAcquisitionService<TParam> where TParam: class, new()
67 {
77 bool RequiresFeedback(TParam parameters);
82 void JobFinished(TParam parameters);
87 void Injected(TParam parameters);
88 }
89
95 [Guid("5670F923-A3BA-4677-827D-0AF480EA94F2")]
96 // ReSharper disable once TypeParameterCanBeVariant
97 public interface IAcquisitionService<TParam> : IAcquisitionServiceBase where TParam: class, new()
98 {
103 void Validate(TParam parameters);
108 void RunAcquisition(TParam parameters);
109 }
110
116 public interface IJitLinkAware
117 {
118
126 Func<string,bool> JitChecker { set; }
127 }
128
132 public interface IRunContextAware
133 {
138 }
139
143 public interface IRunContext
144 {
148 int JobNumber { get; }
152 int RowNumber { get; }
157 }
158
166 [AttributeUsage(AttributeTargets.Property)]
167 public class LockInstrumentAttribute : Attribute
168 { }
169
174 [Guid("D4D8EFB9-9F40-499D-AE8D-8C06C060AF52")]
176 {
183 string Configuration { get; set; }
184 }
192 [Guid("98D96CF1-2AF5-4D5E-979E-2103CF35D587")]
193 public interface IHaveConfigurator
194 {
202 string ShowConfigDialog(IntPtr owner, string oldConfig);
203 }
204
211 [Guid("8D501F13-E70E-4251-B899-7C52996F01E6")]
213 {
218 void BeginSequence(string pathToChronosSampleList);
223 }
224
228 public enum ResultKind
229 {
231 Name,
233 Amount,
235 Area,
237 Height,
242 }
246 [Guid("D4017D28-35DA-49CE-9B7B-21494532300D")]
248 {
256 string[] ExecuteDataReader(string resultFileName, string substances,
257 ResultKind kindOfResult);
258 }
259
267 [Guid("8C446F72-FD60-43FB-A000-1D75C4249A19")]
275
287 [Guid("6901009A-6D89-4B50-9548-B98740258071")]
288 // ReSharper disable once TypeParameterCanBeVariant
289 public interface ICommandUsingAcquisitionService<TCommandAndParameters> : IAcquisitionServiceBase where TCommandAndParameters : class, new()
290 {
295 void ValidateCommand(TCommandAndParameters cmdAndPars);
300 void RunCommand(TCommandAndParameters cmdAndPars);
301 }
302
309 public interface IAcquisitionHostTask : ITask
310 {
321 object Parameters { get; }
322 }
323
324}
Classes and interfaces that are meant for plugins. The classes and interfaces below this namespace ar...
ResultKind
The kind of result expected from the ExecuteDataReader call to an EBIS enabled acquisition service.
Base for acquisition services, parts that are the same regardless of the parameter list....
bool Abort
Will be set to true if you should abort the current acquisition. Will be set to false when everything...
bool IsAvailable
The place to check if you can actually use the acquisition service.
string Name
Name that is visible to the user in the list of acquisition services. Do not localize.
Request retrying if IsAvailable returned false.
TimeSpan RetryInterval
If you are sure the service will not be available, return TimeSpan.Zero. Else return a reasonable int...
If there are several instruments or you can provide some version/configuration information for the se...
string Details
For things like detected version number, configured instruments etc - something the user would like t...
Implement this interface if you want to support soft handshaking (read: not by cable) for your acquis...
void Injected(TParam parameters)
Will be called as closely as possible to the moment of the injection.
bool RequiresFeedback(TParam parameters)
Tell Chronos if you really need soft handshake for this specific parameter set.
void JobFinished(TParam parameters)
If you required feedback for a set of parameters, and the job containing the matching injection finis...
Implement this interface if you want to provide an acquisition service that is loaded on program star...
void Validate(TParam parameters)
Check the given parameters and throw an exception if they are invalid.
void RunAcquisition(TParam parameters)
Send the acquisition parameters to the CDS.
Implement this interface on your ParamT if you need to check for the presence of just in time evaluat...
Func< string, bool > JitChecker
Get a checker delegate that can look for jit links.
Implement this interface on your acquisition parameter type to get information related to the current...
IRunContext ContextInfo
Before Validate or RunAcquisition are called, you will get an object here that contains information o...
Information on the current context during acquisition. Can be extended on request.
IAcquisitionHostTask HostTask
The task that contains the parameters object.
int RowNumber
One based row number as displayed in the sample list.
Decorate a property of your ParamT class with this property if your acquisition service can be used s...
Implement this interface if your acquisition service requires some kind of configuration.
string Configuration
XML Fragment containing the services configuration, if any.
The GUI for the configuration can be managed seperately from the service.
string ShowConfigDialog(IntPtr owner, string oldConfig)
Show a configuration dialog for your acquisition service.
Implement this if your acquisition service has to know when a Chronos sequence starts / ends.
void EndSequence()
The Chronos sequence has ended. Good moment, for example, to export sample information to a list for ...
void BeginSequence(string pathToChronosSampleList)
A new Chronos sequence has started. You can use the path to the list file to construct your own seque...
To be implemented by acquisition services that cooperate with the EBIS module for Chronos.
string[] ExecuteDataReader(string resultFileName, string substances, ResultKind kindOfResult)
No public documentation yet - please let us know when you want to implement this.
For services that can be put into some kind of standby mode (by an error method, for example)
void GoToStandby()
Send the system to standby mode.
Implement this interface if your acquisition service supports some kind of utility commands that coul...
void ValidateCommand(TCommandAndParameters cmdAndPars)
Please check if it is likely that you can actually execute the parameters.
void RunCommand(TCommandAndParameters cmdAndPars)
Perform the actual command action.
This interface is implemented by the acquisition task instance that hosts your parameter list.
IAcquisitionServiceBase Service
Your service instance.
object Parameters
You can cast this to your known parameters class.
To be implemented by the "task" part of a Chronos plugin. Public properties of the implementing type ...