use of org.eclipse.milo.opcua.stack.core.serialization.OpcUaXmlStreamDecoder in project milo by eclipse.
the class VariableNodeLoader method loadNode1037.
private void loadNode1037() throws IOException, SAXException {
PropertyTypeNode node = new PropertyTypeNode(this.context, Identifiers.FileType_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.FileType_GetPosition_InputArguments, Identifiers.HasTypeDefinition, Identifiers.PropertyType.expanded(), true));
node.addReference(new Reference(Identifiers.FileType_GetPosition_InputArguments, Identifiers.HasModellingRule, Identifiers.ModellingRule_Mandatory.expanded(), true));
node.addReference(new Reference(Identifiers.FileType_GetPosition_InputArguments, Identifiers.HasProperty, Identifiers.FileType_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 loadNode433.
private void loadNode433() throws IOException, SAXException {
PropertyTypeNode node = new PropertyTypeNode(this.context, Identifiers.CertificateGroupFolderType_AdditionalGroup_Placeholder_TrustList_Open_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.CertificateGroupFolderType_AdditionalGroup_Placeholder_TrustList_Open_OutputArguments, Identifiers.HasTypeDefinition, Identifiers.PropertyType.expanded(), true));
node.addReference(new Reference(Identifiers.CertificateGroupFolderType_AdditionalGroup_Placeholder_TrustList_Open_OutputArguments, Identifiers.HasModellingRule, Identifiers.ModellingRule_Mandatory.expanded(), true));
node.addReference(new Reference(Identifiers.CertificateGroupFolderType_AdditionalGroup_Placeholder_TrustList_Open_OutputArguments, Identifiers.HasProperty, Identifiers.CertificateGroupFolderType_AdditionalGroup_Placeholder_TrustList_Open.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 loadNode1178.
private void loadNode1178() throws IOException, SAXException {
DataTypeDescriptionTypeNode node = new DataTypeDescriptionTypeNode(this.context, Identifiers.OpcUa_BinarySchema_ElementOperand, new QualifiedName(0, "ElementOperand"), new LocalizedText("en", "ElementOperand"), 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_BinarySchema_ElementOperand, Identifiers.HasTypeDefinition, Identifiers.DataTypeDescriptionType.expanded(), true));
node.addReference(new Reference(Identifiers.OpcUa_BinarySchema_ElementOperand, Identifiers.HasComponent, Identifiers.OpcUa_BinarySchema.expanded(), false));
StringBuilder sb = new StringBuilder();
sb.append("<String xmlns=\"http://opcfoundation.org/UA/2008/02/Types.xsd\">ElementOperand</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);
}
use of org.eclipse.milo.opcua.stack.core.serialization.OpcUaXmlStreamDecoder in project milo by eclipse.
the class VariableNodeLoader method loadNode50.
private void loadNode50() throws IOException, SAXException {
PropertyTypeNode node = new PropertyTypeNode(this.context, Identifiers.TrustListType_AddCertificate_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.TrustListType_AddCertificate_InputArguments, Identifiers.HasTypeDefinition, Identifiers.PropertyType.expanded(), true));
node.addReference(new Reference(Identifiers.TrustListType_AddCertificate_InputArguments, Identifiers.HasModellingRule, Identifiers.ModellingRule_Mandatory.expanded(), true));
node.addReference(new Reference(Identifiers.TrustListType_AddCertificate_InputArguments, Identifiers.HasProperty, Identifiers.TrustListType_AddCertificate.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>Certificate</Name><DataType><Identifier>i=15</Identifier> </DataType><ValueRank>-1</ValueRank><ArrayDimensions/> </Argument> </Body> </ExtensionObject><ExtensionObject><TypeId><Identifier>i=297</Identifier> </TypeId><Body><Argument><Name>IsTrustedCertificate</Name><DataType><Identifier>i=1</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 loadNode113.
private void loadNode113() throws IOException, SAXException {
DataTypeDescriptionTypeNode node = new DataTypeDescriptionTypeNode(this.context, Identifiers.OpcUa_BinarySchema_Union, new QualifiedName(0, "Union"), new LocalizedText("en", "Union"), 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_BinarySchema_Union, Identifiers.HasTypeDefinition, Identifiers.DataTypeDescriptionType.expanded(), true));
node.addReference(new Reference(Identifiers.OpcUa_BinarySchema_Union, Identifiers.HasComponent, Identifiers.OpcUa_BinarySchema.expanded(), false));
StringBuilder sb = new StringBuilder();
sb.append("<String xmlns=\"http://opcfoundation.org/UA/2008/02/Types.xsd\">Union</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