Skip to main content
Question

Writing CityGML generics attribute


Hi,

 

 

I am wondering how it is possible to write generics attribute in CityGML?

 

 

Any help appreciated :)

 

 

Regards,

 

 

Asher

6 replies

aklamwis
Contributor
  • Contributor
  • December 16, 2023

Hello Asherk, did you ever find out how to do this?


takashi
Evangelist
  • December 16, 2023

Try defining attributes which you want to add to the the destination dataset as generic attributes in the User Attributes tab of the CityGML writer feature type.

For example, if you add a user attribute called "foo" with xml_buffer type, CityGML writer generates this generic attribute element.

<gen:stringAttribute name="foo">
    <gen:value>value of foo</gen:value>
</gen:stringAttribute>

 

 


aklamwis
Contributor
  • Contributor
  • December 16, 2023
takashi wrote:

Try defining attributes which you want to add to the the destination dataset as generic attributes in the User Attributes tab of the CityGML writer feature type.

For example, if you add a user attribute called "foo" with xml_buffer type, CityGML writer generates this generic attribute element.

<gen:stringAttribute name="foo">
    <gen:value>value of foo</gen:value>
</gen:stringAttribute>

 

 

Thanks so much for the quick reply


aklamwis
Contributor
  • Contributor
  • December 16, 2023
takashi wrote:

Try defining attributes which you want to add to the the destination dataset as generic attributes in the User Attributes tab of the CityGML writer feature type.

For example, if you add a user attribute called "foo" with xml_buffer type, CityGML writer generates this generic attribute element.

<gen:stringAttribute name="foo">
    <gen:value>value of foo</gen:value>
</gen:stringAttribute>

 

 

 

I did it like this but nothing is showing when I open the XML file in notepad++. When I edit the Value field it becomes invalid. Example; by typing Fooimage


takashi
Evangelist
  • December 16, 2023
aklamwis wrote:

 

I did it like this but nothing is showing when I open the XML file in notepad++. When I edit the Value field it becomes invalid. Example; by typing Fooimage

Cannot find what is wrong just seeing the User Attributes definition. See the attached example which generates a generic attribute definitely.


aklamwis
Contributor
  • Contributor
  • December 17, 2023
aklamwis wrote:

 

I did it like this but nothing is showing when I open the XML file in notepad++. When I edit the Value field it becomes invalid. Example; by typing Fooimage

Thanks so much for your support Takashi, I was able to get it done


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings