blob: bfcf8b2c0109da3325852aaeb6ff0d0a3e2fc00a [file] [log] [blame]
Matteo Scandoloa6a3aee2019-11-26 13:30:14 -07001/*
2 * Copyright (c) 2018 - present. Boling Consulting Solutions (bcsw.net)
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 * http://www.apache.org/licenses/LICENSE-2.0
8 * Unless required by applicable law or agreed to in writing, software
9 * distributed under the License is distributed on an "AS IS" BASIS,
10 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 * See the License for the specific language governing permissions and
12 * limitations under the License.
13 */
14/*
15 * NOTE: This file was generated, manual edits will be overwritten!
16 *
17 * Generated by 'goCodeGenerator.py':
18 * https://github.com/cboling/OMCI-parser/README.md
19 */
20package generated
21
22import "github.com/deckarep/golang-set"
23
24const MacBridgePortDesignationDataClassId ClassID = ClassID(48)
25
26var macbridgeportdesignationdataBME *ManagedEntityDefinition
27
28// MacBridgePortDesignationData (class ID #48)
29// This ME records data associated with a bridge port. The ONU automatically creates or deletes an
30// instance of this managed entity upon the creation or deletion of a MAC bridge port configuration
31// data ME.
32//
33// Relationships
34// An instance of this managed entity is associated with one MAC bridge port configuration data ME.
35//
36// Attributes
37// Managed Entity Id
38// Managed entity ID: This attribute uniquely identifies each instance of this ME. Through an
39// identical ID, this ME is implicitly linked to an instance of the MAC bridge port configuration
40// data. (R) (mandatory) (2 bytes)
41//
42// Designated Bridge Root Cost Port
43// Upon ME instantiation, the ONU sets this attribute to 0. (R) (mandatory) (24 bytes)
44//
45// Port State
46// The value (R)stp_off is introduced to denote the port status where the (rapid) spanning tree
47// protocol has been disabled by setting the port spanning tree ind attribute of the MAC bridge
48// port configuration data to false, and the Ethernet link state is up. This value distinguishes
49// whether frame forwarding is under the control of (R)STP.
50//
51type MacBridgePortDesignationData struct {
52 ManagedEntityDefinition
53 Attributes AttributeValueMap
54}
55
56func init() {
57 macbridgeportdesignationdataBME = &ManagedEntityDefinition{
58 Name: "MacBridgePortDesignationData",
59 ClassID: 48,
60 MessageTypes: mapset.NewSetWith(
61 Get,
62 ),
63 AllowedAttributeMask: 0XC000,
64 AttributeDefinitions: AttributeDefinitionMap{
65 0: Uint16Field("ManagedEntityId", 0, mapset.NewSetWith(Read), false, false, false, false, 0),
66 1: MultiByteField("DesignatedBridgeRootCostPort", 24, nil, mapset.NewSetWith(Read), false, false, false, false, 1),
67 2: ByteField("PortState", 0, mapset.NewSetWith(Read), false, false, false, false, 2),
68 },
69 }
70}
71
72// NewMacBridgePortDesignationData (class ID 48 creates the basic
73// Managed Entity definition that is used to validate an ME of this type that
74// is received from the wire, about to be sent on the wire.
75func NewMacBridgePortDesignationData(params ...ParamData) (*ManagedEntity, OmciErrors) {
76 return NewManagedEntity(macbridgeportdesignationdataBME, params...)
77}