Avatar

Please consider registering
guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed Topic RSS sp_TopicIcon
Using generated types at MyBigNodeManager
March 10, 2017
14:28, EET
Avatar
Michael
New Member
Members
Forum Posts: 2
Member Since:
March 10, 2017
sp_UserOfflineSmall Offline

Hi Support Team,
I am evaluating your Server SDK and therefore trying to use the generated types by codegen at the class MyBigNodeManager.
The reason for this combination is that I want to combine the advantages of the MyBigNodeManager class (no duplication of existing data to UaNode objects, small Memory usage) with the user defined types be codegen. For instance I want to use the type “ValveType” defined at SampleTypes.xml at the MyBigNodeManager.
Is this combination possible? And how do I have to modify MyBigNodeManager?

Thanks.
Michael

March 10, 2017
16:10, EET
Avatar
Bjarne Boström
Moderator
Moderators
Forum Posts: 1032
Member Since:
April 3, 2012
sp_UserOfflineSmall Offline

Hi,

Codegen does create UaNode based classes and MyBigNodeManager is a sample for situations where you might not have memory for UaNode model, therefore I would say these 2 are not mutually compatible. Also I suppose I should mention that the MyBigNodeManager sample is from the era before we had a codegen.

Also the codegen classes expect to get UaNodes for subcomponents, i.e. the generated code operates on the node model.

I would say situation where you have enough memory for the UaNodes but not for the values is rare, so I would assume the duplication is the main problem here.

Unfortunately there is not any out-of-the-box-easy-to-use options currently for this.

For the top-level-node the data has to be in the node OR handled with custom IoManager(Listener) (NOTE! this does not link to the UaNode used in the server side)

For components of the top-level-node, as long as they are Properties, you could use a NodeBuilderConfiguration and set InstantiationStrategy that provides the values via callback method (e.g. CallbackInstancePropertyInstantiationStrategy). These should work from the server side generated nodes. This works as all generated code operates on UaProperty for Properties. However the generated getXXXNode methods do return other generated nodes for non-Property components. I would note that this is a bit experimental at the moment and used mainly for few SDK internal functionalities.

I see how this could be implemented better in the future, but not sure when.

– Bjarne

Forum Timezone: Europe/Helsinki

Most Users Ever Online: 1919

Currently Online:
27 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

Heikki Tahvanainen: 402

hbrackel: 144

rocket science: 88

pramanj: 86

Francesco Zambon: 83

Ibrahim: 78

Sabari: 62

kapsl: 57

gjevremovic: 49

Xavier: 43

Member Stats:

Guest Posters: 0

Members: 730

Moderators: 7

Admins: 1

Forum Stats:

Groups: 3

Forums: 15

Topics: 1529

Posts: 6471

Newest Members:

HypromeImpupe, toneylapham544, rondawolinski7, Marypof5711, roycedelargie91, kourtneyquisenbe, ellis87832073466, zkxwilliemae, gabriellabachus, Deakin

Moderators: Jouni Aro: 1026, Pyry: 1, Petri: 0, Bjarne Boström: 1032, Jimmy Ni: 26, Matti Siponen: 349, Lusetti: 0

Administrators: admin: 1