Mandatory property attributes (11.1.1)

aread

New member
An acceptable example:
XML:
<Property id="FocalDistance" type="UInt32" value="2540" />

Could this acceptable?
XML:
<Property id="FocalDistance" type="UInt32" />
<Property id="FocalDistance" value="2540"  />

The alternative more directly maps to simple key-value structures. Of course in this case input validation must be postponed.

I am programming in a low-level language, Forth!

 
Hi, and welcome to PixInsight Forum!

Wow, Forth! Not for the casual programmer! :)

Your second examples are not valid serializations of scalar properties; see sections 11.1.1 (the id and type attributes are required) and 11.1.4 (the value attribute is required). You cannot "split" the serialization of a property into two XML elements. Properties must be unique for a given image, and we always need to know a property's identifier, type, and value.
 
Thank you and understood.

Forth? It's a nice language for experimenting with low-level devices. Good experience interacting with camera and mount drivers in Forth.

I'm learning a lot implementing a baseline XISF writer and I like the format very much.
 
Back
Top