gdata.apps.migration | index /home/afshar/working/gdata-python-client/src/gdata/apps/migration/__init__.py

`Contains objects used with Google Apps.`

Package Contents
`` |  |
service |  |  |

Classes
`` |  | __builtin__.object MailEntryProperties atom.AtomBase(atom.ExtensionContainer) Label MailItemProperty Rfc822Msg gdata.BatchEntry(gdata.GDataEntry) BatchMailEntry gdata.BatchFeed(gdata.GDataFeed) BatchMailEventFeed gdata.GDataEntry(atom.Entry, gdata.LinkFinder) MailEntry
class BatchMailEntry(gdata.BatchEntry)
`` | `A Google Migration flavor of an Atom Entry.`
| Method resolution order: BatchMailEntry gdata.BatchEntry gdata.GDataEntry atom.Entry atom.FeedEntryParent atom.AtomBase atom.ExtensionContainer gdata.LinkFinder atom.LinkFinder __builtin__.object Methods defined here: __init__(self, author=None, category=None, content=None, atom_id=None, link=None, published=None, title=None, updated=None, rfc822_msg=None, mail_item_property=None, label=None, batch_operation=None, batch_id=None, batch_status=None, extended_property=None, extension_elements=None, extension_attributes=None, text=None) Methods inherited from gdata.GDataEntry: GetMediaURL(self) `Returns the URL to the media content, if the entry is a media entry. Otherwise returns None.` IsMedia(self) `Determines whether or not an entry is a GData Media entry.` Data descriptors inherited from gdata.GDataEntry: id Methods inherited from atom.AtomBase: ToString(self, string_encoding='UTF-8') `Converts the Atom object to a string containing XML.` __str__(self) Methods inherited from atom.ExtensionContainer: FindExtensions(self, tag=None, namespace=None) `Searches extension elements for child nodes with the desired name. Returns a list of extension elements within this object whose tag and/or namespace match those passed in. To find all extensions in a particular namespace, specify the namespace but not the tag name. If you specify only the tag, the result list may contain extension elements in multiple namespaces. Args: tag: str (optional) The desired tag namespace: str (optional) The desired namespace Returns: A list of elements whose tag and/or namespace match the parameters values` Data descriptors inherited from atom.ExtensionContainer: __dict__ `dictionary for instance variables (if defined)` __weakref__ `list of weak references to the object (if defined)` Methods inherited from gdata.LinkFinder: GetAclLink(self) GetEditLink(self) GetEditMediaLink(self) `The Picasa API mistakenly returns media-edit rather than edit-media, but this may change soon.` GetFeedLink(self) GetHtmlLink(self) `Find the first link with rel of alternate and type of text/html Returns: An atom.Link or None if no links matched` GetNextLink(self) GetPostLink(self) `Get a link containing the POST target URL. The POST target URL is used to insert new entries. Returns: A link object with a rel matching the POST type.` GetPrevLink(self) GetSelfLink(self) `Find the first link with rel set to 'self' Returns: An atom.Link or none if none of the links had rel equal to 'self'` Methods inherited from atom.LinkFinder: GetAlternateLink(self) GetLicenseLink(self)
class BatchMailEventFeed(gdata.BatchFeed)
`` | `A Migration event feed flavor of an Atom Feed.`
| Method resolution order: BatchMailEventFeed gdata.BatchFeed gdata.GDataFeed atom.Feed atom.Source atom.FeedEntryParent atom.AtomBase atom.ExtensionContainer gdata.LinkFinder atom.LinkFinder __builtin__.object Methods defined here: __init__(self, author=None, category=None, contributor=None, generator=None, icon=None, atom_id=None, link=None, logo=None, rights=None, subtitle=None, title=None, updated=None, entry=None, total_results=None, start_index=None, items_per_page=None, interrupted=None, extension_elements=None, extension_attributes=None, text=None) Methods inherited from gdata.BatchFeed: AddBatchEntry(self, entry=None, id_url_string=None, batch_id_string=None, operation_string=None) `Logic for populating members of a BatchEntry and adding to the feed. If the entry is not a BatchEntry, it is converted to a BatchEntry so that the batch specific members will be present. The id_url_string can be used in place of an entry if the batch operation applies to a URL. For example query and delete operations require just the URL of an entry, no body is sent in the HTTP request. If an id_url_string is sent instead of an entry, a BatchEntry is created and added to the feed. This method also assigns the desired batch id to the entry so that it can be referenced in the server's response. If the batch_id_string is None, this method will assign a batch_id to be the index at which this entry will be in the feed's entry list. Args: entry: BatchEntry, atom.Entry, or another Entry flavor (optional) The entry which will be sent to the server as part of the batch request. The item must have a valid atom id so that the server knows which entry this request references. id_url_string: str (optional) The URL of the entry to be acted on. You can find this URL in the text member of the atom id for an entry. If an entry is not sent, this id will be used to construct a new BatchEntry which will be added to the request feed. batch_id_string: str (optional) The batch ID to be used to reference this batch operation in the results feed. If this parameter is None, the current length of the feed's entry array will be used as a count. Note that batch_ids should either always be specified or never, mixing could potentially result in duplicate batch ids. operation_string: str (optional) The desired batch operation which will set the batch_operation.type member of the entry. Options are 'insert', 'update', 'delete', and 'query' Raises: MissingRequiredParameters: Raised if neither an id_ url_string nor an entry are provided in the request. Returns: The added entry.` AddDelete(self, url_string=None, entry=None, batch_id_string=None) `Adds a delete request to the batch request feed. This method takes either the url_string which is the atom id of the item to be deleted, or the entry itself. The atom id of the entry must be present so that the server knows which entry should be deleted. Args: url_string: str (optional) The URL of the entry to be deleted. You can find this URL in the text member of the atom id for an entry. entry: BatchEntry (optional) The entry to be deleted. batch_id_string: str (optional) Raises: MissingRequiredParameters: Raised if neither a url_string nor an entry are provided in the request.` AddInsert(self, entry, batch_id_string=None) `Add an insert request to the operations in this batch request feed. If the entry doesn't yet have an operation or a batch id, these will be set to the insert operation and a batch_id specified as a parameter. Args: entry: BatchEntry The entry which will be sent in the batch feed as an insert request. batch_id_string: str (optional) The batch ID to be used to reference this batch operation in the results feed. If this parameter is None, the current length of the feed's entry array will be used as a count. Note that batch_ids should either always be specified or never, mixing could potentially result in duplicate batch ids.` AddQuery(self, url_string=None, entry=None, batch_id_string=None) `Adds a query request to the batch request feed. This method takes either the url_string which is the query URL whose results will be added to the result feed. The query URL will be encapsulated in a BatchEntry, and you may pass in the BatchEntry with a query URL instead of sending a url_string. Args: url_string: str (optional) entry: BatchEntry (optional) batch_id_string: str (optional) Raises: MissingRequiredParameters` AddUpdate(self, entry, batch_id_string=None) `Add an update request to the list of batch operations in this feed. Sets the operation type of the entry to insert if it is not already set and assigns the desired batch id to the entry so that it can be referenced in the server's response. Args: entry: BatchEntry The entry which will be sent to the server as an update (HTTP PUT) request. The item must have a valid atom id so that the server knows which entry to replace. batch_id_string: str (optional) The batch ID to be used to reference this batch operation in the results feed. If this parameter is None, the current length of the feed's entry array will be used as a count. See also comments for AddInsert.` GetBatchLink(self) Data descriptors inherited from gdata.GDataFeed: generator id Methods inherited from atom.AtomBase: ToString(self, string_encoding='UTF-8') `Converts the Atom object to a string containing XML.` __str__(self) Methods inherited from atom.ExtensionContainer: FindExtensions(self, tag=None, namespace=None) `Searches extension elements for child nodes with the desired name. Returns a list of extension elements within this object whose tag and/or namespace match those passed in. To find all extensions in a particular namespace, specify the namespace but not the tag name. If you specify only the tag, the result list may contain extension elements in multiple namespaces. Args: tag: str (optional) The desired tag namespace: str (optional) The desired namespace Returns: A list of elements whose tag and/or namespace match the parameters values` Data descriptors inherited from atom.ExtensionContainer: __dict__ `dictionary for instance variables (if defined)` __weakref__ `list of weak references to the object (if defined)` Methods inherited from gdata.LinkFinder: GetAclLink(self) GetEditLink(self) GetEditMediaLink(self) `The Picasa API mistakenly returns media-edit rather than edit-media, but this may change soon.` GetFeedLink(self) GetHtmlLink(self) `Find the first link with rel of alternate and type of text/html Returns: An atom.Link or None if no links matched` GetNextLink(self) GetPostLink(self) `Get a link containing the POST target URL. The POST target URL is used to insert new entries. Returns: A link object with a rel matching the POST type.` GetPrevLink(self) GetSelfLink(self) `Find the first link with rel set to 'self' Returns: An atom.Link or none if none of the links had rel equal to 'self'` Methods inherited from atom.LinkFinder: GetAlternateLink(self) GetLicenseLink(self)
class Label(atom.AtomBase)
`` | `The Migration label element.`
| Method resolution order: Label atom.AtomBase atom.ExtensionContainer __builtin__.object Methods defined here: __init__(self, label_name=None, extension_elements=None, extension_attributes=None, text=None) Methods inherited from atom.AtomBase: ToString(self, string_encoding='UTF-8') `Converts the Atom object to a string containing XML.` __str__(self) Methods inherited from atom.ExtensionContainer: FindExtensions(self, tag=None, namespace=None) `Searches extension elements for child nodes with the desired name. Returns a list of extension elements within this object whose tag and/or namespace match those passed in. To find all extensions in a particular namespace, specify the namespace but not the tag name. If you specify only the tag, the result list may contain extension elements in multiple namespaces. Args: tag: str (optional) The desired tag namespace: str (optional) The desired namespace Returns: A list of elements whose tag and/or namespace match the parameters values` Data descriptors inherited from atom.ExtensionContainer: __dict__ `dictionary for instance variables (if defined)` __weakref__ `list of weak references to the object (if defined)`
class MailEntry(gdata.GDataEntry)
`` | `A Google Migration flavor of an Atom Entry.`
| Method resolution order: MailEntry gdata.GDataEntry atom.Entry atom.FeedEntryParent atom.AtomBase atom.ExtensionContainer gdata.LinkFinder atom.LinkFinder __builtin__.object Methods defined here: __init__(self, author=None, category=None, content=None, atom_id=None, link=None, published=None, title=None, updated=None, rfc822_msg=None, mail_item_property=None, label=None, extended_property=None, extension_elements=None, extension_attributes=None, text=None) Methods inherited from gdata.GDataEntry: GetMediaURL(self) `Returns the URL to the media content, if the entry is a media entry. Otherwise returns None.` IsMedia(self) `Determines whether or not an entry is a GData Media entry.` Data descriptors inherited from gdata.GDataEntry: id Methods inherited from atom.AtomBase: ToString(self, string_encoding='UTF-8') `Converts the Atom object to a string containing XML.` __str__(self) Methods inherited from atom.ExtensionContainer: FindExtensions(self, tag=None, namespace=None) `Searches extension elements for child nodes with the desired name. Returns a list of extension elements within this object whose tag and/or namespace match those passed in. To find all extensions in a particular namespace, specify the namespace but not the tag name. If you specify only the tag, the result list may contain extension elements in multiple namespaces. Args: tag: str (optional) The desired tag namespace: str (optional) The desired namespace Returns: A list of elements whose tag and/or namespace match the parameters values` Data descriptors inherited from atom.ExtensionContainer: __dict__ `dictionary for instance variables (if defined)` __weakref__ `list of weak references to the object (if defined)` Methods inherited from gdata.LinkFinder: GetAclLink(self) GetEditLink(self) GetEditMediaLink(self) `The Picasa API mistakenly returns media-edit rather than edit-media, but this may change soon.` GetFeedLink(self) GetHtmlLink(self) `Find the first link with rel of alternate and type of text/html Returns: An atom.Link or None if no links matched` GetNextLink(self) GetPostLink(self) `Get a link containing the POST target URL. The POST target URL is used to insert new entries. Returns: A link object with a rel matching the POST type.` GetPrevLink(self) GetSelfLink(self) `Find the first link with rel set to 'self' Returns: An atom.Link or none if none of the links had rel equal to 'self'` Methods inherited from atom.LinkFinder: GetAlternateLink(self) GetLicenseLink(self)
class MailEntryProperties(__builtin__.object)
`` | `Represents a mail message and its attributes.`
| Methods defined here: __init__(self, mail_message=None, mail_item_properties=None, mail_labels=None, identifier=None) Data descriptors defined here: __dict__ `dictionary for instance variables (if defined)` __weakref__ `list of weak references to the object (if defined)`
class MailItemProperty(atom.AtomBase)
`` | `The Migration mailItemProperty element.`
| Method resolution order: MailItemProperty atom.AtomBase atom.ExtensionContainer __builtin__.object Methods defined here: __init__(self, value=None, extension_elements=None, extension_attributes=None, text=None) Methods inherited from atom.AtomBase: ToString(self, string_encoding='UTF-8') `Converts the Atom object to a string containing XML.` __str__(self) Methods inherited from atom.ExtensionContainer: FindExtensions(self, tag=None, namespace=None) `Searches extension elements for child nodes with the desired name. Returns a list of extension elements within this object whose tag and/or namespace match those passed in. To find all extensions in a particular namespace, specify the namespace but not the tag name. If you specify only the tag, the result list may contain extension elements in multiple namespaces. Args: tag: str (optional) The desired tag namespace: str (optional) The desired namespace Returns: A list of elements whose tag and/or namespace match the parameters values` Data descriptors inherited from atom.ExtensionContainer: __dict__ `dictionary for instance variables (if defined)` __weakref__ `list of weak references to the object (if defined)`
class Rfc822Msg(atom.AtomBase)
`` | `The Migration rfc822Msg element.`
| Method resolution order: Rfc822Msg atom.AtomBase atom.ExtensionContainer __builtin__.object Methods defined here: __init__(self, extension_elements=None, extension_attributes=None, text=None) Methods inherited from atom.AtomBase: ToString(self, string_encoding='UTF-8') `Converts the Atom object to a string containing XML.` __str__(self) Methods inherited from atom.ExtensionContainer: FindExtensions(self, tag=None, namespace=None) `Searches extension elements for child nodes with the desired name. Returns a list of extension elements within this object whose tag and/or namespace match those passed in. To find all extensions in a particular namespace, specify the namespace but not the tag name. If you specify only the tag, the result list may contain extension elements in multiple namespaces. Args: tag: str (optional) The desired tag namespace: str (optional) The desired namespace Returns: A list of elements whose tag and/or namespace match the parameters values` Data descriptors inherited from atom.ExtensionContainer: __dict__ `dictionary for instance variables (if defined)` __weakref__ `list of weak references to the object (if defined)`

Functions
`` |  | BatchMailEntryFromString(xml_string) `Parse in the BatchMailEntry from the XML definition.` BatchMailEventFeedFromString(xml_string) `Parse in the BatchMailEventFeed from the XML definition.` LabelFromString(xml_string) `Parse in the mailItemProperty from the XML definition.` MailEntryFromString(xml_string) `Parse in the MailEntry from the XML definition.` MailItemPropertyFromString(xml_string) `Parse in the MailItemProperiy from the XML definition.` Rfc822MsgFromString(xml_string) `Parse in the Rrc822 message from the XML definition.`

Data
`` |  | APPS_NAMESPACE = 'http://schemas.google.com/apps/2006' APPS_TEMPLATE = '{http://schemas.google.com/apps/2006}%s' __author__ = 'google-apps-apis@googlegroups.com'

Author
`` |  | google-apps-apis@googlegroups.com