Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implementation Guidance of using this project with ExampleServer #12

Open
gsshiva opened this issue Feb 20, 2023 · 0 comments
Open

Implementation Guidance of using this project with ExampleServer #12

gsshiva opened this issue Feb 20, 2023 · 0 comments

Comments

@gsshiva
Copy link

gsshiva commented Feb 20, 2023

I am a new to OPC/UA and getting up to speed. We have a project that depends on DI and Robotics. I want to expose both models with the ExampleServer in the MILO's server-examples . I was able to do the folliowing

 @Test
    public void testMerge() throws Exception {
        UaNodeSet roboticsNodeSet = parse("robotics/Opc.Ua.Robotics.NodeSet2.xml");
        UaNodeSet devicesNodeSet = parse("di/Opc.Ua.Di.NodeSet2.xml");
        UaNodeSet mergedNodeSet = UaNodeSetMerger.merge(roboticsNodeSet, devicesNodeSet);
        System.out.println("Merged nodes has " mergedNodeSet.getNodes().size());
    }

I see that the ExampleServer starts up an ExampleNamespace. If I need to expose the mergedNodeSet which contains 2 namespaces,

  1. Should I be creating two DINamespace and RoboticsNamespace classes which takes in the mergedNodeSet and filters only those nodes relavant for that namespace and add them ?
  2. Also, should I be doing the following code to get the FolderNode for References , DataTypes , ObjectTypes and simply add the nodes from the UANodeSet ?
getServer()
            .getAddressSpaceManager()
            .getManagedNode()

If you can guide with some sample code for the import process, I appreciate that. Thanks in advance for your time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant