blob: 501492877b7472cdb1bb88d7c1ec788eb8b20c31 [file] [log] [blame]
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><title>Python: class Resource</title>
</head><body bgcolor="#f0f0f8">
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ffc8d8">
<td colspan=3 valign=bottom>&nbsp;<br>
<font color="#000000" face="helvetica, arial"><a name="Resource">class <strong>Resource</strong></a>(<a href="__builtin__.html#object">__builtin__.object</a>)</font></td></tr>
<tr bgcolor="#ffc8d8"><td rowspan=2><tt>&nbsp;&nbsp;&nbsp;</tt></td>
<td colspan=2><tt>A&nbsp;class&nbsp;for&nbsp;interacting&nbsp;with&nbsp;a&nbsp;resource.<br>&nbsp;</tt></td></tr>
<tr><td>&nbsp;</td>
<td width="100%">Methods defined here:<br>
<dl><dt><a name="Resource-__init__"><strong>__init__</strong></a>(self)</dt></dl>
<dl><dt><a name="Resource-get"><strong>get</strong></a> = method(self, **kwargs)</dt><dd><tt>Retrieves&nbsp;my&nbsp;reading&nbsp;position&nbsp;information&nbsp;for&nbsp;a&nbsp;volume.<br>
&nbsp;<br>
Args:<br>
&nbsp;&nbsp;source:&nbsp;string,&nbsp;String&nbsp;to&nbsp;identify&nbsp;the&nbsp;originator&nbsp;of&nbsp;this&nbsp;request.<br>
&nbsp;&nbsp;country:&nbsp;string,&nbsp;ISO-3166-1&nbsp;code&nbsp;to&nbsp;override&nbsp;the&nbsp;IP-based&nbsp;location.<br>
&nbsp;&nbsp;volumeId:&nbsp;string,&nbsp;Id&nbsp;of&nbsp;volume&nbsp;for&nbsp;which&nbsp;to&nbsp;retrieve&nbsp;a&nbsp;reading&nbsp;position.&nbsp;(required)<br>
&nbsp;&nbsp;contentVersion:&nbsp;string,&nbsp;Volume&nbsp;content&nbsp;version&nbsp;for&nbsp;which&nbsp;this&nbsp;reading&nbsp;position&nbsp;is&nbsp;requested.<br>
&nbsp;<br>
Returns:<br>
&nbsp;&nbsp;An&nbsp;object&nbsp;of&nbsp;the&nbsp;form<br>
&nbsp;<br>
&nbsp;&nbsp;&nbsp;&nbsp;{<br>
&nbsp;&nbsp;&nbsp;&nbsp;"kind":&nbsp;"books#readingPosition",&nbsp;#&nbsp;Resource&nbsp;type&nbsp;for&nbsp;a&nbsp;reading&nbsp;position.<br>
&nbsp;&nbsp;&nbsp;&nbsp;"gbImagePosition":&nbsp;"A&nbsp;String",&nbsp;#&nbsp;Position&nbsp;in&nbsp;a&nbsp;volume&nbsp;for&nbsp;image-based&nbsp;content.<br>
&nbsp;&nbsp;&nbsp;&nbsp;"epubCfiPosition":&nbsp;"A&nbsp;String",&nbsp;#&nbsp;Position&nbsp;in&nbsp;an&nbsp;EPUB&nbsp;as&nbsp;a&nbsp;CFI.<br>
&nbsp;&nbsp;&nbsp;&nbsp;"updated":&nbsp;"A&nbsp;String",&nbsp;#&nbsp;Timestamp&nbsp;when&nbsp;this&nbsp;reading&nbsp;position&nbsp;was&nbsp;last&nbsp;updated&nbsp;(formatted&nbsp;UTC&nbsp;timestamp&nbsp;with&nbsp;millisecond&nbsp;resolution).<br>
&nbsp;&nbsp;&nbsp;&nbsp;"volumeId":&nbsp;"A&nbsp;String",&nbsp;#&nbsp;Volume&nbsp;id&nbsp;associated&nbsp;with&nbsp;this&nbsp;reading&nbsp;position.<br>
&nbsp;&nbsp;&nbsp;&nbsp;"pdfPosition":&nbsp;"A&nbsp;String",&nbsp;#&nbsp;Position&nbsp;in&nbsp;a&nbsp;PDF&nbsp;file.<br>
&nbsp;&nbsp;&nbsp;&nbsp;"gbTextPosition":&nbsp;"A&nbsp;String",&nbsp;#&nbsp;Position&nbsp;in&nbsp;a&nbsp;volume&nbsp;for&nbsp;text-based&nbsp;content.<br>
&nbsp;&nbsp;}</tt></dd></dl>
<dl><dt><a name="Resource-setPosition"><strong>setPosition</strong></a> = method(self, **kwargs)</dt><dd><tt>Sets&nbsp;my&nbsp;reading&nbsp;position&nbsp;information&nbsp;for&nbsp;a&nbsp;volume.<br>
&nbsp;<br>
Args:<br>
&nbsp;&nbsp;source:&nbsp;string,&nbsp;String&nbsp;to&nbsp;identify&nbsp;the&nbsp;originator&nbsp;of&nbsp;this&nbsp;request.<br>
&nbsp;&nbsp;volumeId:&nbsp;string,&nbsp;Id&nbsp;of&nbsp;volume&nbsp;for&nbsp;which&nbsp;to&nbsp;update&nbsp;the&nbsp;reading&nbsp;position.&nbsp;(required)<br>
&nbsp;&nbsp;contentVersion:&nbsp;string,&nbsp;Volume&nbsp;content&nbsp;version&nbsp;for&nbsp;which&nbsp;this&nbsp;reading&nbsp;position&nbsp;applies.<br>
&nbsp;&nbsp;country:&nbsp;string,&nbsp;ISO-3166-1&nbsp;code&nbsp;to&nbsp;override&nbsp;the&nbsp;IP-based&nbsp;location.<br>
&nbsp;&nbsp;position:&nbsp;string,&nbsp;Position&nbsp;string&nbsp;for&nbsp;the&nbsp;new&nbsp;volume&nbsp;reading&nbsp;position.&nbsp;(required)<br>
&nbsp;&nbsp;timestamp:&nbsp;string,&nbsp;<a href="http://www.rfc-editor.org/rfc/rfc3339.txt">RFC&nbsp;3339</a>&nbsp;UTC&nbsp;format&nbsp;timestamp&nbsp;associated&nbsp;with&nbsp;this&nbsp;reading&nbsp;position.&nbsp;(required)<br>
&nbsp;&nbsp;action:&nbsp;string,&nbsp;Action&nbsp;that&nbsp;caused&nbsp;this&nbsp;reading&nbsp;position&nbsp;to&nbsp;be&nbsp;set.<br>
&nbsp;&nbsp;&nbsp;&nbsp;Allowed&nbsp;values<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;bookmark&nbsp;-&nbsp;User&nbsp;chose&nbsp;bookmark&nbsp;within&nbsp;volume.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;chapter&nbsp;-&nbsp;User&nbsp;selected&nbsp;chapter&nbsp;from&nbsp;list.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;next-page&nbsp;-&nbsp;Next&nbsp;page&nbsp;event.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;prev-page&nbsp;-&nbsp;Previous&nbsp;page&nbsp;event.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;scroll&nbsp;-&nbsp;User&nbsp;navigated&nbsp;to&nbsp;page.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;search&nbsp;-&nbsp;User&nbsp;chose&nbsp;search&nbsp;results&nbsp;within&nbsp;volume.</tt></dd></dl>
<hr>
Data descriptors defined here:<br>
<dl><dt><strong>__dict__</strong></dt>
<dd><tt>dictionary&nbsp;for&nbsp;instance&nbsp;variables&nbsp;(if&nbsp;defined)</tt></dd>
</dl>
<dl><dt><strong>__weakref__</strong></dt>
<dd><tt>list&nbsp;of&nbsp;weak&nbsp;references&nbsp;to&nbsp;the&nbsp;object&nbsp;(if&nbsp;defined)</tt></dd>
</dl>
</td></tr></table>
</body></html>