modelgbp Generated OpFlex Model  1.3.0
modelgbp::cdp::Config Class Reference
Inheritance diagram for modelgbp::cdp::Config:

Public Member Functions

bool isNameSet ()
 Check whether name has been set. More...
 
boost::optional< const
std::string & > 
getName ()
 Get the value of name if it has been set. More...
 
const std::string & getName (const std::string &defaultValue)
 Get the value of name if set, otherwise the value of default passed in. More...
 
modelgbp::cdp::ConfigsetName (const std::string &newValue)
 Set name to the specified value in the currently-active mutator. More...
 
modelgbp::cdp::ConfigunsetName ()
 Unset name in the currently-active mutator. More...
 
bool isStateSet ()
 Check whether state has been set. More...
 
boost::optional< const uint8_t > getState ()
 Get the value of state if it has been set. More...
 
const uint8_t getState (const uint8_t defaultValue)
 Get the value of state if set, otherwise the value of default passed in. More...
 
modelgbp::cdp::ConfigsetState (const uint8_t newValue)
 Set state to the specified value in the currently-active mutator. More...
 
modelgbp::cdp::ConfigunsetState ()
 Unset state in the currently-active mutator. More...
 
void remove ()
 Remove this instance using the currently-active mutator. More...
 
 Config (opflex::ofcore::OFFramework &framework, const opflex::modb::URI &uri, const boost::shared_ptr< const opflex::modb::mointernal::ObjectInstance > &oi)
 Construct an instance of Config. More...
 

Static Public Member Functions

static boost::optional
< boost::shared_ptr
< modelgbp::cdp::Config > > 
resolve (opflex::ofcore::OFFramework &framework, const opflex::modb::URI &uri)
 Retrieve an instance of Config from the managed object store. More...
 
static boost::optional
< boost::shared_ptr
< modelgbp::cdp::Config > > 
resolve (const opflex::modb::URI &uri)
 Retrieve an instance of Config from the managed object store using the default framework instance. More...
 
static boost::optional
< boost::shared_ptr
< modelgbp::cdp::Config > > 
resolve (opflex::ofcore::OFFramework &framework, const std::string &platformConfigName)
 Retrieve an instance of Config from the managed object store by constructing its URI from the path elements that lead to it. More...
 
static boost::optional
< boost::shared_ptr
< modelgbp::cdp::Config > > 
resolve (const std::string &platformConfigName)
 Retrieve an instance of Config from the default managed object store by constructing its URI from the path elements that lead to it. More...
 
static void remove (opflex::ofcore::OFFramework &framework, const opflex::modb::URI &uri)
 Remove the Config object with the specified URI using the currently-active mutator. More...
 
static void remove (const opflex::modb::URI &uri)
 Remove the Config object with the specified URI using the currently-active mutator and the default framework instance. More...
 
static void remove (opflex::ofcore::OFFramework &framework, const std::string &platformConfigName)
 Remove the Config object with the specified path elements from the managed object store. More...
 
static void remove (const std::string &platformConfigName)
 Remove the Config object with the specified path elements from the managed object store using the default framework instance. More...
 
static void registerListener (opflex::ofcore::OFFramework &framework, opflex::modb::ObjectListener *listener)
 Register a listener that will get called for changes related to this class. More...
 
static void registerListener (opflex::modb::ObjectListener *listener)
 Register a listener that will get called for changes related to this class with the default framework instance. More...
 
static void unregisterListener (opflex::ofcore::OFFramework &framework, opflex::modb::ObjectListener *listener)
 Unregister a listener from updates to this class. More...
 
static void unregisterListener (opflex::modb::ObjectListener *listener)
 Unregister a listener from updates to this class from the default framework instance. More...
 

Static Public Attributes

static const
opflex::modb::class_id_t 
CLASS_ID = 39
 The unique class ID for Config.
 

Constructor & Destructor Documentation

modelgbp::cdp::Config::Config ( opflex::ofcore::OFFramework &  framework,
const opflex::modb::URI &  uri,
const boost::shared_ptr< const opflex::modb::mointernal::ObjectInstance > &  oi 
)
inline

Construct an instance of Config.

This should not typically be called from user code.

Member Function Documentation

boost::optional<const std::string&> modelgbp::cdp::Config::getName ( )
inline

Get the value of name if it has been set.

