Skip to content

[BUG] Handling of special characters #273

@BirgitBoss

Description

@BirgitBoss

How: List of performed steps

Import Model to AME

@prefix samm: <urn:samm:org.eclipse.esmf.samm:meta-model:2.1.0#> .
@prefix samm-c: <urn:samm:org.eclipse.esmf.samm:characteristic:2.1.0#> .
@prefix samm-e: <urn:samm:org.eclipse.esmf.samm:entity:2.1.0#> .
@prefix unit: <urn:samm:org.eclipse.esmf.samm:unit:2.1.0#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix : <urn:samm:io.admin-shell.idta.shared:3.1.0#> .

:testSpecialChar a samm:Property ;
   samm:preferredName "organization name"@en ;
   samm:preferredName "Überblick"@de ;
   samm:description "no special characters or if encoded like %23"@en ;
   samm:description "Description soll Sonderzeichen enthalten: # ü ä . see enthält auch Sonderzeichen #"@de ;
   samm:see <urn:irdi:0173-1%2302-ABI002%23003> ;
   samm:characteristic samm-c:Text ;
   samm:exampleValue "Example company" .

After import everything seems fine (the %23 for # are imported but the display shows it in a human friendly way:
Image

Then click "Save" in the property editor on the right side and then export model again. After it looks like this (special char in see attributes now subsituted by not allowed "#" char):

@prefix samm: <urn:samm:org.eclipse.esmf.samm:meta-model:2.1.0#> .
@prefix samm-c: <urn:samm:org.eclipse.esmf.samm:characteristic:2.1.0#> .
@prefix samm-e: <urn:samm:org.eclipse.esmf.samm:entity:2.1.0#> .
@prefix unit: <urn:samm:org.eclipse.esmf.samm:unit:2.1.0#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix : <urn:samm:io.admin-shell.idta.shared:3.1.0#> .

:testSpecialChar a samm:Property ;
   samm:preferredName "Überblick"@de ;
   samm:preferredName "organization name"@en ;
   samm:description "Description soll Sonderzeichen enthalten: # ü ä . see enthält auch Sonderzeichn #"@de ;
   samm:description "no special characters or if encoded like %23"@en ;
   samm:see <urn:irdi:0173-1#02-ABI002#003> ;
   samm:characteristic samm-c:Text ;
   samm:exampleValue "Example company" .

Metadata

Metadata

Assignees

No one assigned

    Labels

    acknowledgedHas been viewed by one of the maintainers and is ready for further work, discussion or other steps.bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions