Xerces2-J
  1. Xerces2-J
  2. XERCESJ-1522

Trailing spaces in DOMMessages.properties

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Trivial Trivial
    • Resolution: Fixed
    • Affects Version/s: 2.11.0
    • Fix Version/s: None
    • Component/s: DOM (Level 3 Core)
    • Labels:
      None

      Description

      https://svn.apache.org/repos/asf/xerces/java/trunk/src/org/apache/xerces/impl/msg/DOMMessages.properties @1157184 contains a number of lines with trailing spaces (noticed on INVALID_CHARACTER_ERR). This results in an odd appearance when DOMException messages are displayed in some contexts.

      (BTW https://bitbucket.org/jglick/misc-elisp/raw/d84e13fa8778/extensions/java-properties-mode.el highlights this in Emacs.)

        Activity

        Hide
        Michael Glavassevich added a comment -

        Fixed. See SVN rev 1157205.

        Show
        Michael Glavassevich added a comment - Fixed. See SVN rev 1157205.
        Hide
        Jesse Glick added a comment -

        Note that there are other such cases in nearby message files:

        $ egrep '[^# ] +$' src/org/apache/xerces/impl/msg/*.properties | fgrep -v '\n' | sed 's/ /␣/g'
        src/org/apache/xerces/impl/msg/SAXMessages.properties:jaxp-order-not-supported␣=␣Property␣''

        {0}''␣must␣be␣set␣before␣setting␣property␣''{1}''.␣
        src/org/apache/xerces/impl/msg/XMLMessages.properties:␣␣␣␣␣␣␣␣PseudoAttrNameExpected␣=␣A␣pseudo␣attribute␣name␣is␣expected.␣
        src/org/apache/xerces/impl/msg/XMLMessages.properties:␣␣␣␣␣␣␣␣ExpectedByte␣=␣Expected␣byte␣{0}

        ␣of␣

        {1}-byte␣UTF-8␣sequence.␣␣
        src/org/apache/xerces/impl/msg/XMLMessages.properties:␣␣␣␣␣␣␣␣MSG_DUPLICATE_ENTITY_DEFINITION␣=␣Entity␣\"{0}\"␣is␣declared␣more␣than␣once.␣␣␣␣␣␣␣␣
        src/org/apache/xerces/impl/msg/XMLMessages.properties:␣␣␣␣␣␣␣␣IllegalQName␣=␣Element␣or␣attribute␣do␣not␣match␣QName␣production:␣QName::=(NCName':')?NCName.␣
        src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties:␣␣␣␣␣␣␣␣length-minLength-maxLength.1.2.a␣=␣length-minLength-maxLength.1.2.a:␣For␣type␣{0},␣it␣is␣an␣error␣for␣the␣base␣to␣not␣have␣a␣minLength␣facet␣if␣the␣current␣restriction␣has␣the␣minLength␣facet␣and␣the␣current␣restriction␣or␣base␣has␣the␣length␣facet.␣
        src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties:␣␣␣␣␣␣␣␣length-minLength-maxLength.2.1␣=␣length-minLength-maxLength.2.1:␣For␣type␣{0},␣it␣is␣an␣error␣for␣the␣value␣of␣length␣''{1}

        ''␣to␣be␣greater␣than␣the␣value␣of␣maxLength␣''

        {2}''.␣
        src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties:␣␣␣␣␣␣␣␣length-minLength-maxLength.2.2.a␣=␣length-minLength-maxLength.2.2.a:␣For␣type␣{0},␣it␣is␣an␣error␣for␣the␣base␣to␣not␣have␣a␣maxLength␣facet␣if␣the␣current␣restriction␣has␣the␣maxLength␣facet␣and␣the␣current␣restriction␣or␣base␣has␣the␣length␣facet.␣
        src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties:␣␣␣␣␣␣␣␣length-minLength-maxLength.2.2.b␣=␣length-minLength-maxLength.2.2.b:␣For␣type␣{0},␣it␣is␣an␣error␣for␣the␣current␣maxLength␣''{1}''␣to␣not␣equal␣the␣base␣maxLength␣''{2}

        ''.␣␣␣␣␣␣␣␣
        src/org/apache/xerces/impl/msg/XMLSerializerMessages.properties:#␣serializer.␣␣Many␣DOM␣Load/Save␣error␣messages␣also␣
        src/org/apache/xerces/impl/msg/XPointerMessages.properties:MultipleShortHandPointers␣=␣MultipleShortHandPointers:␣␣The␣XPointer␣expression␣''

        {0}''␣is␣invalid.␣␣It␣has␣more␣than␣one␣ShortHand␣Pointer.␣
        src/org/apache/xerces/impl/msg/XPointerMessages.properties:SchemeDataNotFollowedByCloseParenthesis␣=␣SchemeDataNotFollowedByCloseParenthesis:␣The␣XPointer␣expression␣''{0}

        ''␣is␣invalid.␣␣The␣SchemeData␣was␣not␣followed␣by␣a␣'')''␣character.␣
        src/org/apache/xerces/impl/msg/XPointerMessages.properties:InvalidChildSequenceCharacter␣=␣InvalidChildSequenceCharacter:␣The␣element()␣Scheme␣contains␣an␣invalid␣child␣sequence␣character␣''

        {0}

        ''.␣

        Show
        Jesse Glick added a comment - Note that there are other such cases in nearby message files: $ egrep ' [^# ] +$' src/org/apache/xerces/impl/msg/*.properties | fgrep -v '\n' | sed 's/ /␣/g' src/org/apache/xerces/impl/msg/SAXMessages.properties:jaxp-order-not-supported␣=␣Property␣'' {0}''␣must␣be␣set␣before␣setting␣property␣''{1}''.␣ src/org/apache/xerces/impl/msg/XMLMessages.properties:␣␣␣␣␣␣␣␣PseudoAttrNameExpected␣=␣A␣pseudo␣attribute␣name␣is␣expected.␣ src/org/apache/xerces/impl/msg/XMLMessages.properties:␣␣␣␣␣␣␣␣ExpectedByte␣=␣Expected␣byte␣{0} ␣of␣ {1}-byte␣UTF-8␣sequence.␣␣ src/org/apache/xerces/impl/msg/XMLMessages.properties:␣␣␣␣␣␣␣␣MSG_DUPLICATE_ENTITY_DEFINITION␣=␣Entity␣\"{0}\"␣is␣declared␣more␣than␣once.␣␣␣␣␣␣␣␣ src/org/apache/xerces/impl/msg/XMLMessages.properties:␣␣␣␣␣␣␣␣IllegalQName␣=␣Element␣or␣attribute␣do␣not␣match␣QName␣production:␣QName::=(NCName':')?NCName.␣ src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties:␣␣␣␣␣␣␣␣length-minLength-maxLength.1.2.a␣=␣length-minLength-maxLength.1.2.a:␣For␣type␣{0},␣it␣is␣an␣error␣for␣the␣base␣to␣not␣have␣a␣minLength␣facet␣if␣the␣current␣restriction␣has␣the␣minLength␣facet␣and␣the␣current␣restriction␣or␣base␣has␣the␣length␣facet.␣ src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties:␣␣␣␣␣␣␣␣length-minLength-maxLength.2.1␣=␣length-minLength-maxLength.2.1:␣For␣type␣{0},␣it␣is␣an␣error␣for␣the␣value␣of␣length␣''{1} ''␣to␣be␣greater␣than␣the␣value␣of␣maxLength␣'' {2}''.␣ src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties:␣␣␣␣␣␣␣␣length-minLength-maxLength.2.2.a␣=␣length-minLength-maxLength.2.2.a:␣For␣type␣{0},␣it␣is␣an␣error␣for␣the␣base␣to␣not␣have␣a␣maxLength␣facet␣if␣the␣current␣restriction␣has␣the␣maxLength␣facet␣and␣the␣current␣restriction␣or␣base␣has␣the␣length␣facet.␣ src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties:␣␣␣␣␣␣␣␣length-minLength-maxLength.2.2.b␣=␣length-minLength-maxLength.2.2.b:␣For␣type␣{0},␣it␣is␣an␣error␣for␣the␣current␣maxLength␣''{1}''␣to␣not␣equal␣the␣base␣maxLength␣''{2} ''.␣␣␣␣␣␣␣␣ src/org/apache/xerces/impl/msg/XMLSerializerMessages.properties:#␣serializer.␣␣Many␣DOM␣Load/Save␣error␣messages␣also␣ src/org/apache/xerces/impl/msg/XPointerMessages.properties:MultipleShortHandPointers␣=␣MultipleShortHandPointers:␣␣The␣XPointer␣expression␣'' {0}''␣is␣invalid.␣␣It␣has␣more␣than␣one␣ShortHand␣Pointer.␣ src/org/apache/xerces/impl/msg/XPointerMessages.properties:SchemeDataNotFollowedByCloseParenthesis␣=␣SchemeDataNotFollowedByCloseParenthesis:␣The␣XPointer␣expression␣''{0} ''␣is␣invalid.␣␣The␣SchemeData␣was␣not␣followed␣by␣a␣'')''␣character.␣ src/org/apache/xerces/impl/msg/XPointerMessages.properties:InvalidChildSequenceCharacter␣=␣InvalidChildSequenceCharacter:␣The␣element()␣Scheme␣contains␣an␣invalid␣child␣sequence␣character␣'' {0} ''.␣
        Hide
        Michael Glavassevich added a comment -

        Jesse, thanks for pointing these out. I've fixed them too.

        Show
        Michael Glavassevich added a comment - Jesse, thanks for pointing these out. I've fixed them too.

          People

          • Assignee:
            Michael Glavassevich
            Reporter:
            Jesse Glick
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 5m
              5m
              Remaining:
              Remaining Estimate - 5m
              5m
              Logged:
              Time Spent - Not Specified
              Not Specified

                Development