11 #ifndef GI_INV_DHCPV6CONFIG_HPP
12 #define GI_INV_DHCPV6CONFIG_HPP
14 #include <boost/optional.hpp>
15 #include "opflex/modb/URIBuilder.h"
16 #include "opflex/modb/mo-internal/MO.h"
20 #include "modelgbp/inv/DNSServer.hpp"
24 #include "modelgbp/inv/SearchListEntry.hpp"
30 :
public opflex::modb::mointernal::MO
37 static const opflex::modb::class_id_t
CLASS_ID = 134;
45 return getObjectInstance().isSet(4390916ul, opflex::modb::PropertyInfo::U64);
55 return (uint32_t)getObjectInstance().getUInt64(4390916ul);
79 getTLMutator().modify(getClassId(), getURI())->setUInt64(4390916ul, newValue);
91 getTLMutator().modify(getClassId(), getURI())->unset(4390916ul, opflex::modb::PropertyInfo::U64, opflex::modb::PropertyInfo::SCALAR);
101 return getObjectInstance().isSet(4390913ul, opflex::modb::PropertyInfo::U64);
111 return (uint32_t)getObjectInstance().getUInt64(4390913ul);
120 uint32_t
getT1(uint32_t defaultValue)
122 return getT1().get_value_or(defaultValue);
135 getTLMutator().modify(getClassId(), getURI())->setUInt64(4390913ul, newValue);
147 getTLMutator().modify(getClassId(), getURI())->unset(4390913ul, opflex::modb::PropertyInfo::U64, opflex::modb::PropertyInfo::SCALAR);
157 return getObjectInstance().isSet(4390914ul, opflex::modb::PropertyInfo::U64);
167 return (uint32_t)getObjectInstance().getUInt64(4390914ul);
176 uint32_t
getT2(uint32_t defaultValue)
178 return getT2().get_value_or(defaultValue);
191 getTLMutator().modify(getClassId(), getURI())->setUInt64(4390914ul, newValue);
203 getTLMutator().modify(getClassId(), getURI())->unset(4390914ul, opflex::modb::PropertyInfo::U64, opflex::modb::PropertyInfo::SCALAR);
213 return getObjectInstance().isSet(4390915ul, opflex::modb::PropertyInfo::U64);
223 return (uint32_t)getObjectInstance().getUInt64(4390915ul);
247 getTLMutator().modify(getClassId(), getURI())->setUInt64(4390915ul, newValue);
259 getTLMutator().modify(getClassId(), getURI())->unset(4390915ul, opflex::modb::PropertyInfo::U64, opflex::modb::PropertyInfo::SCALAR);
274 static boost::optional<OF_SHARED_PTR<modelgbp::inv::DHCPv6Config> >
resolve(
275 opflex::ofcore::OFFramework& framework,
276 const opflex::modb::URI& uri)
278 return opflex::modb::mointernal::MO::resolve<modelgbp::inv::DHCPv6Config>(framework,
CLASS_ID, uri);
292 static boost::optional<OF_SHARED_PTR<modelgbp::inv::DHCPv6Config> >
resolve(
293 const opflex::modb::URI& uri)
295 return opflex::modb::mointernal::MO::resolve<modelgbp::inv::DHCPv6Config>(opflex::ofcore::OFFramework::defaultInstance(),
CLASS_ID, uri);
316 static boost::optional<OF_SHARED_PTR<modelgbp::inv::DHCPv6Config> >
resolve(
317 opflex::ofcore::OFFramework& framework,
318 const std::string& invLocalEndpointInventoryName,
319 const std::string& invLocalInventoryEpUuid)
321 return resolve(framework,opflex::modb::URIBuilder().addElement(
"InvUniverse").addElement(
"InvLocalEndpointInventory").addElement(invLocalEndpointInventoryName).addElement(
"InvLocalInventoryEp").addElement(invLocalInventoryEpUuid).addElement(
"InvDHCPv6Config").build());
341 static boost::optional<OF_SHARED_PTR<modelgbp::inv::DHCPv6Config> >
resolve(
342 const std::string& invLocalEndpointInventoryName,
343 const std::string& invLocalInventoryEpUuid)
345 return resolve(opflex::ofcore::OFFramework::defaultInstance(),invLocalEndpointInventoryName,invLocalInventoryEpUuid);
360 const std::string& invDNSServerName)
378 const std::string& invDNSServerName)
380 OF_SHARED_PTR<modelgbp::inv::DNSServer> result = addChild<modelgbp::inv::DNSServer>(
381 CLASS_ID, getURI(), 2151874691ul, 131,
382 opflex::modb::URIBuilder(getURI()).addElement(
"InvDNSServer").addElement(invDNSServerName).build()
384 result->setName(invDNSServerName);
404 opflex::modb::mointernal::MO::resolveChildren<modelgbp::inv::DNSServer>(
405 getFramework(),
CLASS_ID, getURI(), 2151874691ul, 131, out);
420 const std::string& invSearchListEntryName)
438 const std::string& invSearchListEntryName)
440 OF_SHARED_PTR<modelgbp::inv::SearchListEntry> result = addChild<modelgbp::inv::SearchListEntry>(
441 CLASS_ID, getURI(), 2151874695ul, 135,
442 opflex::modb::URIBuilder(getURI()).addElement(
"InvSearchListEntry").addElement(invSearchListEntryName).build()
444 result->setName(invSearchListEntryName);
464 opflex::modb::mointernal::MO::resolveChildren<modelgbp::inv::SearchListEntry>(
465 getFramework(),
CLASS_ID, getURI(), 2151874695ul, 135, out);
478 getTLMutator().remove(
CLASS_ID, getURI());
491 static void remove(opflex::ofcore::OFFramework& framework,
492 const opflex::modb::URI& uri)
494 MO::remove(framework,
CLASS_ID, uri);
507 static void remove(
const opflex::modb::URI& uri)
509 remove(opflex::ofcore::OFFramework::defaultInstance(), uri);
529 opflex::ofcore::OFFramework& framework,
530 const std::string& invLocalEndpointInventoryName,
531 const std::string& invLocalInventoryEpUuid)
533 MO::remove(framework,
CLASS_ID, opflex::modb::URIBuilder().addElement(
"InvUniverse").addElement(
"InvLocalEndpointInventory").addElement(invLocalEndpointInventoryName).addElement(
"InvLocalInventoryEp").addElement(invLocalInventoryEpUuid).addElement(
"InvDHCPv6Config").build());
553 const std::string& invLocalEndpointInventoryName,
554 const std::string& invLocalInventoryEpUuid)
556 remove(opflex::ofcore::OFFramework::defaultInstance(),invLocalEndpointInventoryName,invLocalInventoryEpUuid);
571 opflex::ofcore::OFFramework& framework,
572 opflex::modb::ObjectListener* listener)
574 opflex::modb::mointernal
575 ::MO::registerListener(framework, listener,
CLASS_ID);
590 opflex::modb::ObjectListener* listener)
602 opflex::ofcore::OFFramework& framework,
603 opflex::modb::ObjectListener* listener)
605 opflex::modb::mointernal
606 ::MO::unregisterListener(framework, listener,
CLASS_ID);
616 opflex::modb::ObjectListener* listener)
626 opflex::ofcore::OFFramework& framework,
627 const opflex::modb::URI& uri,
628 const OF_SHARED_PTR<const opflex::modb::mointernal::ObjectInstance>& oi)
629 : MO(framework,
CLASS_ID, uri, oi) { }
634 #endif // GI_INV_DHCPV6CONFIG_HPP
boost::optional< OF_SHARED_PTR< modelgbp::inv::DNSServer > > resolveInvDNSServer(const std::string &invDNSServerName)
Retrieve the child object with the specified naming properties.
Definition: DHCPv6Config.hpp:359
bool isT1Set()
Check whether t1 has been set.
Definition: DHCPv6Config.hpp:99
static boost::optional< OF_SHARED_PTR< modelgbp::inv::DHCPv6Config > > resolve(opflex::ofcore::OFFramework &framework, const std::string &invLocalEndpointInventoryName, const std::string &invLocalInventoryEpUuid)
Retrieve an instance of DHCPv6Config from the managed object store by constructing its URI from the p...
Definition: DHCPv6Config.hpp:316
uint32_t getPreferredLifetime(uint32_t defaultValue)
Get the value of preferredLifetime if set, otherwise the value of default passed in.
Definition: DHCPv6Config.hpp:64
static boost::optional< OF_SHARED_PTR< modelgbp::inv::SearchListEntry > > resolve(opflex::ofcore::OFFramework &framework, const opflex::modb::URI &uri)
Retrieve an instance of SearchListEntry from the managed object store.
Definition: SearchListEntry.hpp:98
static void unregisterListener(opflex::modb::ObjectListener *listener)
Unregister a listener from updates to this class from the default framework instance.
Definition: DHCPv6Config.hpp:615
modelgbp::inv::DHCPv6Config & unsetT2()
Unset t2 in the currently-active mutator.
Definition: DHCPv6Config.hpp:201
static void registerListener(opflex::modb::ObjectListener *listener)
Register a listener that will get called for changes related to this class with the default framework...
Definition: DHCPv6Config.hpp:589
bool isT2Set()
Check whether t2 has been set.
Definition: DHCPv6Config.hpp:155
static const opflex::modb::class_id_t CLASS_ID
The unique class ID for DHCPv6Config.
Definition: DHCPv6Config.hpp:37
modelgbp::inv::DHCPv6Config & unsetPreferredLifetime()
Unset preferredLifetime in the currently-active mutator.
Definition: DHCPv6Config.hpp:89
modelgbp::inv::DHCPv6Config & unsetValidLifetime()
Unset validLifetime in the currently-active mutator.
Definition: DHCPv6Config.hpp:257
boost::optional< OF_SHARED_PTR< modelgbp::inv::SearchListEntry > > resolveInvSearchListEntry(const std::string &invSearchListEntryName)
Retrieve the child object with the specified naming properties.
Definition: DHCPv6Config.hpp:419
static void registerListener(opflex::ofcore::OFFramework &framework, opflex::modb::ObjectListener *listener)
Register a listener that will get called for changes related to this class.
Definition: DHCPv6Config.hpp:570
modelgbp::inv::DHCPv6Config & setPreferredLifetime(uint32_t newValue)
Set preferredLifetime to the specified value in the currently-active mutator.
Definition: DHCPv6Config.hpp:77
static boost::optional< OF_SHARED_PTR< modelgbp::inv::DHCPv6Config > > resolve(const opflex::modb::URI &uri)
Retrieve an instance of DHCPv6Config from the managed object store using the default framework instan...
Definition: DHCPv6Config.hpp:292
uint32_t getT1(uint32_t defaultValue)
Get the value of t1 if set, otherwise the value of default passed in.
Definition: DHCPv6Config.hpp:120
modelgbp::inv::DHCPv6Config & setValidLifetime(uint32_t newValue)
Set validLifetime to the specified value in the currently-active mutator.
Definition: DHCPv6Config.hpp:245
bool isPreferredLifetimeSet()
Check whether preferredLifetime has been set.
Definition: DHCPv6Config.hpp:43
uint32_t getValidLifetime(uint32_t defaultValue)
Get the value of validLifetime if set, otherwise the value of default passed in.
Definition: DHCPv6Config.hpp:232
Definition: DHCPv6Config.hpp:29
boost::optional< uint32_t > getPreferredLifetime()
Get the value of preferredLifetime if it has been set.
Definition: DHCPv6Config.hpp:52
void resolveInvSearchListEntry(std::vector< OF_SHARED_PTR< modelgbp::inv::SearchListEntry > > &out)
Resolve and retrieve all of the immediate children of type modelgbp::inv::SearchListEntry.
Definition: DHCPv6Config.hpp:462
OF_SHARED_PTR< modelgbp::inv::DNSServer > addInvDNSServer(const std::string &invDNSServerName)
Create a new child object with the specified naming properties and make it a child of this object in ...
Definition: DHCPv6Config.hpp:377
DHCPv6Config(opflex::ofcore::OFFramework &framework, const opflex::modb::URI &uri, const OF_SHARED_PTR< const opflex::modb::mointernal::ObjectInstance > &oi)
Construct an instance of DHCPv6Config.
Definition: DHCPv6Config.hpp:625
bool isValidLifetimeSet()
Check whether validLifetime has been set.
Definition: DHCPv6Config.hpp:211
static boost::optional< OF_SHARED_PTR< modelgbp::inv::DHCPv6Config > > resolve(const std::string &invLocalEndpointInventoryName, const std::string &invLocalInventoryEpUuid)
Retrieve an instance of DHCPv6Config from the default managed object store by constructing its URI fr...
Definition: DHCPv6Config.hpp:341
static void unregisterListener(opflex::ofcore::OFFramework &framework, opflex::modb::ObjectListener *listener)
Unregister a listener from updates to this class.
Definition: DHCPv6Config.hpp:601
OF_SHARED_PTR< modelgbp::inv::SearchListEntry > addInvSearchListEntry(const std::string &invSearchListEntryName)
Create a new child object with the specified naming properties and make it a child of this object in ...
Definition: DHCPv6Config.hpp:437
modelgbp::inv::DHCPv6Config & unsetT1()
Unset t1 in the currently-active mutator.
Definition: DHCPv6Config.hpp:145
void resolveInvDNSServer(std::vector< OF_SHARED_PTR< modelgbp::inv::DNSServer > > &out)
Resolve and retrieve all of the immediate children of type modelgbp::inv::DNSServer.
Definition: DHCPv6Config.hpp:402
static boost::optional< OF_SHARED_PTR< modelgbp::inv::DNSServer > > resolve(opflex::ofcore::OFFramework &framework, const opflex::modb::URI &uri)
Retrieve an instance of DNSServer from the managed object store.
Definition: DNSServer.hpp:98
uint32_t getT2(uint32_t defaultValue)
Get the value of t2 if set, otherwise the value of default passed in.
Definition: DHCPv6Config.hpp:176
boost::optional< uint32_t > getT1()
Get the value of t1 if it has been set.
Definition: DHCPv6Config.hpp:108
static boost::optional< OF_SHARED_PTR< modelgbp::inv::DHCPv6Config > > resolve(opflex::ofcore::OFFramework &framework, const opflex::modb::URI &uri)
Retrieve an instance of DHCPv6Config from the managed object store.
Definition: DHCPv6Config.hpp:274
boost::optional< uint32_t > getValidLifetime()
Get the value of validLifetime if it has been set.
Definition: DHCPv6Config.hpp:220
modelgbp::inv::DHCPv6Config & setT1(uint32_t newValue)
Set t1 to the specified value in the currently-active mutator.
Definition: DHCPv6Config.hpp:133
boost::optional< uint32_t > getT2()
Get the value of t2 if it has been set.
Definition: DHCPv6Config.hpp:164
modelgbp::inv::DHCPv6Config & setT2(uint32_t newValue)
Set t2 to the specified value in the currently-active mutator.
Definition: DHCPv6Config.hpp:189