ome-xml  5.2.2
Screen.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_SCREEN_H
47 #define OME_XML_MODEL_SCREEN_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/primitives/Quantity.h>
63 
64 #include <ome/xml/model/detail/OMEModelObject.h>
65 
66 namespace ome
67 {
68  namespace xml
69  {
70  namespace model
71  {
72 
73  // Forward declarations.
74  class Annotation;
75  class OMEModel;
76  class Plate;
77  class Reagent;
78 
83  {
84  private:
85  class Impl;
87  ome::compat::shared_ptr<Impl> impl;
88 
89  public:
91  Screen();
92 
98  Screen (const Screen& copy);
99 
101  virtual
102  ~Screen ();
103 
118  static ome::compat::shared_ptr< Screen>
119  create(const common::xml::dom::Element& element,
121 
122  // Documented in superclass.
123  const std::string&
124  elementName() const;
125 
126  // Documented in superclass.
127  bool
128  validElementName(const std::string& name) const;
129 
130  private:
132  Screen&
133  operator= (const Screen&);
134 
135  public:
136  // -- OMEModelObject API methods --
137 
139  virtual void
140  update(const common::xml::dom::Element& element,
142 
143  public:
144  // -- Screen API methods --
145 
147  bool
148  link (ome::compat::shared_ptr<Reference>& reference,
149  ome::compat::shared_ptr< ome::xml::model::OMEModelObject>& object);
150 
156  ome::compat::shared_ptr<std::string>
157  getName ();
158 
164  const ome::compat::shared_ptr<std::string>
165  getName () const;
166 
172  void
173  setName (ome::compat::shared_ptr<std::string>& name);
174 
180  ome::compat::shared_ptr<std::string>
182 
188  const ome::compat::shared_ptr<std::string>
189  getProtocolDescription () const;
190 
196  void
197  setProtocolDescription (ome::compat::shared_ptr<std::string>& protocolDescription);
198 
204  ome::compat::shared_ptr<std::string>
206 
212  const ome::compat::shared_ptr<std::string>
213  getProtocolIdentifier () const;
214 
220  void
221  setProtocolIdentifier (ome::compat::shared_ptr<std::string>& protocolIdentifier);
222 
228  ome::compat::shared_ptr<std::string>
230 
236  const ome::compat::shared_ptr<std::string>
237  getReagentSetDescription () const;
238 
244  void
245  setReagentSetDescription (ome::compat::shared_ptr<std::string>& reagentSetDescription);
246 
252  ome::compat::shared_ptr<std::string>
253  getType ();
254 
260  const ome::compat::shared_ptr<std::string>
261  getType () const;
262 
268  void
269  setType (ome::compat::shared_ptr<std::string>& type);
270 
276  const std::string&
277  getID () const;
278 
284  void
285  setID (const std::string& id);
286 
292  ome::compat::shared_ptr<std::string>
294 
300  const ome::compat::shared_ptr<std::string>
301  getReagentSetIdentifier () const;
302 
308  void
309  setReagentSetIdentifier (ome::compat::shared_ptr<std::string>& reagentSetIdentifier);
310 
316  ome::compat::shared_ptr<std::string>
317  getDescription ();
318 
324  const ome::compat::shared_ptr<std::string>
325  getDescription () const;
326 
332  void
333  setDescription (ome::compat::shared_ptr<std::string>& description);
334 
340  std::vector<ome::compat::shared_ptr<ome::xml::model::Reagent> >::size_type
341  sizeOfReagentList () const;
342 
349  std::vector<ome::compat::shared_ptr<ome::xml::model::Reagent> >&
350  getReagentList ();
351 
358  const std::vector<ome::compat::shared_ptr<ome::xml::model::Reagent> >&
359  getReagentList () const;
360 
368  ome::compat::shared_ptr<ome::xml::model::Reagent>&
369  getReagent (std::vector<ome::compat::shared_ptr<ome::xml::model::Reagent> >::size_type index);
370 
378  const ome::compat::shared_ptr<ome::xml::model::Reagent>&
379  getReagent (std::vector<ome::compat::shared_ptr<ome::xml::model::Reagent> >::size_type index) const;
380 
388  void
389  setReagent (std::vector<ome::compat::shared_ptr<ome::xml::model::Reagent> >::size_type index,
390  ome::compat::shared_ptr<ome::xml::model::Reagent>& reagent);
391 
400  void
401  addReagent (ome::compat::shared_ptr<ome::xml::model::Reagent>& reagent);
402 
412  void
413  removeReagent (ome::compat::shared_ptr<ome::xml::model::Reagent>& reagent);
414 
421  sizeOfLinkedPlateList () const;
422 
429  getLinkedPlateList () const;
430 
438  const ome::compat::weak_ptr<ome::xml::model::Plate>&
440 
451  const ome::compat::weak_ptr<ome::xml::model::Plate>&
453  const ome::compat::shared_ptr<ome::xml::model::Plate>& plate);
454 
465  bool
466  linkPlate (const ome::compat::shared_ptr<ome::xml::model::Plate>& plate);
467 
483  bool
484  unlinkPlate (const ome::compat::shared_ptr<ome::xml::model::Plate>& plate);
485 
493 
500  getLinkedAnnotationList () const;
501 
509  const ome::compat::weak_ptr<ome::xml::model::Annotation>&
511 
522  const ome::compat::weak_ptr<ome::xml::model::Annotation>&
524  const ome::compat::shared_ptr<ome::xml::model::Annotation>& annotation);
525 
536  bool
537  linkAnnotation (const ome::compat::shared_ptr<ome::xml::model::Annotation>& annotation);
538 
554  bool
555  unlinkAnnotation (const ome::compat::shared_ptr<ome::xml::model::Annotation>& annotation);
556 
559  asXMLElement (common::xml::dom::Document& document) const;
560 
561 
562  protected:
563  // Documented in base class.
566  common::xml::dom::Element& element) const;
567 
568  public:
569  // Documented in superclass.
570  const std::string&
571  getXMLNamespace() const;
572  };
573 
574  }
575  }
576 }
577 
578 #endif // OME_XML_MODEL_SCREEN_H
579 
580 /*
581  * Local Variables:
582  * mode:C++
583  * End:
584  */
OME model interface (abstract top-level container)
Definition: OMEModel.h:62
const std::string & elementName() const
Get the element name of this model object.
Definition: Screen.cpp:218
const std::string & getID() const
Get the ID property.
Definition: Screen.cpp:518
std::vector< ome::compat::shared_ptr< ome::xml::model::Reagent > > & getReagentList()
Get the Reagent list.
Definition: Screen.cpp:580
const ome::compat::weak_ptr< ome::xml::model::Plate > & getLinkedPlate(OMEModelObject::indexed_container< ome::xml::model::Plate, ome::compat::weak_ptr >::type::size_type index) const
Get linked Plate.
Definition: Screen.cpp:644
ome::compat::shared_ptr< std::string > getType()
Get the Type property.
Definition: Screen.cpp:497
ome::compat::shared_ptr< ome::xml::model::Reagent > & getReagent(std::vector< ome::compat::shared_ptr< ome::xml::model::Reagent > >::size_type index)
Get Reagent.
Definition: Screen.cpp:592
const ome::compat::weak_ptr< ome::xml::model::Plate > & setLinkedPlate(OMEModelObject::indexed_container< ome::xml::model::Plate, ome::compat::weak_ptr >::type::size_type index, const ome::compat::shared_ptr< ome::xml::model::Plate > &plate)
Set linked Plate.
Definition: Screen.cpp:650
ome::compat::shared_ptr< std::string > getReagentSetDescription()
Get the ReagentSetDescription property.
Definition: Screen.cpp:476
OME model object (concrete implementation).
Definition: OMEModelObject.h:64
Screen()
Default constructor.
Definition: Screen.cpp:185
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 > >, ome::compat::owner_less< Ptr< T > > > > > type
Multi-index container type.
Definition: OMEModelObject.h:94
void setDescription(ome::compat::shared_ptr< std::string > &description)
Set the Description property.
Definition: Screen.cpp:567
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: Screen.cpp:233
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: Screen.cpp:758
bool linkAnnotation(const ome::compat::shared_ptr< ome::xml::model::Annotation > &annotation)
Link Annotation.
Definition: Screen.cpp:720
OMEModelObject::indexed_container< ome::xml::model::Plate, ome::compat::weak_ptr >::type getLinkedPlateList() const
Get the linked Plate list.
Definition: Screen.cpp:638
void setName(ome::compat::shared_ptr< std::string > &name)
Set the Name property.
Definition: Screen.cpp:427
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: Screen.cpp:366
void addReagent(ome::compat::shared_ptr< ome::xml::model::Reagent > &reagent)
Add Reagent.
Definition: Screen.cpp:613
Screen model object.
Definition: Screen.h:82
const std::string & getXMLNamespace() const
Get the XML namespace for this model object.
Definition: Screen.cpp:929
Multi-index container for efficient ordered insertion and deletion of model object references...
Definition: OMEModelObject.h:85
static ome::compat::shared_ptr< Screen > create(const common::xml::dom::Element &element, ome::xml::model::OMEModel &model)
Create a Screen model object from DOM element.
Definition: Screen.cpp:209
Open Microscopy Environment C++ implementation.
ome::compat::shared_ptr< std::string > getName()
Get the Name property.
Definition: Screen.cpp:413
bool unlinkAnnotation(const ome::compat::shared_ptr< ome::xml::model::Annotation > &annotation)
Unlink Annotation.
Definition: Screen.cpp:734
OMEModelObject::indexed_container< ome::xml::model::Annotation, ome::compat::weak_ptr >::type getLinkedAnnotationList() const
Get the linked Annotation list.
Definition: Screen.cpp:698
const ome::compat::weak_ptr< ome::xml::model::Annotation > & setLinkedAnnotation(OMEModelObject::indexed_container< ome::xml::model::Annotation, ome::compat::weak_ptr >::type::size_type index, const ome::compat::shared_ptr< ome::xml::model::Annotation > &annotation)
Set linked Annotation.
Definition: Screen.cpp:710
Screen & operator=(const Screen &)
Assignment operator (deleted).
std::vector< ome::compat::shared_ptr< ome::xml::model::Reagent > >::size_type sizeOfReagentList() const
Get size of linked Reagent list.
Definition: Screen.cpp:574
ome::compat::shared_ptr< std::string > getProtocolDescription()
Get the ProtocolDescription property.
Definition: Screen.cpp:434
void setReagent(std::vector< ome::compat::shared_ptr< ome::xml::model::Reagent > >::size_type index, ome::compat::shared_ptr< ome::xml::model::Reagent > &reagent)
Set Reagent.
Definition: Screen.cpp:604
virtual ~Screen()
Destructor.
Definition: Screen.cpp:204
void setReagentSetIdentifier(ome::compat::shared_ptr< std::string > &reagentSetIdentifier)
Set the ReagentSetIdentifier property.
Definition: Screen.cpp:546
void removeReagent(ome::compat::shared_ptr< ome::xml::model::Reagent > &reagent)
Remove Reagent.
Definition: Screen.cpp:621
void setProtocolDescription(ome::compat::shared_ptr< std::string > &protocolDescription)
Set the ProtocolDescription property.
Definition: Screen.cpp:448
bool linkPlate(const ome::compat::shared_ptr< ome::xml::model::Plate > &plate)
Link Plate.
Definition: Screen.cpp:660
ome::compat::shared_ptr< std::string > getReagentSetIdentifier()
Get the ReagentSetIdentifier property.
Definition: Screen.cpp:532
ome::compat::shared_ptr< std::string > getDescription()
Get the Description property.
Definition: Screen.cpp:553
void setProtocolIdentifier(ome::compat::shared_ptr< std::string > &protocolIdentifier)
Set the ProtocolIdentifier property.
Definition: Screen.cpp:469
Private implementation details of Screen model object.
Definition: Screen.cpp:76
void setType(ome::compat::shared_ptr< std::string > &type)
Set the Type property.
Definition: Screen.cpp:511
ome::compat::shared_ptr< std::string > getProtocolIdentifier()
Get the ProtocolIdentifier property.
Definition: Screen.cpp:455
bool unlinkPlate(const ome::compat::shared_ptr< ome::xml::model::Plate > &plate)
Unlink Plate.
Definition: Screen.cpp:674
virtual common::xml::dom::Element asXMLElement(common::xml::dom::Document &document) const
Transform the object hierarchy rooted at this element to XML.
Definition: Screen.cpp:751
OMEModelObject::indexed_container< ome::xml::model::Annotation, ome::compat::weak_ptr >::type::size_type sizeOfLinkedAnnotationList() const
Get size of linked Annotation list.
Definition: Screen.cpp:692
const ome::compat::weak_ptr< ome::xml::model::Annotation > & getLinkedAnnotation(OMEModelObject::indexed_container< ome::xml::model::Annotation, ome::compat::weak_ptr >::type::size_type index) const
Get linked Annotation.
Definition: Screen.cpp:704
ome::compat::shared_ptr< Impl > impl
Private implementation details.
Definition: Screen.h:85
void setReagentSetDescription(ome::compat::shared_ptr< std::string > &reagentSetDescription)
Set the ReagentSetDescription property.
Definition: Screen.cpp:490
bool validElementName(const std::string &name) const
Check if a given element name is valid for processing by this model object.
Definition: Screen.cpp:225
OMEModelObject::indexed_container< ome::xml::model::Plate, ome::compat::weak_ptr >::type::size_type sizeOfLinkedPlateList() const
Get size of linked Plate list.
Definition: Screen.cpp:632
void setID(const std::string &id)
Set the ID property.
Definition: Screen.cpp:525