XML схема FBA - формата информации об авторе
Материал из FictionBook.
(Различия между версиями)
Версия 07:32, 29 марта 2007 FBAdmin (Обсуждение | вклад) ← К предыдущему изменению |
Текущая версия FBAdmin (Обсуждение | вклад) |
||
Строка 1: | Строка 1: | ||
Данная схема описывает формат информации об авторе, включая данные, биографию и библиографию. | Данная схема описывает формат информации об авторе, включая данные, биографию и библиографию. | ||
+ | Скачать схему можно [ftp://ftp.fictionbook.org/pub/FBA/FBA.xsd здесь]. | ||
<pre> | <pre> |
Текущая версия
Данная схема описывает формат информации об авторе, включая данные, биографию и библиографию. Скачать схему можно здесь.
<?xml version="1.0" encoding="UTF-8"?> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.alexs.ru/xml/fbauthor/1.0" xmlns="http://www.alexs.ru/xml/fbauthor/1.0" attributeFormDefault="unqualified" elementFormDefault="qualified" version="1.0"> <xsd:element name="FBA" type="FBAType"> <xsd:annotation> <xsd:documentation xml:lang="en">Root element</xsd:documentation> <xsd:documentation xml:lang="ru">Корневой элемент</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:complexType name="FBAType"> <xsd:sequence> <xsd:element name="fbAuthor" maxOccurs="unbounded" type="AuthorRecordType"> <xsd:annotation> <xsd:documentation xml:lang="en">Record about author</xsd:documentation> <xsd:documentation xml:lang="ru">Запись об авторе</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="photo" minOccurs="0" type="PhotoType"> <xsd:annotation> <xsd:documentation xml:lang="en">Author's photo</xsd:documentation> <xsd:documentation xml:lang="ru">Фотография автора</xsd:documentation> </xsd:annotation> </xsd:element> </xsd:sequence> </xsd:complexType> <xsd:complexType name="AuthorRecordType"> <xsd:sequence> <xsd:element name="document-info" type="DocumentInfoType"> <xsd:annotation> <xsd:documentation xml:lang="en">Information about this particular (xml) document</xsd:documentation> <xsd:documentation xml:lang="ru">Информация об этом документе</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="author-info" type="AuthorInfoType"> <xsd:annotation> <xsd:documentation xml:lang="en">Information about author</xsd:documentation> <xsd:documentation xml:lang="ru">Информация об авторе</xsd:documentation> </xsd:annotation> </xsd:element> </xsd:sequence> <xsd:attribute use="required" name="lang" type="xsd:language"/> </xsd:complexType> <xsd:complexType name="DocumentInfoType"> <xsd:sequence> <xsd:element name="author" type="authorType" maxOccurs="unbounded"> <xsd:annotation> <xsd:documentation xml:lang="en">Author this particular (xml) document</xsd:documentation> <xsd:documentation xml:lang="ru">Автор этого документа</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="date" type="DateType"> <xsd:annotation> <xsd:documentation xml:lang="en">Date document was written</xsd:documentation> <xsd:documentation xml:lang="ru">Дата подготовки документа</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="last-updating" type="DateType"> <xsd:annotation> <xsd:documentation xml:lang="en">Date of last updating</xsd:documentation> <xsd:documentation xml:lang="ru">Дата последней модификации</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="src-url" type="xsd:anyURI" minOccurs="0" maxOccurs="unbounded"> <xsd:annotation> <xsd:documentation xml:lang="en">Source URL if this document is a conversion of some other (online) document</xsd:documentation> <xsd:documentation xml:lang="ru">Исходный URL, если этот документ - преобразование некоторого другого документа (онлайн)</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="id" type="xsd:token"> <xsd:annotation> <xsd:documentation xml:lang="en">This is a unique identifier for a document. This must not change unless you make substantial updates to the document</xsd:documentation> <xsd:documentation xml:lang="ru">Уникальный идентификатор документа. Он не должен меняться при изменении и перезаливки документа</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="version" type="xsd:float"> <xsd:annotation> <xsd:documentation xml:lang="en">Document version, in free format, should be incremented if the document is changed and re-released to the public</xsd:documentation> <xsd:documentation xml:lang="ru">Версия документа в свободном формате, должна увеличиваться при изменении и перезаливки документа</xsd:documentation> </xsd:annotation> </xsd:element> </xsd:sequence> </xsd:complexType> <xsd:complexType name="AuthorInfoType"> <xsd:sequence> <xsd:element name="author" type="authorType"> <xsd:annotation> <xsd:documentation xml:lang="en">Author</xsd:documentation> <xsd:documentation xml:lang="ru">Автор</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="synonym" type="authorType" minOccurs="0" maxOccurs="unbounded"> <xsd:annotation> <xsd:documentation xml:lang="en">Synonym for that autor(unfull names, incorrect names, other language)</xsd:documentation> <xsd:documentation xml:lang="ru">Синонимы для этого автора (неполные имена, ошибочно написанные имена, имена на других языках)</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="born" type="DateType" minOccurs="0"> <xsd:annotation> <xsd:documentation xml:lang="en">Birthday of the author</xsd:documentation> <xsd:documentation xml:lang="ru">День рождения автора</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="dead" type="DateType" minOccurs="0"> <xsd:annotation> <xsd:documentation xml:lang="en">Day of death of the author</xsd:documentation> <xsd:documentation xml:lang="ru">День смерти автора</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="biography" minOccurs="0" type="BiographyType"> <xsd:annotation> <xsd:documentation xml:lang="en">Author's biography</xsd:documentation> <xsd:documentation xml:lang="ru">Биография автора</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="bibliography" minOccurs="0" type="BibliographyType"> <xsd:annotation> <xsd:documentation xml:lang="en">Author's bibliography</xsd:documentation> <xsd:documentation xml:lang="ru">Библиография автора</xsd:documentation> </xsd:annotation> </xsd:element> </xsd:sequence> </xsd:complexType> <xsd:complexType name="authorType"> <xsd:choice> <xsd:sequence> <xsd:element name="first-name" type="xsd:token" default="Noname"> <xsd:annotation> <xsd:documentation xml:lang="en">The type xsd:token is a line without initial and final blanks and symbols of the end of a line, single blanks between words are supposed only</xsd:documentation> <xsd:documentation xml:lang="ru">Тип xsd:token - это строка без начальных и конечных пробелов и переводов строки, допускаются только одиночные пробелы между словами</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="middle-name" type="xsd:token" minOccurs="0"/> <xsd:element name="last-name" type="xsd:token" default="Unknown"/> <xsd:element name="nickname" type="xsd:token" minOccurs="0"/> <xsd:element name="home-page" type="xsd:anyURI" minOccurs="0"> <xsd:annotation> <xsd:documentation xml:lang="en">Examples of use of type xsd:anyURI - http://www.any.ru/index.html, mailto:author@mybooks.ru</xsd:documentation> <xsd:documentation xml:lang="ru">Примеры использования типа xsd:anyURI - http://www.any.ru/index.html, mailto:author@mybooks.ru</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="email" type="xsd:anyURI" minOccurs="0"/> </xsd:sequence> <xsd:sequence> <xsd:element name="nickname" type="xsd:token"/> <xsd:element name="home-page" type="xsd:anyURI" minOccurs="0"/> <xsd:element name="email" type="xsd:anyURI" minOccurs="0"/> </xsd:sequence> </xsd:choice> </xsd:complexType> <xsd:complexType name="Biblio-recordType"> <xsd:sequence> <xsd:element name="year" type="xsd:gYear"> <xsd:annotation> <xsd:documentation xml:lang="en">Year, when book was written</xsd:documentation> <xsd:documentation xml:lang="ru">Год, когда книга была написана</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="title" type="xsd:token"> <xsd:annotation> <xsd:documentation xml:lang="en">Title of book</xsd:documentation> <xsd:documentation xml:lang="ru">Название книги</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="coauthor" type="authorType" minOccurs="0" maxOccurs="unbounded"> <xsd:annotation> <xsd:documentation xml:lang="en">Co-аuthor of this book</xsd:documentation> <xsd:documentation xml:lang="ru">Соавторы этой книги</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="book-link" type="xsd:anyURI" minOccurs="0"> <xsd:annotation> <xsd:documentation xml:lang="en">Link to book</xsd:documentation> <xsd:documentation xml:lang="ru">Ссылка на книгу</xsd:documentation> </xsd:annotation> </xsd:element> </xsd:sequence> </xsd:complexType> <xsd:complexType name="BiographyType"> <xsd:annotation> <xsd:documentation xml:lang="en">Biography (the short information about the author)</xsd:documentation> <xsd:documentation xml:lang="ru">Короткая биографическая информация об авторе</xsd:documentation> </xsd:annotation> <xsd:choice minOccurs="1" maxOccurs="unbounded"> <xsd:element name="p" type="PType"> <xsd:annotation> <xsd:documentation xml:lang="en">The paragraph - a string limited by a symbol of a new line.</xsd:documentation> <xsd:documentation xml:lang="ru">Параграф - строка, ограниченная символом новой строки.</xsd:documentation> </xsd:annotation> </xsd:element> <xsd:element name="cite" minOccurs="0" type="CiteType"> <xsd:annotation> <xsd:documentation xml:lang="en">Cite</xsd:documentation> <xsd:documentation xml:lang="ru">Цитата</xsd:documentation> </xsd:annotation> </xsd:element> </xsd:choice> </xsd:complexType> <xsd:complexType name="DateType"> <xsd:annotation> <xsd:documentation xml:lang="en">A human readable date, maybe not exact, with an optional computer readable variant</xsd:documentation> <xsd:documentation xml:lang="ru">Свободный вариант написания даты с опциональным стандартным типом xsd:date, для обработки компьютером</xsd:documentation> </xsd:annotation> <xsd:simpleContent> <xsd:extension base="xsd:string"> <xsd:attribute name="value" type="xsd:date" use="optional"/> </xsd:extension> </xsd:simpleContent> </xsd:complexType> <xsd:complexType name="PhotoType"> <xsd:annotation> <xsd:documentation xml:lang="en">The author's photo in base64 format</xsd:documentation> <xsd:documentation xml:lang="ru">Фотография автора в формате base64</xsd:documentation> </xsd:annotation> <xsd:simpleContent> <xsd:extension base="xsd:base64Binary"> <xsd:attribute name="content-type" type="xsd:string" use="required"/> </xsd:extension> </xsd:simpleContent> </xsd:complexType> <xsd:complexType name="BibliographyType"> <xsd:annotation> <xsd:documentation xml:lang="en">Bibliography by years</xsd:documentation> <xsd:documentation xml:lang="ru">Библиография произведений автора, выпущенных на соответствующем языке, по годам</xsd:documentation> </xsd:annotation> <xsd:sequence> <xsd:element name="Biblio-record" type="Biblio-recordType" minOccurs="0" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> <xsd:complexType name="PType" mixed="true"> <xsd:choice maxOccurs="unbounded"> <xsd:element name="strong" minOccurs="0" type="StyleType"/> <xsd:element name="emphasis" minOccurs="0" type="StyleType"/> </xsd:choice> </xsd:complexType> <xsd:complexType name="CiteType" mixed="true"> <xsd:sequence minOccurs="1" maxOccurs="1"> <xsd:choice minOccurs="1" maxOccurs="unbounded"> <xsd:element name="strong" minOccurs="0" type="StyleType"/> <xsd:element name="emphasis" minOccurs="0" type="StyleType"/> </xsd:choice> <xsd:element name="text-author" minOccurs="0" maxOccurs="unbounded" type="xsd:string"/> </xsd:sequence> </xsd:complexType> <xsd:complexType name="StyleType"> <xsd:annotation> <xsd:documentation xml:lang="en">Markup</xsd:documentation> <xsd:documentation xml:lang="ru">Стилевое выделение текста</xsd:documentation> </xsd:annotation> <xsd:choice minOccurs="0" maxOccurs="unbounded"> <xsd:element name="strong" type="StyleType"/> <xsd:element name="emphasis" type="StyleType"/> </xsd:choice> </xsd:complexType> </xsd:schema>