Home » railML newsgroups » railml.common » [railML3] Change pattern for tOtherEnumerationValue
Re: [railML3] Change pattern for tOtherEnumerationValue [message #3797 is a reply to message #3557] Thu, 27 November 2025 14:32 Go to previous messageGo to previous message
Dominik Looser is currently offline  Dominik Looser
Messages: 66
Registered: March 2020
Member
Dear Thomas

While trying out the new railML3.4 beta 2 in our exporting software, our XML validation component reports that the schema files cannot be loaded.
This appears to be caused by the regular expression introduced above:
other:[A-Za-z0-9-_]{2,}
In this form, the hyphen (-) in the character class is interpreted as a range operator, which results in a validation error. According to multiple sources ([1, [2], [3]), a hyphen inside [ ... ] must either be escaped or placed at the beginning or end of the class to be interpreted literally.
I would therefore suggest to either negate the hyphen
other:[A-Za-z0-9\-_]{2,}
or place it at the end of the brackets
other:[A-Za-z0-9_-]{2,}

Thank you in advance for looking into this.

Best regards,
Dominik Looser
trafIT solutions gmbh

[1] https://stackoverflow.com/questions/3697202/including-a-hyph en-in-a-regex-character-bracket
[2] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guid e/Regular_expressions/Character_classes
[3] https://www.regular-expressions.info/charclass.html
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: [Ontology v0.6] Missing properties for intrinsicCoordBegin/End
Next Topic: [railVIVID 2.1] Visualisation issue
Goto Forum:
  


Current Time: Mon Nov 09 01:16:01 GMT+1 2026