@@ 5997-6067 (lines=71) @@ | ||
5994 | __repr__ = __str__ |
|
5995 | ||
5996 | ||
5997 | class BrowseDescription(FrozenClass): |
|
5998 | ''' |
|
5999 | A request to browse the the references from a node. |
|
6000 | ||
6001 | :ivar NodeId: |
|
6002 | :vartype NodeId: NodeId |
|
6003 | :ivar BrowseDirection: |
|
6004 | :vartype BrowseDirection: BrowseDirection |
|
6005 | :ivar ReferenceTypeId: |
|
6006 | :vartype ReferenceTypeId: NodeId |
|
6007 | :ivar IncludeSubtypes: |
|
6008 | :vartype IncludeSubtypes: Boolean |
|
6009 | :ivar NodeClassMask: |
|
6010 | :vartype NodeClassMask: UInt32 |
|
6011 | :ivar ResultMask: |
|
6012 | :vartype ResultMask: UInt32 |
|
6013 | ''' |
|
6014 | ||
6015 | ua_types = { |
|
6016 | 'NodeId': 'NodeId', |
|
6017 | 'BrowseDirection': 'BrowseDirection', |
|
6018 | 'ReferenceTypeId': 'NodeId', |
|
6019 | 'IncludeSubtypes': 'Boolean', |
|
6020 | 'NodeClassMask': 'UInt32', |
|
6021 | 'ResultMask': 'UInt32', |
|
6022 | } |
|
6023 | ||
6024 | def __init__(self, binary=None): |
|
6025 | if binary is not None: |
|
6026 | self._binary_init(binary) |
|
6027 | self._freeze = True |
|
6028 | return |
|
6029 | self.NodeId = NodeId() |
|
6030 | self.BrowseDirection = BrowseDirection(0) |
|
6031 | self.ReferenceTypeId = NodeId() |
|
6032 | self.IncludeSubtypes = True |
|
6033 | self.NodeClassMask = 0 |
|
6034 | self.ResultMask = 0 |
|
6035 | self._freeze = True |
|
6036 | ||
6037 | def to_binary(self): |
|
6038 | packet = [] |
|
6039 | packet.append(self.NodeId.to_binary()) |
|
6040 | packet.append(uabin.Primitives.UInt32.pack(self.BrowseDirection.value)) |
|
6041 | packet.append(self.ReferenceTypeId.to_binary()) |
|
6042 | packet.append(uabin.Primitives.Boolean.pack(self.IncludeSubtypes)) |
|
6043 | packet.append(uabin.Primitives.UInt32.pack(self.NodeClassMask)) |
|
6044 | packet.append(uabin.Primitives.UInt32.pack(self.ResultMask)) |
|
6045 | return b''.join(packet) |
|
6046 | ||
6047 | @staticmethod |
|
6048 | def from_binary(data): |
|
6049 | return BrowseDescription(data) |
|
6050 | ||
6051 | def _binary_init(self, data): |
|
6052 | self.NodeId = NodeId.from_binary(data) |
|
6053 | self.BrowseDirection = BrowseDirection(uabin.Primitives.UInt32.unpack(data)) |
|
6054 | self.ReferenceTypeId = NodeId.from_binary(data) |
|
6055 | self.IncludeSubtypes = uabin.Primitives.Boolean.unpack(data) |
|
6056 | self.NodeClassMask = uabin.Primitives.UInt32.unpack(data) |
|
6057 | self.ResultMask = uabin.Primitives.UInt32.unpack(data) |
|
6058 | ||
6059 | def __str__(self): |
|
6060 | return 'BrowseDescription(' + 'NodeId:' + str(self.NodeId) + ', ' + \ |
|
6061 | 'BrowseDirection:' + str(self.BrowseDirection) + ', ' + \ |
|
6062 | 'ReferenceTypeId:' + str(self.ReferenceTypeId) + ', ' + \ |
|
6063 | 'IncludeSubtypes:' + str(self.IncludeSubtypes) + ', ' + \ |
|
6064 | 'NodeClassMask:' + str(self.NodeClassMask) + ', ' + \ |
|
6065 | 'ResultMask:' + str(self.ResultMask) + ')' |
|
6066 | ||
6067 | __repr__ = __str__ |
|
6068 | ||
6069 | ||
6070 | class ReferenceDescription(FrozenClass): |
|
@@ 5221-5291 (lines=71) @@ | ||
5218 | __repr__ = __str__ |
|
5219 | ||
5220 | ||
5221 | class AddReferencesItem(FrozenClass): |
|
5222 | ''' |
|
5223 | A request to add a reference to the server address space. |
|
5224 | ||
5225 | :ivar SourceNodeId: |
|
5226 | :vartype SourceNodeId: NodeId |
|
5227 | :ivar ReferenceTypeId: |
|
5228 | :vartype ReferenceTypeId: NodeId |
|
5229 | :ivar IsForward: |
|
5230 | :vartype IsForward: Boolean |
|
5231 | :ivar TargetServerUri: |
|
5232 | :vartype TargetServerUri: String |
|
5233 | :ivar TargetNodeId: |
|
5234 | :vartype TargetNodeId: ExpandedNodeId |
|
5235 | :ivar TargetNodeClass: |
|
5236 | :vartype TargetNodeClass: NodeClass |
|
5237 | ''' |
|
5238 | ||
5239 | ua_types = { |
|
5240 | 'SourceNodeId': 'NodeId', |
|
5241 | 'ReferenceTypeId': 'NodeId', |
|
5242 | 'IsForward': 'Boolean', |
|
5243 | 'TargetServerUri': 'String', |
|
5244 | 'TargetNodeId': 'ExpandedNodeId', |
|
5245 | 'TargetNodeClass': 'NodeClass', |
|
5246 | } |
|
5247 | ||
5248 | def __init__(self, binary=None): |
|
5249 | if binary is not None: |
|
5250 | self._binary_init(binary) |
|
5251 | self._freeze = True |
|
5252 | return |
|
5253 | self.SourceNodeId = NodeId() |
|
5254 | self.ReferenceTypeId = NodeId() |
|
5255 | self.IsForward = True |
|
5256 | self.TargetServerUri = None |
|
5257 | self.TargetNodeId = ExpandedNodeId() |
|
5258 | self.TargetNodeClass = NodeClass(0) |
|
5259 | self._freeze = True |
|
5260 | ||
5261 | def to_binary(self): |
|
5262 | packet = [] |
|
5263 | packet.append(self.SourceNodeId.to_binary()) |
|
5264 | packet.append(self.ReferenceTypeId.to_binary()) |
|
5265 | packet.append(uabin.Primitives.Boolean.pack(self.IsForward)) |
|
5266 | packet.append(uabin.Primitives.String.pack(self.TargetServerUri)) |
|
5267 | packet.append(self.TargetNodeId.to_binary()) |
|
5268 | packet.append(uabin.Primitives.UInt32.pack(self.TargetNodeClass.value)) |
|
5269 | return b''.join(packet) |
|
5270 | ||
5271 | @staticmethod |
|
5272 | def from_binary(data): |
|
5273 | return AddReferencesItem(data) |
|
5274 | ||
5275 | def _binary_init(self, data): |
|
5276 | self.SourceNodeId = NodeId.from_binary(data) |
|
5277 | self.ReferenceTypeId = NodeId.from_binary(data) |
|
5278 | self.IsForward = uabin.Primitives.Boolean.unpack(data) |
|
5279 | self.TargetServerUri = uabin.Primitives.String.unpack(data) |
|
5280 | self.TargetNodeId = ExpandedNodeId.from_binary(data) |
|
5281 | self.TargetNodeClass = NodeClass(uabin.Primitives.UInt32.unpack(data)) |
|
5282 | ||
5283 | def __str__(self): |
|
5284 | return 'AddReferencesItem(' + 'SourceNodeId:' + str(self.SourceNodeId) + ', ' + \ |
|
5285 | 'ReferenceTypeId:' + str(self.ReferenceTypeId) + ', ' + \ |
|
5286 | 'IsForward:' + str(self.IsForward) + ', ' + \ |
|
5287 | 'TargetServerUri:' + str(self.TargetServerUri) + ', ' + \ |
|
5288 | 'TargetNodeId:' + str(self.TargetNodeId) + ', ' + \ |
|
5289 | 'TargetNodeClass:' + str(self.TargetNodeClass) + ')' |
|
5290 | ||
5291 | __repr__ = __str__ |
|
5292 | ||
5293 | ||
5294 | class AddReferencesParameters(FrozenClass): |
|
@@ 4775-4845 (lines=71) @@ | ||
4772 | __repr__ = __str__ |
|
4773 | ||
4774 | ||
4775 | class DataTypeAttributes(FrozenClass): |
|
4776 | ''' |
|
4777 | The attributes for a data type node. |
|
4778 | ||
4779 | :ivar SpecifiedAttributes: |
|
4780 | :vartype SpecifiedAttributes: UInt32 |
|
4781 | :ivar DisplayName: |
|
4782 | :vartype DisplayName: LocalizedText |
|
4783 | :ivar Description: |
|
4784 | :vartype Description: LocalizedText |
|
4785 | :ivar WriteMask: |
|
4786 | :vartype WriteMask: UInt32 |
|
4787 | :ivar UserWriteMask: |
|
4788 | :vartype UserWriteMask: UInt32 |
|
4789 | :ivar IsAbstract: |
|
4790 | :vartype IsAbstract: Boolean |
|
4791 | ''' |
|
4792 | ||
4793 | ua_types = { |
|
4794 | 'SpecifiedAttributes': 'UInt32', |
|
4795 | 'DisplayName': 'LocalizedText', |
|
4796 | 'Description': 'LocalizedText', |
|
4797 | 'WriteMask': 'UInt32', |
|
4798 | 'UserWriteMask': 'UInt32', |
|
4799 | 'IsAbstract': 'Boolean', |
|
4800 | } |
|
4801 | ||
4802 | def __init__(self, binary=None): |
|
4803 | if binary is not None: |
|
4804 | self._binary_init(binary) |
|
4805 | self._freeze = True |
|
4806 | return |
|
4807 | self.SpecifiedAttributes = 0 |
|
4808 | self.DisplayName = LocalizedText() |
|
4809 | self.Description = LocalizedText() |
|
4810 | self.WriteMask = 0 |
|
4811 | self.UserWriteMask = 0 |
|
4812 | self.IsAbstract = True |
|
4813 | self._freeze = True |
|
4814 | ||
4815 | def to_binary(self): |
|
4816 | packet = [] |
|
4817 | packet.append(uabin.Primitives.UInt32.pack(self.SpecifiedAttributes)) |
|
4818 | packet.append(self.DisplayName.to_binary()) |
|
4819 | packet.append(self.Description.to_binary()) |
|
4820 | packet.append(uabin.Primitives.UInt32.pack(self.WriteMask)) |
|
4821 | packet.append(uabin.Primitives.UInt32.pack(self.UserWriteMask)) |
|
4822 | packet.append(uabin.Primitives.Boolean.pack(self.IsAbstract)) |
|
4823 | return b''.join(packet) |
|
4824 | ||
4825 | @staticmethod |
|
4826 | def from_binary(data): |
|
4827 | return DataTypeAttributes(data) |
|
4828 | ||
4829 | def _binary_init(self, data): |
|
4830 | self.SpecifiedAttributes = uabin.Primitives.UInt32.unpack(data) |
|
4831 | self.DisplayName = LocalizedText.from_binary(data) |
|
4832 | self.Description = LocalizedText.from_binary(data) |
|
4833 | self.WriteMask = uabin.Primitives.UInt32.unpack(data) |
|
4834 | self.UserWriteMask = uabin.Primitives.UInt32.unpack(data) |
|
4835 | self.IsAbstract = uabin.Primitives.Boolean.unpack(data) |
|
4836 | ||
4837 | def __str__(self): |
|
4838 | return 'DataTypeAttributes(' + 'SpecifiedAttributes:' + str(self.SpecifiedAttributes) + ', ' + \ |
|
4839 | 'DisplayName:' + str(self.DisplayName) + ', ' + \ |
|
4840 | 'Description:' + str(self.Description) + ', ' + \ |
|
4841 | 'WriteMask:' + str(self.WriteMask) + ', ' + \ |
|
4842 | 'UserWriteMask:' + str(self.UserWriteMask) + ', ' + \ |
|
4843 | 'IsAbstract:' + str(self.IsAbstract) + ')' |
|
4844 | ||
4845 | __repr__ = __str__ |
|
4846 | ||
4847 | ||
4848 | class ViewAttributes(FrozenClass): |
|
@@ 4512-4582 (lines=71) @@ | ||
4509 | __repr__ = __str__ |
|
4510 | ||
4511 | ||
4512 | class ObjectTypeAttributes(FrozenClass): |
|
4513 | ''' |
|
4514 | The attributes for an object type node. |
|
4515 | ||
4516 | :ivar SpecifiedAttributes: |
|
4517 | :vartype SpecifiedAttributes: UInt32 |
|
4518 | :ivar DisplayName: |
|
4519 | :vartype DisplayName: LocalizedText |
|
4520 | :ivar Description: |
|
4521 | :vartype Description: LocalizedText |
|
4522 | :ivar WriteMask: |
|
4523 | :vartype WriteMask: UInt32 |
|
4524 | :ivar UserWriteMask: |
|
4525 | :vartype UserWriteMask: UInt32 |
|
4526 | :ivar IsAbstract: |
|
4527 | :vartype IsAbstract: Boolean |
|
4528 | ''' |
|
4529 | ||
4530 | ua_types = { |
|
4531 | 'SpecifiedAttributes': 'UInt32', |
|
4532 | 'DisplayName': 'LocalizedText', |
|
4533 | 'Description': 'LocalizedText', |
|
4534 | 'WriteMask': 'UInt32', |
|
4535 | 'UserWriteMask': 'UInt32', |
|
4536 | 'IsAbstract': 'Boolean', |
|
4537 | } |
|
4538 | ||
4539 | def __init__(self, binary=None): |
|
4540 | if binary is not None: |
|
4541 | self._binary_init(binary) |
|
4542 | self._freeze = True |
|
4543 | return |
|
4544 | self.SpecifiedAttributes = 0 |
|
4545 | self.DisplayName = LocalizedText() |
|
4546 | self.Description = LocalizedText() |
|
4547 | self.WriteMask = 0 |
|
4548 | self.UserWriteMask = 0 |
|
4549 | self.IsAbstract = True |
|
4550 | self._freeze = True |
|
4551 | ||
4552 | def to_binary(self): |
|
4553 | packet = [] |
|
4554 | packet.append(uabin.Primitives.UInt32.pack(self.SpecifiedAttributes)) |
|
4555 | packet.append(self.DisplayName.to_binary()) |
|
4556 | packet.append(self.Description.to_binary()) |
|
4557 | packet.append(uabin.Primitives.UInt32.pack(self.WriteMask)) |
|
4558 | packet.append(uabin.Primitives.UInt32.pack(self.UserWriteMask)) |
|
4559 | packet.append(uabin.Primitives.Boolean.pack(self.IsAbstract)) |
|
4560 | return b''.join(packet) |
|
4561 | ||
4562 | @staticmethod |
|
4563 | def from_binary(data): |
|
4564 | return ObjectTypeAttributes(data) |
|
4565 | ||
4566 | def _binary_init(self, data): |
|
4567 | self.SpecifiedAttributes = uabin.Primitives.UInt32.unpack(data) |
|
4568 | self.DisplayName = LocalizedText.from_binary(data) |
|
4569 | self.Description = LocalizedText.from_binary(data) |
|
4570 | self.WriteMask = uabin.Primitives.UInt32.unpack(data) |
|
4571 | self.UserWriteMask = uabin.Primitives.UInt32.unpack(data) |
|
4572 | self.IsAbstract = uabin.Primitives.Boolean.unpack(data) |
|
4573 | ||
4574 | def __str__(self): |
|
4575 | return 'ObjectTypeAttributes(' + 'SpecifiedAttributes:' + str(self.SpecifiedAttributes) + ', ' + \ |
|
4576 | 'DisplayName:' + str(self.DisplayName) + ', ' + \ |
|
4577 | 'Description:' + str(self.Description) + ', ' + \ |
|
4578 | 'WriteMask:' + str(self.WriteMask) + ', ' + \ |
|
4579 | 'UserWriteMask:' + str(self.UserWriteMask) + ', ' + \ |
|
4580 | 'IsAbstract:' + str(self.IsAbstract) + ')' |
|
4581 | ||
4582 | __repr__ = __str__ |
|
4583 | ||
4584 | ||
4585 | class VariableTypeAttributes(FrozenClass): |
|
@@ 4235-4305 (lines=71) @@ | ||
4232 | __repr__ = __str__ |
|
4233 | ||
4234 | ||
4235 | class ObjectAttributes(FrozenClass): |
|
4236 | ''' |
|
4237 | The attributes for an object node. |
|
4238 | ||
4239 | :ivar SpecifiedAttributes: |
|
4240 | :vartype SpecifiedAttributes: UInt32 |
|
4241 | :ivar DisplayName: |
|
4242 | :vartype DisplayName: LocalizedText |
|
4243 | :ivar Description: |
|
4244 | :vartype Description: LocalizedText |
|
4245 | :ivar WriteMask: |
|
4246 | :vartype WriteMask: UInt32 |
|
4247 | :ivar UserWriteMask: |
|
4248 | :vartype UserWriteMask: UInt32 |
|
4249 | :ivar EventNotifier: |
|
4250 | :vartype EventNotifier: Byte |
|
4251 | ''' |
|
4252 | ||
4253 | ua_types = { |
|
4254 | 'SpecifiedAttributes': 'UInt32', |
|
4255 | 'DisplayName': 'LocalizedText', |
|
4256 | 'Description': 'LocalizedText', |
|
4257 | 'WriteMask': 'UInt32', |
|
4258 | 'UserWriteMask': 'UInt32', |
|
4259 | 'EventNotifier': 'Byte', |
|
4260 | } |
|
4261 | ||
4262 | def __init__(self, binary=None): |
|
4263 | if binary is not None: |
|
4264 | self._binary_init(binary) |
|
4265 | self._freeze = True |
|
4266 | return |
|
4267 | self.SpecifiedAttributes = 0 |
|
4268 | self.DisplayName = LocalizedText() |
|
4269 | self.Description = LocalizedText() |
|
4270 | self.WriteMask = 0 |
|
4271 | self.UserWriteMask = 0 |
|
4272 | self.EventNotifier = 0 |
|
4273 | self._freeze = True |
|
4274 | ||
4275 | def to_binary(self): |
|
4276 | packet = [] |
|
4277 | packet.append(uabin.Primitives.UInt32.pack(self.SpecifiedAttributes)) |
|
4278 | packet.append(self.DisplayName.to_binary()) |
|
4279 | packet.append(self.Description.to_binary()) |
|
4280 | packet.append(uabin.Primitives.UInt32.pack(self.WriteMask)) |
|
4281 | packet.append(uabin.Primitives.UInt32.pack(self.UserWriteMask)) |
|
4282 | packet.append(uabin.Primitives.Byte.pack(self.EventNotifier)) |
|
4283 | return b''.join(packet) |
|
4284 | ||
4285 | @staticmethod |
|
4286 | def from_binary(data): |
|
4287 | return ObjectAttributes(data) |
|
4288 | ||
4289 | def _binary_init(self, data): |
|
4290 | self.SpecifiedAttributes = uabin.Primitives.UInt32.unpack(data) |
|
4291 | self.DisplayName = LocalizedText.from_binary(data) |
|
4292 | self.Description = LocalizedText.from_binary(data) |
|
4293 | self.WriteMask = uabin.Primitives.UInt32.unpack(data) |
|
4294 | self.UserWriteMask = uabin.Primitives.UInt32.unpack(data) |
|
4295 | self.EventNotifier = uabin.Primitives.Byte.unpack(data) |
|
4296 | ||
4297 | def __str__(self): |
|
4298 | return 'ObjectAttributes(' + 'SpecifiedAttributes:' + str(self.SpecifiedAttributes) + ', ' + \ |
|
4299 | 'DisplayName:' + str(self.DisplayName) + ', ' + \ |
|
4300 | 'Description:' + str(self.Description) + ', ' + \ |
|
4301 | 'WriteMask:' + str(self.WriteMask) + ', ' + \ |
|
4302 | 'UserWriteMask:' + str(self.UserWriteMask) + ', ' + \ |
|
4303 | 'EventNotifier:' + str(self.EventNotifier) + ')' |
|
4304 | ||
4305 | __repr__ = __str__ |
|
4306 | ||
4307 | ||
4308 | class VariableAttributes(FrozenClass): |
|
@@ 14735-14803 (lines=69) @@ | ||
14732 | __repr__ = __str__ |
|
14733 | ||
14734 | ||
14735 | class ServerStatusDataType(FrozenClass): |
|
14736 | ''' |
|
14737 | :ivar StartTime: |
|
14738 | :vartype StartTime: DateTime |
|
14739 | :ivar CurrentTime: |
|
14740 | :vartype CurrentTime: DateTime |
|
14741 | :ivar State: |
|
14742 | :vartype State: ServerState |
|
14743 | :ivar BuildInfo: |
|
14744 | :vartype BuildInfo: BuildInfo |
|
14745 | :ivar SecondsTillShutdown: |
|
14746 | :vartype SecondsTillShutdown: UInt32 |
|
14747 | :ivar ShutdownReason: |
|
14748 | :vartype ShutdownReason: LocalizedText |
|
14749 | ''' |
|
14750 | ||
14751 | ua_types = { |
|
14752 | 'StartTime': 'DateTime', |
|
14753 | 'CurrentTime': 'DateTime', |
|
14754 | 'State': 'ServerState', |
|
14755 | 'BuildInfo': 'BuildInfo', |
|
14756 | 'SecondsTillShutdown': 'UInt32', |
|
14757 | 'ShutdownReason': 'LocalizedText', |
|
14758 | } |
|
14759 | ||
14760 | def __init__(self, binary=None): |
|
14761 | if binary is not None: |
|
14762 | self._binary_init(binary) |
|
14763 | self._freeze = True |
|
14764 | return |
|
14765 | self.StartTime = datetime.utcnow() |
|
14766 | self.CurrentTime = datetime.utcnow() |
|
14767 | self.State = ServerState(0) |
|
14768 | self.BuildInfo = BuildInfo() |
|
14769 | self.SecondsTillShutdown = 0 |
|
14770 | self.ShutdownReason = LocalizedText() |
|
14771 | self._freeze = True |
|
14772 | ||
14773 | def to_binary(self): |
|
14774 | packet = [] |
|
14775 | packet.append(uabin.Primitives.DateTime.pack(self.StartTime)) |
|
14776 | packet.append(uabin.Primitives.DateTime.pack(self.CurrentTime)) |
|
14777 | packet.append(uabin.Primitives.UInt32.pack(self.State.value)) |
|
14778 | packet.append(self.BuildInfo.to_binary()) |
|
14779 | packet.append(uabin.Primitives.UInt32.pack(self.SecondsTillShutdown)) |
|
14780 | packet.append(self.ShutdownReason.to_binary()) |
|
14781 | return b''.join(packet) |
|
14782 | ||
14783 | @staticmethod |
|
14784 | def from_binary(data): |
|
14785 | return ServerStatusDataType(data) |
|
14786 | ||
14787 | def _binary_init(self, data): |
|
14788 | self.StartTime = uabin.Primitives.DateTime.unpack(data) |
|
14789 | self.CurrentTime = uabin.Primitives.DateTime.unpack(data) |
|
14790 | self.State = ServerState(uabin.Primitives.UInt32.unpack(data)) |
|
14791 | self.BuildInfo = BuildInfo.from_binary(data) |
|
14792 | self.SecondsTillShutdown = uabin.Primitives.UInt32.unpack(data) |
|
14793 | self.ShutdownReason = LocalizedText.from_binary(data) |
|
14794 | ||
14795 | def __str__(self): |
|
14796 | return 'ServerStatusDataType(' + 'StartTime:' + str(self.StartTime) + ', ' + \ |
|
14797 | 'CurrentTime:' + str(self.CurrentTime) + ', ' + \ |
|
14798 | 'State:' + str(self.State) + ', ' + \ |
|
14799 | 'BuildInfo:' + str(self.BuildInfo) + ', ' + \ |
|
14800 | 'SecondsTillShutdown:' + str(self.SecondsTillShutdown) + ', ' + \ |
|
14801 | 'ShutdownReason:' + str(self.ShutdownReason) + ')' |
|
14802 | ||
14803 | __repr__ = __str__ |
|
14804 | ||
14805 | ||
14806 | class SessionDiagnosticsDataType(FrozenClass): |