ome-xml  5.6.0
Experimenter.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_EXPERIMENTER_H
47 #define OME_XML_MODEL_EXPERIMENTER_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/detail/OMEModelObject.h>
64 
65 namespace ome
66 {
67  namespace xml
68  {
69  namespace model
70  {
71 
72  // Forward declarations.
73  class Annotation;
74  class Dataset;
75  class Experiment;
76  class ExperimenterGroup;
77  class Image;
78  class MicrobeamManipulation;
79  class OMEModel;
80  class Project;
81 
86  {
87  private:
88  class Impl;
90  std::shared_ptr<Impl> impl;
91 
92  public:
94  Experimenter();
95 
101  Experimenter (const Experimenter& copy);
102 
104  virtual
105  ~Experimenter ();
106 
121  static std::shared_ptr<Experimenter>
122  create(const common::xml::dom::Element& element,
124 
125  // Documented in superclass.
126  const std::string&
127  elementName() const;
128 
129  // Documented in superclass.
130  bool
131  validElementName(const std::string& name) const;
132 
134  Experimenter&
135  operator= (const Experimenter&) = delete;
137 
138  // -- OMEModelObject API methods --
139 
141  virtual void
142  update(const common::xml::dom::Element& element,
144 
145  public:
146  // -- Experimenter 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  getEmail ();
160 
166  const std::shared_ptr<std::string>
167  getEmail () const;
168 
174  void
175  setEmail (std::shared_ptr<std::string>& email);
176 
182  std::shared_ptr<std::string>
183  getUserName ();
184 
190  const std::shared_ptr<std::string>
191  getUserName () const;
192 
198  void
199  setUserName (std::shared_ptr<std::string>& userName);
200 
206  std::shared_ptr<std::string>
207  getFirstName ();
208 
214  const std::shared_ptr<std::string>
215  getFirstName () const;
216 
222  void
223  setFirstName (std::shared_ptr<std::string>& firstName);
224 
230  std::shared_ptr<std::string>
231  getMiddleName ();
232 
238  const std::shared_ptr<std::string>
239  getMiddleName () const;
240 
246  void
247  setMiddleName (std::shared_ptr<std::string>& middleName);
248 
254  std::shared_ptr<std::string>
255  getLastName ();
256 
262  const std::shared_ptr<std::string>
263  getLastName () const;
264 
270  void
271  setLastName (std::shared_ptr<std::string>& lastName);
272 
278  const std::string&
279  getID () const;
280 
286  void
287  setID (const std::string& id);
288 
294  std::shared_ptr<std::string>
295  getInstitution ();
296 
302  const std::shared_ptr<std::string>
303  getInstitution () const;
304 
310  void
311  setInstitution (std::shared_ptr<std::string>& institution);
312 
320 
327  getLinkedAnnotationList () const;
328 
336  const std::weak_ptr<ome::xml::model::Annotation>&
338 
349  const std::weak_ptr<ome::xml::model::Annotation>&
351  const std::shared_ptr<ome::xml::model::Annotation>& annotation);
352 
363  bool
364  linkAnnotation (const std::shared_ptr<ome::xml::model::Annotation>& annotation);
365 
381  bool
382  unlinkAnnotation (const std::shared_ptr<ome::xml::model::Annotation>& annotation);
383 
390  sizeOfLinkedImageList () const;
391 
398  getLinkedImageList () const;
399 
407  const std::weak_ptr<ome::xml::model::Image>&
409 
420  const std::weak_ptr<ome::xml::model::Image>&
422  const std::shared_ptr<ome::xml::model::Image>& image_BackReference);
423 
434  bool
435  linkImage (const std::shared_ptr<ome::xml::model::Image>& image_BackReference);
436 
452  bool
453  unlinkImage (const std::shared_ptr<ome::xml::model::Image>& image_BackReference);
454 
462 
470 
478  const std::weak_ptr<ome::xml::model::MicrobeamManipulation>&
480 
491  const std::weak_ptr<ome::xml::model::MicrobeamManipulation>&
493  const std::shared_ptr<ome::xml::model::MicrobeamManipulation>& microbeamManipulation_BackReference);
494 
505  bool
506  linkMicrobeamManipulation (const std::shared_ptr<ome::xml::model::MicrobeamManipulation>& microbeamManipulation_BackReference);
507 
523  bool
524  unlinkMicrobeamManipulation (const std::shared_ptr<ome::xml::model::MicrobeamManipulation>& microbeamManipulation_BackReference);
525 
532  sizeOfLinkedProjectList () const;
533 
540  getLinkedProjectList () const;
541 
549  const std::weak_ptr<ome::xml::model::Project>&
551 
562  const std::weak_ptr<ome::xml::model::Project>&
564  const std::shared_ptr<ome::xml::model::Project>& project_BackReference);
565 
576  bool
577  linkProject (const std::shared_ptr<ome::xml::model::Project>& project_BackReference);
578 
594  bool
595  unlinkProject (const std::shared_ptr<ome::xml::model::Project>& project_BackReference);
596 
604 
612 
620  const std::weak_ptr<ome::xml::model::ExperimenterGroup>&
622 
633  const std::weak_ptr<ome::xml::model::ExperimenterGroup>&
635  const std::shared_ptr<ome::xml::model::ExperimenterGroup>& experimenterGroup_BackReference);
636 
647  bool
648  linkExperimenterGroup (const std::shared_ptr<ome::xml::model::ExperimenterGroup>& experimenterGroup_BackReference);
649 
665  bool
666  unlinkExperimenterGroup (const std::shared_ptr<ome::xml::model::ExperimenterGroup>& experimenterGroup_BackReference);
667 
674  sizeOfLinkedDatasetList () const;
675 
682  getLinkedDatasetList () const;
683 
691  const std::weak_ptr<ome::xml::model::Dataset>&
693 
704  const std::weak_ptr<ome::xml::model::Dataset>&
706  const std::shared_ptr<ome::xml::model::Dataset>& dataset_BackReference);
707 
718  bool
719  linkDataset (const std::shared_ptr<ome::xml::model::Dataset>& dataset_BackReference);
720 
736  bool
737  unlinkDataset (const std::shared_ptr<ome::xml::model::Dataset>& dataset_BackReference);
738 
746 
753  getLinkedExperimentList () const;
754 
762  const std::weak_ptr<ome::xml::model::Experiment>&
764 
775  const std::weak_ptr<ome::xml::model::Experiment>&
777  const std::shared_ptr<ome::xml::model::Experiment>& experiment_BackReference);
778 
789  bool
790  linkExperiment (const std::shared_ptr<ome::xml::model::Experiment>& experiment_BackReference);
791 
807  bool
808  unlinkExperiment (const std::shared_ptr<ome::xml::model::Experiment>& experiment_BackReference);
809 
810  protected:
811  // Documented in base class.
812  virtual void
814  common::xml::dom::Element& element) const;
815 
816  public:
817  // Documented in superclass.
818  const std::string&
819  getXMLNamespace() const;
820  };
821 
822  }
823  }
824 }
825 
826 #endif // OME_XML_MODEL_EXPERIMENTER_H
827 
828 /*
829  * Local Variables:
830  * mode:C++
831  * End:
832  */
OME model interface (abstract top-level container)
Definition: OMEModel.h:61
OMEModelObject::indexed_container< ome::xml::model::ExperimenterGroup, std::weak_ptr >::type getLinkedExperimenterGroupList() const
Get the linked ExperimenterGroup list.
Definition: Experimenter.cpp:761
const std::string & getXMLNamespace() const
Get the XML namespace for this model object.
Definition: Experimenter.cpp:1031
void setID(const std::string &id)
Set the ID property.
Definition: Experimenter.cpp:493
const std::weak_ptr< ome::xml::model::Dataset > & setLinkedDataset(OMEModelObject::indexed_container< ome::xml::model::Dataset, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::Dataset > &dataset_BackReference)
Set linked Dataset.
Definition: Experimenter.cpp:831
virtual ~Experimenter()
Destructor.
Definition: Experimenter.cpp:231
const std::weak_ptr< ome::xml::model::Experiment > & setLinkedExperiment(OMEModelObject::indexed_container< ome::xml::model::Experiment, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::Experiment > &experiment_BackReference)
Set linked Experiment.
Definition: Experimenter.cpp:889
OMEModelObject::indexed_container< ome::xml::model::Experiment, std::weak_ptr >::type::size_type sizeOfLinkedExperimentList() const
Get size of linked Experiment list.
Definition: Experimenter.cpp:871
const std::weak_ptr< ome::xml::model::Project > & setLinkedProject(OMEModelObject::indexed_container< ome::xml::model::Project, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::Project > &project_BackReference)
Set linked Project.
Definition: Experimenter.cpp:715
bool linkExperimenterGroup(const std::shared_ptr< ome::xml::model::ExperimenterGroup > &experimenterGroup_BackReference)
Link ExperimenterGroup.
Definition: Experimenter.cpp:783
const std::weak_ptr< ome::xml::model::Image > & setLinkedImage(OMEModelObject::indexed_container< ome::xml::model::Image, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::Image > &image_BackReference)
Set linked Image.
Definition: Experimenter.cpp:599
const std::weak_ptr< ome::xml::model::Project > & getLinkedProject(OMEModelObject::indexed_container< ome::xml::model::Project, std::weak_ptr >::type::size_type index) const
Get linked Project.
Definition: Experimenter.cpp:709
Experimenter()
Default constructor.
Definition: Experimenter.cpp:212
const std::weak_ptr< ome::xml::model::Dataset > & getLinkedDataset(OMEModelObject::indexed_container< ome::xml::model::Dataset, std::weak_ptr >::type::size_type index) const
Get linked Dataset.
Definition: Experimenter.cpp:825
bool unlinkDataset(const std::shared_ptr< ome::xml::model::Dataset > &dataset_BackReference)
Unlink Dataset.
Definition: Experimenter.cpp:854
bool linkImage(const std::shared_ptr< ome::xml::model::Image > &image_BackReference)
Link Image.
Definition: Experimenter.cpp:609
bool unlinkProject(const std::shared_ptr< ome::xml::model::Project > &project_BackReference)
Unlink Project.
Definition: Experimenter.cpp:738
void setInstitution(std::shared_ptr< std::string > &institution)
Set the Institution property.
Definition: Experimenter.cpp:514
const std::weak_ptr< ome::xml::model::Experiment > & getLinkedExperiment(OMEModelObject::indexed_container< ome::xml::model::Experiment, std::weak_ptr >::type::size_type index) const
Get linked Experiment.
Definition: Experimenter.cpp:883
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::MicrobeamManipulation, std::weak_ptr >::type::size_type sizeOfLinkedMicrobeamManipulationList() const
Get size of linked MicrobeamManipulation list.
Definition: Experimenter.cpp:639
OME model object (concrete implementation).
Definition: OMEModelObject.h:64
const std::weak_ptr< ome::xml::model::ExperimenterGroup > & getLinkedExperimenterGroup(OMEModelObject::indexed_container< ome::xml::model::ExperimenterGroup, std::weak_ptr >::type::size_type index) const
Get linked ExperimenterGroup.
Definition: Experimenter.cpp:767
std::shared_ptr< std::string > getFirstName()
Get the FirstName property.
Definition: Experimenter.cpp:423
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: Experimenter.cpp:533
bool linkProject(const std::shared_ptr< ome::xml::model::Project > &project_BackReference)
Link Project.
Definition: Experimenter.cpp:725
const std::weak_ptr< ome::xml::model::ExperimenterGroup > & setLinkedExperimenterGroup(OMEModelObject::indexed_container< ome::xml::model::ExperimenterGroup, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::ExperimenterGroup > &experimenterGroup_BackReference)
Set linked ExperimenterGroup.
Definition: Experimenter.cpp:773
bool unlinkAnnotation(const std::shared_ptr< ome::xml::model::Annotation > &annotation)
Unlink Annotation.
Definition: Experimenter.cpp:563
bool validElementName(const std::string &name) const
Check if a given element name is valid for processing by this model object.
Definition: Experimenter.cpp:252
void setLastName(std::shared_ptr< std::string > &lastName)
Set the LastName property.
Definition: Experimenter.cpp:479
OMEModelObject::indexed_container< ome::xml::model::Dataset, std::weak_ptr >::type getLinkedDatasetList() const
Get the linked Dataset list.
Definition: Experimenter.cpp:819
bool linkDataset(const std::shared_ptr< ome::xml::model::Dataset > &dataset_BackReference)
Link Dataset.
Definition: Experimenter.cpp:841
bool unlinkExperimenterGroup(const std::shared_ptr< ome::xml::model::ExperimenterGroup > &experimenterGroup_BackReference)
Unlink ExperimenterGroup.
Definition: Experimenter.cpp:796
Experimenter model object.
Definition: Experimenter.h:85
Multi-index container for efficient ordered insertion and deletion of model object references...
Definition: OMEModelObject.h:84
static std::shared_ptr< Experimenter > create(const common::xml::dom::Element &element, ome::xml::model::OMEModel &model)
Create a Experimenter model object from DOM element.
Definition: Experimenter.cpp:236
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: Experimenter.cpp:539
OMEModelObject::indexed_container< ome::xml::model::Project, std::weak_ptr >::type::size_type sizeOfLinkedProjectList() const
Get size of linked Project list.
Definition: Experimenter.cpp:697
Open Microscopy Environment C++ implementation.
OMEModelObject::indexed_container< ome::xml::model::Project, std::weak_ptr >::type getLinkedProjectList() const
Get the linked Project list.
Definition: Experimenter.cpp:703
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: Experimenter.cpp:928
void setEmail(std::shared_ptr< std::string > &email)
Set the Email property.
Definition: Experimenter.cpp:395
void setMiddleName(std::shared_ptr< std::string > &middleName)
Set the MiddleName property.
Definition: Experimenter.cpp:458
OMEModelObject::indexed_container< ome::xml::model::Annotation, std::weak_ptr >::type getLinkedAnnotationList() const
Get the linked Annotation list.
Definition: Experimenter.cpp:527
std::shared_ptr< std::string > getMiddleName()
Get the MiddleName property.
Definition: Experimenter.cpp:444
bool linkAnnotation(const std::shared_ptr< ome::xml::model::Annotation > &annotation)
Link Annotation.
Definition: Experimenter.cpp:549
OMEModelObject::indexed_container< ome::xml::model::ExperimenterGroup, std::weak_ptr >::type::size_type sizeOfLinkedExperimenterGroupList() const
Get size of linked ExperimenterGroup list.
Definition: Experimenter.cpp:755
bool unlinkMicrobeamManipulation(const std::shared_ptr< ome::xml::model::MicrobeamManipulation > &microbeamManipulation_BackReference)
Unlink MicrobeamManipulation.
Definition: Experimenter.cpp:680
bool unlinkImage(const std::shared_ptr< ome::xml::model::Image > &image_BackReference)
Unlink Image.
Definition: Experimenter.cpp:622
const std::string & getID() const
Get the ID property.
Definition: Experimenter.cpp:486
bool linkExperiment(const std::shared_ptr< ome::xml::model::Experiment > &experiment_BackReference)
Link Experiment.
Definition: Experimenter.cpp:899
OMEModelObject::indexed_container< ome::xml::model::Experiment, std::weak_ptr >::type getLinkedExperimentList() const
Get the linked Experiment list.
Definition: Experimenter.cpp:877
std::shared_ptr< std::string > getInstitution()
Get the Institution property.
Definition: Experimenter.cpp:500
void setFirstName(std::shared_ptr< std::string > &firstName)
Set the FirstName property.
Definition: Experimenter.cpp:437
const std::weak_ptr< ome::xml::model::MicrobeamManipulation > & getLinkedMicrobeamManipulation(OMEModelObject::indexed_container< ome::xml::model::MicrobeamManipulation, std::weak_ptr >::type::size_type index) const
Get linked MicrobeamManipulation.
Definition: Experimenter.cpp:651
bool unlinkExperiment(const std::shared_ptr< ome::xml::model::Experiment > &experiment_BackReference)
Unlink Experiment.
Definition: Experimenter.cpp:912
Private implementation details of Experimenter model object.
Definition: Experimenter.cpp:78
const std::weak_ptr< ome::xml::model::MicrobeamManipulation > & setLinkedMicrobeamManipulation(OMEModelObject::indexed_container< ome::xml::model::MicrobeamManipulation, std::weak_ptr >::type::size_type index, const std::shared_ptr< ome::xml::model::MicrobeamManipulation > &microbeamManipulation_BackReference)
Set linked MicrobeamManipulation.
Definition: Experimenter.cpp:657
bool linkMicrobeamManipulation(const std::shared_ptr< ome::xml::model::MicrobeamManipulation > &microbeamManipulation_BackReference)
Link MicrobeamManipulation.
Definition: Experimenter.cpp:667
const std::weak_ptr< ome::xml::model::Image > & getLinkedImage(OMEModelObject::indexed_container< ome::xml::model::Image, std::weak_ptr >::type::size_type index) const
Get linked Image.
Definition: Experimenter.cpp:593
void setUserName(std::shared_ptr< std::string > &userName)
Set the UserName property.
Definition: Experimenter.cpp:416
std::shared_ptr< std::string > getEmail()
Get the Email property.
Definition: Experimenter.cpp:381
std::shared_ptr< std::string > getLastName()
Get the LastName property.
Definition: Experimenter.cpp:465
OMEModelObject::indexed_container< ome::xml::model::Image, std::weak_ptr >::type getLinkedImageList() const
Get the linked Image list.
Definition: Experimenter.cpp:587
virtual SKIP void update(const common::xml::dom::Element &element, ome::xml::model::OMEModel &model)
Update the object hierarchy recursively from an XML DOM tree.
Definition: Experimenter.cpp:258
OMEModelObject::indexed_container< ome::xml::model::Image, std::weak_ptr >::type::size_type sizeOfLinkedImageList() const
Get size of linked Image list.
Definition: Experimenter.cpp:581
const std::string & elementName() const
Get the element name of this model object.
Definition: Experimenter.cpp:245
std::shared_ptr< Impl > impl
Private implementation details.
Definition: Experimenter.h:88
std::shared_ptr< std::string > getUserName()
Get the UserName property.
Definition: Experimenter.cpp:402
OMEModelObject::indexed_container< ome::xml::model::Dataset, std::weak_ptr >::type::size_type sizeOfLinkedDatasetList() const
Get size of linked Dataset list.
Definition: Experimenter.cpp:813
OMEModelObject::indexed_container< ome::xml::model::MicrobeamManipulation, std::weak_ptr >::type getLinkedMicrobeamManipulationList() const
Get the linked MicrobeamManipulation list.
Definition: Experimenter.cpp:645
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: Experimenter.cpp:350
OMEModelObject::indexed_container< ome::xml::model::Annotation, std::weak_ptr >::type::size_type sizeOfLinkedAnnotationList() const
Get size of linked Annotation list.
Definition: Experimenter.cpp:521