blob: a1be9fbb0e35bd071e1d3d3200abdcdd67840417 [file] [log] [blame]
Chip Boling610117d2021-09-09 11:24:34 -05001/*
2 * Copyright (c) 2018 - present. Boling Consulting Solutions (bcsw.net)
3 * Copyright 2020-present Open Networking Foundation
Chip Boling8cdd6392022-01-27 08:43:37 -06004 *
Chip Boling610117d2021-09-09 11:24:34 -05005 * 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
Chip Boling8cdd6392022-01-27 08:43:37 -06008 *
Chip Boling610117d2021-09-09 11:24:34 -05009 * http://www.apache.org/licenses/LICENSE-2.0
Chip Boling8cdd6392022-01-27 08:43:37 -060010 *
Chip Boling610117d2021-09-09 11:24:34 -050011 * 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 */
17/*
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
24package generated
25
26import "github.com/deckarep/golang-set"
27
28// EponDownstreamPerformanceMonitoringConfigurationClassID is the 16-bit ID for the OMCI
29// Managed entity EPON downstream performance monitoring configuration
30const EponDownstreamPerformanceMonitoringConfigurationClassID = ClassID(406) // 0x0196
31
32var epondownstreamperformancemonitoringconfigurationBME *ManagedEntityDefinition
33
34// EponDownstreamPerformanceMonitoringConfiguration (Class ID: #406 / 0x0196)
35// This ME represents window sizes and threshold values for EPON downstream PM operations which are
36// defined in [IEEE 802.3] as: errored symbol period, errored frame, errored frame period and
37// errored frame seconds summary.
38//
39// The EPON ONU automatically instantiates an instance of this ME for each ANI-E.
40//
41// Relationships
42// An instance of this ME is associated with an ANI-E.
43//
44// Attributes
45// Managed Entity Id
46// This attribute uniquely identifies each instance of this ME. Through an identical ID, this ME is
47// implicitly linked to an instance of the ANI-E. (R, set-by-create) (mandatory) (2-bytes)
48//
49// Errored Symbol Period Window
50// This attribute specifies the number of symbols in the measurement period, as defined in clause
51// 57.5.3.1 of [IEEE 802.3]. (R, W) (optional) (8-bytes)
52//
53// Errored Symbol Period Threshold
54// This attribute specifies the threshold of errored symbols for generating an event report, as
55// defined in clause 57.5.3.1 of [IEEE 802.3]. (R, W) (optional) (8-bytes)
56//
57// Errored Frame Window
58// This attribute specifies the duration in units of 100-ms of the measurement period, as defined
59// in clause 57.5.3.2 of [IEEE 802.3]. (R, W) (optional) (2-bytes)
60//
61// Errored Frame Threshold
62// This attribute specifies the threshold of errored frames for generating an event report, as
63// defined in clause 57.5.3.2 of [IEEE 802.3]. (R, W) (optional) (4-bytes)
64//
65// Errored Frame Period Window
66// This attribute specifies the duration in terms of frames of the measurement period, as defined
67// in clause 57.5.3.3 of [IEEE 802.3]. (R, W) (optional) (4-bytes)
68//
69// Errored Frame Period Threshold
70// This attribute specifies the threshold of errored frames for generating an event report, as
71// defined in clause 57.5.3.3 of [IEEE 802.3]. (R, W) (optional) (4-bytes)
72//
73// Errored Frame Seconds Summary Window
74// This attribute specifies the duration in units of 100ms of the measurement period, as defined in
75// clause-57.5.3.4 of [IEEE-802.3]. (R, W) (optional) (2-bytes)
76//
77// Errored Frame Seconds Summary Threshold
78// This attribute specifies the threshold of errored frame seconds for generating an event report,
79// as defined in clause 57.5.3.4 of [IEEE 802.3]. (R, W) (optional) (2-bytes)
80//
81type EponDownstreamPerformanceMonitoringConfiguration struct {
82 ManagedEntityDefinition
83 Attributes AttributeValueMap
84}
85
Chip Boling8cdd6392022-01-27 08:43:37 -060086// Attribute name constants
87
88const EponDownstreamPerformanceMonitoringConfiguration_ErroredSymbolPeriodWindow = "ErroredSymbolPeriodWindow"
89const EponDownstreamPerformanceMonitoringConfiguration_ErroredSymbolPeriodThreshold = "ErroredSymbolPeriodThreshold"
90const EponDownstreamPerformanceMonitoringConfiguration_ErroredFrameWindow = "ErroredFrameWindow"
91const EponDownstreamPerformanceMonitoringConfiguration_ErroredFrameThreshold = "ErroredFrameThreshold"
92const EponDownstreamPerformanceMonitoringConfiguration_ErroredFramePeriodWindow = "ErroredFramePeriodWindow"
93const EponDownstreamPerformanceMonitoringConfiguration_ErroredFramePeriodThreshold = "ErroredFramePeriodThreshold"
94const EponDownstreamPerformanceMonitoringConfiguration_ErroredFrameSecondsSummaryWindow = "ErroredFrameSecondsSummaryWindow"
95const EponDownstreamPerformanceMonitoringConfiguration_ErroredFrameSecondsSummaryThreshold = "ErroredFrameSecondsSummaryThreshold"
96
Chip Boling610117d2021-09-09 11:24:34 -050097func init() {
98 epondownstreamperformancemonitoringconfigurationBME = &ManagedEntityDefinition{
99 Name: "EponDownstreamPerformanceMonitoringConfiguration",
Chip Boling8cdd6392022-01-27 08:43:37 -0600100 ClassID: EponDownstreamPerformanceMonitoringConfigurationClassID,
Chip Boling610117d2021-09-09 11:24:34 -0500101 MessageTypes: mapset.NewSetWith(
102 Get,
103 Set,
104 ),
105 AllowedAttributeMask: 0xff00,
106 AttributeDefinitions: AttributeDefinitionMap{
Chip Boling8cdd6392022-01-27 08:43:37 -0600107 0: Uint16Field(ManagedEntityID, PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read, SetByCreate), false, false, false, 0),
108 1: Uint64Field(EponDownstreamPerformanceMonitoringConfiguration_ErroredSymbolPeriodWindow, UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read, Write), false, true, false, 1),
109 2: Uint64Field(EponDownstreamPerformanceMonitoringConfiguration_ErroredSymbolPeriodThreshold, UnsignedIntegerAttributeType, 0x4000, 0, mapset.NewSetWith(Read, Write), false, true, false, 2),
110 3: Uint16Field(EponDownstreamPerformanceMonitoringConfiguration_ErroredFrameWindow, UnsignedIntegerAttributeType, 0x2000, 0, mapset.NewSetWith(Read, Write), false, true, false, 3),
111 4: Uint32Field(EponDownstreamPerformanceMonitoringConfiguration_ErroredFrameThreshold, UnsignedIntegerAttributeType, 0x1000, 0, mapset.NewSetWith(Read, Write), false, true, false, 4),
112 5: Uint32Field(EponDownstreamPerformanceMonitoringConfiguration_ErroredFramePeriodWindow, UnsignedIntegerAttributeType, 0x0800, 0, mapset.NewSetWith(Read, Write), false, true, false, 5),
113 6: Uint32Field(EponDownstreamPerformanceMonitoringConfiguration_ErroredFramePeriodThreshold, UnsignedIntegerAttributeType, 0x0400, 0, mapset.NewSetWith(Read, Write), false, true, false, 6),
114 7: Uint16Field(EponDownstreamPerformanceMonitoringConfiguration_ErroredFrameSecondsSummaryWindow, UnsignedIntegerAttributeType, 0x0200, 0, mapset.NewSetWith(Read, Write), false, true, false, 7),
115 8: Uint16Field(EponDownstreamPerformanceMonitoringConfiguration_ErroredFrameSecondsSummaryThreshold, UnsignedIntegerAttributeType, 0x0100, 0, mapset.NewSetWith(Read, Write), false, true, false, 8),
Chip Boling610117d2021-09-09 11:24:34 -0500116 },
117 Access: CreatedByOnu,
118 Support: UnknownSupport,
119 }
120}
121
122// NewEponDownstreamPerformanceMonitoringConfiguration (class ID 406) creates the basic
123// Managed Entity definition that is used to validate an ME of this type that
124// is received from or transmitted to the OMCC.
125func NewEponDownstreamPerformanceMonitoringConfiguration(params ...ParamData) (*ManagedEntity, OmciErrors) {
126 return NewManagedEntity(*epondownstreamperformancemonitoringconfigurationBME, params...)
127}