/// <summary> /// Saves the attributes from the stream. /// </summary> /// <param name="context">The context for the system being accessed.</param> /// <param name="encoder">The encoder wrapping the stream to write.</param> public override void Save(ISystemContext context, XmlEncoder encoder) { base.Save(context, encoder); encoder.PushNamespace(Namespaces.OpcUaXsd); if (!NodeId.IsNull(m_referenceTypeId)) { encoder.WriteNodeId("ReferenceTypeId", m_referenceTypeId); } if (!NodeId.IsNull(m_typeDefinitionId)) { encoder.WriteNodeId("TypeDefinitionId", m_typeDefinitionId); } if (!NodeId.IsNull(m_modellingRuleId)) { encoder.WriteNodeId("ModellingRuleId", m_modellingRuleId); } if (m_numericId != 0) { encoder.WriteUInt32("NumericId", m_numericId); } encoder.PopNamespace(); }
/// <summary> /// Saves the attributes from the stream. /// </summary> /// <param name="context">The context for the system being accessed.</param> /// <param name="encoder">The encoder wrapping the stream to write.</param> public override void Save(ISystemContext context, XmlEncoder encoder) { base.Save(context, encoder); encoder.PushNamespace(Namespaces.OpcUaXsd); if (m_value != null) { encoder.WriteVariant("Value", WrappedValue); } if (!NodeId.IsNull(DataType)) { encoder.WriteNodeId("DataType", DataType); } if (ValueRank != ValueRanks.Any) { encoder.WriteInt32("ValueRank", ValueRank); } if (ArrayDimensions != null) { encoder.WriteString("ArrayDimensions", BaseVariableState.ArrayDimensionsToXml(ArrayDimensions)); } encoder.PopNamespace(); }
/// <summary> /// Saves the attributes from the stream. /// </summary> /// <param name="context">The context for the system being accessed.</param> /// <param name="encoder">The encoder wrapping the stream to write.</param> public override void Save(ISystemContext context, XmlEncoder encoder) { base.Save(context, encoder); encoder.PushNamespace(Namespaces.OpcUaXsd); if (!NodeId.IsNull(m_superTypeId)) { encoder.WriteNodeId("SuperTypeId", m_superTypeId); } if (m_isAbstract) { encoder.WriteBoolean("IsAbstract", m_isAbstract); } encoder.PopNamespace(); }