<!--
    Local copy of
    http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd

    $Id: catalog.dtd,v 1.2 2020/12/12 20:28:09 plm Exp $
-->

<!ENTITY % pubIdChars "CDATA">
<!ENTITY % publicIdentifier "%pubIdChars;">
<!ENTITY % partialPublicIdentifier "%pubIdChars;">
<!ENTITY % uriReference "CDATA">
<!ENTITY % string "CDATA">
<!ENTITY % systemOrPublic "(system|public)">

<!ENTITY % p "">
<!ENTITY % s "">
<!ENTITY % nsdecl "xmlns%s;">

<!ENTITY % catalog "%p;catalog">
<!ENTITY % public "%p;public">
<!ENTITY % system "%p;system">
<!ENTITY % uri "%p;uri">
<!ENTITY % rewriteSystem "%p;rewriteSystem">
<!ENTITY % rewriteURI "%p;rewriteURI">
<!ENTITY % delegatePublic "%p;delegatePublic">
<!ENTITY % delegateSystem "%p;delegateSystem">
<!ENTITY % delegateURI "%p;delegateURI">
<!ENTITY % nextCatalog "%p;nextCatalog">
<!ENTITY % group "%p;group">

<!ENTITY % local.catalog.mix "">
<!ENTITY % local.catalog.attribs "">

<!ELEMENT %catalog; (%public;|%system;|%uri;
                     |%rewriteSystem;|%rewriteURI;
                     |%delegatePublic;|%delegateSystem;|%delegateURI;
                     |%nextCatalog;|%group; %local.catalog.mix;)+>
<!ATTLIST %catalog;
	%nsdecl;	%uriReference;		#FIXED
		'urn:oasis:names:tc:entity:xmlns:xml:catalog'
	prefer		%systemOrPublic;	#IMPLIED
	xml:base	%uriReference;		#IMPLIED
	%local.catalog.attribs;
>

<!ENTITY % local.public.attribs "">

<!ELEMENT %public; EMPTY>
<!ATTLIST %public;
	id		ID			#IMPLIED
	publicId	%publicIdentifier;	#REQUIRED
	uri		%uriReference;		#REQUIRED
	xml:base	%uriReference;		#IMPLIED
        %local.public.attribs;
>

<!ENTITY % local.system.attribs "">

<!ELEMENT %system; EMPTY>
<!ATTLIST %system;
	id		ID			#IMPLIED
	systemId	%string;		#REQUIRED
	uri		%uriReference;		#REQUIRED
	xml:base	%uriReference;		#IMPLIED
        %local.system.attribs;
>

<!ENTITY % local.uri.attribs "">

<!ELEMENT %uri; EMPTY>
<!ATTLIST %uri;
	id		ID			#IMPLIED
	name		%string;		#REQUIRED
	uri		%uriReference;		#REQUIRED
	xml:base	%uriReference;		#IMPLIED
        %local.uri.attribs;
>

<!ENTITY % local.rewriteSystem.attribs "">

<!ELEMENT %rewriteSystem; EMPTY>
<!ATTLIST %rewriteSystem;
	id		ID			#IMPLIED
	systemIdStartString	%string;	#REQUIRED
	rewritePrefix		%string;		#REQUIRED
        %local.rewriteSystem.attribs;
>

<!ENTITY % local.rewriteURI.attribs "">

<!ELEMENT %rewriteURI; EMPTY>
<!ATTLIST %rewriteURI;
	id		ID			#IMPLIED
	uriStartString	%string;		#REQUIRED
	rewritePrefix	%string;		#REQUIRED
        %local.rewriteURI.attribs;
>

<!ENTITY % local.delegatePublic.attribs "">

<!ELEMENT %delegatePublic; EMPTY>
<!ATTLIST %delegatePublic;
	id		ID			#IMPLIED
	publicIdStartString	%partialPublicIdentifier;	#REQUIRED
	catalog		%uriReference;		#REQUIRED
	xml:base	%uriReference;		#IMPLIED
        %local.delegatePublic.attribs;
>

<!ENTITY % local.delegateSystem.attribs "">

<!ELEMENT %delegateSystem; EMPTY>
<!ATTLIST %delegateSystem;
	id		ID			#IMPLIED
	systemIdStartString	%string;	#REQUIRED
	catalog		%uriReference;		#REQUIRED
	xml:base	%uriReference;		#IMPLIED
        %local.delegateSystem.attribs;
>

<!ENTITY % local.delegateURI.attribs "">

<!ELEMENT %delegateURI; EMPTY>
<!ATTLIST %delegateURI;
	id		ID			#IMPLIED
	uriStartString	%string;		#REQUIRED
	catalog		%uriReference;		#REQUIRED
	xml:base	%uriReference;		#IMPLIED
        %local.delegateURI.attribs;
>

<!ENTITY % local.nextCatalog.attribs "">

<!ELEMENT %nextCatalog; EMPTY>
<!ATTLIST %nextCatalog;
	id		ID			#IMPLIED
	catalog		%uriReference;		#REQUIRED
	xml:base	%uriReference;		#IMPLIED
        %local.nextCatalog.attribs;
>

<!ENTITY % local.group.mix "">
<!ENTITY % local.group.attribs "">

<!ELEMENT %group; (%public;|%system;|%uri;
                   |%rewriteSystem;|%rewriteURI;
                   |%delegatePublic;|%delegateSystem;|%delegateURI;
                   |%nextCatalog; %local.group.mix;)+>
<!ATTLIST %group;
	id		ID			#IMPLIED
	prefer		%systemOrPublic;	#IMPLIED
	xml:base	%uriReference;		#IMPLIED
        %local.group.attribs;
>
