use of org.eclipse.milo.opcua.stack.core.serialization.OpcUaXmlStreamDecoder in project milo by eclipse.
the class VariableNodeLoader method loadNode1057.
private void loadNode1057() throws IOException, SAXException {
PropertyTypeNode node = new PropertyTypeNode(this.context, Identifiers.NamespaceMetadataType_NamespaceFile_SetPosition_InputArguments, new QualifiedName(0, "InputArguments"), new LocalizedText("en", "InputArguments"), LocalizedText.NULL_VALUE, UInteger.valueOf(0), UInteger.valueOf(0), new DataValue(Variant.NULL_VALUE), Identifiers.Argument, 1, new UInteger[] { org.eclipse.milo.opcua.stack.core.types.builtin.unsigned.UInteger.valueOf(0) }, UByte.valueOf(1), UByte.valueOf(1), 0.0, false);
node.addReference(new Reference(Identifiers.NamespaceMetadataType_NamespaceFile_SetPosition_InputArguments, Identifiers.HasTypeDefinition, Identifiers.PropertyType.expanded(), true));
node.addReference(new Reference(Identifiers.NamespaceMetadataType_NamespaceFile_SetPosition_InputArguments, Identifiers.HasModellingRule, Identifiers.ModellingRule_Mandatory.expanded(), true));
node.addReference(new Reference(Identifiers.NamespaceMetadataType_NamespaceFile_SetPosition_InputArguments, Identifiers.HasProperty, Identifiers.NamespaceMetadataType_NamespaceFile_SetPosition.expanded(), false));
StringBuilder sb = new StringBuilder();
sb.append("<ListOfExtensionObject xmlns=\"http://opcfoundation.org/UA/2008/02/Types.xsd\"><ExtensionObject><TypeId><Identifier>i=297</Identifier> </TypeId><Body><Argument><Name>FileHandle</Name><DataType><Identifier>i=7</Identifier> </DataType><ValueRank>-1</ValueRank><ArrayDimensions/> </Argument> </Body> </ExtensionObject><ExtensionObject><TypeId><Identifier>i=297</Identifier> </TypeId><Body><Argument><Name>Position</Name><DataType><Identifier>i=9</Identifier> </DataType><ValueRank>-1</ValueRank><ArrayDimensions/> </Argument> </Body> </ExtensionObject> </ListOfExtensionObject>");
String xml = sb.toString();
OpcUaXmlStreamDecoder decoder = new OpcUaXmlStreamDecoder(context.getServer().getSerializationContext()).setInput(new StringReader(xml));
Object o = decoder.readVariantValue();
DataValue value = new DataValue(new Variant(o));
node.setValue(value);
this.nodeManager.addNode(node);
}
use of org.eclipse.milo.opcua.stack.core.serialization.OpcUaXmlStreamDecoder in project milo by eclipse.
the class VariableNodeLoader method loadNode76.
private void loadNode76() throws IOException, SAXException {
PropertyTypeNode node = new PropertyTypeNode(this.context, Identifiers.ServerConfiguration_CertificateGroups_DefaultApplicationGroup_TrustList_OpenWithMasks_OutputArguments, new QualifiedName(0, "OutputArguments"), new LocalizedText("en", "OutputArguments"), LocalizedText.NULL_VALUE, UInteger.valueOf(0), UInteger.valueOf(0), new DataValue(Variant.NULL_VALUE), Identifiers.Argument, 1, new UInteger[] { org.eclipse.milo.opcua.stack.core.types.builtin.unsigned.UInteger.valueOf(0) }, UByte.valueOf(1), UByte.valueOf(1), 0.0, false);
node.addReference(new Reference(Identifiers.ServerConfiguration_CertificateGroups_DefaultApplicationGroup_TrustList_OpenWithMasks_OutputArguments, Identifiers.HasTypeDefinition, Identifiers.PropertyType.expanded(), true));
node.addReference(new Reference(Identifiers.ServerConfiguration_CertificateGroups_DefaultApplicationGroup_TrustList_OpenWithMasks_OutputArguments, Identifiers.HasProperty, Identifiers.ServerConfiguration_CertificateGroups_DefaultApplicationGroup_TrustList_OpenWithMasks.expanded(), false));
StringBuilder sb = new StringBuilder();
sb.append("<ListOfExtensionObject xmlns=\"http://opcfoundation.org/UA/2008/02/Types.xsd\"><ExtensionObject><TypeId><Identifier>i=297</Identifier> </TypeId><Body><Argument><Name>FileHandle</Name><DataType><Identifier>i=7</Identifier> </DataType><ValueRank>-1</ValueRank><ArrayDimensions/> </Argument> </Body> </ExtensionObject> </ListOfExtensionObject>");
String xml = sb.toString();
OpcUaXmlStreamDecoder decoder = new OpcUaXmlStreamDecoder(context.getServer().getSerializationContext()).setInput(new StringReader(xml));
Object o = decoder.readVariantValue();
DataValue value = new DataValue(new Variant(o));
node.setValue(value);
this.nodeManager.addNode(node);
}
use of org.eclipse.milo.opcua.stack.core.serialization.OpcUaXmlStreamDecoder in project milo by eclipse.
the class VariableNodeLoader method loadNode1055.
private void loadNode1055() throws IOException, SAXException {
PropertyTypeNode node = new PropertyTypeNode(this.context, Identifiers.NamespaceMetadataType_NamespaceFile_GetPosition_InputArguments, new QualifiedName(0, "InputArguments"), new LocalizedText("en", "InputArguments"), LocalizedText.NULL_VALUE, UInteger.valueOf(0), UInteger.valueOf(0), new DataValue(Variant.NULL_VALUE), Identifiers.Argument, 1, new UInteger[] { org.eclipse.milo.opcua.stack.core.types.builtin.unsigned.UInteger.valueOf(0) }, UByte.valueOf(1), UByte.valueOf(1), 0.0, false);
node.addReference(new Reference(Identifiers.NamespaceMetadataType_NamespaceFile_GetPosition_InputArguments, Identifiers.HasTypeDefinition, Identifiers.PropertyType.expanded(), true));
node.addReference(new Reference(Identifiers.NamespaceMetadataType_NamespaceFile_GetPosition_InputArguments, Identifiers.HasModellingRule, Identifiers.ModellingRule_Mandatory.expanded(), true));
node.addReference(new Reference(Identifiers.NamespaceMetadataType_NamespaceFile_GetPosition_InputArguments, Identifiers.HasProperty, Identifiers.NamespaceMetadataType_NamespaceFile_GetPosition.expanded(), false));
StringBuilder sb = new StringBuilder();
sb.append("<ListOfExtensionObject xmlns=\"http://opcfoundation.org/UA/2008/02/Types.xsd\"><ExtensionObject><TypeId><Identifier>i=297</Identifier> </TypeId><Body><Argument><Name>FileHandle</Name><DataType><Identifier>i=7</Identifier> </DataType><ValueRank>-1</ValueRank><ArrayDimensions/> </Argument> </Body> </ExtensionObject> </ListOfExtensionObject>");
String xml = sb.toString();
OpcUaXmlStreamDecoder decoder = new OpcUaXmlStreamDecoder(context.getServer().getSerializationContext()).setInput(new StringReader(xml));
Object o = decoder.readVariantValue();
DataValue value = new DataValue(new Variant(o));
node.setValue(value);
this.nodeManager.addNode(node);
}
use of org.eclipse.milo.opcua.stack.core.serialization.OpcUaXmlStreamDecoder in project milo by eclipse.
the class VariableNodeLoader method loadNode1075.
private void loadNode1075() throws IOException, SAXException {
PropertyTypeNode node = new PropertyTypeNode(this.context, Identifiers.MessageSecurityMode_EnumStrings, new QualifiedName(0, "EnumStrings"), new LocalizedText("en", "EnumStrings"), LocalizedText.NULL_VALUE, UInteger.valueOf(0), UInteger.valueOf(0), new DataValue(Variant.NULL_VALUE), Identifiers.LocalizedText, 1, new UInteger[] { org.eclipse.milo.opcua.stack.core.types.builtin.unsigned.UInteger.valueOf(0) }, UByte.valueOf(1), UByte.valueOf(1), 0.0, false);
node.addReference(new Reference(Identifiers.MessageSecurityMode_EnumStrings, Identifiers.HasTypeDefinition, Identifiers.PropertyType.expanded(), true));
node.addReference(new Reference(Identifiers.MessageSecurityMode_EnumStrings, Identifiers.HasModellingRule, Identifiers.ModellingRule_Mandatory.expanded(), true));
node.addReference(new Reference(Identifiers.MessageSecurityMode_EnumStrings, Identifiers.HasProperty, Identifiers.MessageSecurityMode.expanded(), false));
StringBuilder sb = new StringBuilder();
sb.append("<ListOfLocalizedText xmlns=\"http://opcfoundation.org/UA/2008/02/Types.xsd\"><LocalizedText><Locale> </Locale><Text>Invalid</Text> </LocalizedText><LocalizedText><Locale> </Locale><Text>None</Text> </LocalizedText><LocalizedText><Locale> </Locale><Text>Sign</Text> </LocalizedText><LocalizedText><Locale> </Locale><Text>SignAndEncrypt</Text> </LocalizedText> </ListOfLocalizedText>");
String xml = sb.toString();
OpcUaXmlStreamDecoder decoder = new OpcUaXmlStreamDecoder(context.getServer().getSerializationContext()).setInput(new StringReader(xml));
Object o = decoder.readVariantValue();
DataValue value = new DataValue(new Variant(o));
node.setValue(value);
this.nodeManager.addNode(node);
}
use of org.eclipse.milo.opcua.stack.core.serialization.OpcUaXmlStreamDecoder in project milo by eclipse.
the class VariableNodeLoader method loadNode18.
private void loadNode18() throws IOException, SAXException {
DataTypeDescriptionTypeNode node = new DataTypeDescriptionTypeNode(this.context, Identifiers.OpcUa_XmlSchema_StatusResult, new QualifiedName(0, "StatusResult"), new LocalizedText("en", "StatusResult"), LocalizedText.NULL_VALUE, UInteger.valueOf(0), UInteger.valueOf(0), new DataValue(Variant.NULL_VALUE), Identifiers.String, -1, new UInteger[] {}, UByte.valueOf(1), UByte.valueOf(1), 0.0, false);
node.addReference(new Reference(Identifiers.OpcUa_XmlSchema_StatusResult, Identifiers.HasTypeDefinition, Identifiers.DataTypeDescriptionType.expanded(), true));
node.addReference(new Reference(Identifiers.OpcUa_XmlSchema_StatusResult, Identifiers.HasComponent, Identifiers.OpcUa_XmlSchema.expanded(), false));
StringBuilder sb = new StringBuilder();
sb.append("<String xmlns=\"http://opcfoundation.org/UA/2008/02/Types.xsd\">//xs:element[@name='StatusResult']</String>");
String xml = sb.toString();
OpcUaXmlStreamDecoder decoder = new OpcUaXmlStreamDecoder(context.getServer().getSerializationContext()).setInput(new StringReader(xml));
Object o = decoder.readVariantValue();
DataValue value = new DataValue(new Variant(o));
node.setValue(value);
this.nodeManager.addNode(node);
}
Aggregations