Class Chars

java.lang.Object
eu.bandm.tools.d2d2.model.Chars

public class Chars extends Object
Fundamental character and string constant definition. Used ubiquituously. Handwritten, but conceptually and actually part of the model package.
  • Field Details

    • STRING_VERSION_NUMBERS

      public static final String STRING_VERSION_NUMBERS
      Version number of the current implementation. Used by all applications "Main" and "Batch".
      See Also:
    • SOURCE_DOCUMENT_LEFTMOST_COLUMN_NUMBER

      public static final int SOURCE_DOCUMENT_LEFTMOST_COLUMN_NUMBER
      Complies to XEmacs counting.
      See Also:
    • SOURCE_DOCUMENT_TOPMOST_LINE_NUMBER

      public static final int SOURCE_DOCUMENT_TOPMOST_LINE_NUMBER
      Complies to XEmacs counting.
      See Also:
    • STRING_NAMING_LEVEL_SEPARATOR

      public static final String STRING_NAMING_LEVEL_SEPARATOR
      Separator for hierarchical identifiers. Used for names of sub-modules, for sequences of import prefixes, and for local definitions. Is also used to separate import prefices from definition names. Is in sync with parser rule "reference =.." from ../parser/d2d.g2
      See Also:
    • CHAR_NAMING_LEVEL_SEPARATOR

      public static final char CHAR_NAMING_LEVEL_SEPARATOR
      Evident. @see #STRING_NAMING_LEVEL_SEPARATOR
    • REGEXP_NAMING_LEVEL_SEPARATOR

      public static final String REGEXP_NAMING_LEVEL_SEPARATOR
      Evident. @see #STRING_NAMING_LEVEL_SEPARATOR
    • STRING_LEXICAL_WORLDS_SEPARATOR

      public static final String STRING_LEXICAL_WORLDS_SEPARATOR
      Used to separate the lexical world of module names from that of definition names. (Both have their own hierarchy, but never meet in execution.) Is used in documentation print-outs.
      See Also:
    • REGEXP_NEWLINE

      public static final String REGEXP_NEWLINE
      Matches one newline character.
    • STRING_NEWLINE

      public static final String STRING_NEWLINE
      Contains only one newline character.
      See Also:
    • STRING_MODULE_FROM_TOPLEVEL_ELEMENT_SEPARATOR

      public static final String STRING_MODULE_FROM_TOPLEVEL_ELEMENT_SEPARATOR
      Separator used in a d2d2 text type declaration header. (Must be distinct from STRING_NAMING_LEVEL_SEPARATOR for the module part to be recognizable immediately.) .
      See Also:
    • CHAR_MODULE_FROM_TOPLEVEL_ELEMENT_SEPARATOR

      public static final char CHAR_MODULE_FROM_TOPLEVEL_ELEMENT_SEPARATOR
      Evident. @see #STRING_MODULE_FROM_TOPLEVEL_ELEMENT_SEPARATOR
    • PREFIX_DOCUMENT_TARGET_USER

      public static final String PREFIX_DOCUMENT_TARGET_USER
      Prefix for user documentation in the d2d type definition files.
      See Also:
    • DOCUMENT_TARGET_USER_EN

      public static final String DOCUMENT_TARGET_USER_EN
      Prefix for English user documentation in the d2d type definition files.
      See Also:
    • DOCUMENT_TARGET_USER_DE

      public static final String DOCUMENT_TARGET_USER_DE
      Prefix for German user documentation in the d2d type definition files.
      See Also:
    • STRING_TAGNAME_chardata

      public static final String STRING_TAGNAME_chardata
      Content model for character data.
      See Also:
    • CHAR_COMMAND_DEFAULT

      public static final char CHAR_COMMAND_DEFAULT
      Default setting of the d2d text input command character.
      See Also:
    • CHAR_COMMENT_1_DEFAULT

      public static final char CHAR_COMMENT_1_DEFAULT
      Default setting of the d2d text input first comment character.
      See Also:
    • CHAR_COMMENT_2

      public static final char CHAR_COMMENT_2
      The d2d text input second comment character.
      See Also:
    • CHAR_ENDTAG_LEADIN

      public static final char CHAR_ENDTAG_LEADIN
      The d2d text input close tag character.
      See Also:
    • STRING_SET_COMMAND_CHAR

      public static final String STRING_SET_COMMAND_CHAR
      The d2d text input reserved tag for changing the command character.
      See Also:
    • STRING_SET_COMMENT_CHAR

      public static final String STRING_SET_COMMENT_CHAR
      The d2d text input reserved tag for changing the comment character.
      See Also:
    • STRING_SUPPRESS_VERB_WARNING

      public static final String STRING_SUPPRESS_VERB_WARNING
      The d2d text input reserved tag for suppressing the warnings when the command character appears in "verbatim" input text.
      See Also:
    • STRING_TAGNAME_eof

      public static final String STRING_TAGNAME_eof
      The d2d text input reserved tag for the end of the text input.
      See Also:
    • MESSAGE_REPRESENTATION_EXPRESSION_NONE

      public static final String MESSAGE_REPRESENTATION_EXPRESSION_NONE
      The string to eliminate an expression in a rewrite expression.
      See Also:
    • charset_eoline

      public static final CharSet charset_eoline
      Contains carriage return and linefeed.
    • charset_blanks

      public static final CharSet charset_blanks
      Contains carriage return, linefeed, tab, and blank.
    • charset_ascii_alpha_lower

      public static final CharSet charset_ascii_alpha_lower
      Evident
    • charset_ascii_alpha_upper

      public static final CharSet charset_ascii_alpha_upper
      Evident
    • charset_ascii_numeric

      public static final CharSet charset_ascii_numeric
      Decinal digits.
    • charset_ident_initial

      public static final CharSet charset_ident_initial
      Only alphabetic letters, lower or upper case.
    • charset_ident_subsequent

      public static final CharSet charset_ident_subsequent
      Alphabetic letters, lower or upper case, the undescore sign, and decimal digits..
    • charset_ident_initial_or_subsequent

      public static final CharSet charset_ident_initial_or_subsequent
      Evident
    • charset_numeric_initial

      public static final CharSet charset_numeric_initial
      The start symbols for number inputs: Digits only (no sign symbol!)
    • charset_hex_letters

      public static final CharSet charset_hex_letters
      The hexadecimal digits which are no decimal digits, in both caes.
    • charset_numeric_initial_or_subsequent

      public static final CharSet charset_numeric_initial_or_subsequent
      All hexadecimal digits, including 0..9, in lower and upper case.
    • closeParentheses

      public static final SortedMap<Character,Character> closeParentheses
      Maps all allowedxs open parantheses to their closing counterpart.
    • openParentheses

      public static final SortedSet<Character> openParentheses
      All allowed open parantheses.
    • STRING_DTD_attribute_disambiguation_prefix

      public static final String STRING_DTD_attribute_disambiguation_prefix
      Prepended to the name of an XML-DTD attribute to distinguish it from a leading content element.
      See Also:
    • STRING_DTD_namespace_mangling

      public static final String STRING_DTD_namespace_mangling
      Replaces the namespace separator when translating xml dtd identifier to d2d definitions.
      See Also:
    • STRING_DTD_attContainerNamer

      public static final String STRING_DTD_attContainerNamer
      Synthetic d2d element definition to contain all attributes common to more than one DTD element.
      See Also:
    • empty_uri_indication

      public static final String empty_uri_indication
      Used in d2d module's namespace declaration.
      See Also:
    • DUMMY_XSLT_TARGET_UNSTRUCTURED

      public static final String DUMMY_XSLT_TARGET_UNSTRUCTURED
      Used when an xslt transformation generates plain text, not xml.
      See Also:
    • modulename_docuTextDeclaration

      public static final String modulename_docuTextDeclaration
      The module name for the type definition of the documentation text extracted from d2d defintions.
      See Also:
    • defname_docuTextDeclaration

      public static final String defname_docuTextDeclaration
      The definition name for the type definition of the documentation text extracted from d2d defintions.
      See Also:
    • xslt_modulename

      public static final String xslt_modulename
      The module name of the d2d type definition of xslt files.
      See Also:
    • xslt_generic_tag_for_backend_elements

      public static final String xslt_generic_tag_for_backend_elements
      The tag which stands for any result element in the d2d definition of xslt.
      See Also:
    • xslt_tag_toplevel

      public static final String xslt_tag_toplevel
      One of the two tags foreseen for the top-level xml element of an xslt style sheet, supported by the d2d model fo xslt.
      See Also:
    • xslt_tag_ubiquituous

      public static final String xslt_tag_ubiquituous
      The definition in the d2d definition of xslt which lists all elements which can appear anywhere in the result elements an xslt code file.
      See Also:
    • xslt_prefices

      public static final List<String> xslt_prefices
      Prefices used to disambiguate the xslt tags from the tags in the result text format.
  • Method Details

    • checkName

      public static <D> boolean checkName(String s, @Opt @Opt Location<D> elloc, @Opt @Opt MessageReceiver<SimpleMessage<D>> msg)
      Checks that not illegal characters are in the name of the d2d definition to create. An d2d ident must follow the grammar ('A'..'Z'|'a'..'z')(('a'..'z')|('A'..'Z')|('0'..'9')| '_' | '-' )* . "Extender" characters allowed in XML tags are rejected. So are colons forgotten to remove, because namespace mode has not been declared by PIs.
      Parameters:
      s - the name for the constructed d2d definition
      elloc - the location of the source element declaration, for error messages.
      msg - where to send the error messages
    • isReservedTag

      public static boolean isReservedTag(String tag)
      Is true for some tags which are allowed, but reserved for future special use.
    • isValidTag

      public static boolean isValidTag(String tag)
      Excludes all those identifiers (=tags), which are reserved tags in d2d input files (commandchar, commentchar, suppressVerbatimCommandCharWarning, eof).