Returns
the value of name or boost::none if not set

References isNameSet().

Referenced by getName().

const std::string& modelgbp::cdp::Config::getName ( const std::string &  defaultValue)
inline

Get the value of name if set, otherwise the value of default passed in.

Parameters
defaultValuedefault value returned if the property is not set
Returns
the value of name if set, otherwise the value of default passed in

References getName().

boost::optional<const uint8_t> modelgbp::cdp::Config::getState ( )
inline

Get the value of state if it has been set.

Returns
the value of state or boost::none if not set

References isStateSet().

Referenced by getState().

const uint8_t modelgbp::cdp::Config::getState ( const uint8_t  defaultValue)
inline

Get the value of state if set, otherwise the value of default passed in.

Parameters
defaultValuedefault value returned if the property is not set
Returns
the value of state if set, otherwise the value of default passed in

References getState().

bool modelgbp::cdp::Config::isNameSet ( )
inline

Check whether name has been set.

Returns
true if name has been set

Referenced by getName().

bool modelgbp::cdp::Config::isStateSet ( )
inline

Check whether state has been set.

Returns
true if state has been set

Referenced by getState().

static void modelgbp::cdp::Config::registerListener ( opflex::ofcore::OFFramework &  framework,
opflex::modb::ObjectListener *  listener 
)
inlinestatic

Register a listener that will get called for changes related to this class.

This listener will be called for any modifications of this class or any transitive children of this class.

Parameters
frameworkthe framework instance
listenerthe listener functional object that should be called when changes occur related to the class. This memory is owned by the caller and should be freed only after it has been unregistered.

References CLASS_ID.

Referenced by registerListener().

static void modelgbp::cdp::Config::registerListener ( opflex::modb::ObjectListener *  listener)
inlinestatic

Register a listener that will get called for changes related to this class with the default framework instance.

This listener will be called for any modifications of this class or any transitive children of this class.

Parameters
listenerthe listener functional object that should be called when changes occur related to the class. This memory is owned by the caller and should be freed only after it has been unregistered.

References registerListener().

void modelgbp::cdp::Config::remove ( )
inline

Remove this instance using the currently-active mutator.

If the object does not exist, then this will be a no-op. If this object has any children, they will be garbage-collected at some future time.

Exceptions
std::logic_errorif no mutator is active

References CLASS_ID.

static void modelgbp::cdp::Config::remove ( opflex::ofcore::OFFramework &  framework,
const opflex::modb::URI &  uri 
)
inlinestatic

Remove the Config object with the specified URI using the currently-active mutator.

If the object does not exist, then this will be a no-op. If this object has any children, they will be garbage-collected at some future time.

Parameters
frameworkthe framework instance to use
urithe URI of the object to remove
Exceptions
std::logic_errorif no mutator is active

References CLASS_ID.

static void modelgbp::cdp::Config::remove ( const opflex::modb::URI &  uri)
inlinestatic

Remove the Config object with the specified URI using the currently-active mutator and the default framework instance.

If the object does not exist, then this will be a no-op. If this object has any children, they will be garbage-collected at some future time.

Parameters
urithe URI of the object to remove
Exceptions
std::logic_errorif no mutator is active
static void modelgbp::cdp::Config::remove ( opflex::ofcore::OFFramework &  framework,
const std::string &  platformConfigName 
)
inlinestatic

Remove the Config object with the specified path elements from the managed object store.

If the object does not exist, then this will be a no-op. If this object has any children, they will be garbage-collected at some future time.

The object URI generated by this function will take the form: /PolicyUniverse/PlatformConfig/[platformConfigName]/CdpConfig

Parameters
frameworkthe framework instance to use
platformConfigNamethe value of platformConfigName, a naming property for Config
Exceptions
std::logic_errorif no mutator is active

References CLASS_ID.

static void modelgbp::cdp::Config::remove ( const std::string &  platformConfigName)
inlinestatic

Remove the Config object with the specified path elements from the managed object store using the default framework instance.

If the object does not exist, then this will be a no-op. If this object has any children, they will be garbage-collected at some future time.

The object URI generated by this function will take the form: /PolicyUniverse/PlatformConfig/[platformConfigName]/CdpConfig

