Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2018 - present. Boling Consulting Solutions (bcsw.net) |
Andrea Campanella | 7167ebb | 2020-02-24 09:56:38 +0100 | [diff] [blame] | 3 | * Copyright 2020-present Open Networking Foundation |
| 4 | |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 5 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | * you may not use this file except in compliance with the License. |
| 7 | * You may obtain a copy of the License at |
Andrea Campanella | 7167ebb | 2020-02-24 09:56:38 +0100 | [diff] [blame] | 8 | |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 9 | * http://www.apache.org/licenses/LICENSE-2.0 |
Andrea Campanella | 7167ebb | 2020-02-24 09:56:38 +0100 | [diff] [blame] | 10 | |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 11 | * Unless required by applicable law or agreed to in writing, software |
| 12 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | * See the License for the specific language governing permissions and |
| 15 | * limitations under the License. |
| 16 | */ |
Chip Boling | 34ebcb6 | 2021-02-02 12:13:58 -0600 | [diff] [blame] | 17 | /* |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 18 | * NOTE: This file was generated, manual edits will be overwritten! |
| 19 | * |
| 20 | * Generated by 'goCodeGenerator.py': |
| 21 | * https://github.com/cboling/OMCI-parser/README.md |
| 22 | */ |
| 23 | |
| 24 | package generated |
| 25 | |
| 26 | import "github.com/deckarep/golang-set" |
| 27 | |
| 28 | // EfmBondingLinkClassID is the 16-bit ID for the OMCI |
| 29 | // Managed entity EFM bonding link |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 30 | const EfmBondingLinkClassID = ClassID(419) // 0x01a3 |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 31 | |
| 32 | var efmbondinglinkBME *ManagedEntityDefinition |
| 33 | |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 34 | // EfmBondingLink (Class ID: #419 / 0x01a3) |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 35 | // The EFM bonding link represents a link that can be bonded with other links to form a group. In |
| 36 | // [IEEE 802.3], a bonding group is known as a PAF and a link is known as a PME. Instances of this |
| 37 | // ME are created and deleted by the OLT. |
| 38 | // |
| 39 | // Relationships |
| 40 | // An instance of this ME may be associated with zero or one instance of an EFM bonding group. |
| 41 | // |
| 42 | // Attributes |
| 43 | // Managed Entity Id |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 44 | // This attribute uniquely identifies each instance of this ME. The two MSBs of the first byte are |
| 45 | // the bearer channel ID. Excluding the first 2-bits of the first byte, the remaining part of the |
| 46 | // ME ID is identical to that of this ME's parent PPTP xDSL UNI part 1. |
| 47 | // |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 48 | // NOTE - This attribute has the same meaning as the Stream ID in clause C.3.1.2 of [ITU-T |
| 49 | // G.998.2], except that it cannot be changed. (R, setbycreate) (mandatory) (2-bytes) |
| 50 | // |
| 51 | // Associated Group Me Id |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 52 | // This attribute is the ME ID of the bonding group to which this link is associated. Changing this |
| 53 | // attribute moves the link from one group to another. Setting this attribute to an ME ID that has |
| 54 | // not yet been provisioned will result in this link being placed in a single-link group that |
| 55 | // contains only this link. The default value for this attribute is the null pointer, 0xFFFF. |
| 56 | // (R,-W, setbycreate) (mandatory) (2-bytes) |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 57 | // |
| 58 | // Link Alarm Enable |
Chip Boling | 610117d | 2021-09-09 11:24:34 -0500 | [diff] [blame] | 59 | // This bit mapped attribute enables the group down and group partial alarms. A bit value of 1 |
| 60 | // means "enable". |
| 61 | // |
| 62 | // Bit Meaning |
| 63 | // |
| 64 | // 1 (LSB) Link down |
| 65 | // |
| 66 | // 2-8 Reserved |
| 67 | // |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 68 | // (R,-W, setbycreate) (mandatory) (1-bytes) |
| 69 | // |
| 70 | type EfmBondingLink struct { |
| 71 | ManagedEntityDefinition |
| 72 | Attributes AttributeValueMap |
| 73 | } |
| 74 | |
| 75 | func init() { |
| 76 | efmbondinglinkBME = &ManagedEntityDefinition{ |
| 77 | Name: "EfmBondingLink", |
Chip Boling | 7a6e8d9 | 2021-07-14 15:42:21 -0500 | [diff] [blame] | 78 | ClassID: 419, |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 79 | MessageTypes: mapset.NewSetWith( |
| 80 | Create, |
| 81 | Delete, |
| 82 | Get, |
| 83 | Set, |
| 84 | ), |
| 85 | AllowedAttributeMask: 0xc000, |
| 86 | AttributeDefinitions: AttributeDefinitionMap{ |
| 87 | 0: Uint16Field("ManagedEntityId", PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read, SetByCreate), false, false, false, 0), |
| 88 | 1: Uint16Field("AssociatedGroupMeId", UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read, SetByCreate, Write), false, false, false, 1), |
| 89 | 2: ByteField("LinkAlarmEnable", UnsignedIntegerAttributeType, 0x4000, 0, mapset.NewSetWith(Read, SetByCreate, Write), false, false, false, 2), |
| 90 | }, |
| 91 | Access: CreatedByOlt, |
| 92 | Support: UnknownSupport, |
Chip Boling | 34ebcb6 | 2021-02-02 12:13:58 -0600 | [diff] [blame] | 93 | Alarms: AlarmMap{ |
| 94 | 0: "Link down", |
| 95 | }, |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 96 | } |
| 97 | } |
| 98 | |
Chip Boling | 7a6e8d9 | 2021-07-14 15:42:21 -0500 | [diff] [blame] | 99 | // NewEfmBondingLink (class ID 419) creates the basic |
Chip Boling | 6e27b35 | 2020-02-14 09:10:01 -0600 | [diff] [blame] | 100 | // Managed Entity definition that is used to validate an ME of this type that |
| 101 | // is received from or transmitted to the OMCC. |
| 102 | func NewEfmBondingLink(params ...ParamData) (*ManagedEntity, OmciErrors) { |
| 103 | return NewManagedEntity(*efmbondinglinkBME, params...) |
| 104 | } |