ome-xml  5.2.2
ExperimenterGroup.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_EXPERIMENTERGROUP_H
47 #define OME_XML_MODEL_EXPERIMENTERGROUP_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 Dataset;
76  class Experimenter;
77  class Image;
78  class OMEModel;
79  class Project;
80 
85  {
86  private:
87  class Impl;
89  ome::compat::shared_ptr<Impl> impl;
90 
91  public:
94 
100  ExperimenterGroup (const ExperimenterGroup& copy);
101 
103  virtual
105 
120  static ome::compat::shared_ptr< ExperimenterGroup>
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:
136 
137  public:
138  // -- OMEModelObject API methods --
139 
141  virtual void
142  update(const common::xml::dom::Element& element,
144 
145  public:
146  // -- ExperimenterGroup API methods --
147 
149  bool
150  link (ome::compat::shared_ptr<Reference>& reference,
151  ome::compat::shared_ptr< ome::xml::model::OMEModelObject>& object);
152 
158  ome::compat::shared_ptr<std::string>
159  getName ();
160 
166  const ome::compat::shared_ptr<std::string>
167  getName () const;
168 
174  void
175  setName (ome::compat::shared_ptr<std::string>& name);
176 
182  const std::string&
183  getID () const;
184 
190  void
191  setID (const std::string& id);
192 
198  ome::compat::shared_ptr<std::string>
199  getDescription ();
200 
206  const ome::compat::shared_ptr<std::string>
207  getDescription () const;
208 
214  void
215  setDescription (ome::compat::shared_ptr<std::string>& description);
216 
224 
231  getLinkedExperimenterList () const;
232 
240  const ome::compat::weak_ptr<ome::xml::model::Experimenter>&
242 
253  const ome::compat::weak_ptr<ome::xml::model::Experimenter>&
255  const ome::compat::shared_ptr<ome::xml::model::Experimenter>& experimenter);
256 
267  bool
268  linkExperimenter (const ome::compat::shared_ptr<ome::xml::model::Experimenter>& experimenter);
269 
285  bool
286  unlinkExperimenter (const ome::compat::shared_ptr<ome::xml::model::Experimenter>& experimenter);
287 
294  sizeOfLinkedLeaderList () const;
295 
302  getLinkedLeaderList () const;
303 
311  const ome::compat::weak_ptr<ome::xml::model::Experimenter>&
313 
324  const ome::compat::weak_ptr<ome::xml::model::Experimenter>&
326  const ome::compat::shared_ptr<ome::xml::model::Experimenter>& leader);
327 
338  bool
339  linkLeader (const ome::compat::shared_ptr<ome::xml::model::Experimenter>& leader);
340 
356  bool
357  unlinkLeader (const ome::compat::shared_ptr<ome::xml::model::Experimenter>& leader);
358 
366 
373  getLinkedAnnotationList () const;
374 
382  const ome::compat::weak_ptr<ome::xml::model::Annotation>&
384 
395  const ome::compat::weak_ptr<ome::xml::model::Annotation>&
397  const ome::compat::shared_ptr<ome::xml::model::Annotation>& annotation);
398 
409  bool
410  linkAnnotation (const ome::compat::shared_ptr<ome::xml::model::Annotation>& annotation);
411 
427  bool
428  unlinkAnnotation (const ome::compat::shared_ptr<ome::xml::model::Annotation>& annotation);
429 
436  sizeOfLinkedImageList () const;
437 
444  getLinkedImageList () const;
445 
453  const ome::compat::weak_ptr<ome::xml::model::Image>&
455 
466  const ome::compat::weak_ptr<ome::xml::model::Image>&
468  const ome::compat::shared_ptr<ome::xml::model::Image>& image_BackReference);
469 
480  bool
481  linkImage (const ome::compat::shared_ptr<ome::xml::model::Image>& image_BackReference);
482 
498  bool
499  unlinkImage (const ome::compat::shared_ptr<ome::xml::model::Image>& image_BackReference);
500 
507  sizeOfLinkedProjectList () const;
508 
515  getLinkedProjectList () const;
516 
524  const ome::compat::weak_ptr<ome::xml::model::Project>&
526 
537  const ome::compat::weak_ptr<ome::xml::model::Project>&
539  const ome::compat::shared_ptr<ome::xml::model::Project>& project_BackReference);
540 
551  bool
552  linkProject (const ome::compat::shared_ptr<ome::xml::model::Project>& project_BackReference);
553 
569  bool
570  unlinkProject (const ome::compat::shared_ptr<ome::xml::model::Project>& project_BackReference);
571 
578  sizeOfLinkedDatasetList () const;
579 
586  getLinkedDatasetList () const;
587 
595  const ome::compat::weak_ptr<ome::xml::model::Dataset>&
597 
608  const ome::compat::weak_ptr<ome::xml::model::Dataset>&
610  const ome::compat::shared_ptr<ome::xml::model::Dataset>& dataset_BackReference);
611 
622  bool
623  linkDataset (const ome::compat::shared_ptr<ome::xml::model::Dataset>& dataset_BackReference);
624 
640  bool
641  unlinkDataset (const ome::compat::shared_ptr<ome::xml::model::Dataset>& dataset_BackReference);
642 
645  asXMLElement (common::xml::dom::Document& document) const;
646 
647 
648  protected:
649  // Documented in base class.
652  common::xml::dom::Element& element) const;
653 
654  public:
655  // Documented in superclass.
656  const std::string&
657  getXMLNamespace() const;
658  };
659 
660  }
661  }
662 }
663 
664 #endif // OME_XML_MODEL_EXPERIMENTERGROUP_H
665 
666 /*
667  * Local Variables:
668  * mode:C++
669  * End:
670  */
OME model interface (abstract top-level container)
Definition: OMEModel.h:62
virtual ~ExperimenterGroup()
Destructor.
Definition: ExperimenterGroup.cpp:192
ExperimenterGroup model object.
Definition: ExperimenterGroup.h:84
bool validElementName(const std::string &name) const
Check if a given element name is valid for processing by this model object.
Definition: ExperimenterGroup.cpp:213
OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type getLinkedExperimenterList() const
Get the linked Experimenter list.
Definition: ExperimenterGroup.cpp:434
const std::string & getXMLNamespace() const
Get the XML namespace for this model object.
Definition: ExperimenterGroup.cpp:911
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: ExperimenterGroup.cpp:309
OMEModelObject::indexed_container< ome::xml::model::Dataset, ome::compat::weak_ptr >::type getLinkedDatasetList() const
Get the linked Dataset list.
Definition: ExperimenterGroup.cpp:730
bool unlinkProject(const ome::compat::shared_ptr< ome::xml::model::Project > &project_BackReference)
Unlink Project.
Definition: ExperimenterGroup.cpp:707
const ome::compat::weak_ptr< ome::xml::model::Experimenter > & setLinkedExperimenter(OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type::size_type index, const ome::compat::shared_ptr< ome::xml::model::Experimenter > &experimenter)
Set linked Experimenter.
Definition: ExperimenterGroup.cpp:446
bool unlinkExperimenter(const ome::compat::shared_ptr< ome::xml::model::Experimenter > &experimenter)
Unlink Experimenter.
Definition: ExperimenterGroup.cpp:470
const ome::compat::weak_ptr< ome::xml::model::Dataset > & getLinkedDataset(OMEModelObject::indexed_container< ome::xml::model::Dataset, ome::compat::weak_ptr >::type::size_type index) const
Get linked Dataset.
Definition: ExperimenterGroup.cpp:736
const ome::compat::weak_ptr< ome::xml::model::Image > & setLinkedImage(OMEModelObject::indexed_container< ome::xml::model::Image, ome::compat::weak_ptr >::type::size_type index, const ome::compat::shared_ptr< ome::xml::model::Image > &image_BackReference)
Set linked Image.
Definition: ExperimenterGroup.cpp:626
void setID(const std::string &id)
Set the ID property.
Definition: ExperimenterGroup.cpp:400
static ome::compat::shared_ptr< ExperimenterGroup > create(const common::xml::dom::Element &element, ome::xml::model::OMEModel &model)
Create a ExperimenterGroup model object from DOM element.
Definition: ExperimenterGroup.cpp:197
const std::string & getID() const
Get the ID property.
Definition: ExperimenterGroup.cpp:393
ExperimenterGroup & operator=(const ExperimenterGroup &)
Assignment operator (deleted).
const ome::compat::weak_ptr< ome::xml::model::Experimenter > & getLinkedLeader(OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type::size_type index) const
Get linked Leader.
Definition: ExperimenterGroup.cpp:500
bool linkLeader(const ome::compat::shared_ptr< ome::xml::model::Experimenter > &leader)
Link Leader.
Definition: ExperimenterGroup.cpp:516
const std::string & elementName() const
Get the element name of this model object.
Definition: ExperimenterGroup.cpp:206
bool linkProject(const ome::compat::shared_ptr< ome::xml::model::Project > &project_BackReference)
Link Project.
Definition: ExperimenterGroup.cpp:694
OMEModelObject::indexed_container< ome::xml::model::Annotation, ome::compat::weak_ptr >::type getLinkedAnnotationList() const
Get the linked Annotation list.
Definition: ExperimenterGroup.cpp:554
const ome::compat::weak_ptr< ome::xml::model::Experimenter > & getLinkedExperimenter(OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type::size_type index) const
Get linked Experimenter.
Definition: ExperimenterGroup.cpp:440
OME model object (concrete implementation).
Definition: OMEModelObject.h:64
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
bool linkImage(const ome::compat::shared_ptr< ome::xml::model::Image > &image_BackReference)
Link Image.
Definition: ExperimenterGroup.cpp:636
OMEModelObject::indexed_container< ome::xml::model::Dataset, ome::compat::weak_ptr >::type::size_type sizeOfLinkedDatasetList() const
Get size of linked Dataset list.
Definition: ExperimenterGroup.cpp:724
const ome::compat::weak_ptr< ome::xml::model::Dataset > & setLinkedDataset(OMEModelObject::indexed_container< ome::xml::model::Dataset, ome::compat::weak_ptr >::type::size_type index, const ome::compat::shared_ptr< ome::xml::model::Dataset > &dataset_BackReference)
Set linked Dataset.
Definition: ExperimenterGroup.cpp:742
ExperimenterGroup()
Default constructor.
Definition: ExperimenterGroup.cpp:173
bool linkAnnotation(const ome::compat::shared_ptr< ome::xml::model::Annotation > &annotation)
Link Annotation.
Definition: ExperimenterGroup.cpp:576
Private implementation details of ExperimenterGroup model object.
Definition: ExperimenterGroup.cpp:78
OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type::size_type sizeOfLinkedExperimenterList() const
Get size of linked Experimenter list.
Definition: ExperimenterGroup.cpp:428
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: ExperimenterGroup.cpp:221
void setName(ome::compat::shared_ptr< std::string > &name)
Set the Name property.
Definition: ExperimenterGroup.cpp:386
bool unlinkDataset(const ome::compat::shared_ptr< ome::xml::model::Dataset > &dataset_BackReference)
Unlink Dataset.
Definition: ExperimenterGroup.cpp:765
Multi-index container for efficient ordered insertion and deletion of model object references...
Definition: OMEModelObject.h:85
bool unlinkLeader(const ome::compat::shared_ptr< ome::xml::model::Experimenter > &leader)
Unlink Leader.
Definition: ExperimenterGroup.cpp:530
void setDescription(ome::compat::shared_ptr< std::string > &description)
Set the Description property.
Definition: ExperimenterGroup.cpp:421
ome::compat::shared_ptr< std::string > getDescription()
Get the Description property.
Definition: ExperimenterGroup.cpp:407
Open Microscopy Environment C++ implementation.
const ome::compat::weak_ptr< ome::xml::model::Project > & setLinkedProject(OMEModelObject::indexed_container< ome::xml::model::Project, ome::compat::weak_ptr >::type::size_type index, const ome::compat::shared_ptr< ome::xml::model::Project > &project_BackReference)
Set linked Project.
Definition: ExperimenterGroup.cpp:684
OMEModelObject::indexed_container< ome::xml::model::Project, ome::compat::weak_ptr >::type getLinkedProjectList() const
Get the linked Project list.
Definition: ExperimenterGroup.cpp:672
const ome::compat::weak_ptr< ome::xml::model::Experimenter > & setLinkedLeader(OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type::size_type index, const ome::compat::shared_ptr< ome::xml::model::Experimenter > &leader)
Set linked Leader.
Definition: ExperimenterGroup.cpp:506
ome::compat::shared_ptr< Impl > impl
Private implementation details.
Definition: ExperimenterGroup.h:87
bool linkExperimenter(const ome::compat::shared_ptr< ome::xml::model::Experimenter > &experimenter)
Link Experimenter.
Definition: ExperimenterGroup.cpp:456
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: ExperimenterGroup.cpp:788
const ome::compat::weak_ptr< ome::xml::model::Project > & getLinkedProject(OMEModelObject::indexed_container< ome::xml::model::Project, ome::compat::weak_ptr >::type::size_type index) const
Get linked Project.
Definition: ExperimenterGroup.cpp:678
OMEModelObject::indexed_container< ome::xml::model::Image, ome::compat::weak_ptr >::type::size_type sizeOfLinkedImageList() const
Get size of linked Image list.
Definition: ExperimenterGroup.cpp:608
OMEModelObject::indexed_container< ome::xml::model::Annotation, ome::compat::weak_ptr >::type::size_type sizeOfLinkedAnnotationList() const
Get size of linked Annotation list.
Definition: ExperimenterGroup.cpp:548
virtual common::xml::dom::Element asXMLElement(common::xml::dom::Document &document) const
Transform the object hierarchy rooted at this element to XML.
Definition: ExperimenterGroup.cpp:781
bool unlinkImage(const ome::compat::shared_ptr< ome::xml::model::Image > &image_BackReference)
Unlink Image.
Definition: ExperimenterGroup.cpp:649
OMEModelObject::indexed_container< ome::xml::model::Project, ome::compat::weak_ptr >::type::size_type sizeOfLinkedProjectList() const
Get size of linked Project list.
Definition: ExperimenterGroup.cpp:666
OMEModelObject::indexed_container< ome::xml::model::Image, ome::compat::weak_ptr >::type getLinkedImageList() const
Get the linked Image list.
Definition: ExperimenterGroup.cpp:614
OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type::size_type sizeOfLinkedLeaderList() const
Get size of linked Leader list.
Definition: ExperimenterGroup.cpp:488
OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type getLinkedLeaderList() const
Get the linked Leader list.
Definition: ExperimenterGroup.cpp:494
const ome::compat::weak_ptr< ome::xml::model::Image > & getLinkedImage(OMEModelObject::indexed_container< ome::xml::model::Image, ome::compat::weak_ptr >::type::size_type index) const
Get linked Image.
Definition: ExperimenterGroup.cpp:620
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: ExperimenterGroup.cpp:566
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: ExperimenterGroup.cpp:560
bool unlinkAnnotation(const ome::compat::shared_ptr< ome::xml::model::Annotation > &annotation)
Unlink Annotation.
Definition: ExperimenterGroup.cpp:590
bool linkDataset(const ome::compat::shared_ptr< ome::xml::model::Dataset > &dataset_BackReference)
Link Dataset.
Definition: ExperimenterGroup.cpp:752
ome::compat::shared_ptr< std::string > getName()
Get the Name property.
Definition: ExperimenterGroup.cpp:372