DTD For Validating Transaction Set Rules

OBOE Basic Edition

<?xml encoding="UTF-8"?> <!-- OBOE release 3.5.0 Thursday, February 22, 2007--> <!-- http://www.americancoders.com --> <!-- OBOE - Open Business Objects for EDI --> <!-- Purpose: validates EDI rules --> <!-- 3.4.0 change: added used attribute to most major nodes, added exclude/include to idlistfile--> <!-- 3.5.0 change: further defined type attribute of dataElement node added exclude/include to idlistfile--> <!-- 3.5.9 change: relaxed rule for idValue node in idList node now an optional node --> <!ELEMENT transactionSet (table+)> <!ATTLIST transactionSet name CDATA #REQUIRED id CDATA #REQUIRED revision CDATA #IMPLIED functionalGroup CDATA #IMPLIED description CDATA #IMPLIED xmlTag CDATA #IMPLIED> <!ELEMENT table (segment?, loop?)*> <!ATTLIST table section (header | detail | summary) "header"> <!ELEMENT loop (((segment?, loop?)*)|(copyLoop))> <!ATTLIST loop name CDATA #REQUIRED id CDATA #REQUIRED occurs CDATA #REQUIRED required (M | O | C) "M" used (Y | N) "Y" xmlTag CDATA #IMPLIED> <!ELEMENT copyLoop EMPTY> <!ATTLIST copyLoop refid CDATA #REQUIRED> <!ELEMENT segment ((compositeDE?, dataElement?)*|(copySegment))> <!ATTLIST segment name CDATA #REQUIRED id CDATA #REQUIRED sequence CDATA #REQUIRED description CDATA #IMPLIED occurs CDATA #IMPLIED required (M | O | C) "M" used (Y | N) "Y" xmlTag CDATA #IMPLIED> <!ELEMENT compositeDE (dataElement)+> <!ATTLIST compositeDE name CDATA #REQUIRED id CDATA #REQUIRED description CDATA #IMPLIED sequence CDATA #IMPLIED required CDATA #IMPLIED occurs CDATA #IMPLIED used (Y | N) "Y" xmlTag CDATA #IMPLIED> <!ELEMENT dataElement (idList | idListClass | idListFile)?> <!ATTLIST dataElement name CDATA #REQUIRED id CDATA #REQUIRED type (A | AN | B | DT | ID | N | N0 | N1 | N2 | N3 | N4 | N5 | N6 | N7 | N8 | N9 | R | TM) #REQUIRED sequence CDATA #IMPLIED required CDATA #IMPLIED description CDATA #IMPLIED minLength CDATA #REQUIRED maxLength CDATA #REQUIRED occurs CDATA #IMPLIED used (Y | N) "Y" xmlTag CDATA #IMPLIED> <!ELEMENT idList ((idCode, idValue?)*)> <!ELEMENT idCode (#PCDATA)> <!ATTLIST idCode used (Y | N) "Y"> <!ELEMENT idValue (#PCDATA)> <!ELEMENT idListClass EMPTY> <!ATTLIST idListClass className CDATA #REQUIRED> <!ELEMENT idListFile EMPTY> <!ATTLIST idListFile fileName CDATA #REQUIRED include CDATA #IMPLIED exclude CDATA #IMPLIED> <!ELEMENT copySegment EMPTY> <!ATTLIST copySegment refid CDATA #REQUIRED>
  1. transactionSet - root contains 1 to 3 tables
      Attributes
    • name - short description
    • id - as defined by a standards group (e.g.. 840 - X12)
    • description - long description
    • revision - standards group release number (e.g.. 4010 - X12)
    • functionalGroup - standards group id (e.g., FA - X12)
    • xmlTag - used when creating/parsing EDI/XML files
  2. table contain one to many segments or loops
      Attributes
    • Table section name Header, Detail or Summary
  3. loop contain one to many segments or loops OR one copyLoop
      Attributes
    • name - short description
    • id - as defined by a standards group (e.g.. PO1 - X12)
    • description - long description
    • occurs - repeats 1 or more times
    • required - edit rule
    • used - the loop is defined in the standards but not used by this implemenation
    • xmlTag - used when creating/parsing EDI/XML files
  4. copyLoop - used to copy a loop of the exact same structure
    • refid, id of the loop to copy.
  5. segment contain composite data elements and data elements OR one copySegment
      Attributes
    • name - short description
    • id - as defined by a standards group (e.g.. PO1 - X12)
    • description - long description
    • sequence - position within segment
    • occurs - repeats 1 or more times
    • required - edit rule
    • used - the segment is defined in the standards but not used by this implemenation
    • xmlTag - used when creating/parsing EDI/XML files
  6. compositeDE or Composite Data Elements contain data elements
      Attributes
    • name - short description
    • id - as defined by a standards group (e.g.. C030 - X12)
    • description - long description
    • sequence - position within segment
    • occurs - repeats 1 or more times
    • required - edit rule
    • used - the composite is defined in the standards but not used by this implemenation
    • xmlTag - used when creating/parsing EDI/XML files
  7. dataElement - defines most basic of EDI data structure and they may contain some type of id list control element
      Attributes
    • name - short description
    • id - as defined by a standards e.g.. C030 - X12)
    • description - long description
    • type - Char, date, time, id, real or numeric
    • sequence - position within segment or composite
    • occurs - repeats 1 or more times
    • required - M mandatory, O optional, C computed
    • minLength - minimum length
    • maxLength - maximum length
    • used - the data element is defined in the standards but not used by this implemenation
    • xmlTag - used when creating/parsing EDI/XML files
  8. ID List Control Elements
    • IDList may contain multiple idCode and idValue pairs
        Pair Values
      • idCode - value to be transmitted.
      • idValue - meaningful description, this is optional and will default to the idCode value.
    • idListClass - name of a Java class to provide the idCode and idList pairs
        Attributes
      • className - a fully qualified java class name that implements IDListProcessor.
    • idListFile - a XML file name that contains the idCode and idList pairs
        Attributes
      • fileName - a fully qualified file name that is validated by the idlist.dtd file.
  9. copySegment - used to copy a segment of the exact same structure
    • refid, id of the segment to copy.

