文書型 > Creating a Document Type Definition (DTD) > Understanding the Public Identifier
  
Understanding the Public Identifier
In SGML, every external entity has at least one external identifier associated with it. Each identifier is a kind of label by which the entity is known. An external identifier can be a “system identifier” (for example, a file name) that is used directly by the SGML system to locate the entity. Alternatively, an external identifier can be a “Public Identifier” that must be mapped to the appropriate storage object identifier, such as a file name, by the entity management catalog. The SGML standard defines a specific format for a class of Public Identifier known as a Formal Public Identifier (FPI).
The public text language must be a two-character name, entered with upper case letters. The name must be a language code from ISO 639 that identifies the principal natural language used in the public text.
* 
The SGML standard, ISO 8879–1986, disallows the following characters in public identifiers: semicolon (;), exclamation point (!), asterisk (*), number or hash sign (#), commercial at sign (@), dollar sign ($), underscore (_), and percentage sign (%). However, the XML standard allows these characters. Arbortext Editor supports the additional characters.
Arbortext Editor generally uses a Formal Public Identifier (FPI) to identify and locate a document type. This FPI is mapped to point to the DTD file in the document type directory.
If you are writing a new DTD, entering a unique name identifies the application publicly on your computer system. If you are setting up a document type using a DTD written elsewhere, check the DTD for comments that specify the FPI to be used with the DTD. An FPI for a DTD generally has the following syntax:
Owner ID //DTD Public Text Description//Public Text Language
The Owner ID identifies the owner of a public text. There are three kinds of public text owner identifiers:
Registered Owner ID — an owner identifier constructed in accordance with ISO 9070. It has the following format: +//Organization or Registry. At this time the only common use of registered owner identifiers is the use of ISBNs.
Unregistered Owner ID — an owner identifier that is not registered according to ISO 9070. It is guaranteed to be different from other Registered Owner IDs, but not from other Unregistered Owner IDs. It has the following format: -//Organization. This is by far the most common form at the present time.
ISO Owner ID — used to identify an ISO publication. An example is ISO 8879:1986.
The Document Type Description is a short description of the document type. The Language Code identifies the native language of the document type and is composed of two uppercase characters (for example, EN for English)
An example of a Public Identifier for the document type DocBook V3.0 is:
-//Davenport//DTD DocBook V3.0//EN.
A public document type declaration might look like this: <!DOCTYPE BOOK PUBLIC "-//Davenport//DTD DocBook V3.0//EN">