Skip to content

Commit

Permalink
Update auto generated go snappi
Browse files Browse the repository at this point in the history
  • Loading branch information
actions-user committed Feb 26, 2025
1 parent a13d1ba commit 8e6096d
Show file tree
Hide file tree
Showing 48 changed files with 41,547 additions and 24,403 deletions.
38 changes: 19 additions & 19 deletions gosnappi/bgp_attributes_community.go
Original file line number Diff line number Diff line change
Expand Up @@ -278,16 +278,16 @@ type BgpAttributesCommunity interface {
Choice() BgpAttributesCommunityChoiceEnum
// setChoice assigns BgpAttributesCommunityChoiceEnum provided by user to BgpAttributesCommunity
setChoice(value BgpAttributesCommunityChoiceEnum) BgpAttributesCommunity
// getter for NoExportSubconfed to set choice.
NoExportSubconfed()
// getter for NoAdvertised to set choice.
NoAdvertised()
// getter for NoExport to set choice.
NoExport()
// getter for LlgrStale to set choice.
LlgrStale()
// getter for NoExport to set choice.
NoExport()
// getter for NoLlgr to set choice.
NoLlgr()
// getter for NoAdvertised to set choice.
NoAdvertised()
// getter for NoExportSubconfed to set choice.
NoExportSubconfed()
// CustomCommunity returns BgpAttributesCustomCommunity, set in BgpAttributesCommunity.
// BgpAttributesCustomCommunity is user defined COMMUNITY attribute containing 2 byte AS and custom 2 byte value defined by the administrator of the domain.
CustomCommunity() BgpAttributesCustomCommunity
Expand Down Expand Up @@ -322,31 +322,31 @@ func (obj *bgpAttributesCommunity) Choice() BgpAttributesCommunityChoiceEnum {
return BgpAttributesCommunityChoiceEnum(obj.obj.Choice.Enum().String())
}

// getter for NoExportSubconfed to set choice
func (obj *bgpAttributesCommunity) NoExportSubconfed() {
obj.setChoice(BgpAttributesCommunityChoice.NO_EXPORT_SUBCONFED)
}

// getter for NoAdvertised to set choice
func (obj *bgpAttributesCommunity) NoAdvertised() {
obj.setChoice(BgpAttributesCommunityChoice.NO_ADVERTISED)
// getter for LlgrStale to set choice
func (obj *bgpAttributesCommunity) LlgrStale() {
obj.setChoice(BgpAttributesCommunityChoice.LLGR_STALE)
}

// getter for NoExport to set choice
func (obj *bgpAttributesCommunity) NoExport() {
obj.setChoice(BgpAttributesCommunityChoice.NO_EXPORT)
}

// getter for LlgrStale to set choice
func (obj *bgpAttributesCommunity) LlgrStale() {
obj.setChoice(BgpAttributesCommunityChoice.LLGR_STALE)
}

// getter for NoLlgr to set choice
func (obj *bgpAttributesCommunity) NoLlgr() {
obj.setChoice(BgpAttributesCommunityChoice.NO_LLGR)
}

// getter for NoAdvertised to set choice
func (obj *bgpAttributesCommunity) NoAdvertised() {
obj.setChoice(BgpAttributesCommunityChoice.NO_ADVERTISED)
}

// getter for NoExportSubconfed to set choice
func (obj *bgpAttributesCommunity) NoExportSubconfed() {
obj.setChoice(BgpAttributesCommunityChoice.NO_EXPORT_SUBCONFED)
}

func (obj *bgpAttributesCommunity) setChoice(value BgpAttributesCommunityChoiceEnum) BgpAttributesCommunity {
intValue, ok := otg.BgpAttributesCommunity_Choice_Enum_value[string(value)]
if !ok {
Expand Down
24 changes: 12 additions & 12 deletions gosnappi/bgp_attributes_sr_policy_explicit_null_policy.go
Original file line number Diff line number Diff line change
Expand Up @@ -272,16 +272,16 @@ type BgpAttributesSrPolicyExplicitNullPolicy interface {
setChoice(value BgpAttributesSrPolicyExplicitNullPolicyChoiceEnum) BgpAttributesSrPolicyExplicitNullPolicy
// HasChoice checks if Choice has been set in BgpAttributesSrPolicyExplicitNullPolicy
HasChoice() bool
// getter for DonotPush to set choice.
DonotPush()
// getter for PushIpv6 to set choice.
PushIpv6()
// getter for PushIpv4AndIpv6 to set choice.
PushIpv4AndIpv6()
// getter for PushIpv4 to set choice.
PushIpv4()
// getter for PushIpv6 to set choice.
PushIpv6()
// getter for Unknown to set choice.
Unknown()
// getter for DonotPush to set choice.
DonotPush()
}

type BgpAttributesSrPolicyExplicitNullPolicyChoiceEnum string
Expand All @@ -305,9 +305,9 @@ func (obj *bgpAttributesSrPolicyExplicitNullPolicy) Choice() BgpAttributesSrPoli
return BgpAttributesSrPolicyExplicitNullPolicyChoiceEnum(obj.obj.Choice.Enum().String())
}

// getter for DonotPush to set choice
func (obj *bgpAttributesSrPolicyExplicitNullPolicy) DonotPush() {
obj.setChoice(BgpAttributesSrPolicyExplicitNullPolicyChoice.DONOT_PUSH)
// getter for PushIpv6 to set choice
func (obj *bgpAttributesSrPolicyExplicitNullPolicy) PushIpv6() {
obj.setChoice(BgpAttributesSrPolicyExplicitNullPolicyChoice.PUSH_IPV6)
}

// getter for PushIpv4AndIpv6 to set choice
Expand All @@ -320,16 +320,16 @@ func (obj *bgpAttributesSrPolicyExplicitNullPolicy) PushIpv4() {
obj.setChoice(BgpAttributesSrPolicyExplicitNullPolicyChoice.PUSH_IPV4)
}

// getter for PushIpv6 to set choice
func (obj *bgpAttributesSrPolicyExplicitNullPolicy) PushIpv6() {
obj.setChoice(BgpAttributesSrPolicyExplicitNullPolicyChoice.PUSH_IPV6)
}

// getter for Unknown to set choice
func (obj *bgpAttributesSrPolicyExplicitNullPolicy) Unknown() {
obj.setChoice(BgpAttributesSrPolicyExplicitNullPolicyChoice.UNKNOWN)
}

// getter for DonotPush to set choice
func (obj *bgpAttributesSrPolicyExplicitNullPolicy) DonotPush() {
obj.setChoice(BgpAttributesSrPolicyExplicitNullPolicyChoice.DONOT_PUSH)
}

// The Explicit NULL Label policy.
// Choice returns a string
func (obj *bgpAttributesSrPolicyExplicitNullPolicy) HasChoice() bool {
Expand Down
80 changes: 70 additions & 10 deletions gosnappi/device_isis_router.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,17 @@ import (
// ***** DeviceIsisRouter *****
type deviceIsisRouter struct {
validation
obj *otg.DeviceIsisRouter
marshaller marshalDeviceIsisRouter
unMarshaller unMarshalDeviceIsisRouter
instanceHolder DeviceIsisMultiInstance
interfacesHolder DeviceIsisRouterIsisInterfaceIter
basicHolder IsisBasic
advancedHolder IsisAdvanced
routerAuthHolder IsisAuthentication
v4RoutesHolder DeviceIsisRouterIsisV4RouteRangeIter
v6RoutesHolder DeviceIsisRouterIsisV6RouteRangeIter
obj *otg.DeviceIsisRouter
marshaller marshalDeviceIsisRouter
unMarshaller unMarshalDeviceIsisRouter
instanceHolder DeviceIsisMultiInstance
interfacesHolder DeviceIsisRouterIsisInterfaceIter
basicHolder IsisBasic
advancedHolder IsisAdvanced
routerAuthHolder IsisAuthentication
v4RoutesHolder DeviceIsisRouterIsisV4RouteRangeIter
v6RoutesHolder DeviceIsisRouterIsisV6RouteRangeIter
segmentRoutingHolder IsisSegmentRouting
}

func NewDeviceIsisRouter() DeviceIsisRouter {
Expand Down Expand Up @@ -257,6 +258,7 @@ func (obj *deviceIsisRouter) setNil() {
obj.routerAuthHolder = nil
obj.v4RoutesHolder = nil
obj.v6RoutesHolder = nil
obj.segmentRoutingHolder = nil
obj.validationErrors = nil
obj.warnings = nil
obj.constraints = make(map[string]map[string]Constraints)
Expand Down Expand Up @@ -330,6 +332,30 @@ type DeviceIsisRouter interface {
Name() string
// SetName assigns string provided by user to DeviceIsisRouter
SetName(value string) DeviceIsisRouter
// SegmentRouting returns IsisSegmentRouting, set in DeviceIsisRouter.
// IsisSegmentRouting is segment Routing (SR) allows for a flexible definition of end-to-end paths within IGP topologies by encoding paths as sequences of topological sub-paths,
// called "segments". These segments are advertised by the link-state routing protocols (IS-IS and OSPF).
// Prefix segments represent an ECMP-aware shortest path to a prefix (or a node), as per the state of the IGP topology.
// Adjacency segments represent a hop over a specific adjacency between two nodes in the IGP.
// A prefix segment is typically a multi-hop path while an adjacency segment, in most of the cases, is a one-hop path.
// These segments act as topological sub-paths that can be combined together to form the required path.
// Reference: https://datatracker.ietf.org/doc/html/rfc8667.:w
// An implementation may advertise Router Capability with default values if a user does not even set the properties
// of Router Capability and Segment Routing Capability.
SegmentRouting() IsisSegmentRouting
// SetSegmentRouting assigns IsisSegmentRouting provided by user to DeviceIsisRouter.
// IsisSegmentRouting is segment Routing (SR) allows for a flexible definition of end-to-end paths within IGP topologies by encoding paths as sequences of topological sub-paths,
// called "segments". These segments are advertised by the link-state routing protocols (IS-IS and OSPF).
// Prefix segments represent an ECMP-aware shortest path to a prefix (or a node), as per the state of the IGP topology.
// Adjacency segments represent a hop over a specific adjacency between two nodes in the IGP.
// A prefix segment is typically a multi-hop path while an adjacency segment, in most of the cases, is a one-hop path.
// These segments act as topological sub-paths that can be combined together to form the required path.
// Reference: https://datatracker.ietf.org/doc/html/rfc8667.:w
// An implementation may advertise Router Capability with default values if a user does not even set the properties
// of Router Capability and Segment Routing Capability.
SetSegmentRouting(value IsisSegmentRouting) DeviceIsisRouter
// HasSegmentRouting checks if SegmentRouting has been set in DeviceIsisRouter
HasSegmentRouting() bool
setNil()
}

Expand Down Expand Up @@ -738,6 +764,34 @@ func (obj *deviceIsisRouter) SetName(value string) DeviceIsisRouter {
return obj
}

// Optional Segment Routing (SR).
// SegmentRouting returns a IsisSegmentRouting
func (obj *deviceIsisRouter) SegmentRouting() IsisSegmentRouting {
if obj.obj.SegmentRouting == nil {
obj.obj.SegmentRouting = NewIsisSegmentRouting().msg()
}
if obj.segmentRoutingHolder == nil {
obj.segmentRoutingHolder = &isisSegmentRouting{obj: obj.obj.SegmentRouting}
}
return obj.segmentRoutingHolder
}

// Optional Segment Routing (SR).
// SegmentRouting returns a IsisSegmentRouting
func (obj *deviceIsisRouter) HasSegmentRouting() bool {
return obj.obj.SegmentRouting != nil
}

// Optional Segment Routing (SR).
// SetSegmentRouting sets the IsisSegmentRouting value in the DeviceIsisRouter object
func (obj *deviceIsisRouter) SetSegmentRouting(value IsisSegmentRouting) DeviceIsisRouter {

obj.segmentRoutingHolder = nil
obj.obj.SegmentRouting = value.msg()

return obj
}

func (obj *deviceIsisRouter) validateObj(vObj *validation, set_default bool) {
if set_default {
obj.setDefault()
Expand Down Expand Up @@ -822,6 +876,12 @@ func (obj *deviceIsisRouter) validateObj(vObj *validation, set_default bool) {
if obj.obj.Name == nil {
vObj.validationErrors = append(vObj.validationErrors, "Name is required field on interface DeviceIsisRouter")
}

if obj.obj.SegmentRouting != nil {

obj.SegmentRouting().validateObj(vObj, set_default)
}

}

func (obj *deviceIsisRouter) setDefault() {
Expand Down
14 changes: 7 additions & 7 deletions gosnappi/dhcpv6_client_options_duid_uuid_variant.go
Original file line number Diff line number Diff line change
Expand Up @@ -272,12 +272,12 @@ type Dhcpv6ClientOptionsDuidUuidVariant interface {
HasChoice() bool
// getter for Ncs to set choice.
Ncs()
// getter for Dce to set choice.
Dce()
// getter for Guid to set choice.
Guid()
// getter for VarReserved to set choice.
VarReserved()
// getter for Dce to set choice.
Dce()
}

type Dhcpv6ClientOptionsDuidUuidVariantChoiceEnum string
Expand All @@ -304,6 +304,11 @@ func (obj *dhcpv6ClientOptionsDuidUuidVariant) Ncs() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVariantChoice.NCS)
}

// getter for Dce to set choice
func (obj *dhcpv6ClientOptionsDuidUuidVariant) Dce() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVariantChoice.DCE)
}

// getter for Guid to set choice
func (obj *dhcpv6ClientOptionsDuidUuidVariant) Guid() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVariantChoice.GUID)
Expand All @@ -314,11 +319,6 @@ func (obj *dhcpv6ClientOptionsDuidUuidVariant) VarReserved() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVariantChoice.VAR_RESERVED)
}

// getter for Dce to set choice
func (obj *dhcpv6ClientOptionsDuidUuidVariant) Dce() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVariantChoice.DCE)
}

// The current variants are ncs, dce,microsoft guid and reserved.
// Choice returns a string
func (obj *dhcpv6ClientOptionsDuidUuidVariant) HasChoice() bool {
Expand Down
24 changes: 12 additions & 12 deletions gosnappi/dhcpv6_client_options_duid_uuid_version.go
Original file line number Diff line number Diff line change
Expand Up @@ -272,14 +272,14 @@ type Dhcpv6ClientOptionsDuidUuidVersion interface {
HasChoice() bool
// getter for V_1 to set choice.
V_1()
// getter for V_2 to set choice.
V_2()
// getter for V_3 to set choice.
V_3()
// getter for V_4 to set choice.
V_4()
// getter for V_5 to set choice.
V_5()
// getter for V_2 to set choice.
V_2()
// getter for V_4 to set choice.
V_4()
}

type Dhcpv6ClientOptionsDuidUuidVersionChoiceEnum string
Expand Down Expand Up @@ -308,24 +308,24 @@ func (obj *dhcpv6ClientOptionsDuidUuidVersion) V_1() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVersionChoice.V_1)
}

// getter for V_2 to set choice
func (obj *dhcpv6ClientOptionsDuidUuidVersion) V_2() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVersionChoice.V_2)
}

// getter for V_3 to set choice
func (obj *dhcpv6ClientOptionsDuidUuidVersion) V_3() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVersionChoice.V_3)
}

// getter for V_4 to set choice
func (obj *dhcpv6ClientOptionsDuidUuidVersion) V_4() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVersionChoice.V_4)
}

// getter for V_5 to set choice
func (obj *dhcpv6ClientOptionsDuidUuidVersion) V_5() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVersionChoice.V_5)
}

// getter for V_2 to set choice
func (obj *dhcpv6ClientOptionsDuidUuidVersion) V_2() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVersionChoice.V_2)
// getter for V_4 to set choice
func (obj *dhcpv6ClientOptionsDuidUuidVersion) V_4() {
obj.setChoice(Dhcpv6ClientOptionsDuidUuidVersionChoice.V_4)
}

// The version values are from 1 to 5 in the most significant 4 bits of the timestamp (bits 4 through 7 of the time_hi_and_version field).
Expand Down
Loading

0 comments on commit 8e6096d

Please sign in to comment.