You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

76 lines
2.1 KiB

  1. <?xml version="1.0" standalone="no"?>
  2. <!--
  3. * Licensed to the Apache Software Foundation (ASF) under one or more
  4. * contributor license agreements. See the NOTICE file distributed with
  5. * this work for additional information regarding copyright ownership.
  6. * The ASF licenses this file to You under the Apache License, Version 2.0
  7. * (the "License"); you may not use this file except in compliance with
  8. * the License. You may obtain a copy of the License at
  9. *
  10. * http://www.apache.org/licenses/LICENSE-2.0
  11. *
  12. * Unless required by applicable law or agreed to in writing, software
  13. * distributed under the License is distributed on an "AS IS" BASIS,
  14. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. * See the License for the specific language governing permissions and
  16. * limitations under the License.
  17. -->
  18. <!DOCTYPE s1 SYSTEM "sbk:/style/dtd/document.dtd">
  19. <s1 title="Sample: EnumVal">
  20. <s2 title="EnumVal">
  21. <p>EnumVal shows how to enumerate the markup declarations in a DTD Grammar.</p>
  22. <s3 title="Running EnumVal">
  23. <p>This program parses the specified XML file, then shows how to
  24. enumerate the contents of the DTD Grammar.</p>
  25. <source>
  26. Usage:
  27. EnumVal &lt;XML file&gt;
  28. This program parses the specified XML file, then shows how to
  29. enumerate the contents of the DTD Grammar. Essentially,
  30. shows how one can access the DTD information stored in internal
  31. data structures.
  32. </source>
  33. <p>Here is a sample output from EnumVal</p>
  34. <source>cd &XercesC3InstallDir;/samples/data
  35. EnumVal personal.xml
  36. ELEMENTS:
  37. ----------------------------
  38. Name: personnel
  39. Content Model: (person)+
  40. Name: person
  41. Content Model: (name,email*,url*,link?)
  42. Attributes:
  43. Name:id, Type: ID
  44. Name: name
  45. Content Model: (#PCDATA|family|given)*
  46. Name: email
  47. Content Model: (#PCDATA)*
  48. Name: url
  49. Content Model: EMPTY
  50. Attributes:
  51. Name:href, Type: CDATA
  52. Name: link
  53. Content Model: EMPTY
  54. Attributes:
  55. Name:subordinates, Type: IDREF(S)
  56. Name:manager, Type: IDREF(S)
  57. Name: family
  58. Content Model: (#PCDATA)*
  59. Name: given
  60. Content Model: (#PCDATA)*</source>
  61. </s3>
  62. </s2>
  63. </s1>