From 172070fc8573f620b233ae91c55a58bf851ea84d Mon Sep 17 00:00:00 2001 From: Joel Bender Date: Tue, 27 Jul 2021 00:01:57 -0400 Subject: [PATCH] clean up camel case names that should have been hyphenated --- py27/bacpypes/apdu.py | 2 +- py27/bacpypes/basetypes.py | 24 ++++++++++++------------ py27/bacpypes/object.py | 4 ++-- py27/bacpypes/primitivedata.py | 1 + py34/bacpypes/apdu.py | 2 +- py34/bacpypes/basetypes.py | 24 ++++++++++++------------ py34/bacpypes/object.py | 4 ++-- py34/bacpypes/primitivedata.py | 1 + 8 files changed, 32 insertions(+), 30 deletions(-) diff --git a/py27/bacpypes/apdu.py b/py27/bacpypes/apdu.py index b272f3f9..672b2f9e 100755 --- a/py27/bacpypes/apdu.py +++ b/py27/bacpypes/apdu.py @@ -1241,7 +1241,7 @@ class GetEnrollmentSummaryRequestEventStateFilterType(Enumerated): , 'active':4 } -class GetEnrollmentSummaryRequestPriorityFilterType: +class GetEnrollmentSummaryRequestPriorityFilterType(Sequence): sequenceElements = \ [ Element('minPriority', Unsigned, 0) , Element('maxPriority', Unsigned, 1) diff --git a/py27/bacpypes/basetypes.py b/py27/bacpypes/basetypes.py index 6bcaec25..87792f48 100755 --- a/py27/bacpypes/basetypes.py +++ b/py27/bacpypes/basetypes.py @@ -482,8 +482,8 @@ class BinaryLightingPV(Enumerated): { 'off':0 , 'on':1 , 'warn':2 - , 'warn-off':3 - , 'warn-relinquish':4 + , 'warnOff':3 + , 'warnRelinquish':4 , 'stop':5 } @@ -1016,11 +1016,11 @@ class EventType(Enumerated): class FaultType(Enumerated): enumerations = \ { 'none':0 - , 'fault-characterstring':1 - , 'fault-extended':2 - , 'fault-life-safety':3 - , 'fault-state':4 - , 'fault-status-flags':5 + , 'faultCharacterstring':1 + , 'faultExtended':2 + , 'faultLifeSafety':3 + , 'faultState':4 + , 'faultStatusFlags':5 } class FileAccessMethod(Enumerated): @@ -1831,7 +1831,7 @@ class Reliability(Enumerated): , 'lampFailure': 16 , 'activationFailure': 17 , 'renewDHCPFailure': 18 - , 'renewFDRegistration-failure': 19 + , 'renewFDRegistrationFailure': 19 , 'restartAutoNegotiationFailure': 20 , 'restartFailure': 21 , 'proprietaryCommandFailure': 22 @@ -1918,12 +1918,12 @@ class VTClass(Enumerated): vendor_range = (64, 65535) enumerations = \ { 'defaultTerminal':0 - , 'ansiX3-64':1 + , 'ansiX364':1 , 'decVt52':2 , 'decVt100':3 , 'decVt220':4 - , 'hp-700-94':5 - , 'ibm-3130':6 + , 'hp70094':5 + , 'ibm3130':6 } class WriteStatus(Enumerated): @@ -3187,7 +3187,7 @@ class ValueSource(Choice): choiceElements = \ [ Element('none', Null, 0) , Element('object', DeviceObjectReference, 1) - , Element('Address', Address) + , Element('address', Address, 2) ] diff --git a/py27/bacpypes/object.py b/py27/bacpypes/object.py index b14941d1..8feeb818 100755 --- a/py27/bacpypes/object.py +++ b/py27/bacpypes/object.py @@ -1109,7 +1109,7 @@ class AnalogValueObject(Object): @register_object_type class AuditLogObject(Object): - objectType = 'analogLog' + objectType = 'auditLog' properties = \ [ ReadableProperty('statusFlags', StatusFlags) @@ -1217,7 +1217,7 @@ class BinaryInputObject(Object): @register_object_type class BinaryLightingOutputObject(Object): - objectType = 'binaryLightingOutputObject' + objectType = 'binaryLightingOutput' properties = \ [ WritableProperty('presentValue', BinaryLightingPV) diff --git a/py27/bacpypes/primitivedata.py b/py27/bacpypes/primitivedata.py index 8921ac6f..a659a2ce 100755 --- a/py27/bacpypes/primitivedata.py +++ b/py27/bacpypes/primitivedata.py @@ -1714,6 +1714,7 @@ class ObjectType(Enumerated): , 'program':16 , 'pulseConverter':24 , 'schedule':17 + , 'staging':60 , 'structuredView':29 , 'timePatternValue':49 , 'timeValue':50 diff --git a/py34/bacpypes/apdu.py b/py34/bacpypes/apdu.py index b272f3f9..672b2f9e 100755 --- a/py34/bacpypes/apdu.py +++ b/py34/bacpypes/apdu.py @@ -1241,7 +1241,7 @@ class GetEnrollmentSummaryRequestEventStateFilterType(Enumerated): , 'active':4 } -class GetEnrollmentSummaryRequestPriorityFilterType: +class GetEnrollmentSummaryRequestPriorityFilterType(Sequence): sequenceElements = \ [ Element('minPriority', Unsigned, 0) , Element('maxPriority', Unsigned, 1) diff --git a/py34/bacpypes/basetypes.py b/py34/bacpypes/basetypes.py index 6bcaec25..87792f48 100755 --- a/py34/bacpypes/basetypes.py +++ b/py34/bacpypes/basetypes.py @@ -482,8 +482,8 @@ class BinaryLightingPV(Enumerated): { 'off':0 , 'on':1 , 'warn':2 - , 'warn-off':3 - , 'warn-relinquish':4 + , 'warnOff':3 + , 'warnRelinquish':4 , 'stop':5 } @@ -1016,11 +1016,11 @@ class EventType(Enumerated): class FaultType(Enumerated): enumerations = \ { 'none':0 - , 'fault-characterstring':1 - , 'fault-extended':2 - , 'fault-life-safety':3 - , 'fault-state':4 - , 'fault-status-flags':5 + , 'faultCharacterstring':1 + , 'faultExtended':2 + , 'faultLifeSafety':3 + , 'faultState':4 + , 'faultStatusFlags':5 } class FileAccessMethod(Enumerated): @@ -1831,7 +1831,7 @@ class Reliability(Enumerated): , 'lampFailure': 16 , 'activationFailure': 17 , 'renewDHCPFailure': 18 - , 'renewFDRegistration-failure': 19 + , 'renewFDRegistrationFailure': 19 , 'restartAutoNegotiationFailure': 20 , 'restartFailure': 21 , 'proprietaryCommandFailure': 22 @@ -1918,12 +1918,12 @@ class VTClass(Enumerated): vendor_range = (64, 65535) enumerations = \ { 'defaultTerminal':0 - , 'ansiX3-64':1 + , 'ansiX364':1 , 'decVt52':2 , 'decVt100':3 , 'decVt220':4 - , 'hp-700-94':5 - , 'ibm-3130':6 + , 'hp70094':5 + , 'ibm3130':6 } class WriteStatus(Enumerated): @@ -3187,7 +3187,7 @@ class ValueSource(Choice): choiceElements = \ [ Element('none', Null, 0) , Element('object', DeviceObjectReference, 1) - , Element('Address', Address) + , Element('address', Address, 2) ] diff --git a/py34/bacpypes/object.py b/py34/bacpypes/object.py index 5c53d141..5a142088 100644 --- a/py34/bacpypes/object.py +++ b/py34/bacpypes/object.py @@ -1109,7 +1109,7 @@ class AnalogValueObject(Object): @register_object_type class AuditLogObject(Object): - objectType = 'analogLog' + objectType = 'auditLog' properties = \ [ ReadableProperty('statusFlags', StatusFlags) @@ -1217,7 +1217,7 @@ class BinaryInputObject(Object): @register_object_type class BinaryLightingOutputObject(Object): - objectType = 'binaryLightingOutputObject' + objectType = 'binaryLightingOutput' properties = \ [ WritableProperty('presentValue', BinaryLightingPV) diff --git a/py34/bacpypes/primitivedata.py b/py34/bacpypes/primitivedata.py index 32f6a146..bf94bca2 100755 --- a/py34/bacpypes/primitivedata.py +++ b/py34/bacpypes/primitivedata.py @@ -1696,6 +1696,7 @@ class ObjectType(Enumerated): , 'program':16 , 'pulseConverter':24 , 'schedule':17 + , 'staging':60 , 'structuredView':29 , 'timePatternValue':49 , 'timeValue':50