blob: d48e2522f59ff147ca38cef6e769017b5ae9fa7f [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// MgcPerformanceMonitoringHistoryDataClassID is the 16-bit ID for the OMCI
26// Managed entity MGC performance monitoring history data
27const MgcPerformanceMonitoringHistoryDataClassID ClassID = ClassID(156)
28
29var mgcperformancemonitoringhistorydataBME *ManagedEntityDefinition
30
31// MgcPerformanceMonitoringHistoryData (class ID #156)
32// The MGC monitoring data ME provides run-time statistics for an active MGC association. Instances
33// of this ME are created and deleted by the OLT.
34//
35// For a complete discussion of generic PM architecture, refer to clause I.4.
36//
37// Relationships
38// An instance of this ME is associated with an instance of the MGC config data or MGC config
39// portal ME.
40//
41// Attributes
42// Managed Entity Id
43// Managed entity ID: This attribute uniquely identifies each instance of this ME. Through an
44// identical ID, this ME is implicitly linked to an instance of the associated MGC config data or
45// to the MGC config portal ME. If a non-OMCI configuration method is used for VoIP, there can be
46// only one live ME instance, associated with the MGC config portal, and with ME ID 0. (R,
47// setbycreate) (mandatory) (2-bytes)
48//
49// Interval End Time
50// Interval end time: This attribute identifies the most recently finished 15-min interval. (R)
51// (mandatory) (1-byte)
52//
53// Threshold Data 1_2 Id
54// Threshold data 1/2 ID: This attribute points to an instance of the threshold data 1 ME that
55// contains PM threshold values. Since no threshold value attribute number exceeds 7, a threshold
56// data 2 ME is optional. (R,-W, setbycreate) (mandatory) (2-bytes)
57//
58// Received Messages
59// Received messages: This attribute counts the number of received Megaco messages on this
60// association, as defined by [ITUT H.341]. (R) (mandatory) (4-bytes)
61//
62// Received Octets
63// Received octets: This attribute counts the total number of octets received on this association,
64// as defined by [ITU-T H.341]. (R) (mandatory) (4-bytes)
65//
66// Sent Messages
67// Sent messages: This attribute counts the total number of Megaco messages sent over this
68// association, as defined by [ITU-T H.341]. (R) (mandatory) (4-bytes)
69//
70// Sent Octets
71// Sent octets: This attribute counts the total number of octets sent over this association, as
72// defined by [ITU-T H.341]. (R) (mandatory) (4-bytes)
73//
74// Protocol Errors
75// (R) (mandatory) (4-bytes)
76//
77// Transport Losses
78// Transport losses: This attribute counts the total number of transport losses (e.g., socket
79// problems) detected on this association. A link loss is defined as loss of communication with the
80// remote entity due to hardware/transient problems, or problems in related software. (R)
81// (mandatory) (4-bytes)
82//
83// Last Detected Event
84// (R) (mandatory) (1-byte)
85//
86// Last Detected Event Time
87// Last detected event time: This attribute reports the time in seconds since the last event on
88// this association was detected, as defined by [ITU-T H.341]. (R) (mandatory) (4-bytes)
89//
90// Last Detected Reset Time
91// Last detected reset time: This attribute reports the time in seconds since these statistics were
92// last reset, as defined by [ITU-T H.341]. Under normal circumstances, a get action on this
93// attribute would return 900-s to indicate a completed 15-min interval. (R) (mandatory) (4-bytes)
94//
95type MgcPerformanceMonitoringHistoryData struct {
96 ManagedEntityDefinition
97 Attributes AttributeValueMap
98}
99
100func init() {
101 mgcperformancemonitoringhistorydataBME = &ManagedEntityDefinition{
102 Name: "MgcPerformanceMonitoringHistoryData",
103 ClassID: 156,
104 MessageTypes: mapset.NewSetWith(
105 Create,
106 Delete,
107 Get,
108 Set,
109 ),
110 AllowedAttributeMask: 0xffe0,
111 AttributeDefinitions: AttributeDefinitionMap{
112 0: Uint16Field("ManagedEntityId", PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read, SetByCreate), false, false, false, 0),
113 1: ByteField("IntervalEndTime", UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read), false, false, false, 1),
114 2: Uint16Field("ThresholdData12Id", UnsignedIntegerAttributeType, 0x4000, 0, mapset.NewSetWith(Read, SetByCreate, Write), false, false, false, 2),
115 3: Uint32Field("ReceivedMessages", CounterAttributeType, 0x2000, 0, mapset.NewSetWith(Read), false, false, false, 3),
116 4: Uint32Field("ReceivedOctets", CounterAttributeType, 0x1000, 0, mapset.NewSetWith(Read), false, false, false, 4),
117 5: Uint32Field("SentMessages", CounterAttributeType, 0x0800, 0, mapset.NewSetWith(Read), false, false, false, 5),
118 6: Uint32Field("SentOctets", CounterAttributeType, 0x0400, 0, mapset.NewSetWith(Read), false, false, false, 6),
119 7: Uint32Field("ProtocolErrors", CounterAttributeType, 0x0200, 0, mapset.NewSetWith(Read), false, false, false, 7),
120 8: Uint32Field("TransportLosses", CounterAttributeType, 0x0100, 0, mapset.NewSetWith(Read), false, false, false, 8),
121 9: ByteField("LastDetectedEvent", CounterAttributeType, 0x0080, 0, mapset.NewSetWith(Read), false, false, false, 9),
122 10: Uint32Field("LastDetectedEventTime", CounterAttributeType, 0x0040, 0, mapset.NewSetWith(Read), false, false, false, 10),
123 11: Uint32Field("LastDetectedResetTime", CounterAttributeType, 0x0020, 0, mapset.NewSetWith(Read), false, false, false, 11),
124 },
125 Access: CreatedByOlt,
126 Support: UnknownSupport,
127 }
128}
129
130// NewMgcPerformanceMonitoringHistoryData (class ID 156) creates the basic
131// Managed Entity definition that is used to validate an ME of this type that
132// is received from or transmitted to the OMCC.
133func NewMgcPerformanceMonitoringHistoryData(params ...ParamData) (*ManagedEntity, OmciErrors) {
134 return NewManagedEntity(*mgcperformancemonitoringhistorydataBME, params...)
135}