6.7. The Atom Publishing Protocol (RFC5023)

This module defines functions and classes for working with the Atom Publishing Protocl as defined by RFC5023: http://www.ietf.org/rfc/rfc5023.txt

6.7.1. Reference

6.7.1.1. Elements

class pyslet.rfc5023.Service(parent)

Bases: pyslet.rfc5023.APPElement

The container for service information

Associated with one or more Workspaces.

Workspace = None

a list of Workspace instances

class pyslet.rfc5023.Workspace(parent)

Bases: pyslet.rfc5023.APPElement

Workspaces are server-defined groups of Collections.

Title = None

the title of this workspace

Collection = None

a list of Collection

class pyslet.rfc5023.Collection(parent)

Bases: pyslet.rfc5023.APPElement

Describes a collection (feed).

Title = None

the URI of the collection (feed)

Accept = None

the human readable title of the collection

Categories = None

list of Accept media ranges that can be posted to the collection

get_feed_url()

Returns a fully resolved URL for the collection (feed).

GetFeedURL(*args, **kwargs)

Deprecated equivalent to get_feed_url()

class pyslet.rfc5023.Categories(parent)

Bases: pyslet.rfc5023.APPElement

The root of a Category Document.

A category document is a document that describes the categories allowed in a collection.

fixed = None

an optional URI to the category

scheme = None

indicates whether the list of categories is a fixed set. By default they’re open.

Category = None

identifies the default scheme for categories defined by this element

6.7.1.2. Base Classes

class pyslet.rfc5023.Accept(parent, name=None)

Bases: pyslet.rfc5023.APPElement

Represents the accept element.

class pyslet.rfc5023.Document(**args)

Bases: pyslet.rfc4287.AtomDocument

Class for working with APP documents.

This call can represent both APP and Atom documents.

ValidateMimeType(mimetype)

Checks mimetype against the APP or Atom specifications.

classmethod get_element_class(name)

Returns the APP or Atom class used to represent name.

Overrides get_element_class() when the namespace is APP_NAMESPACE.

class pyslet.rfc5023.APPElement(parent, name=None)

Bases: pyslet.xml.namespace.NSElement

Base class for all APP elements.

All APP elements can have xml:base, xml:lang and/or xml:space attributes. These are handled by the base Element base class.

6.7.1.3. Constants

pyslet.rfc5023.APP_NAMESPACE = 'http://www.w3.org/2007/app'

The namespace to use for Atom Publishing Protocol elements

pyslet.rfc5023.ATOMSVC_MIMETYPE = 'application/atomsvc+xml'

The mime type for service documents

pyslet.rfc5023.ATOMCAT_MIMETYPE = 'application/atomcat+xml'

The mime type for category documents