bioformats  5.1.3
Objective.h
1 /*
2  * #%L
3  * OME-XML C++ library for working with OME-XML metadata structures.
4  * %%
5  * Copyright © 2006 - 2015 Open Microscopy Environment:
6  * - Massachusetts Institute of Technology
7  * - National Institutes of Health
8  * - University of Dundee
9  * - Board of Regents of the University of Wisconsin-Madison
10  * - Glencoe Software, Inc.
11  * %%
12  * Redistribution and use in source and binary forms, with or without
13  * modification, are permitted provided that the following conditions are met:
14  *
15  * 1. Redistributions of source code must retain the above copyright notice,
16  * this list of conditions and the following disclaimer.
17  * 2. Redistributions in binary form must reproduce the above copyright notice,
18  * this list of conditions and the following disclaimer in the documentation
19  * and/or other materials provided with the distribution.
20  *
21  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
22  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24  * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE
25  * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
26  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
27  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
28  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
29  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
30  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
31  * POSSIBILITY OF SUCH DAMAGE.
32  *
33  * The views and conclusions contained in the software and documentation are
34  * those of the authors and should not be interpreted as representing official
35  * policies, either expressed or implied, of any organization.
36  * #L%
37  */
38 
39 /*─────────────────────────────────────────────────────────────────────────────
40  *
41  * THIS IS AUTOMATICALLY GENERATED CODE. DO NOT MODIFY.
42  *
43  *─────────────────────────────────────────────────────────────────────────────
44  */
45 
46 #ifndef OME_XML_MODEL_OBJECTIVE_H
47 #define OME_XML_MODEL_OBJECTIVE_H
48 
49 #include <algorithm>
50 #include <list>
51 #include <stdexcept>
52 #include <string>
53 #include <vector>
54 
55 #include <ome/common/log.h>
56 
57 #include <ome/common/xml/dom/Document.h>
58 #include <ome/common/xml/dom/Element.h>
59 #include <ome/common/xml/dom/Node.h>
60 #include <ome/common/xml/dom/NodeList.h>
61 
62 #include <ome/xml/model/Instrument.h>
63 #include <ome/xml/model/ManufacturerSpec.h>
64 #include <ome/xml/model/enums/Correction.h>
65 #include <ome/xml/model/enums/Immersion.h>
66 
67 namespace ome
68 {
69  namespace xml
70  {
71  namespace model
72  {
73 
74  // Forward declarations.
75  class OMEModel;
76 
80  class Objective : public ManufacturerSpec
81  {
82  private:
84  ome::compat::shared_ptr<bool> iris;
86  ome::compat::shared_ptr<double> workingDistance;
88  ome::compat::shared_ptr<ome::xml::model::enums::Immersion> immersion;
90  ome::compat::shared_ptr<ome::xml::model::enums::Correction> correction;
92  ome::compat::shared_ptr<double> lensNA;
94  ome::compat::shared_ptr<double> nominalMagnification;
96  ome::compat::shared_ptr<double> calibratedMagnification;
98  std::string id;
100  ome::compat::weak_ptr<ome::xml::model::Instrument> instrument;
101 
102  public:
104  Objective ();
105 
111  Objective (const Objective& copy);
112 
114  virtual
115  ~Objective ();
116 
117 
118 
133  static ome::compat::shared_ptr< Objective>
134  create(const common::xml::dom::Element& element,
136 
137  // Documented in superclass.
138  const std::string&
139  elementName() const;
140 
141  // Documented in superclass.
142  bool
143  validElementName(const std::string& name) const;
144 
145 
146  // -- OMEModelObject API methods --
147 
149  virtual void
150  update(const common::xml::dom::Element& element,
152 
153  public:
154  // -- Objective API methods --
155 
157  bool
158  link (ome::compat::shared_ptr<Reference>& reference,
159  ome::compat::shared_ptr< ome::xml::model::OMEModelObject>& object);
160 
166  ome::compat::shared_ptr<bool>
167  getIris ();
168 
174  const ome::compat::shared_ptr<bool>
175  getIris () const;
176 
182  void
183  setIris (ome::compat::shared_ptr<bool>& iris);
184 
190  ome::compat::shared_ptr<double>
192 
198  const ome::compat::shared_ptr<double>
199  getWorkingDistance () const;
200 
206  void
207  setWorkingDistance (ome::compat::shared_ptr<double>& workingDistance);
208 
214  ome::compat::shared_ptr<ome::xml::model::enums::Immersion>
215  getImmersion ();
216 
222  const ome::compat::shared_ptr<ome::xml::model::enums::Immersion>
223  getImmersion () const;
224 
230  void
231  setImmersion (ome::compat::shared_ptr<ome::xml::model::enums::Immersion>& immersion);
232 
238  ome::compat::shared_ptr<ome::xml::model::enums::Correction>
239  getCorrection ();
240 
246  const ome::compat::shared_ptr<ome::xml::model::enums::Correction>
247  getCorrection () const;
248 
254  void
255  setCorrection (ome::compat::shared_ptr<ome::xml::model::enums::Correction>& correction);
256 
262  ome::compat::shared_ptr<double>
263  getLensNA ();
264 
270  const ome::compat::shared_ptr<double>
271  getLensNA () const;
272 
278  void
279  setLensNA (ome::compat::shared_ptr<double>& lensNA);
280 
286  ome::compat::shared_ptr<double>
288 
294  const ome::compat::shared_ptr<double>
295  getNominalMagnification () const;
296 
302  void
303  setNominalMagnification (ome::compat::shared_ptr<double>& nominalMagnification);
304 
310  ome::compat::shared_ptr<double>
312 
318  const ome::compat::shared_ptr<double>
320 
326  void
327  setCalibratedMagnification (ome::compat::shared_ptr<double>& calibratedMagnification);
328 
334  const std::string&
335  getID () const;
336 
342  void
343  setID (const std::string& id);
344 
350  ome::compat::weak_ptr<ome::xml::model::Instrument>
351  getInstrument ();
352 
358  const ome::compat::weak_ptr<ome::xml::model::Instrument>
359  getInstrument () const;
360 
366  void
367  setInstrument (ome::compat::weak_ptr<ome::xml::model::Instrument>& instrument_BackReference);
368 
369 
372  asXMLElement (common::xml::dom::Document& document) const;
373 
374 
375  protected:
376  // Documented in base class.
379  common::xml::dom::Element& element) const;
380 
381  public:
382  // Documented in superclass.
383  const std::string&
384  getXMLNamespace() const;
385  };
386 
387  }
388  }
389 }
390 
391 #endif // OME_XML_MODEL_OBJECTIVE_H
392 
393 /*
394  * Local Variables:
395  * mode:C++
396  * End:
397  */
OME model interface (abstract top-level container)
Definition: OMEModel.h:62
void setImmersion(ome::compat::shared_ptr< ome::xml::model::enums::Immersion > &immersion)
Set the Immersion property.
Definition: Objective.cpp:344
ome::compat::shared_ptr< double > getWorkingDistance()
Get the WorkingDistance property.
Definition: Objective.cpp:309
ome::compat::shared_ptr< ome::xml::model::enums::Correction > correction
Correction property.
Definition: Objective.h:90
void setWorkingDistance(ome::compat::shared_ptr< double > &workingDistance)
Set the WorkingDistance property.
Definition: Objective.cpp:323
const std::string & getXMLNamespace() const
Get the XML namespace for this model object.
Definition: Objective.cpp:587
ome::compat::shared_ptr< std::string > model
Model property.
Definition: ManufacturerSpec.h:83
void setNominalMagnification(ome::compat::shared_ptr< double > &nominalMagnification)
Set the NominalMagnification property.
Definition: Objective.cpp:407
bool validElementName(const std::string &name) const
Check if a given element name is valid for processing by this model object.
Definition: Objective.cpp:178
DOM Document wrapper.
Definition: Document.h:82
DOM Element wrapper.
Definition: Element.h:66
ome::compat::weak_ptr< ome::xml::model::Instrument > getInstrument()
Get the Instrument property.
Definition: Objective.cpp:449
void setLensNA(ome::compat::shared_ptr< double > &lensNA)
Set the LensNA property.
Definition: Objective.cpp:386
ome::compat::shared_ptr< double > getNominalMagnification()
Get the NominalMagnification property.
Definition: Objective.cpp:393
ome::compat::shared_ptr< double > getLensNA()
Get the LensNA property.
Definition: Objective.cpp:372
static ome::compat::shared_ptr< Objective > create(const common::xml::dom::Element &element, ome::xml::model::OMEModel &model)
Create a Objective model object from DOM element.
Definition: Objective.cpp:162
bool link(ome::compat::shared_ptr< Reference > &reference, ome::compat::shared_ptr< ome::xml::model::OMEModelObject > &object)
Link a given OME model object to this model object.
Definition: Objective.cpp:273
Open Microscopy Environment C++ implementation.
Definition: CoreMetadata.cpp:40
ome::compat::shared_ptr< double > calibratedMagnification
CalibratedMagnification property.
Definition: Objective.h:96
ome::compat::shared_ptr< ome::xml::model::enums::Correction > getCorrection()
Get the Correction property.
Definition: Objective.cpp:351
std::string id
ID property.
Definition: Objective.h:98
void setCalibratedMagnification(ome::compat::shared_ptr< double > &calibratedMagnification)
Set the CalibratedMagnification property.
Definition: Objective.cpp:428
Objective model object.
Definition: Objective.h:80
virtual void update(const common::xml::dom::Element &element, ome::xml::model::OMEModel &model)
Update the object hierarchy recursively from an XML DOM tree.
Definition: Objective.cpp:187
void setCorrection(ome::compat::shared_ptr< ome::xml::model::enums::Correction > &correction)
Set the Correction property.
Definition: Objective.cpp:365
const std::string & getID() const
Get the ID property.
Definition: Objective.cpp:435
ome::compat::shared_ptr< double > lensNA
LensNA property.
Definition: Objective.h:92
ome::compat::shared_ptr< double > workingDistance
WorkingDistance property.
Definition: Objective.h:86
ome::compat::weak_ptr< ome::xml::model::Instrument > instrument
Instrument_BackReference back reference.
Definition: Objective.h:100
virtual ~Objective()
Destructor.
Definition: Objective.cpp:157
ManufacturerSpec model object.
Definition: ManufacturerSpec.h:77
ome::compat::shared_ptr< ome::xml::model::enums::Immersion > getImmersion()
Get the Immersion property.
Definition: Objective.cpp:330
void setIris(ome::compat::shared_ptr< bool > &iris)
Set the Iris property.
Definition: Objective.cpp:302
ome::compat::shared_ptr< double > nominalMagnification
NominalMagnification property.
Definition: Objective.h:94
Objective()
Default constructor.
Definition: Objective.cpp:122
ome::compat::shared_ptr< ome::xml::model::enums::Immersion > immersion
Immersion property.
Definition: Objective.h:88
void setInstrument(ome::compat::weak_ptr< ome::xml::model::Instrument > &instrument_BackReference)
Set the Instrument property.
Definition: Objective.cpp:463
virtual common::xml::dom::Element asXMLElementInternal(common::xml::dom::Document &document, common::xml::dom::Element &element) const
Transform the object hierarchy rooted at this element to XML.
Definition: Objective.cpp:477
Boost.Log compatibility.
ome::compat::shared_ptr< double > getCalibratedMagnification()
Get the CalibratedMagnification property.
Definition: Objective.cpp:414
virtual common::xml::dom::Element asXMLElement(common::xml::dom::Document &document) const
Transform the object hierarchy rooted at this element to XML.
Definition: Objective.cpp:470
ome::compat::shared_ptr< bool > getIris()
Get the Iris property.
Definition: Objective.cpp:288
void setID(const std::string &id)
Set the ID property.
Definition: Objective.cpp:442
ome::compat::shared_ptr< bool > iris
Iris property.
Definition: Objective.h:84
Xerces-C modern C++ wrapper.
Definition: Base.h:53
const std::string & elementName() const
Get the element name of this model object.
Definition: Objective.cpp:171