bioformats  5.1.3
ExperimenterGroup.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_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/detail/OMEModelObject.h>
63 
64 namespace ome
65 {
66  namespace xml
67  {
68  namespace model
69  {
70 
71  // Forward declarations.
72  class Annotation;
73  class Dataset;
74  class Experimenter;
75  class Image;
76  class OMEModel;
77  class Project;
78 
83  {
84  private:
86  ome::compat::shared_ptr<std::string> name;
88  std::string id;
90  ome::compat::shared_ptr<std::string> description;
103 
104  public:
107 
113  ExperimenterGroup (const ExperimenterGroup& copy);
114 
116  virtual
118 
119 
120 
135  static ome::compat::shared_ptr< ExperimenterGroup>
136  create(const common::xml::dom::Element& element,
138 
139  // Documented in superclass.
140  const std::string&
141  elementName() const;
142 
143  // Documented in superclass.
144  bool
145  validElementName(const std::string& name) const;
146 
147 
148  // -- OMEModelObject API methods --
149 
151  virtual void
152  update(const common::xml::dom::Element& element,
154 
155  public:
156  // -- ExperimenterGroup API methods --
157 
159  bool
160  link (ome::compat::shared_ptr<Reference>& reference,
161  ome::compat::shared_ptr< ome::xml::model::OMEModelObject>& object);
162 
168  ome::compat::shared_ptr<std::string>
169  getName ();
170 
176  const ome::compat::shared_ptr<std::string>
177  getName () const;
178 
184  void
185  setName (ome::compat::shared_ptr<std::string>& name);
186 
192  const std::string&
193  getID () const;
194 
200  void
201  setID (const std::string& id);
202 
208  ome::compat::shared_ptr<std::string>
209  getDescription ();
210 
216  const ome::compat::shared_ptr<std::string>
217  getDescription () const;
218 
224  void
225  setDescription (ome::compat::shared_ptr<std::string>& description);
226 
234 
241  getLinkedExperimenterList () const;
242 
250  const ome::compat::weak_ptr<ome::xml::model::Experimenter>&
252 
263  const ome::compat::weak_ptr<ome::xml::model::Experimenter>&
265  const ome::compat::shared_ptr<ome::xml::model::Experimenter>& experimenter);
266 
277  bool
278  linkExperimenter (const ome::compat::shared_ptr<ome::xml::model::Experimenter>& experimenter);
279 
295  bool
296  unlinkExperimenter (const ome::compat::shared_ptr<ome::xml::model::Experimenter>& experimenter);
297 
304  sizeOfLinkedLeaderList () const;
305 
312  getLinkedLeaderList () const;
313 
321  const ome::compat::weak_ptr<ome::xml::model::Experimenter>&
323 
334  const ome::compat::weak_ptr<ome::xml::model::Experimenter>&
336  const ome::compat::shared_ptr<ome::xml::model::Experimenter>& leader);
337 
348  bool
349  linkLeader (const ome::compat::shared_ptr<ome::xml::model::Experimenter>& leader);
350 
366  bool
367  unlinkLeader (const ome::compat::shared_ptr<ome::xml::model::Experimenter>& leader);
368 
376 
383  getLinkedAnnotationList () const;
384 
392  const ome::compat::weak_ptr<ome::xml::model::Annotation>&
394 
405  const ome::compat::weak_ptr<ome::xml::model::Annotation>&
407  const ome::compat::shared_ptr<ome::xml::model::Annotation>& annotation);
408 
419  bool
420  linkAnnotation (const ome::compat::shared_ptr<ome::xml::model::Annotation>& annotation);
421 
437  bool
438  unlinkAnnotation (const ome::compat::shared_ptr<ome::xml::model::Annotation>& annotation);
439 
446  sizeOfLinkedImageList () const;
447 
454  getLinkedImageList () const;
455 
463  const ome::compat::weak_ptr<ome::xml::model::Image>&
465 
476  const ome::compat::weak_ptr<ome::xml::model::Image>&
478  const ome::compat::shared_ptr<ome::xml::model::Image>& image_BackReference);
479 
490  bool
491  linkImage (const ome::compat::shared_ptr<ome::xml::model::Image>& image_BackReference);
492 
508  bool
509  unlinkImage (const ome::compat::shared_ptr<ome::xml::model::Image>& image_BackReference);
510 
517  sizeOfLinkedProjectList () const;
518 
525  getLinkedProjectList () const;
526 
534  const ome::compat::weak_ptr<ome::xml::model::Project>&
536 
547  const ome::compat::weak_ptr<ome::xml::model::Project>&
549  const ome::compat::shared_ptr<ome::xml::model::Project>& project_BackReference);
550 
561  bool
562  linkProject (const ome::compat::shared_ptr<ome::xml::model::Project>& project_BackReference);
563 
579  bool
580  unlinkProject (const ome::compat::shared_ptr<ome::xml::model::Project>& project_BackReference);
581 
588  sizeOfLinkedDatasetList () const;
589 
596  getLinkedDatasetList () const;
597 
605  const ome::compat::weak_ptr<ome::xml::model::Dataset>&
607 
618  const ome::compat::weak_ptr<ome::xml::model::Dataset>&
620  const ome::compat::shared_ptr<ome::xml::model::Dataset>& dataset_BackReference);
621 
632  bool
633  linkDataset (const ome::compat::shared_ptr<ome::xml::model::Dataset>& dataset_BackReference);
634 
650  bool
651  unlinkDataset (const ome::compat::shared_ptr<ome::xml::model::Dataset>& dataset_BackReference);
652 
653 
656  asXMLElement (common::xml::dom::Document& document) const;
657 
658 
659  protected:
660  // Documented in base class.
663  common::xml::dom::Element& element) const;
664 
665  public:
666  // Documented in superclass.
667  const std::string&
668  getXMLNamespace() const;
669  };
670 
671  }
672  }
673 }
674 
675 #endif // OME_XML_MODEL_EXPERIMENTERGROUP_H
676 
677 /*
678  * Local Variables:
679  * mode:C++
680  * End:
681  */
OME model interface (abstract top-level container)
Definition: OMEModel.h:62
virtual ~ExperimenterGroup()
Destructor.
Definition: ExperimenterGroup.cpp:162
ExperimenterGroup model object.
Definition: ExperimenterGroup.h:82
bool validElementName(const std::string &name) const
Check if a given element name is valid for processing by this model object.
Definition: ExperimenterGroup.cpp:183
OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type getLinkedExperimenterList() const
Get the linked Experimenter list.
Definition: ExperimenterGroup.cpp:404
const std::string & getXMLNamespace() const
Get the XML namespace for this model object.
Definition: ExperimenterGroup.cpp:882
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:279
OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type leaders
Leader reference (occurs more than once)
Definition: ExperimenterGroup.h:94
OMEModelObject::indexed_container< ome::xml::model::Dataset, ome::compat::weak_ptr >::type getLinkedDatasetList() const
Get the linked Dataset list.
Definition: ExperimenterGroup.cpp:700
bool unlinkProject(const ome::compat::shared_ptr< ome::xml::model::Project > &project_BackReference)
Unlink Project.
Definition: ExperimenterGroup.cpp:677
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:416
bool unlinkExperimenter(const ome::compat::shared_ptr< ome::xml::model::Experimenter > &experimenter)
Unlink Experimenter.
Definition: ExperimenterGroup.cpp:440
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:706
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:596
void setID(const std::string &id)
Set the ID property.
Definition: ExperimenterGroup.cpp:370
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:167
OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type experimenterLinks
ExperimenterRef reference (occurs more than once)
Definition: ExperimenterGroup.h:92
std::string id
ID property.
Definition: ExperimenterGroup.h:88
const std::string & getID() const
Get the ID property.
Definition: ExperimenterGroup.cpp:363
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:470
bool linkLeader(const ome::compat::shared_ptr< ome::xml::model::Experimenter > &leader)
Link Leader.
Definition: ExperimenterGroup.cpp:486
const std::string & elementName() const
Get the element name of this model object.
Definition: ExperimenterGroup.cpp:176
bool linkProject(const ome::compat::shared_ptr< ome::xml::model::Project > &project_BackReference)
Link Project.
Definition: ExperimenterGroup.cpp:664
OMEModelObject::indexed_container< ome::xml::model::Annotation, ome::compat::weak_ptr >::type getLinkedAnnotationList() const
Get the linked Annotation list.
Definition: ExperimenterGroup.cpp:524
DOM Document wrapper.
Definition: Document.h:82
DOM Element wrapper.
Definition: Element.h:66
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:410
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
ome::compat::shared_ptr< std::string > name
Name property.
Definition: ExperimenterGroup.h:86
bool linkImage(const ome::compat::shared_ptr< ome::xml::model::Image > &image_BackReference)
Link Image.
Definition: ExperimenterGroup.cpp:606
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:694
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:712
ome::compat::shared_ptr< std::string > description
Description property.
Definition: ExperimenterGroup.h:90
ExperimenterGroup()
Default constructor.
Definition: ExperimenterGroup.cpp:127
bool linkAnnotation(const ome::compat::shared_ptr< ome::xml::model::Annotation > &annotation)
Link Annotation.
Definition: ExperimenterGroup.cpp:546
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:398
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:192
void setName(ome::compat::shared_ptr< std::string > &name)
Set the Name property.
Definition: ExperimenterGroup.cpp:356
OMEModelObject::indexed_container< ome::xml::model::Dataset, ome::compat::weak_ptr >::type datasets
Dataset_BackReference back reference (occurs more than once)
Definition: ExperimenterGroup.h:102
bool unlinkDataset(const ome::compat::shared_ptr< ome::xml::model::Dataset > &dataset_BackReference)
Unlink Dataset.
Definition: ExperimenterGroup.cpp:735
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:500
void setDescription(ome::compat::shared_ptr< std::string > &description)
Set the Description property.
Definition: ExperimenterGroup.cpp:391
ome::compat::shared_ptr< std::string > getDescription()
Get the Description property.
Definition: ExperimenterGroup.cpp:377
Open Microscopy Environment C++ implementation.
Definition: CoreMetadata.cpp:40
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:654
OMEModelObject::indexed_container< ome::xml::model::Project, ome::compat::weak_ptr >::type getLinkedProjectList() const
Get the linked Project list.
Definition: ExperimenterGroup.cpp:642
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:476
bool linkExperimenter(const ome::compat::shared_ptr< ome::xml::model::Experimenter > &experimenter)
Link Experimenter.
Definition: ExperimenterGroup.cpp:426
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:759
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:648
OMEModelObject::indexed_container< ome::xml::model::Image, ome::compat::weak_ptr >::type images
Image_BackReference back reference (occurs more than once)
Definition: ExperimenterGroup.h:98
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:578
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:518
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:752
bool unlinkImage(const ome::compat::shared_ptr< ome::xml::model::Image > &image_BackReference)
Unlink Image.
Definition: ExperimenterGroup.cpp:619
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:636
OMEModelObject::indexed_container< ome::xml::model::Image, ome::compat::weak_ptr >::type getLinkedImageList() const
Get the linked Image list.
Definition: ExperimenterGroup.cpp:584
OMEModelObject::indexed_container< ome::xml::model::Project, ome::compat::weak_ptr >::type projects
Project_BackReference back reference (occurs more than once)
Definition: ExperimenterGroup.h:100
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:458
OMEModelObject::indexed_container< ome::xml::model::Experimenter, ome::compat::weak_ptr >::type getLinkedLeaderList() const
Get the linked Leader list.
Definition: ExperimenterGroup.cpp:464
Boost.Log compatibility.
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:590
OMEModelObject::indexed_container< ome::xml::model::Annotation, ome::compat::weak_ptr >::type annotationLinks
AnnotationRef reference (occurs more than once)
Definition: ExperimenterGroup.h:96
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:536
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:530
Xerces-C modern C++ wrapper.
Definition: Base.h:53
bool unlinkAnnotation(const ome::compat::shared_ptr< ome::xml::model::Annotation > &annotation)
Unlink Annotation.
Definition: ExperimenterGroup.cpp:560
bool linkDataset(const ome::compat::shared_ptr< ome::xml::model::Dataset > &dataset_BackReference)
Link Dataset.
Definition: ExperimenterGroup.cpp:722
ome::compat::shared_ptr< std::string > getName()
Get the Name property.
Definition: ExperimenterGroup.cpp:342