HOME XML-SCHEMA XML-EXAMPLES CHESS VARIANTS FBR MBN ANCP FAQ RESOURCES ABOUT

CIF - Index Data


<xs:complexType name="Index"> <xs:choice minOccurs="0" maxOccurs="unbounded"> <xs:element name="game" type="IndexGame"/> <xs:element name="document" type="DocumentEntry"/> </xs:choice> <xs:attribute name="creator" type="Signature" use="optional"> <xs:attribute name="signature" type="Signature" use="optional"> <xs:attribute name="version" type="xs:string" use="optional"> <xs:attribute name="type" type="IndexType" default="index"> </xs:complexType> <xs:complexType name="DocumentEntry"> <xs:complexContent> <xs:extension base="Empty"> <xs:attribute name="id" type="IndexID" use="required"/> </xs:extension> </xs:complexContent> </xs:complexType> <xs:simpleType name="IndexType"> <xs:restriction base="xs:token"> <xs:enumeration value="index"/> <xs:enumeration value="listing"/> </xs:restriction> </xs:simpleType>

An index section is mainly a container of game header information, each entry in the index section will be referenced by an ID. For every item type the specified ID must be unique. Normally the index section will be written at the beginning of the archive, after an optional namebase section, but this is not mandatory. But an index item must be written before it can be referenced. It is possible to split into more than one index section.

It is the decision of the application whether he is writing index sections, the compactness of a CCIF archive is not depending on this decision (not significantly). But it depends on the specific application if a namebase has an impact on the speed while reading the archive. The use of a namebase can be very useful for an application who is the creator of this archive. If the writer of the archive decides to write index sections, then it is mandatory that this section must contain all games and all document entries of this archive, no more, no less. If an index sections exists, then the order of the games/documents will be determined by the order in the index section, this means the order of the games/documents inside the archive is not siginificant anymore.

The writer of the index section can give the index a creator. It is not allowed to use a signature which is reserved for a specific application. The writer of an archive may use this creator, in combination with a specified database version in version, for a very fast processing of this archive. This works only if he can trust in the uniqueness of the signature.

Attribute signature is the default owner for all games belonging to this index section.

An index section may be used as a container for search results, or similar purposes. In this case the index entries are not referencing any game inside the archive, instead it is only a listing of game headers. For such listings the attribute type has to be set to listing.

Note that the empty element document is only a placeholder for a document section.



Google translation

Share this page

C/CIF at Sourceforge

C/CIF at Sourceforge

C/CIF at Launchpad

C/CIF at Launchpad