blob: 2420670f9fd9aaac59ad1d2765b24b1797cf15db [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// MacBridgePerformanceMonitoringHistoryDataClassID is the 16-bit ID for the OMCI
26// Managed entity MAC bridge performance monitoring history data
27const MacBridgePerformanceMonitoringHistoryDataClassID ClassID = ClassID(51)
28
29var macbridgeperformancemonitoringhistorydataBME *ManagedEntityDefinition
30
31// MacBridgePerformanceMonitoringHistoryData (class ID #51)
32// This ME collects PM data associated with a MAC bridge. Instances of this ME are created and
33// deleted by the OLT.
34//
35// For a complete discussion of generic PM architecture, refer to clause I.4.
36//
37// Relationships
38// This ME is associated with an instance of a MAC bridge service profile.
39//
40// Attributes
41// Managed Entity Id
42// Managed entity ID: This attribute uniquely identifies each instance of this ME. Through an
43// identical ID, this ME is implicitly linked to an instance of the MAC bridge service profile. (R,
44// setbycreate) (mandatory) (2-bytes)
45//
46// Interval End Time
47// Interval end time: This attribute identifies the most recently finished 15-min interval. (R)
48// (mandatory) (1-byte)
49//
50// Threshold Data 1_2 Id
51// Threshold data 1/2 ID: This attribute points to an instance of the threshold data 1 ME that
52// contains PM threshold values. Since no threshold value attribute number exceeds 7, a threshold
53// data 2 ME is optional. Since no threshold value attribute number exceeds 7, a threshold data 2
54// ME is optional. (R,-W, setbycreate) (mandatory) (2-bytes)
55//
56// Bridge Learning Entry Discard Count
57// Bridge learning entry discard count: This attribute counts forwarding database entries that have
58// been or would have been learned, but were discarded or replaced due to a lack of space in the
59// database table. When used with the MAC learning depth attribute of the MAC bridge service
60// profile, the bridge learning entry discard count may be particularly useful in detecting MAC
61// spoofing attempts. (R) (mandatory) (4-bytes)
62//
63type MacBridgePerformanceMonitoringHistoryData struct {
64 ManagedEntityDefinition
65 Attributes AttributeValueMap
66}
67
68func init() {
69 macbridgeperformancemonitoringhistorydataBME = &ManagedEntityDefinition{
70 Name: "MacBridgePerformanceMonitoringHistoryData",
71 ClassID: 51,
72 MessageTypes: mapset.NewSetWith(
73 Create,
74 Delete,
75 Get,
76 Set,
77 ),
78 AllowedAttributeMask: 0xe000,
79 AttributeDefinitions: AttributeDefinitionMap{
80 0: Uint16Field("ManagedEntityId", PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read, SetByCreate), false, false, false, 0),
81 1: ByteField("IntervalEndTime", UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read), false, false, false, 1),
82 2: Uint16Field("ThresholdData12Id", PointerAttributeType, 0x4000, 0, mapset.NewSetWith(Read, SetByCreate, Write), false, false, false, 2),
83 3: Uint32Field("BridgeLearningEntryDiscardCount", CounterAttributeType, 0x2000, 0, mapset.NewSetWith(Read), false, false, false, 3),
84 },
85 Access: CreatedByOlt,
86 Support: UnknownSupport,
87 }
88}
89
90// NewMacBridgePerformanceMonitoringHistoryData (class ID 51) creates the basic
91// Managed Entity definition that is used to validate an ME of this type that
92// is received from or transmitted to the OMCC.
93func NewMacBridgePerformanceMonitoringHistoryData(params ...ParamData) (*ManagedEntity, OmciErrors) {
94 return NewManagedEntity(*macbridgeperformancemonitoringhistorydataBME, params...)
95}