Question

AIXM Annotations


Badge
Hello,

 

 

Feature Type RunwayTimeSlice (Runway Class (http://webprisme.cfmu.eurocontrol.int/aixmwiki_public/bin/view/AIXM/Class_Runway" target="_blank">https://extranet.eurocontrol.int/http://webprisme.cfmu.eurocontrol.int/aixmwiki_public/bin/view/AIXM/Class_Runway)) has an Attribute annotation{}. But it doesn't find its way into my XML File. ;)

 

I tried it the same way as shown in the AIXM Demo for responsibleOrganisation (EU Airports Demo (https://knowledge.safe.com/articles/How_To/AIXM)), but it doesn't work. What am I doing wrong?

 

 

0684Q00000ArDSWQA3.png

 

Shouldn't this one produce something like this?: 
 <aixm:annotation> 	<aixm:Note gml:id="uuid.f19ffb15-d86b-4336-a8e2-04f3af652350"> 		<aixm:purpose>REMARK</aixm:purpose> 	</aixm:Note> </aixm:annotation>
 

 

Help is appreciated :)

 

Melanie

2 replies

Badge
I guess its because the annotation attribute is of type xml_xml... but I don't know what I should do different.
Badge +6

To write to an xml_xml field with the AIXM5 writer (or for xml_xml fields in any GML writer), the field value needs to be a valid XML fragment. Also, given that annotation{} is a series object, you need to define it as a list element. So in the attached EUairports_inspire2aixm5_v1.1.fmw I added a field in AttributeCreator_AHTS called annotation{0} with the value: 

<aixm:annotation xmlns:aixm="http://www.aixm.aero/schema/5.1" xmlns:gml="http://www.opengis.net/gml/3.2"><aixm:Note  gml:id="anno_@Value(_uuid)"> <aixm:purpose>REMARK</aixm:purpose></aixm:Note> </aixm:annotation>

Two important notes to make this valid. First, the aixm and gml namespaces need to be defined within the first element. These will be consolidated into the namespace header on write. Second, the gml_id needs to be unique. So I created an annotation id based on the feature uuid. 

If you have difficulty troubleshooting this, you can always use a separate workspace with an XMLValidator pointing to FME\xml\schemas\aixm\5.1\message\AIXM_BasicMessage.xsd to help diagnose problems and make the XML valid. The validation results are typically quite informative. If you still have trouble please contact support@safe.com for help with your particular workflow.euairports-inspire2aixm5-v11.zip

Reply