Not sure if I missed this in one of the tutorials, apologies if I have.
Let's say I want to detail shipping containers.
I'm interested in the weight and the maximum carrying weight of the container. Using NIEM, I decide to use nc:ItemWeightMeasure for the purpose of representing these measures.
In CAM, I create my template with the ShippingContainer element at the top level. I drag over a nc:ItemWeightMeasure element from the NIEM dictionary.
How do I now name it to ShippingContainerTareWeightMeasure whilst maintaining the type, so I don't need to create a new type? Once renaming, will I then be able to drag over a second nc:ItemWeightMeasure item underneath ShippingContainer?
If this isn't possible, what is the general pattern for addressing this type of problem?
tom
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Tom, a very good question. The simplest thing is to create a parent element ShippingContainerTareWeightMeasure and make nc:ItemWeightMeasure a child of that. This is assuming you will use Files / Export / Template as XSD / and pick the NIEM output option to create a new schema.
Another approach is to get into manual schema editing of the generated schema and switch the defined type reference with the nc:ItemWeightMeasure. You could put an annotation of "Type" into the template to assist with that.
Now you are asking this - it occurs to me - we could enhance the XSLT that is generating the XSD to use those Type annotations to create a named type.
Also - the Rename UI tool - if someone renames a namespaced item - could prompt to automatically add that Type annotation.
If you concur I will add these to the enhancements for upcoming release, although I am wondering if this is enough, and maybe opening up more details to be considered too?
Thanks, David
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi David,
Not sure if I missed this in one of the tutorials, apologies if I have.
Let's say I want to detail shipping containers.
I'm interested in the weight and the maximum carrying weight of the container. Using NIEM, I decide to use nc:ItemWeightMeasure for the purpose of representing these measures.
In CAM, I create my template with the ShippingContainer element at the top level. I drag over a nc:ItemWeightMeasure element from the NIEM dictionary.
How do I now name it to ShippingContainerTareWeightMeasure whilst maintaining the type, so I don't need to create a new type? Once renaming, will I then be able to drag over a second nc:ItemWeightMeasure item underneath ShippingContainer?
If this isn't possible, what is the general pattern for addressing this type of problem?
tom
Tom, a very good question. The simplest thing is to create a parent element ShippingContainerTareWeightMeasure and make nc:ItemWeightMeasure a child of that. This is assuming you will use Files / Export / Template as XSD / and pick the NIEM output option to create a new schema.
Another approach is to get into manual schema editing of the generated schema and switch the defined type reference with the nc:ItemWeightMeasure. You could put an annotation of "Type" into the template to assist with that.
Now you are asking this - it occurs to me - we could enhance the XSLT that is generating the XSD to use those Type annotations to create a named type.
Also - the Rename UI tool - if someone renames a namespaced item - could prompt to automatically add that Type annotation.
If you concur I will add these to the enhancements for upcoming release, although I am wondering if this is enough, and maybe opening up more details to be considered too?
Thanks, David
Hi David,
Thanks for the tips and I think the additional functionality sounds very (very) useful.
thanks,
tom
Tom, its in the bug tracker as enhancements now.
Thanks, David
Hi David,
I've just thought the same annotation mechanism would probably be useful for extensions.
tom
Last edit: tom 2015-05-08