ome-xml  5.5.0
Filter.h
1 /*
2  * #%L
3  * OME-XML C++ library for working with OME-XML metadata structures.
4  * %%
5  * Copyright © 2006 - 2016 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_FILTER_H
47 #define OME_XML_MODEL_FILTER_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 
61 #include <ome/xml/model/primitives/Quantity.h>
62 
63 #include <ome/xml/model/Instrument.h>
64 #include <ome/xml/model/ManufacturerSpec.h>
65 #include <ome/xml/model/TransmittanceRange.h>
66 #include <ome/xml/model/enums/FilterType.h>
67 
68 namespace ome
69 {
70  namespace xml
71  {
72  namespace model
73  {
74 
75  // Forward declarations.
76  class Annotation;
77  class FilterSet;
78  class LightPath;
79  class OMEModel;
80 
84  class Filter : public ManufacturerSpec
85  {
86  private:
87  class Impl;
89  std::shared_ptr<Impl> impl;
90 
91  public:
93  Filter();
94 
100  Filter (const Filter& copy);
101 
103  virtual
104  ~Filter ();
105 
120  static std::shared_ptr<Filter>
121  create(const common::xml::dom::Element& element,
123 
124  // Documented in superclass.
125  const std::string&
126  elementName() const;
127 
128  // Documented in superclass.
129  bool
130  validElementName(const std::string& name) const;
131 
132  private:
134  Filter&
135  operator= (const Filter&);
136 
137  public:
138  // -- OMEModelObject API methods --
139 
141  virtual void
142  update(const common::xml::dom::Element& element,
144 
145  public:
146  // -- Filter API methods --
147 
149  bool
150  link (std::shared_ptr<Reference>& reference,
151  std::shared_ptr<ome::xml::model::OMEModelObject>& object);
152 
158  std::shared_ptr<std::string>
159  getFilterWheel ();
160 
166  const std::shared_ptr<std::string>
167  getFilterWheel () const;
168 
174  void
175  setFilterWheel (std::shared_ptr<std::string>& filterWheel);
176 
182  std::shared_ptr<ome::xml::model::enums::FilterType>
183  getType ();
184 
190  const std::shared_ptr<ome::xml::model::enums::FilterType>
191  getType () const;
192 
198  void
199  setType (std::shared_ptr<ome::xml::model::enums::FilterType>& type);
200 
206  const std::string&
207  getID () const;
208 
214  void
215  setID (const std::string& id);
216 
222  std::shared_ptr<ome::xml::model::TransmittanceRange>
224 
230  const std::shared_ptr<ome::xml::model::TransmittanceRange>
231  getTransmittanceRange () const;
232 
238  void
239  setTransmittanceRange (std::shared_ptr<ome::xml::model::TransmittanceRange>& transmittanceRange);
240 
248 
255  getLinkedAnnotationList () const;
256 
264  const std::weak_ptr<ome::xml::model::Annotation>&
266 
277  const std::weak_ptr<ome::xml::model::Annotation>&
279  const std::shared_ptr<ome::xml::model::Annotation>& annotation);
280 
291  bool
292  linkAnnotation (const std::shared_ptr<ome::xml::model::Annotation>& annotation);
293 
309  bool
310  unlinkAnnotation (const std::shared_ptr<ome::xml::model::Annotation>& annotation);
311 
317  std::weak_ptr<ome::xml::model::Instrument>
318  getInstrument ();
319 
325  const std::weak_ptr<ome::xml::model::Instrument>
326  getInstrument () const;
327 
333  void
334  setInstrument (std::weak_ptr<ome::xml::model::Instrument>& instrument_BackReference);
335 
343 
351 
359  const std::weak_ptr<ome::xml::model::FilterSet>&
361 
372  const std::weak_ptr<ome::xml::model::FilterSet>&
374  const std::shared_ptr<ome::xml::model::FilterSet>& filterSet_BackReference);
375 
386  bool
387  linkFilterSetExcitationFilter (const std::shared_ptr<ome::xml::model::FilterSet>& filterSet_BackReference);
388 
404  bool
405  unlinkFilterSetExcitationFilter (const std::shared_ptr<ome::xml::model::FilterSet>& filterSet_BackReference);
406 
414 
422 
430  const std::weak_ptr<ome::xml::model::FilterSet>&
432 
443  const std::weak_ptr<ome::xml::model::FilterSet>&
445  const std::shared_ptr<ome::xml::model::FilterSet>& filterSet_BackReference);
446 
457  bool
458  linkFilterSetEmissionFilter (const std::shared_ptr<ome::xml::model::FilterSet>& filterSet_BackReference);
459 
475  bool
476  unlinkFilterSetEmissionFilter (const std::shared_ptr<ome::xml::model::FilterSet>& filterSet_BackReference);
477 
485 
493 
501  const std::weak_ptr<ome::xml::model::LightPath>&
503 
514  const std::weak_ptr<ome::xml::model::LightPath>&
516  const std::shared_ptr<ome::xml::model::LightPath>& lightPath_BackReference);
517 
528  bool
529  linkLightPathExcitationFilter (const std::shared_ptr<ome::xml::model::LightPath>& lightPath_BackReference);
530 
546  bool
547  unlinkLightPathExcitationFilter (const std::shared_ptr<ome::xml::model::LightPath>& lightPath_BackReference);
548 
556 
564 
572  const std::weak_ptr<ome::xml::model::LightPath>&
574 
585  const std::weak_ptr<ome::xml::model::LightPath>&
587  const std::shared_ptr<ome::xml::model::LightPath>& lightPath_BackReference);
588 
599  bool
600  linkLightPathEmissionFilter (const std::shared_ptr<ome::xml::model::LightPath>& lightPath_BackReference);
601 
617  bool
618  unlinkLightPathEmissionFilter (const std::shared_ptr<ome::xml::model::LightPath>& lightPath_BackReference);
619 
620  protected:
621  // Documented in base class.
622  virtual void
624  common::xml::dom::Element& element) const;
625 
626  public:
627  // Documented in superclass.
628  const std::string&
629  getXMLNamespace() const;
630  };
631 
632  }
633  }
634 }
635 
636 #endif // OME_XML_MODEL_FILTER_H
637 
638 /*
639  * Local Variables:
640  * mode:C++
641  * End:
642  */
OME model interface (abstract top-level container)
Definition: OMEModel.h:61
std::weak_ptr< ome::xml::model::Instrument > getInstrument()
Get the Instrument property.
Definition: Filter.cpp:460
bool validElementName(const std::string &name) const
Check if a given element name is valid for processing by this model object.
Definition: Filter.cpp:216
bool linkAnnotation(const std::shared_ptr< ome::xml::model::Annotation > &annotation)
Link Annotation.
Definition: Filter.cpp:428
std::shared_ptr< Impl > impl
Private implementation details.
Definition: Filter.h:87
static std::shared_ptr< Filter > create(const common::xml::dom::Element &element, ome::xml::model::OMEModel &model)
Create a Filter model object from DOM element.
Definition: Filter.cpp:200
std::shared_ptr< ome::xml::model::enums::FilterType > getType()
Get the Type property.
Definition: Filter.cpp:344
const std::weak_ptr< ome::xml::model::FilterSet > & setLinkedFilterSetExcitationFilter(OMEModelObject::indexed_container< ome::xml::model::FilterSet, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::FilterSet > &filterSet_BackReference)
Set linked FilterSetExcitationFilter.
Definition: Filter.cpp:499
Filter()
Default constructor.
Definition: Filter.cpp:180
bool unlinkAnnotation(const std::shared_ptr< ome::xml::model::Annotation > &annotation)
Unlink Annotation.
Definition: Filter.cpp:442
const std::string & elementName() const
Get the element name of this model object.
Definition: Filter.cpp:209
virtual ~Filter()
Destructor.
Definition: Filter.cpp:195
bool linkLightPathEmissionFilter(const std::shared_ptr< ome::xml::model::LightPath > &lightPath_BackReference)
Link LightPathEmissionFilter.
Definition: Filter.cpp:683
void setTransmittanceRange(std::shared_ptr< ome::xml::model::TransmittanceRange > &transmittanceRange)
Set the TransmittanceRange property.
Definition: Filter.cpp:393
void setFilterWheel(std::shared_ptr< std::string > &filterWheel)
Set the FilterWheel property.
Definition: Filter.cpp:337
Filter & operator=(const Filter &)
Assignment operator (deleted).
OMEModelObject::indexed_container< ome::xml::model::FilterSet, std::weak_ptr >::type::size_type sizeOfLinkedFilterSetEmissionFilterList() const
Get size of linked FilterSetEmissionFilter list.
Definition: Filter.cpp:539
std::shared_ptr< std::string > getFilterWheel()
Get the FilterWheel property.
Definition: Filter.cpp:323
const std::weak_ptr< ome::xml::model::LightPath > & getLinkedLightPathExcitationFilter(OMEModelObject::indexed_container< ome::xml::model::LightPath, std::weak_ptr >::type::size_type index) const
Get linked LightPathExcitationFilter.
Definition: Filter.cpp:609
const std::weak_ptr< ome::xml::model::Annotation > & getLinkedAnnotation(OMEModelObject::indexed_container< ome::xml::model::Annotation, std::weak_ptr >::type::size_type index) const
Get linked Annotation.
Definition: Filter.cpp:412
boost::multi_index_container< Ptr< T >, boost::multi_index::indexed_by< boost::multi_index::random_access<>, boost::multi_index::ordered_unique< boost::multi_index::identity< Ptr< T > >, std::owner_less< Ptr< T > > > > > type
Multi-index container type.
Definition: OMEModelObject.h:93
OMEModelObject::indexed_container< ome::xml::model::LightPath, std::weak_ptr >::type getLinkedLightPathEmissionFilterList() const
Get the linked LightPathEmissionFilter list.
Definition: Filter.cpp:661
OMEModelObject::indexed_container< ome::xml::model::LightPath, std::weak_ptr >::type getLinkedLightPathExcitationFilterList() const
Get the linked LightPathExcitationFilter list.
Definition: Filter.cpp:603
bool unlinkLightPathExcitationFilter(const std::shared_ptr< ome::xml::model::LightPath > &lightPath_BackReference)
Unlink LightPathExcitationFilter.
Definition: Filter.cpp:638
bool linkFilterSetExcitationFilter(const std::shared_ptr< ome::xml::model::FilterSet > &filterSet_BackReference)
Link FilterSetExcitationFilter.
Definition: Filter.cpp:509
const std::string & getID() const
Get the ID property.
Definition: Filter.cpp:365
void setInstrument(std::weak_ptr< ome::xml::model::Instrument > &instrument_BackReference)
Set the Instrument property.
Definition: Filter.cpp:474
const std::weak_ptr< ome::xml::model::Annotation > & setLinkedAnnotation(OMEModelObject::indexed_container< ome::xml::model::Annotation, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::Annotation > &annotation)
Set linked Annotation.
Definition: Filter.cpp:418
Multi-index container for efficient ordered insertion and deletion of model object references...
Definition: OMEModelObject.h:84
OMEModelObject::indexed_container< ome::xml::model::LightPath, std::weak_ptr >::type::size_type sizeOfLinkedLightPathEmissionFilterList() const
Get size of linked LightPathEmissionFilter list.
Definition: Filter.cpp:655
Private implementation details of Filter model object.
Definition: Filter.cpp:78
Open Microscopy Environment C++ implementation.
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: Filter.cpp:222
OMEModelObject::indexed_container< ome::xml::model::LightPath, std::weak_ptr >::type::size_type sizeOfLinkedLightPathExcitationFilterList() const
Get size of linked LightPathExcitationFilter list.
Definition: Filter.cpp:597
OMEModelObject::indexed_container< ome::xml::model::FilterSet, std::weak_ptr >::type getLinkedFilterSetExcitationFilterList() const
Get the linked FilterSetExcitationFilter list.
Definition: Filter.cpp:487
bool linkLightPathExcitationFilter(const std::shared_ptr< ome::xml::model::LightPath > &lightPath_BackReference)
Link LightPathExcitationFilter.
Definition: Filter.cpp:625
bool unlinkLightPathEmissionFilter(const std::shared_ptr< ome::xml::model::LightPath > &lightPath_BackReference)
Unlink LightPathEmissionFilter.
Definition: Filter.cpp:696
std::shared_ptr< ome::xml::model::TransmittanceRange > getTransmittanceRange()
Get the TransmittanceRange property.
Definition: Filter.cpp:379
OMEModelObject::indexed_container< ome::xml::model::Annotation, std::weak_ptr >::type::size_type sizeOfLinkedAnnotationList() const
Get size of linked Annotation list.
Definition: Filter.cpp:400
const std::weak_ptr< ome::xml::model::FilterSet > & getLinkedFilterSetExcitationFilter(OMEModelObject::indexed_container< ome::xml::model::FilterSet, std::weak_ptr >::type::size_type index) const
Get linked FilterSetExcitationFilter.
Definition: Filter.cpp:493
const std::weak_ptr< ome::xml::model::LightPath > & setLinkedLightPathEmissionFilter(OMEModelObject::indexed_container< ome::xml::model::LightPath, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::LightPath > &lightPath_BackReference)
Set linked LightPathEmissionFilter.
Definition: Filter.cpp:673
virtual void asXMLElementInternal(common::xml::dom::Document &document, common::xml::dom::Element &element) const
Transform the object hierarchy rooted at this element to XML.
Definition: Filter.cpp:712
bool unlinkFilterSetEmissionFilter(const std::shared_ptr< ome::xml::model::FilterSet > &filterSet_BackReference)
Unlink FilterSetEmissionFilter.
Definition: Filter.cpp:580
ManufacturerSpec model object.
Definition: ManufacturerSpec.h:78
const std::weak_ptr< ome::xml::model::LightPath > & getLinkedLightPathEmissionFilter(OMEModelObject::indexed_container< ome::xml::model::LightPath, std::weak_ptr >::type::size_type index) const
Get linked LightPathEmissionFilter.
Definition: Filter.cpp:667
Filter model object.
Definition: Filter.h:84
const std::weak_ptr< ome::xml::model::FilterSet > & getLinkedFilterSetEmissionFilter(OMEModelObject::indexed_container< ome::xml::model::FilterSet, std::weak_ptr >::type::size_type index) const
Get linked FilterSetEmissionFilter.
Definition: Filter.cpp:551
OMEModelObject::indexed_container< ome::xml::model::FilterSet, std::weak_ptr >::type getLinkedFilterSetEmissionFilterList() const
Get the linked FilterSetEmissionFilter list.
Definition: Filter.cpp:545
OMEModelObject::indexed_container< ome::xml::model::Annotation, std::weak_ptr >::type getLinkedAnnotationList() const
Get the linked Annotation list.
Definition: Filter.cpp:406
const std::string & getXMLNamespace() const
Get the XML namespace for this model object.
Definition: Filter.cpp:783
const std::weak_ptr< ome::xml::model::LightPath > & setLinkedLightPathExcitationFilter(OMEModelObject::indexed_container< ome::xml::model::LightPath, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::LightPath > &lightPath_BackReference)
Set linked LightPathExcitationFilter.
Definition: Filter.cpp:615
OMEModelObject::indexed_container< ome::xml::model::FilterSet, std::weak_ptr >::type::size_type sizeOfLinkedFilterSetExcitationFilterList() const
Get size of linked FilterSetExcitationFilter list.
Definition: Filter.cpp:481
bool link(std::shared_ptr< Reference > &reference, std::shared_ptr< ome::xml::model::OMEModelObject > &object)
Link a given OME model object to this model object.
Definition: Filter.cpp:292
void setID(const std::string &id)
Set the ID property.
Definition: Filter.cpp:372
bool unlinkFilterSetExcitationFilter(const std::shared_ptr< ome::xml::model::FilterSet > &filterSet_BackReference)
Unlink FilterSetExcitationFilter.
Definition: Filter.cpp:522
void setType(std::shared_ptr< ome::xml::model::enums::FilterType > &type)
Set the Type property.
Definition: Filter.cpp:358
bool linkFilterSetEmissionFilter(const std::shared_ptr< ome::xml::model::FilterSet > &filterSet_BackReference)
Link FilterSetEmissionFilter.
Definition: Filter.cpp:567
const std::weak_ptr< ome::xml::model::FilterSet > & setLinkedFilterSetEmissionFilter(OMEModelObject::indexed_container< ome::xml::model::FilterSet, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::FilterSet > &filterSet_BackReference)
Set linked FilterSetEmissionFilter.
Definition: Filter.cpp:557