| |
| <!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> <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> </tt></td> |
| <td colspan=2><tt>A class for interacting with a resource.<br> </tt></td></tr> |
| <tr><td> </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-image"><strong>image</strong></a> = method(self, **kwargs)</dt><dd><tt>Returns the scaled/cropped image attached to a freebase node.<br> |
| <br> |
| Args:<br> |
| maxwidth: integer, Maximum width in pixels for resulting image.<br> |
| maxheight: integer, Maximum height in pixels for resulting image.<br> |
| fallbackid: string, Use the image associated with this secondary id if no image is associated with the primary id.<br> |
| pad: boolean, A boolean specifying whether the resulting image should be padded up to the requested dimensions.<br> |
| mode: string, Method used to scale or crop image.<br> |
| Allowed values<br> |
| fill - TODO(bendrees)<br> |
| fillcrop - TODO(bendrees)<br> |
| fillcropmid - TODO(bendrees)<br> |
| fit - TODO(bendrees)<br> |
| id: string, Freebase entity or content id, mid, or guid. (required) (repeated)</tt></dd></dl> |
| |
| <dl><dt><a name="Resource-mqlread"><strong>mqlread</strong></a> = method(self, **kwargs)</dt><dd><tt>Performs MQL Queries.<br> |
| <br> |
| Args:<br> |
| lang: string, The language of the results - an id of a /type/lang object.<br> |
| cursor: string, The mql cursor.<br> |
| indent: integer, How many spaces to indent the json.<br> |
| callback: string, JS method name for JSONP callbacks.<br> |
| uniqueness_failure: string, How MQL responds to uniqueness failures.<br> |
| Allowed values<br> |
| hard - Be strict - throw an error.<br> |
| soft - Just return the first encountered object.<br> |
| dateline: string, The dateline that you get in a mqlwrite response to ensure consistent results.<br> |
| html_escape: boolean, Whether or not to escape entities.<br> |
| cost: boolean, Show the costs or not.<br> |
| query: string, An envelope containing a single MQL query. (required)<br> |
| as_of_time: string, Run the query as it would've been run at the specified point in time.</tt></dd></dl> |
| |
| <dl><dt><a name="Resource-text"><strong><a href="freebase.v1.text.html">text</a></strong></a> = methodResource(self)</dt><dd><tt>A collection resource.</tt></dd></dl> |
| |
| <hr> |
| Data descriptors defined here:<br> |
| <dl><dt><strong>__dict__</strong></dt> |
| <dd><tt>dictionary for instance variables (if defined)</tt></dd> |
| </dl> |
| <dl><dt><strong>__weakref__</strong></dt> |
| <dd><tt>list of weak references to the object (if defined)</tt></dd> |
| </dl> |
| </td></tr></table> |
| </body></html> |