Parameters
platformConfigNamethe value of platformConfigName, a naming property for Config
Exceptions
std::logic_errorif no mutator is active
static boost::optional<boost::shared_ptr<modelgbp::cdp::Config> > modelgbp::cdp::Config::resolve ( opflex::ofcore::OFFramework &  framework,
const opflex::modb::URI &  uri 
)
inlinestatic

Retrieve an instance of Config from the managed object store.

If the object does not exist in the local store, returns boost::none. Note that even though it may not exist locally, it may still exist remotely.

Parameters
frameworkthe framework instance to use
urithe URI of the object to retrieve
Returns
a shared pointer to the object or boost::none if it does not exist.

References CLASS_ID.

Referenced by resolve(), and modelgbp::platform::Config::resolveCdpConfig().

static boost::optional<boost::shared_ptr<modelgbp::cdp::Config> > modelgbp::cdp::Config::resolve ( const opflex::modb::URI &  uri)
inlinestatic

Retrieve an instance of Config from the managed object store using the default framework instance.

If the object does not exist in the local store, returns boost::none. Note that even though it may not exist locally, it may still exist remotely.

Parameters
urithe URI of the object to retrieve
Returns
a shared pointer to the object or boost::none if it does not exist.

References CLASS_ID.

static boost::optional<boost::shared_ptr<modelgbp::cdp::Config> > modelgbp::cdp::Config::resolve ( opflex::ofcore::OFFramework &  framework,
const std::string &  platformConfigName 
)
inlinestatic

Retrieve an instance of Config from the managed object store by constructing its URI from the path elements that lead to it.

If the object does not exist in the local store, returns boost::none. Note that even though it may not exist locally, it may still exist remotely.

The object URI generated by this function will take the form: /PolicyUniverse/PlatformConfig/[platformConfigName]/CdpConfig

Parameters
frameworkthe framework instance to use
platformConfigNamethe value of platformConfigName, a naming property for Config
Returns
a shared pointer to the object or boost::none if it does not exist.

References resolve().

static boost::optional<boost::shared_ptr<modelgbp::cdp::Config> > modelgbp::cdp::Config::resolve ( const std::string &  platformConfigName)
inlinestatic

Retrieve an instance of Config from the default managed object store by constructing its URI from the path elements that lead to it.

If the object does not exist in the local store, returns boost::none. Note that even though it may not exist locally, it may still exist remotely.

The object URI generated by this function will take the form: /PolicyUniverse/PlatformConfig/[platformConfigName]/CdpConfig

Parameters
platformConfigNamethe value of platformConfigName, a naming property for Config
Returns
a shared pointer to the object or boost::none if it does not exist.

References resolve().

modelgbp::cdp::Config& modelgbp::cdp::Config::setName ( const std::string &  newValue)
inline

Set name to the specified value in the currently-active mutator.

Parameters
newValuethe new value to set.
Returns
a reference to the current object
Exceptions
std::logic_errorif no mutator is active
See Also
opflex::modb::Mutator
modelgbp::cdp::Config& modelgbp::cdp::Config::setState ( const uint8_t  newValue)
inline

Set state to the specified value in the currently-active mutator.

Parameters
newValuethe new value to set.
Returns
a reference to the current object
Exceptions
std::logic_errorif no mutator is active
See Also
opflex::modb::Mutator
static void modelgbp::cdp::Config::unregisterListener ( opflex::ofcore::OFFramework &  framework,
opflex::modb::ObjectListener *  listener 
)
inlinestatic

Unregister a listener from updates to this class.

Parameters
frameworkthe framework instance
listenerThe listener to unregister.

References CLASS_ID.

Referenced by unregisterListener().

static void modelgbp::cdp::Config::unregisterListener ( opflex::modb::ObjectListener *  listener)
inlinestatic

Unregister a listener from updates to this class from the default framework instance.

Parameters
listenerThe listener to unregister.

References unregisterListener().

modelgbp::cdp::Config& modelgbp::cdp::Config::unsetName ( )
inline

Unset name in the currently-active mutator.

Exceptions
std::logic_errorif no mutator is active
Returns
a reference to the current object
See Also
opflex::modb::Mutator
modelgbp::cdp::Config& modelgbp::cdp::Config::unsetState ( )
inline

Unset state in the currently-active mutator.

Exceptions
std::logic_errorif no mutator is active
Returns
a reference to the current object
See Also
opflex::modb::Mutator

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