OBOE Extended Edition

<?xml encoding="UTF-8"?> <!-- OBOE release 3.5.0 Thursday, February 22, 2007--> <!-- http://www.americancoders.com --> <!-- OBOE - Open Business Objects for EDI --> <!-- Purpose: validates EDI rules --> <!-- 3.4.0 change: added used attribute to most major nodes, added exclude/include to idlistfile--> <!-- 3.5.0 change: further defined type attribute of dataElement node added exclude/include to idlistfile--> <!-- 3.5.9 change: relaxed rule for idValue node in idList node now an optional node --> <!ELEMENT transactionSet (table+)> <!ATTLIST transactionSet name CDATA #REQUIRED id CDATA #REQUIRED revision CDATA #IMPLIED functionalGroup CDATA #IMPLIED description CDATA #IMPLIED validatingMethod CDATA #IMPLIED xmlTag CDATA #IMPLIED> <!ELEMENT table (segment?, loop?)*> <!ATTLIST table validatingMethod CDATA #IMPLIED section (header | detail | summary) "header"> <!ELEMENT loop (((segment?, loop?)*)|(copyLoop))> <!ATTLIST loop name CDATA #REQUIRED id CDATA #REQUIRED occurs CDATA #REQUIRED required (M | O | C) "M" validatingMethod CDATA #IMPLIED used (Y | N) "Y" xmlTag CDATA #IMPLIED> <!ELEMENT copyLoop EMPTY> <!ATTLIST copyLoop refid CDATA #REQUIRED> <!ELEMENT segment (((compositeDE?, dataElement?)*, elementRule*)|(copySegment))> <!ATTLIST segment name CDATA #REQUIRED id CDATA #REQUIRED sequence CDATA #REQUIRED description CDATA #IMPLIED occurs CDATA #IMPLIED required (M | O | C) "M" validatingMethod CDATA #IMPLIED used (Y | N) "Y" xmlTag CDATA #IMPLIED> <!ELEMENT compositeDE (dataElement)+> <!ATTLIST compositeDE name CDATA #REQUIRED id CDATA #REQUIRED description CDATA #IMPLIED sequence CDATA #IMPLIED required CDATA #IMPLIED occurs CDATA #IMPLIED validatingMethod CDATA #IMPLIED used (Y | N) "Y" xmlTag CDATA #IMPLIED> <!ELEMENT dataElement ((idList | idListClass | idListFile)?, (default)?)> <!ATTLIST dataElement name CDATA #REQUIRED id CDATA #REQUIRED type (A | AN | B | DT | ID | N| N0 | N1 | N2 | N3 | N4 | N5 | N6 | N7 | N8 | N9 | R | TM) #REQUIRED sequence CDATA #IMPLIED required CDATA #IMPLIED description CDATA #IMPLIED minLength CDATA #REQUIRED maxLength CDATA #REQUIRED occurs CDATA #IMPLIED validatingMethod CDATA #IMPLIED used (Y | N) "Y" xmlTag CDATA #IMPLIED> <!ELEMENT idList ((idCode, idValue?)*)> <!ELEMENT idCode (#PCDATA)> <!ATTLIST idCode used (Y | N) "Y"> <!ELEMENT idValue (#PCDATA)> <!ELEMENT idListClass EMPTY> <!ATTLIST idListClass className CDATA #REQUIRED> <!ELEMENT idListFile EMPTY> <!ATTLIST idListFile fileName CDATA #REQUIRED include CDATA #IMPLIED exclude CDATA #IMPLIED> <!ELEMENT default (#PCDATA)> <!ATTLIST default from (constant | property | method) #REQUIRED> <!ELEMENT elementRule EMPTY> <!ATTLIST elementRule rule (oneOrMoreMustExist | ifFirstExistsThenAllMustExist | oneAndOnlyOneMayExist | ifFirstExistsThenAtLeastOneMoreMustExist | allOrNoneMayExist | ifFirstExistsThenNoOthersMayExist) #REQUIRED positions CDATA #REQUIRED> <!ELEMENT copySegment EMPTY> <!ATTLIST copySegment refid CDATA #REQUIRED>
  1. transactionSet - root contains 1 to 3 tables
      Attributes
    • name - short description
    • id - as defined by a standards group (e.g.. 840 - X12)
    • description - long description
    • revision - standards group release number (e.g.. 4010 - X12)
    • functionalGroup - standards group id (e.g., FA - X12)
    • validatingMethod - a static method called during an incoming message validation process.
    • xmlTag - used when creating/parsing EDI/XML files
  2. table contain one to many segments or loops
      Attributes
    • Table section name Header, Detail or Summary
  3. loop contain one to many segments or loops OR one copyLoop
      Attributes
    • name - short description
    • id - as defined by a standards group (e.g.. PO1 - X12)
    • description - long description
    • occurs - repeats 1 or more times
    • required - edit rule
    • used - the loop is defined in the standards but not used by this implemenation
    • validatingMethod - a static method called during an incoming message validation process.
    • xmlTag - used when creating/parsing EDI/XML files
  4. copyLoop - used to copy a loop of the exact same structure
    • refid, id of the loop to copy.
  5. segment contain composite data elements and data elements OR one copySegment
      Attributes
    • name - short description
    • id - as defined by a standards group (e.g.. PO1 - X12)
    • description - long description
    • sequence - position within segment
    • occurs - repeats 1 or more times
    • required - edit rule
    • used - the segment is defined in the standards but not used by this implemenation
    • validatingMethod - a static method called during an incoming message validation process.
    • xmlTag - used when creating/parsing EDI/XML files
  6. compositeDE or Composite Data Elements contain data elements
      Attributes
    • name - short description
    • id - as defined by a standards group (e.g.. C030 - X12)
    • description - long description
    • sequence - position within segment
    • occurs - repeats 1 or more times
    • required - edit rule
    • used - the composite is defined in the standards but not used by this implemenation
    • validatingMethod - a static method called during an incoming message validation process.
    • xmlTag - used when creating/parsing EDI/XML files
  7. dataElement - defines most basic of EDI data structure and they may contain some type of id list control element
      Attributes
    • name - short description
    • id - as defined by a standards e.g.. C030 - X12)
    • description - long description
    • type - Char, date, time, id, real or numeric
    • sequence - position within segment or composite
    • occurs - repeats 1 or more times
    • required - M mandatory, O optional, C computed
    • minLength - minimum length
    • maxLength - maximum length
    • used - the data element is defined in the standards but not used by this implemenation
    • validatingMethod - a static method called during an incoming message validation process.
    • xmlTag - used when creating/parsing EDI/XML files
  8. ID List Control Elements
    • IDList may contain multiple idCode and idValue pairs
        Pair Values
      • idCode - value to be transmitted.
      • idValue - meaningful description, this is optional and will default to the idCode value.
    • idListClass - name of a Java class to provide the idCode and idList pairs
        Attributes
      • className - a fully qualified java class name that implements IDListProcessor.
    • idListFile - a XML file name that contains the idCode and idList pairs
        Attributes
      • fileName - a fully qualified file name that is validated by the idlist.dtd file.
  9. default - defines ways to initialize data elements. Values are set on a dataElement object by calling its useDefault method.
      Attributes
    • from
      • constant - places contents of node value (#PCDATA) into dataelement
      • property - using node value field, searches oboe .properties file and uses value associated with particular property
      • method - calls a static method as defined by node value. format of value must by xxxxx#yyyyy where xxxxx is some class name and yyyyy is a static method in class. method must not take any parameters and it must return a String object.
  10. copySegment - used to copy a segment of the exact same structure
    • refid, id of the segment to copy.
  11. elementRule - defines logic for dataElements within a segment.
      Attributes
    • rule - defines the specific rule for datalements
      • oneOrMoreMustExist
      • ifFirstExistsThenAllMustExist
      • oneAndOnlyOneMayExist
      • ifFirstExistsThenAtLeastOneMoreMustExist
      • allOrNoneMayExist
      • ifFirstExistsThenNoOthersMayExist
    • positions - specifies elements to be tested by position as identified by sequence field in dataelement rule.
Copyright 2000 - 2007 - American Coders, Ltd Raleigh NC USA