1use std::fmt::Display;
2
3use crate::impl_param_described;
4use crate::params::{ParamCow, ParamLike, ParamList};
5
6#[derive(Debug, Default, Clone, Copy, PartialEq, Eq)]
8#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
9pub enum ComponentType {
10 Analyzer,
12 IonSource,
14 Detector,
16 #[default]
17 Unknown,
18}
19
20impl Display for ComponentType {
21 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
22 write!(f, "{:?}", self)
23 }
24}
25
26#[derive(Default, Debug, Clone, PartialEq, Eq)]
32#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
33pub struct Component {
34 pub component_type: ComponentType,
36 pub order: u8,
38 pub params: ParamList,
39}
40
41impl Component {
42 pub fn mass_analyzer(&self) -> Option<MassAnalyzerTerm> {
43 self.params
44 .iter()
45 .filter(|p| p.is_ms())
46 .flat_map(|p| {
47 if let Some(u) = p.accession {
48 MassAnalyzerTerm::from_accession(u)
49 } else {
50 None
51 }
52 })
53 .next()
54 }
55
56 pub fn detector(&self) -> Option<DetectorTypeTerm> {
57 self.params
58 .iter()
59 .filter(|p| p.is_ms())
60 .flat_map(|p| {
61 if let Some(u) = p.accession {
62 DetectorTypeTerm::from_accession(u)
63 } else {
64 None
65 }
66 })
67 .next()
68 }
69
70 pub fn ionization_type(&self) -> Option<IonizationTypeTerm> {
71 self.params
72 .iter()
73 .filter(|p| p.is_ms())
74 .flat_map(|p| {
75 if let Some(u) = p.accession {
76 IonizationTypeTerm::from_accession(u)
77 } else {
78 None
79 }
80 })
81 .next()
82 }
83
84 pub fn name(&self) -> Option<&str> {
85 let it = self.params.iter().filter(|p| p.is_ms());
86 match self.component_type {
87 ComponentType::Analyzer => it
88 .flat_map(|p| {
89 p.accession
90 .and_then(|u| {
91 MassAnalyzerTerm::from_accession(u)
92 })
93 .map(|u| u.name())
94 })
95 .next(),
96 ComponentType::IonSource => it
97 .flat_map(|p| {
98 p.accession.and_then(|u| {
99 IonizationTypeTerm::from_accession(u)
100 })
101 .map(|u| u.name())
102 })
103 .next(),
104 ComponentType::Detector => it
105 .flat_map(|p| {
106 p.accession.and_then(|u| {
107 DetectorTypeTerm::from_accession(u)
108 })
109 .map(|u| u.name())
110 })
111 .next(),
112 ComponentType::Unknown => None,
113 }
114 }
115
116 pub fn parent_types(&self) -> Vec<ParamCow<'static>> {
117 match self.component_type {
118 ComponentType::Analyzer => self
119 .params
120 .iter()
121 .flat_map(|p| {
122 p.accession.and_then(|u| {
123 MassAnalyzerTerm::from_accession(u)
124 .map(|t| t.parents().into_iter().map(|t| t.to_param()).collect())
125 })
126 })
127 .next()
128 .unwrap_or_default(),
129 ComponentType::IonSource => self
130 .params
131 .iter()
132 .flat_map(|p| {
133 p.accession.and_then(|u| {
134 IonizationTypeTerm::from_accession(u)
135 .map(|t| t.parents().into_iter().map(|t| t.to_param()).collect())
136 })
137 })
138 .next()
139 .unwrap_or_default(),
140 ComponentType::Detector => self
141 .params
142 .iter()
143 .flat_map(|p| {
144 p.accession.and_then(|u| {
145 DetectorTypeTerm::from_accession(u)
146 .map(|t| t.parents().into_iter().map(|t| t.to_param()).collect())
147 })
148 })
149 .next()
150 .unwrap_or_default(),
151 ComponentType::Unknown => vec![],
152 }
153 }
154}
155
156#[derive(Default, Debug, Clone, PartialEq, Eq)]
158#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
159pub struct InstrumentConfiguration {
160 pub components: Vec<Component>,
162 pub params: ParamList,
164 pub software_reference: String,
166 pub id: u32,
168}
169
170impl InstrumentConfiguration {
171 pub fn new_component(&mut self, component_type: ComponentType) -> &mut Component {
173 let component = Component {
174 component_type,
175 ..Default::default()
176 };
177 self.push(component);
178 self.components.last_mut().unwrap()
179 }
180
181 pub fn len(&self) -> usize {
182 self.components.len()
183 }
184
185 pub fn is_empty(&self) -> bool {
186 self.components.is_empty()
187 }
188
189 pub fn push(&mut self, mut value: Component) {
192 let n = self.len();
193 value.order = n as u8;
194 self.components.push(value)
195 }
196
197 pub fn iter(&self) -> std::slice::Iter<'_, Component> {
198 self.components.iter()
199 }
200
201 pub fn last(&self) -> Option<&Component> {
202 self.components.last()
203 }
204
205 pub fn last_mut(&mut self) -> Option<&mut Component> {
206 self.components.last_mut()
207 }
208}
209
210impl_param_described!(InstrumentConfiguration, Component);
211
212crate::cvmap! {
213 #[flag_type=i32]
214 #[allow(unused)]
215 #[derive(Debug, Clone, Copy, PartialEq, Eq)]
216 #[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
217 pub enum MassAnalyzerTerm {
225 #[term(cv=MS, accession=1000078, name="axial ejection linear ion trap", flags={0}, parents={["MS:1000291"]})]
226 #[doc="axial ejection linear ion trap - A linear ion trap mass analyzer where ions are ejected along the axis of the analyzer."]
227 AxialEjectionLinearIonTrap,
228 #[term(cv=MS, accession=1000079, name="fourier transform ion cyclotron resonance", flags={0}, parents={["MS:1000443"]})]
229 #[doc="fourier transform ion cyclotron resonance - A device based on the principle of ion cyclotron resonance in which an ion in a magnetic field moves in a circular orbit at a frequency characteristic of its m/z value. Ions are coherently excited to a larger radius orbit using a pulse of radio frequency energy and their image charge is detected on receiver plates as a time domain signal. Fourier transformation of the time domain signal results in a frequency domain signal which is converted to a mass spectrum based in the inverse relationship between frequency and m/z."]
230 FourierTransformIonCyclotronResonance,
231 #[term(cv=MS, accession=1000080, name="magnetic sector", flags={0}, parents={["MS:1000443"]})]
232 #[doc="magnetic sector - A device that produces a magnetic field perpendicular to a charged particle beam that deflects the beam to an extent that is proportional to the particle momentum per unit charge. For a monoenergetic beam, the deflection is proportional to m/z."]
233 MagneticSector,
234 #[term(cv=MS, accession=1000081, name="quadrupole", flags={0}, parents={["MS:1000443"]})]
235 #[doc="quadrupole - A device that consists of four parallel rods whose centers form the corners of a square and whose opposing poles are connected. The voltage applied to the rods is a superposition of a static potential and a sinusoidal radio frequency potential. The motion of an ion in the x and y dimensions is described by the Matthieu equation whose solutions show that ions in a particular m/z range can be transmitted along the z axis."]
236 Quadrupole,
237 #[term(cv=MS, accession=1000082, name="quadrupole ion trap", flags={0}, parents={["MS:1000264"]})]
238 #[doc="quadrupole ion trap - Quadrupole Ion Trap mass analyzer captures the ions in a three dimensional ion trap and then selectively ejects them by varying the RF and DC potentials."]
239 QuadrupoleIonTrap,
240 #[term(cv=MS, accession=1000083, name="radial ejection linear ion trap", flags={0}, parents={["MS:1000291"]})]
241 #[doc="radial ejection linear ion trap - A linear ion trap mass analyzer where ions are ejected along the radius of the analyzer."]
242 RadialEjectionLinearIonTrap,
243 #[term(cv=MS, accession=1000084, name="time-of-flight", flags={0}, parents={["MS:1000443"]})]
244 #[doc="time-of-flight - Instrument that separates ions by m/z in a field-free region after acceleration to a fixed acceleration energy."]
245 TimeOfFlight,
246 #[term(cv=MS, accession=1000254, name="electrostatic energy analyzer", flags={0}, parents={["MS:1000443"]})]
247 #[doc="electrostatic energy analyzer - A device consisting of conducting parallel plates, concentric cylinders or concentric spheres that separates charged particles according to their kinetic energy by means of an electric field that is constant in time."]
248 ElectrostaticEnergyAnalyzer,
249 #[term(cv=MS, accession=1000264, name="ion trap", flags={0}, parents={["MS:1000443"]})]
250 #[doc="ion trap - A device for spatially confining ions using electric and magnetic fields alone or in combination."]
251 IonTrap,
252 #[term(cv=MS, accession=1000291, name="linear ion trap", flags={0}, parents={["MS:1000264"]})]
253 #[doc="linear ion trap - A two dimensional Paul ion trap in which ions are confined in the axial dimension by means of an electric field at the ends of the trap."]
254 LinearIonTrap,
255 #[term(cv=MS, accession=1000443, name="mass analyzer type", flags={0}, parents={[]})]
256 #[doc="mass analyzer type - Mass analyzer separates the ions according to their mass-to-charge ratio."]
257 MassAnalyzerType,
258 #[term(cv=MS, accession=1000484, name="orbitrap", flags={0}, parents={["MS:1000443"]})]
259 #[doc="orbitrap - An ion trapping device that consists of an outer barrel-like electrode and a coaxial inner spindle-like electrode that form an electrostatic field with quadro-logarithmic potential distribution. The frequency of harmonic oscillations of the orbitally trapped ions along the axis of the electrostatic field is independent of the ion velocity and is inversely proportional to the square root of m/z so that the trap can be used as a mass analyzer."]
260 Orbitrap,
261 #[term(cv=MS, accession=1003379, name="asymmetric track lossless time-of-flight analyzer", flags={0}, parents={["MS:1000084"]})]
262 #[doc="asymmetric track lossless time-of-flight analyzer - A TOF-like mass analyzer with asymmetric ion mirrors to direct ions into transversal asymmetric oscillations and ion foil shapes and maintains ion packet for transmission and resolution."]
263 AsymmetricTrackLosslessTimeOfFlightAnalyzer,
264 }
265 }
267
268crate::cvmap! {
269 #[flag_type=i32]
270 #[allow(unused)]
271 #[derive(Debug, Clone, Copy, PartialEq, Eq)]
272 #[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
273 pub enum IonizationTypeTerm {
281 #[term(cv=MS, accession=1000008, name="ionization type", flags={0}, parents={[]})]
282 #[doc="ionization type - The method by which gas phase ions are generated from the sample."]
283 IonizationType,
284 #[term(cv=MS, accession=1000070, name="atmospheric pressure chemical ionization", flags={0}, parents={["MS:1000240"]})]
285 #[doc="atmospheric pressure chemical ionization - Chemical ionization that takes place at atmospheric pressure as opposed to the reduced pressure is normally used for chemical ionization."]
286 AtmosphericPressureChemicalIonization,
287 #[term(cv=MS, accession=1000071, name="chemical ionization", flags={0}, parents={["MS:1000008"]})]
288 #[doc="chemical ionization - The formation of a new ion by the reaction of a neutral species with an ion. The process may involve transfer of an electron, a proton or other charged species between the reactants. When a positive ion results from chemical ionization the term may be used without qualification. When a negative ion results the term negative ion chemical ionization should be used. Note that this term is not synonymous with chemi-ionization."]
289 ChemicalIonization,
290 #[term(cv=MS, accession=1000073, name="electrospray ionization", flags={0}, parents={["MS:1000008"]})]
291 #[doc="electrospray ionization - A process in which ionized species in the gas phase are produced from an analyte-containing solution via highly charged fine droplets, by means of spraying the solution from a narrow-bore needle tip at atmospheric pressure in the presence of a high electric field. When a pressurized gas is used to aid in the formation of a stable spray, the term pneumatically assisted electrospray ionization is used. The term ion spray is not recommended."]
292 ElectrosprayIonization,
293 #[term(cv=MS, accession=1000074, name="fast atom bombardment ionization", flags={0}, parents={["MS:1000008"]})]
294 #[doc="fast atom bombardment ionization - The ionization of any species by the interaction of a focused beam of neutral atoms having a translational energy of several thousand eV with a sample that is typically dissolved in a solvent matrix. See also secondary ionization."]
295 FastAtomBombardmentIonization,
296 #[term(cv=MS, accession=1000075, name="matrix-assisted laser desorption ionization", flags={0}, parents={["MS:1000247"]})]
297 #[doc="matrix-assisted laser desorption ionization - The formation of gas-phase ions from molecules that are present in a solid or solvent matrix that is irradiated with a pulsed laser. See also laser desorption/ionization."]
298 MatrixAssistedLaserDesorptionIonization,
299 #[term(cv=MS, accession=1000227, name="multiphoton ionization", flags={0}, parents={["MS:1000008"]})]
300 #[doc="multiphoton ionization - Photoionization of an atom or molecule in which in two or more photons are absorbed."]
301 MultiphotonIonization,
302 #[term(cv=MS, accession=1000239, name="atmospheric pressure matrix-assisted laser desorption ionization", flags={0}, parents={["MS:1000240"]})]
303 #[doc="atmospheric pressure matrix-assisted laser desorption ionization - Matrix-assisted laser desorption ionization in which the sample target is at atmospheric pressure and the ions formed by the pulsed laser are sampled through a small aperture into the mass spectrometer."]
304 AtmosphericPressureMatrixAssistedLaserDesorptionIonization,
305 #[term(cv=MS, accession=1000240, name="atmospheric pressure ionization", flags={0}, parents={["MS:1000008"]})]
306 #[doc="atmospheric pressure ionization - Any ionization process in which ions are formed in the gas phase at atmospheric pressure."]
307 AtmosphericPressureIonization,
308 #[term(cv=MS, accession=1000247, name="desorption ionization", flags={0}, parents={["MS:1000008"]})]
309 #[doc="desorption ionization - The formation of ions from a solid or liquid material after the rapid vaporization of that sample."]
310 DesorptionIonization,
311 #[term(cv=MS, accession=1000255, name="flowing afterglow", flags={0}, parents={["MS:1000008"]})]
312 #[doc="flowing afterglow - An ion source immersed in a flow of helium or other inert buffer gas that carries the ions through a meter-long reactor at pressures around 100 Pa."]
313 FlowingAfterglow,
314 #[term(cv=MS, accession=1000257, name="field desorption", flags={0}, parents={["MS:1000247"]})]
315 #[doc="field desorption - The formation of gas-phase ions from a material deposited on a solid surface in the presence of a high electric field. Because this process may encompass ionization by field ionization or other mechanisms, it is not recommended as a synonym for field desorption ionization."]
316 FieldDesorption,
317 #[term(cv=MS, accession=1000258, name="field ionization", flags={0}, parents={["MS:1000008"]})]
318 #[doc="field ionization - The removal of electrons from any species by interaction with a high electric field."]
319 FieldIonization,
320 #[term(cv=MS, accession=1000259, name="glow discharge ionization", flags={0}, parents={["MS:1000008"]})]
321 #[doc="glow discharge ionization - The formation of ions in the gas phase and from solid samples at the cathode by application of a voltage to a low pressure gas."]
322 GlowDischargeIonization,
323 #[term(cv=MS, accession=1000271, name="Negative Ion chemical ionization", flags={0}, parents={["MS:1000008"]})]
324 #[doc="Negative Ion chemical ionization - Chemical ionization that results in the formation of negative ions."]
325 NegativeIonChemicalIonization,
326 #[term(cv=MS, accession=1000272, name="neutralization reionization mass spectrometry", flags={0}, parents={["MS:1000008"]})]
327 #[doc="neutralization reionization mass spectrometry - With this technique, m/z selected ions form neutrals by charge transfer to a collision gas or by dissociation. The neutrals are separated from the remaining ions and ionized in collisions with a second gas. This method is used to investigate reaction intermediates and other unstable species."]
328 NeutralizationReionizationMassSpectrometry,
329 #[term(cv=MS, accession=1000273, name="photoionization", flags={0}, parents={["MS:1000008"]})]
330 #[doc="photoionization - The ionization of an atom or molecule by a photon, written M + h? ? M^+ + e. The term photon impact is not recommended."]
331 Photoionization,
332 #[term(cv=MS, accession=1000274, name="pyrolysis mass spectrometry", flags={0}, parents={["MS:1000008"]})]
333 #[doc="pyrolysis mass spectrometry - A mass spectrometry technique in which the sample is heated to the point of decomposition and the gaseous decomposition products are introduced into the ion source."]
334 PyrolysisMassSpectrometry,
335 #[term(cv=MS, accession=1000276, name="resonance enhanced multiphoton ionization", flags={0}, parents={["MS:1000008"]})]
336 #[doc="resonance enhanced multiphoton ionization - Multiphoton ionization in which the ionization cross section is significantly enhanced because the energy of the incident photons is resonant with an intermediate excited state of the neutral species."]
337 ResonanceEnhancedMultiphotonIonization,
338 #[term(cv=MS, accession=1000278, name="surface enhanced laser desorption ionization", flags={0}, parents={["MS:1000406"]})]
339 #[doc="surface enhanced laser desorption ionization - The formation of ionized species in the gas phase from analytes deposited on a particular surface substrate which is irradiated with a laser beam of which wavelength is absorbed by the surface. See also desorption/ionization on silicon and laser desorption/ionization."]
340 SurfaceEnhancedLaserDesorptionIonization,
341 #[term(cv=MS, accession=1000279, name="surface enhanced neat desorption", flags={0}, parents={["MS:1000406"]})]
342 #[doc="surface enhanced neat desorption - Matrix-assisted laser desorption ionization in which the matrix is covalently linked to the target surface."]
343 SurfaceEnhancedNeatDesorption,
344 #[term(cv=MS, accession=1000380, name="adiabatic ionization", flags={0}, parents={["MS:1000008"]})]
345 #[doc="adiabatic ionization - A process whereby an electron is removed from an atom, ion, or molecule to produce an ion in its lowest energy state."]
346 AdiabaticIonization,
347 #[term(cv=MS, accession=1000381, name="associative ionization", flags={0}, parents={["MS:1000008"]})]
348 #[doc="associative ionization - An ionization process in which two excited atoms or molecules react to form a single positive ion and an electron."]
349 AssociativeIonization,
350 #[term(cv=MS, accession=1000382, name="atmospheric pressure photoionization", flags={0}, parents={["MS:1000240"]})]
351 #[doc="atmospheric pressure photoionization - Atmospheric pressure chemical ionization in which the reactant ions are generated by photo-ionization."]
352 AtmosphericPressurePhotoionization,
353 #[term(cv=MS, accession=1000383, name="autodetachment", flags={0}, parents={["MS:1000008"]})]
354 #[doc="autodetachment - The formation of a neutral when a negative ion in a discrete state with an energy greater than the detachment threshold loses an electron spontaneously without further interaction with an energy source."]
355 Autodetachment,
356 #[term(cv=MS, accession=1000384, name="autoionization", flags={0}, parents={["MS:1000008"]})]
357 #[doc="autoionization - The formation of an ion when an atom or molecule in a discrete state with an energy greater than the ionization threshold loses an electron spontaneously without further interaction with an energy source."]
358 Autoionization,
359 #[term(cv=MS, accession=1000385, name="charge exchange ionization", flags={0}, parents={["MS:1000008"]})]
360 #[doc="charge exchange ionization - The interaction of an ion with an atom or molecule in which the charge on the ion is transferred to the neutral without the dissociation of either. Synonymous with charge transfer ionization."]
361 ChargeExchangeIonization,
362 #[term(cv=MS, accession=1000386, name="chemi-ionization", flags={0}, parents={["MS:1000008"]})]
363 #[doc="chemi-ionization - The reaction of a neutral molecule with an internally excited molecule to form an ion. Note that this term is not synonymous with chemical ionization."]
364 ChemiIonization,
365 #[term(cv=MS, accession=1000387, name="desorption/ionization on silicon", flags={0}, parents={["MS:1000247"]})]
366 #[doc="desorption/ionization on silicon - The formation of ions by laser desorption ionization of a sample deposited on a porous silicon surface."]
367 DesorptionIonizationOnSilicon,
368 #[term(cv=MS, accession=1000388, name="dissociative ionization", flags={0}, parents={["MS:1000008"]})]
369 #[doc="dissociative ionization - The reaction of a gas-phase molecule that results in its decomposition to form products, one of which is an ion."]
370 DissociativeIonization,
371 #[term(cv=MS, accession=1000389, name="electron ionization", flags={0}, parents={["MS:1000008"]})]
372 #[doc="electron ionization - The ionization of an atom or molecule by electrons that are typically accelerated to energies between 50 and 150 eV. Usually 70 eV electrons are used to produce positive ions. The term 'electron impact' is not recommended."]
373 ElectronIonization,
374 #[term(cv=MS, accession=1000393, name="laser desorption ionization", flags={0}, parents={["MS:1000247"]})]
375 #[doc="laser desorption ionization - The formation of gas-phase ions by the interaction of a pulsed laser with a solid or liquid material."]
376 LaserDesorptionIonization,
377 #[term(cv=MS, accession=1000395, name="liquid secondary ionization", flags={0}, parents={["MS:1000008"]})]
378 #[doc="liquid secondary ionization - The ionization of any species by the interaction of a focused beam of ions with a sample that is dissolved in a solvent matrix. See also fast atom bombardment and secondary ionization."]
379 LiquidSecondaryIonization,
380 #[term(cv=MS, accession=1000397, name="microelectrospray", flags={0}, parents={["MS:1000073"]})]
381 #[doc="microelectrospray - Electrospray ionization at a solvent flow rate of 300-800 nL/min where the flow is a result of a mechanical pump. See nanoelectrospray."]
382 Microelectrospray,
383 #[term(cv=MS, accession=1000398, name="nanoelectrospray", flags={0}, parents={["MS:1000073"]})]
384 #[doc="nanoelectrospray - Electrospray ionization at a flow rate less than ~25 nL/min. Nanoelectrospray is synonymous with nanospray. The flow is dependent on the potential on the tip of the electrospray needle and/or a gas pressure to push the sample through the needle. See also electrospray ionization and microelectrospray."]
385 Nanoelectrospray,
386 #[term(cv=MS, accession=1000399, name="penning ionization", flags={0}, parents={["MS:1000008"]})]
387 #[doc="penning ionization - Ionization that occurs through the interaction of two or more neutral gaseous species, at least one of which is internally excited."]
388 PenningIonization,
389 #[term(cv=MS, accession=1000400, name="plasma desorption ionization", flags={0}, parents={["MS:1000008"]})]
390 #[doc="plasma desorption ionization - The ionization of material in a solid sample by bombarding it with ionic or neutral atoms formed as a result of the fission of a suitable nuclide, typically 252Cf. Synonymous with fission fragment ionization."]
391 PlasmaDesorptionIonization,
392 #[term(cv=MS, accession=1000402, name="secondary ionization", flags={0}, parents={["MS:1000008"]})]
393 #[doc="secondary ionization - The process in which ions are ejected from a sample surface as a result of bombardment by a primary beam of atoms or ions."]
394 SecondaryIonization,
395 #[term(cv=MS, accession=1000403, name="soft ionization", flags={0}, parents={["MS:1000008"]})]
396 #[doc="soft ionization - The formation of gas-phase ions without extensive fragmentation."]
397 SoftIonization,
398 #[term(cv=MS, accession=1000404, name="spark ionization", flags={0}, parents={["MS:1000008"]})]
399 #[doc="spark ionization - The formation of ions from a solid material by an intermittent electrical discharge."]
400 SparkIonization,
401 #[term(cv=MS, accession=1000405, name="surface-assisted laser desorption ionization", flags={0}, parents={["MS:1000247"]})]
402 #[doc="surface-assisted laser desorption ionization - The formation of gas-phase ions from molecules that are deposited on a particular surface substrate that is irradiated with a pulsed laser. See also matrix-assisted laser desorption ionization."]
403 SurfaceAssistedLaserDesorptionIonization,
404 #[term(cv=MS, accession=1000406, name="surface ionization", flags={0}, parents={["MS:1000008"]})]
405 #[doc="surface ionization - The ionization of a neutral species when it interacts with a solid surface with an appropriate work function and temperature."]
406 SurfaceIonization,
407 #[term(cv=MS, accession=1000407, name="thermal ionization", flags={0}, parents={["MS:1000008"]})]
408 #[doc="thermal ionization - The ionization of a neutral species through contact with a high temperature surface."]
409 ThermalIonization,
410 #[term(cv=MS, accession=1000408, name="vertical ionization", flags={0}, parents={["MS:1000008"]})]
411 #[doc="vertical ionization - A process in which an electron is removed from or added to a molecule without a change in the positions of the atoms. The resulting ion is typically in an excited vibrational state."]
412 VerticalIonization,
413 #[term(cv=MS, accession=1000446, name="fast ion bombardment", flags={0}, parents={["MS:1000008"]})]
414 #[doc="fast ion bombardment - The ionization of any species by the interaction of a focused beam of ions having a translational energy of several thousand eV with a solid sample."]
415 FastIonBombardment,
416 #[term(cv=MS, accession=1002011, name="desorption electrospray ionization", flags={0}, parents={["MS:1000240"]})]
417 #[doc="desorption electrospray ionization - Combination of electrospray and desorption ionization method that ionizes gases, liquids and solids in open air under atmospheric pressure."]
418 DesorptionElectrosprayIonization,
419 #[term(cv=MS, accession=1003235, name="paper spray ionization", flags={0}, parents={["MS:1000008"]})]
420 #[doc="paper spray ionization - The ionization of analytes from a piece of paper by applying a solvent and voltage."]
421 PaperSprayIonization,
422 #[term(cv=MS, accession=1003248, name="proton transfer reaction", flags={0}, parents={["MS:1000008"]})]
423 #[doc="proton transfer reaction - Process to transfer a proton from a hydronium ion (H3O+) to neutral analyte, leading to a protonated analyte, which typically does not lead to fragmentation."]
424 ProtonTransferReaction,
425 #[term(cv=MS, accession=1003249, name="proton transfer charge reduction", flags={0}, parents={["MS:1000008"]})]
426 #[doc="proton transfer charge reduction - Process to transfer one or more protons from a multiply charged cation (peptide or protein ion) to a proton acceptor anion or neutral basic compound, thereby reducing the charge of the original analyte."]
427 ProtonTransferChargeReduction,
428 #[term(cv=MS, accession=1003775, name="secondary electrospray ionization", flags={0}, parents={["MS:1000240"]})]
429 #[doc="secondary electrospray ionization - Secondary electrospray ionization (SESI) is an atmospheric pressure ionization (API) technique that uses a primary nano-electrospray plume of solvent ions to ionize neutral gaseous molecules in the gas phase via efficient proton transfer reactions. Operating at atmospheric pressure, SESI allows for the sensitive and real-time detection of volatile organic compounds (VOCs) and vapors with minimal sample preparation, making it ideal for applications like breath analysis and environmental monitoring."]
430 SecondaryElectrosprayIonization,
431 #[term(cv=MS, accession=1003954, name="argon gas cluster ion beam", flags={0}, parents={["MS:1003959"]})]
432 #[doc="argon gas cluster ion beam - Argon gas cluster ion beam (Ar GCIB) bombardment uses a focused beam of large argon cluster ions, typically \\[Ar500\\]+ to \\[Ar10000\\]+, accelerated to high energies to sputter and generate secondary ions from a surface, enabling molecular depth profiling and imaging of organic and biological materials with reduced subsurface damage compared to monatomic ion beams."]
433 ArgonGasClusterIonBeam,
434 #[term(cv=MS, accession=1003958, name="bismuth liquid metal ion gun", flags={0}, parents={["MS:1003960"]})]
435 #[doc="bismuth liquid metal ion gun - Bismuth liquid metal ion gun (Bi LMIG) bombardment uses a focused beam of bismuth ions emitted from a liquid metal ion source to desorb and ionize molecules from a surface. The LMIG source generates a diversity of monomers and clusters, which are filtered prior to the sample in order to select the specific ionisation characteristics."]
436 BismuthLiquidMetalIonGun,
437 #[term(cv=MS, accession=1003959, name="gas cluster ion beam", flags={0}, parents={["MS:1000446"]})]
438 #[doc="gas cluster ion beam - A gas cluster ion beam (GCIB) is an ion source that generates and accelerates large aggregates of gas atoms or molecules to high energies. The low energy per constituent atom minimizes surface damage and molecular fragmentation, making it highly effective for molecular depth profiling and the analysis of fragile organic and biological materials."]
439 GasClusterIonBeam,
440 #[term(cv=MS, accession=1003960, name="liquid metal ion gun", flags={0}, parents={["MS:1000446"]})]
441 #[doc="liquid metal ion gun - A liquid metal ion gun (LMIG) is an ion source that extracts and ionizes a thin layer of liquid metal from a fine heated needle using a high-voltage electric field. It produces a high-brightness, tightly focused beam of metal ions or clusters, enabling high-resolution imaging and analysis in Secondary Ion Mass Spectrometry (SIMS)."]
442 LiquidMetalIonGun,
443 }
444 }
446
447crate::cvmap! {
448 #[flag_type=i32]
449 #[allow(unused)]
450 #[derive(Debug, Clone, Copy, PartialEq, Eq)]
451 #[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
452 pub enum InletTypeTerm {
460 #[term(cv=MS, accession=1000007, name="inlet type", flags={0}, parents={[]})]
461 #[doc="inlet type - The nature of the sample inlet."]
462 InletType,
463 #[term(cv=MS, accession=1000055, name="continuous flow fast atom bombardment", flags={0}, parents={["MS:1000007"]})]
464 #[doc="continuous flow fast atom bombardment - Fast atom bombardment ionization in which the analyte in solution is entrained in a flowing liquid matrix."]
465 ContinuousFlowFastAtomBombardment,
466 #[term(cv=MS, accession=1000056, name="direct inlet", flags={0}, parents={["MS:1000007"]})]
467 #[doc="direct inlet - The sample is directly inserted into the ion source, usually on the end of a heatable probe."]
468 DirectInlet,
469 #[term(cv=MS, accession=1000057, name="electrospray inlet", flags={0}, parents={["MS:1000007"]})]
470 #[doc="electrospray inlet - Inlet used for introducing the liquid sample into an electrospray ionization source."]
471 ElectrosprayInlet,
472 #[term(cv=MS, accession=1000058, name="flow injection analysis", flags={0}, parents={["MS:1000007"]})]
473 #[doc="flow injection analysis - A sample introduction method in which a discrete sample aliquot is injected into a continuous carrier solvent stream and transported to the ionization source without separation, producing a transient analytical signal."]
474 FlowInjectionAnalysis,
475 #[term(cv=MS, accession=1000059, name="inductively coupled plasma", flags={0}, parents={["MS:1000007"]})]
476 #[doc="inductively coupled plasma - A gas discharge ion source in which the energy to the plasma is supplied by electromagnetic induction."]
477 InductivelyCoupledPlasma,
478 #[term(cv=MS, accession=1000060, name="infusion", flags={0}, parents={["MS:1000007"]})]
479 #[doc="infusion - A sample introduction method in which a sample solution is continuously delivered to the ionization source at a constant flow rate without separation."]
480 Infusion,
481 #[term(cv=MS, accession=1000061, name="jet separator", flags={0}, parents={["MS:1000007"]})]
482 #[doc="jet separator - A device that separates carrier gas from gaseous analyte molecules on the basis of diffusivity."]
483 JetSeparator,
484 #[term(cv=MS, accession=1000062, name="membrane separator", flags={0}, parents={["MS:1000007"]})]
485 #[doc="membrane separator - A device to separate carrier molecules from analyte molecules on the basis of ease of diffusion across a semipermeable membrane."]
486 MembraneSeparator,
487 #[term(cv=MS, accession=1000063, name="moving belt", flags={0}, parents={["MS:1000007"]})]
488 #[doc="moving belt - Continuous moving surface in the form of a belt which passes through an ion source carrying analyte molecules."]
489 MovingBelt,
490 #[term(cv=MS, accession=1000064, name="moving wire", flags={0}, parents={["MS:1000007"]})]
491 #[doc="moving wire - Continuous moving surface in the form of a wire which passes through an ion source carrying analyte molecules."]
492 MovingWire,
493 #[term(cv=MS, accession=1000065, name="open split", flags={0}, parents={["MS:1000007"]})]
494 #[doc="open split - A division of flowing stream of liquid into two streams."]
495 OpenSplit,
496 #[term(cv=MS, accession=1000066, name="particle beam", flags={0}, parents={["MS:1000007"]})]
497 #[doc="particle beam - Method for generating ions from a solution of an analyte."]
498 ParticleBeam,
499 #[term(cv=MS, accession=1000067, name="reservoir", flags={0}, parents={["MS:1000007"]})]
500 #[doc="reservoir - A sample inlet method involving a reservoir."]
501 Reservoir,
502 #[term(cv=MS, accession=1000068, name="septum", flags={0}, parents={["MS:1000007"]})]
503 #[doc="septum - A disc composed of a flexible material that seals the entrance to the reservoir. Can also be entrance to the vacuum chamber."]
504 Septum,
505 #[term(cv=MS, accession=1000069, name="thermospray inlet", flags={0}, parents={["MS:1000007"]})]
506 #[doc="thermospray inlet - A method for generating gas phase ions from a solution of an analyte by rapid heating of the sample."]
507 ThermosprayInlet,
508 #[term(cv=MS, accession=1000248, name="direct insertion probe", flags={0}, parents={["MS:1000007"]})]
509 #[doc="direct insertion probe - A device for introducing a solid or liquid sample into a mass spectrometer ion source for desorption ionization."]
510 DirectInsertionProbe,
511 #[term(cv=MS, accession=1000249, name="direct liquid introduction", flags={0}, parents={["MS:1000007"]})]
512 #[doc="direct liquid introduction - A legacy liquid chromatography-mass spectrometry interface in which a minor fraction of the eluate flow is split and introduced through a narrow orifice or diaphragm directly into the ion source, with solvent-mediated chemical ionization. This interface was largely superseded by atmospheric pressure ionization methods."]
513 DirectLiquidIntroduction,
514 #[term(cv=MS, accession=1000396, name="membrane inlet", flags={0}, parents={["MS:1000007"]})]
515 #[doc="membrane inlet - A semi-permeable membrane separator that permits the passage of gas sample directly to the mass spectrometer ion source."]
516 MembraneInlet,
517 #[term(cv=MS, accession=1000485, name="nanospray inlet", flags={0}, parents={["MS:1000057"]})]
518 #[doc="nanospray inlet - Nanospray Inlet."]
519 NanosprayInlet,
520 }
521 }
523
524crate::cvmap! {
525 #[flag_type=i32]
526 #[allow(unused)]
527 #[derive(Debug, Clone, Copy, PartialEq, Eq)]
528 #[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
529 pub enum DetectorTypeTerm {
537 #[term(cv=MS, accession=1000026, name="detector type", flags={0}, parents={[]})]
538 #[doc="detector type - Type of detector used in the mass spectrometer."]
539 DetectorType,
540 #[term(cv=MS, accession=1000107, name="channeltron", flags={0}, parents={["MS:1000026"]})]
541 #[doc="channeltron - A horn-shaped (or cone-shaped) continuous dynode particle multiplier. The ion strikes the inner surface of the device and induces the production of secondary electrons that in turn impinge on the inner surfaces to produce more secondary electrons. This avalanche effect produces an increase in signal in the final measured current pulse."]
542 Channeltron,
543 #[term(cv=MS, accession=1000108, name="conversion dynode electron multiplier", flags={0}, parents={["MS:1000346"]})]
544 #[doc="conversion dynode electron multiplier - A surface that is held at high potential so that ions striking the surface produce electrons that are subsequently detected."]
545 ConversionDynodeElectronMultiplier,
546 #[term(cv=MS, accession=1000109, name="conversion dynode photomultiplier", flags={0}, parents={["MS:1000346"]})]
547 #[doc="conversion dynode photomultiplier - A detector in which ions strike a conversion dynode to produce electrons that in turn generate photons through a phosphorescent screen that are detected by a photomultiplier."]
548 ConversionDynodePhotomultiplier,
549 #[term(cv=MS, accession=1000110, name="daly detector", flags={0}, parents={["MS:1000026"]})]
550 #[doc="daly detector - Detector consisting of a conversion dynode, scintillator and photomultiplier. The metal knob at high potential emits secondary electrons when ions impinge on the surface. The secondary electrons are accelerated onto the scintillator that produces light that is then detected by the photomultiplier detector."]
551 DalyDetector,
552 #[term(cv=MS, accession=1000111, name="electron multiplier tube", flags={0}, parents={["MS:1000253"]})]
553 #[doc="electron multiplier tube - A device to amplify the current of a beam or packet of charged particles or photons by incidence upon the surface of an electrode to produce secondary electrons."]
554 ElectronMultiplierTube,
555 #[term(cv=MS, accession=1000112, name="faraday cup", flags={0}, parents={["MS:1000026"]})]
556 #[doc="faraday cup - A conducting cup or chamber that intercepts a charged particle beam and is electrically connected to a current measuring device."]
557 FaradayCup,
558 #[term(cv=MS, accession=1000113, name="focal plane array", flags={0}, parents={["MS:1000348"]})]
559 #[doc="focal plane array - An array of detectors for spatially disperse ion beams in which all ions simultaneously impinge on the detector plane."]
560 FocalPlaneArray,
561 #[term(cv=MS, accession=1000114, name="microchannel plate detector", flags={0}, parents={["MS:1000345"]})]
562 #[doc="microchannel plate detector - A thin plate that contains a closely spaced array of channels that each act as a continuous dynode particle multiplier. A charged particle, fast neutral particle, or photon striking the plate causes a cascade of secondary electrons that ultimately exits the opposite side of the plate."]
563 MicrochannelPlateDetector,
564 #[term(cv=MS, accession=1000115, name="multi-collector", flags={0}, parents={["MS:1000026"]})]
565 #[doc="multi-collector - A detector system commonly used in inductively coupled plasma mass spectrometers."]
566 MultiCollector,
567 #[term(cv=MS, accession=1000116, name="photomultiplier", flags={0}, parents={["MS:1000026"]})]
568 #[doc="photomultiplier - A detector for conversion of the ion/electron signal into photon(s) which are then amplified and detected."]
569 Photomultiplier,
570 #[term(cv=MS, accession=1000253, name="electron multiplier", flags={0}, parents={["MS:1000026"]})]
571 #[doc="electron multiplier - A device to amplify the current of a beam or packet of charged particles or photons by incidence upon the surface of an electrode to produce secondary electrons. The secondary electrons are then accelerated to other electrodes or parts of a continuous electrode to produce further secondary electrons."]
572 ElectronMultiplier,
573 #[term(cv=MS, accession=1000345, name="array detector", flags={0}, parents={["MS:1000026"]})]
574 #[doc="array detector - Detector comprising several ion collection elements, arranged in a line or grid where each element is an individual detector."]
575 ArrayDetector,
576 #[term(cv=MS, accession=1000346, name="conversion dynode", flags={0}, parents={["MS:1000026"]})]
577 #[doc="conversion dynode - A surface that is held at high potential such that ions striking the surface produce electrons that are subsequently detected."]
578 ConversionDynode,
579 #[term(cv=MS, accession=1000347, name="dynode", flags={0}, parents={["MS:1000026"]})]
580 #[doc="dynode - One of a series of electrodes in a photomultiplier tube. Such an arrangement is able to amplify the current emitted by the photocathode."]
581 Dynode,
582 #[term(cv=MS, accession=1000348, name="focal plane collector", flags={0}, parents={["MS:1000026"]})]
583 #[doc="focal plane collector - A detector for spatially disperse ion beams in which all ions simultaneously impinge on the detector plane."]
584 FocalPlaneCollector,
585 #[term(cv=MS, accession=1000349, name="ion-to-photon detector", flags={0}, parents={["MS:1000026"]})]
586 #[doc="ion-to-photon detector - A detector in which ions strike a conversion dynode to produce electrons that in turn strike a phosphor and the resulting photons are detected by a photomultiplier."]
587 IonToPhotonDetector,
588 #[term(cv=MS, accession=1000350, name="point collector", flags={0}, parents={["MS:1000026"]})]
589 #[doc="point collector - A detector in which the ion beam is focused onto a point and the individual ions arrive sequentially."]
590 PointCollector,
591 #[term(cv=MS, accession=1000351, name="postacceleration detector", flags={0}, parents={["MS:1000026"]})]
592 #[doc="postacceleration detector - A detector in which the charged particles are accelerated to a high velocity and impinge on a conversion dynode, emitting secondary electrons. The electrons are accelerated onto a phosphor screen, which emits photons that are in turn detected using a photomultiplier or other photon detector."]
593 PostaccelerationDetector,
594 #[term(cv=MS, accession=1000621, name="photodiode array detector", flags={0}, parents={["MS:1000345"]})]
595 #[doc="photodiode array detector - An array detector used to record spectra in the ultraviolet and visible region of light."]
596 PhotodiodeArrayDetector,
597 #[term(cv=MS, accession=1000624, name="inductive detector", flags={0}, parents={["MS:1000026"]})]
598 #[doc="inductive detector - Inductive detector."]
599 InductiveDetector,
600 #[term(cv=MS, accession=1000818, name="Acquity UPLC PDA", flags={0}, parents={["MS:1000126", "MS:1000621"]})]
601 #[doc="Acquity UPLC PDA - Acquity UPLC Photodiode Array Detector."]
602 AcquityUPLCPDA,
603 #[term(cv=MS, accession=1000819, name="Acquity UPLC FLR", flags={0}, parents={["MS:1000126", "MS:1002308"]})]
604 #[doc="Acquity UPLC FLR - Acquity UPLC Fluorescence Detector."]
605 AcquityUPLCFLR,
606 #[term(cv=MS, accession=1002308, name="fluorescence detector", flags={0}, parents={["MS:1000026"]})]
607 #[doc="fluorescence detector - A detector using a fluorescent signal after excitation with light."]
608 FluorescenceDetector,
609 }
610 }