blob: c2e45394e409cccf5ebfc5745c332a800be14928 [file] [log] [blame]
Chip Boling6e27b352020-02-14 09:10:01 -06001/*
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 */
20
21package generated
22
23import "github.com/deckarep/golang-set"
24
25// EfmBondingLinkClassID is the 16-bit ID for the OMCI
26// Managed entity EFM bonding link
27const EfmBondingLinkClassID ClassID = ClassID(420)
28
29var efmbondinglinkBME *ManagedEntityDefinition
30
31// EfmBondingLink (class ID #420)
32// The EFM bonding link represents a link that can be bonded with other links to form a group. In
33// [IEEE 802.3], a bonding group is known as a PAF and a link is known as a PME. Instances of this
34// ME are created and deleted by the OLT.
35//
36// Relationships
37// An instance of this ME may be associated with zero or one instance of an EFM bonding group.
38//
39// Attributes
40// Managed Entity Id
41// NOTE - This attribute has the same meaning as the Stream ID in clause C.3.1.2 of [ITU-T
42// G.998.2], except that it cannot be changed. (R, setbycreate) (mandatory) (2-bytes)
43//
44// Associated Group Me Id
45// Associated group ME ID: This attribute is the ME ID of the bonding group to which this link is
46// associated. Changing this attribute moves the link from one group to another. Setting this
47// attribute to an ME ID that has not yet been provisioned will result in this link being placed in
48// a single-link group that contains only this link. The default value for this attribute is the
49// null pointer, 0xFFFF. (R,-W, setbycreate) (mandatory) (2-bytes)
50//
51// Link Alarm Enable
52// (R,-W, setbycreate) (mandatory) (1-bytes)
53//
54type EfmBondingLink struct {
55 ManagedEntityDefinition
56 Attributes AttributeValueMap
57}
58
59func init() {
60 efmbondinglinkBME = &ManagedEntityDefinition{
61 Name: "EfmBondingLink",
62 ClassID: 420,
63 MessageTypes: mapset.NewSetWith(
64 Create,
65 Delete,
66 Get,
67 Set,
68 ),
69 AllowedAttributeMask: 0xc000,
70 AttributeDefinitions: AttributeDefinitionMap{
71 0: Uint16Field("ManagedEntityId", PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read, SetByCreate), false, false, false, 0),
72 1: Uint16Field("AssociatedGroupMeId", UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read, SetByCreate, Write), false, false, false, 1),
73 2: ByteField("LinkAlarmEnable", UnsignedIntegerAttributeType, 0x4000, 0, mapset.NewSetWith(Read, SetByCreate, Write), false, false, false, 2),
74 },
75 Access: CreatedByOlt,
76 Support: UnknownSupport,
77 }
78}
79
80// NewEfmBondingLink (class ID 420) creates the basic
81// Managed Entity definition that is used to validate an ME of this type that
82// is received from or transmitted to the OMCC.
83func NewEfmBondingLink(params ...ParamData) (*ManagedEntity, OmciErrors) {
84 return NewManagedEntity(*efmbondinglinkBME, params...)
85}