Opc.Ua.ServerTest.ReadTest.AddAttributes C# (CSharp) Method

AddAttributes() private method

Adds the attributes to the request collection.
private AddAttributes ( Node node, ReadValueIdCollection nodesToRead ) : void
node Node
nodesToRead ReadValueIdCollection
return void
        private void AddAttributes(
            Node node, 
            ReadValueIdCollection nodesToRead, 
            params uint[] attributeIds)
        {
            if (attributeIds != null)
            {
                for (int ii = 0; ii < attributeIds.Length; ii++)
                {
                    ReadValueId nodeToRead = new ReadValueId();

                    nodeToRead.NodeId = node.NodeId;
                    nodeToRead.AttributeId = attributeIds[ii];
                    nodeToRead.Handle = node;

                    nodesToRead.Add(nodeToRead);
                }
            }
        }