aGrUM  0.16.0
gum::prm::o3prm::O3RawCPT Class Reference

The O3RawCPT is part of the AST of the O3PRM language. More...

#include <agrum/PRM/o3prm/O3prm.h>

+ Inheritance diagram for gum::prm::o3prm::O3RawCPT:
+ Collaboration diagram for gum::prm::o3prm::O3RawCPT:

Public Member Functions

 O3RawCPT ()
 
 O3RawCPT (const O3Label &type, const O3Label &name, const O3Attribute::O3LabelList &parents, const O3FormulaList &values)
 
 O3RawCPT (const O3RawCPT &src)
 
 O3RawCPT (O3RawCPT &&src)
 
 ~O3RawCPT ()
 
virtual O3RawCPToperator= (const O3RawCPT &src)
 
virtual O3RawCPToperator= (O3RawCPT &&src)
 
virtual O3FormulaListvalues ()
 
virtual const O3FormulaListvalues () const
 
virtual std::unique_ptr< O3Attributecopy () const
 
virtual O3Labeltype ()
 
virtual const O3Labeltype () const
 
virtual O3Labelname ()
 
virtual const O3Labelname () const
 
virtual O3LabelListparents ()
 
virtual const O3LabelListparents () const
 

Public Types

using O3FormulaList = std::vector< O3Formula >
 
using O3LabelList = std::vector< O3Label >
 

Detailed Description

The O3RawCPT is part of the AST of the O3PRM language.

Definition at line 510 of file O3prm.h.

Member Typedef Documentation

◆ O3FormulaList

Definition at line 512 of file O3prm.h.

◆ O3LabelList

using gum::prm::o3prm::O3Attribute::O3LabelList = std::vector< O3Label >
inherited

Definition at line 473 of file O3prm.h.

Constructor & Destructor Documentation

◆ O3RawCPT() [1/4]

gum::prm::o3prm::O3RawCPT::O3RawCPT ( )

Definition at line 673 of file O3prm.cpp.

Referenced by copy().

673  : O3Attribute(), __values{new O3FormulaList{}} {
674  GUM_CONSTRUCTOR(O3RawCPT);
675  }
std::unique_ptr< O3FormulaList > __values
Definition: O3prm.h:532
std::vector< O3Formula > O3FormulaList
Definition: O3prm.h:512
+ Here is the caller graph for this function:

◆ O3RawCPT() [2/4]

gum::prm::o3prm::O3RawCPT::O3RawCPT ( const O3Label type,
const O3Label name,
const O3Attribute::O3LabelList parents,
const O3FormulaList values 
)

Definition at line 677 of file O3prm.cpp.

References __values, and copy().

680  :
682  GUM_CONSTRUCTOR(O3RawCPT);
683  auto copy = new O3FormulaList(values);
684  __values = std::unique_ptr< O3FormulaList >(copy);
685  }
virtual O3LabelList & parents()
Definition: O3prm.cpp:668
virtual O3FormulaList & values()
Definition: O3prm.cpp:715
std::unique_ptr< O3FormulaList > __values
Definition: O3prm.h:532
virtual std::unique_ptr< O3Attribute > copy() const
Definition: O3prm.cpp:719
std::vector< O3Formula > O3FormulaList
Definition: O3prm.h:512
virtual O3Label & type()
Definition: O3prm.cpp:662
virtual O3Label & name()
Definition: O3prm.cpp:665
+ Here is the call graph for this function:

◆ O3RawCPT() [3/4]

gum::prm::o3prm::O3RawCPT::O3RawCPT ( const O3RawCPT src)

Definition at line 687 of file O3prm.cpp.

References __values, and copy().

687  : O3Attribute(src) {
688  GUM_CONS_CPY(O3RawCPT);
689  auto copy = new O3FormulaList(*(src.__values));
690  __values = std::unique_ptr< O3FormulaList >(copy);
691  }
std::unique_ptr< O3FormulaList > __values
Definition: O3prm.h:532
virtual std::unique_ptr< O3Attribute > copy() const
Definition: O3prm.cpp:719
std::vector< O3Formula > O3FormulaList
Definition: O3prm.h:512
+ Here is the call graph for this function:

◆ O3RawCPT() [4/4]

gum::prm::o3prm::O3RawCPT::O3RawCPT ( O3RawCPT &&  src)

Definition at line 693 of file O3prm.cpp.

693  :
694  O3Attribute(src), __values(std::move(src.__values)) {
695  GUM_CONS_MOV(O3RawCPT);
696  }
std::unique_ptr< O3FormulaList > __values
Definition: O3prm.h:532

◆ ~O3RawCPT()

gum::prm::o3prm::O3RawCPT::~O3RawCPT ( )

Definition at line 698 of file O3prm.cpp.

698 { GUM_DESTRUCTOR(O3RawCPT); }

Member Function Documentation

◆ copy()

std::unique_ptr< O3Attribute > gum::prm::o3prm::O3RawCPT::copy ( ) const
virtual

Implements gum::prm::o3prm::O3Attribute.

Definition at line 719 of file O3prm.cpp.

References O3RawCPT().

Referenced by O3RawCPT(), and operator=().

719  {
720  auto copy = new O3RawCPT(*this);
721  return std::unique_ptr< O3Attribute >(copy);
722  }
virtual std::unique_ptr< O3Attribute > copy() const
Definition: O3prm.cpp:719
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ name() [1/2]

