pydrive2 package¶
pydrive2.apiattr module¶
- class pydrive2.apiattr.ApiAttribute(name)¶
Bases:
object
A data descriptor that sets and returns values.
- class pydrive2.apiattr.ApiAttributeMixin¶
Bases:
object
Mixin to initialize required global variables to use ApiAttribute.
- class pydrive2.apiattr.ApiResource(*args, **kwargs)¶
Bases:
dict
Super class of all api resources.
Inherits and behaves as a python dictionary to handle api resources. Save clean copy of metadata in self.metadata as a dictionary. Provides changed metadata elements to efficiently update api resources.
- GetChanges()¶
Returns changed metadata elements to update api resources efficiently.
- Returns:
dict – changed metadata elements.
- UpdateMetadata(metadata=None)¶
Update metadata and mark all of them to be clean.
- auth¶
A data descriptor that sets and returns values.
- update(*args, **kwargs)¶
Overwritten method of dictionary.
- class pydrive2.apiattr.ApiResourceList(auth=None, metadata=None)¶
Bases:
ApiAttributeMixin
,ApiResource
Abstract class of all api list resources.
Inherits ApiResource and builds iterator to list any API resource.
- GetList()¶
Get list of API resources.
If ‘maxResults’ is not specified, it will automatically iterate through every resources available. Otherwise, it will make API call once and update ‘pageToken’.
- Returns:
list – list of API resources.
- Reset()¶
Resets current iteration
- metadata¶
A data descriptor that sets and returns values.