O3Label & gum::prm::o3prm::O3Attribute::name ( )
virtualinherited

Definition at line 665 of file O3prm.cpp.

References gum::prm::o3prm::O3Attribute::__name.

Referenced by gum::prm::o3prm::O3ClassFactory< GUM_SCALAR >::__checkAttributeForDeclaration(), gum::prm::o3prm::O3ClassFactory< GUM_SCALAR >::__checkRawCPT(), and gum::prm::o3prm::O3ClassFactory< GUM_SCALAR >::__checkRuleCPTSumsTo1().

665 { return __name; }
+ Here is the caller graph for this function:

◆ name() [2/2]

const O3Label & gum::prm::o3prm::O3Attribute::name ( ) const
virtualinherited

Definition at line 666 of file O3prm.cpp.

References gum::prm::o3prm::O3Attribute::__name.

666 { return __name; }

◆ operator=() [1/2]

O3RawCPT & gum::prm::o3prm::O3RawCPT::operator= ( const O3RawCPT src)
virtual

Definition at line 700 of file O3prm.cpp.

References __values, copy(), and gum::prm::o3prm::O3Attribute::operator=().

700  {
701  if (this == &src) { return *this; }
703  auto copy = new O3FormulaList(*(src.__values));
704  __values = std::unique_ptr< O3FormulaList >(copy);
705  return *this;
706  }
std::unique_ptr< O3FormulaList > __values
Definition: O3prm.h:532
virtual std::unique_ptr< O3Attribute > copy() const
Definition: O3prm.cpp:719
virtual O3Attribute & operator=(const O3Attribute &src)
Definition: O3prm.cpp:646
std::vector< O3Formula > O3FormulaList
Definition: O3prm.h:512
+ Here is the call graph for this function:

◆ operator=() [2/2]

O3RawCPT & gum::prm::o3prm::O3RawCPT::operator= ( O3RawCPT &&  src)
virtual

Definition at line 708 of file O3prm.cpp.

References __values, and gum::prm::o3prm::O3Attribute::operator=().

708  {
709  if (this == &src) { return *this; }
711  __values = std::move(src.__values);
712  return *this;
713  }
std::unique_ptr< O3FormulaList > __values
Definition: O3prm.h:532
virtual O3Attribute & operator=(const O3Attribute &src)
Definition: O3prm.cpp:646
+ Here is the call graph for this function:

◆ parents() [1/2]

O3Attribute::O3LabelList & gum::prm::o3prm::O3Attribute::parents ( )
virtualinherited

Definition at line 668 of file O3prm.cpp.

References gum::prm::o3prm::O3Attribute::__parents.

Referenced by gum::prm::o3prm::O3ClassFactory< GUM_SCALAR >::__checkAttributeForCompletion(), gum::prm::o3prm::O3ClassFactory< GUM_SCALAR >::__checkLabelsNumber(), gum::prm::o3prm::O3ClassFactory< GUM_SCALAR >::__checkLabelsValues(), and gum::prm::o3prm::O3ClassFactory< GUM_SCALAR >::__checkRawCPT().

668 { return __parents; }
+ Here is the caller graph for this function:

◆ parents() [2/2]

const O3Attribute::O3LabelList & gum::prm::o3prm::O3Attribute::parents ( ) const
virtualinherited

Definition at line 669 of file O3prm.cpp.

References gum::prm::o3prm::O3Attribute::__parents.

669  {
670  return __parents;
671  }

◆ type() [1/2]

O3Label & gum::prm::o3prm::O3Attribute::type ( )
virtualinherited

Definition at line 662 of file O3prm.cpp.

References gum::prm::o3prm::O3Attribute::__type.

Referenced by gum::prm::o3prm::O3ClassFactory< GUM_SCALAR >::__checkAttributeForDeclaration(), and gum::prm::o3prm::O3ClassFactory< GUM_SCALAR >::__checkRawCPT().

662 { return __type; }
+ Here is the caller graph for this function:

◆ type() [2/2]

const O3Label & gum::prm::o3prm::O3Attribute::type ( ) const
virtualinherited

Definition at line 663 of file O3prm.cpp.

References gum::prm::o3prm::O3Attribute::__type.

663 { return __type; }

◆ values() [1/2]

O3RawCPT::O3FormulaList & gum::prm::o3prm::O3RawCPT::values ( )
virtual

Definition at line 715 of file O3prm.cpp.

References __values.

Referenced by gum::prm::o3prm::O3ClassFactory< GUM_SCALAR >::__checkRawCPT().

715 { return *__values; }
std::unique_ptr< O3FormulaList > __values
Definition: O3prm.h:532
+ Here is the caller graph for this function:

◆ values() [2/2]

const O3RawCPT::O3FormulaList & gum::prm::o3prm::O3RawCPT::values ( ) const
virtual

Definition at line 717 of file O3prm.cpp.

References __values.

717 { return *__values; }
std::unique_ptr< O3FormulaList > __values
Definition: O3prm.h:532

Member Data Documentation

◆ __values

std::unique_ptr< O3FormulaList > gum::prm::o3prm::O3RawCPT::__values
private

Definition at line 532 of file O3prm.h.

Referenced by O3RawCPT(), operator=(), and values().


The documentation for this class was generated from the following files: