Joe Gregorio | 761c456 | 2011-10-28 14:36:24 -0400 | [diff] [blame] | 1 | |
| 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> |
| 3 | <html><head><title>Python: class Resource</title> |
| 4 | </head><body bgcolor="#f0f0f8"> |
| 5 | <p> |
| 6 | <table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section"> |
| 7 | <tr bgcolor="#ffc8d8"> |
| 8 | <td colspan=3 valign=bottom> <br> |
| 9 | <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> |
| 10 | |
| 11 | <tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td> |
| 12 | <td colspan=2><tt>A class for interacting with a resource.<br> </tt></td></tr> |
| 13 | <tr><td> </td> |
| 14 | <td width="100%">Methods defined here:<br> |
| 15 | <dl><dt><a name="Resource-__init__"><strong>__init__</strong></a>(self)</dt></dl> |
| 16 | |
| 17 | <dl><dt><a name="Resource-delete"><strong>delete</strong></a> = method(self, **kwargs)</dt><dd><tt>Deletes an existing comment.<br> |
| 18 | <br> |
| 19 | Args:<br> |
| 20 | commentId: string, ID of the comment to remove. (required)</tt></dd></dl> |
| 21 | |
| 22 | <dl><dt><a name="Resource-get"><strong>get</strong></a> = method(self, **kwargs)</dt><dd><tt>Retrieves an existing comment.<br> |
| 23 | <br> |
| 24 | Args:<br> |
| 25 | hl: string, Specifies the interface language (host language) of your user interface.<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 26 | commentId: string, ID of the comment to get. (required)<br> |
| 27 | <br> |
| 28 | Returns:<br> |
| 29 | An object of the form<br> |
| 30 | <br> |
| 31 | {<br> |
| 32 | "inReplyTo": { # Link to the original activity where this comment was posted.<br> |
| 33 | "type": "A String", # Type of the post on activity stream being commented. Always text/html.<br> |
| 34 | "href": "A String", # Link to the post on activity stream being commented.<br> |
| 35 | "ref": "A String", # Unique identifier of the post on activity stream being commented.<br> |
| 36 | "rel": "inReplyTo", # Relationship between the comment and the post on activity stream being commented. Always inReplyTo.<br> |
| 37 | },<br> |
| 38 | "kind": "orkut#comment", # Identifies this resource as a comment. Value: "orkut#comment"<br> |
| 39 | "links": [ # List of resources for the comment.<br> |
| 40 | { # Links to resources related to the parent object.<br> |
| 41 | "href": "A String", # URL of the link.<br> |
| 42 | "type": "A String", # Media type of the link.<br> |
| 43 | "rel": "A String", # Relation between the resource and the parent object.<br> |
| 44 | "title": "A String", # Title of the link.<br> |
| 45 | },<br> |
| 46 | ],<br> |
| 47 | "actor": { # The person who posted the comment.<br> |
| 48 | "url": "A String", # The URL of the author who posted the comment [not yet implemented]<br> |
| 49 | "image": { # Image data about the actor.<br> |
| 50 | "url": "A String", # A URL that points to a thumbnail photo of the author.<br> |
| 51 | },<br> |
| 52 | "displayName": "A String", # The name of the author, suitable for display.<br> |
| 53 | "id": "A String", # Unique identifier of the person who posted the comment. This is the person's OpenSocial ID.<br> |
| 54 | },<br> |
| 55 | "content": "A String", # The content of the comment in text/html<br> |
| 56 | "published": "A String", # The time the comment was initially published, in <a href="http://www.rfc-editor.org/rfc/rfc3339.txt">RFC 3339</a> format.<br> |
| 57 | "id": "A String", # The unique ID for the comment.<br> |
| 58 | }</tt></dd></dl> |
Joe Gregorio | 761c456 | 2011-10-28 14:36:24 -0400 | [diff] [blame] | 59 | |
| 60 | <dl><dt><a name="Resource-insert"><strong>insert</strong></a> = method(self, **kwargs)</dt><dd><tt>Inserts a new comment to an activity.<br> |
| 61 | <br> |
| 62 | Args:<br> |
| 63 | body: object, The request body. (required)<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 64 | The object takes the form of:<br> |
| 65 | <br> |
| 66 | {<br> |
| 67 | "inReplyTo": { # Link to the original activity where this comment was posted.<br> |
| 68 | "type": "A String", # Type of the post on activity stream being commented. Always text/html.<br> |
| 69 | "href": "A String", # Link to the post on activity stream being commented.<br> |
| 70 | "ref": "A String", # Unique identifier of the post on activity stream being commented.<br> |
| 71 | "rel": "inReplyTo", # Relationship between the comment and the post on activity stream being commented. Always inReplyTo.<br> |
| 72 | },<br> |
| 73 | "kind": "orkut#comment", # Identifies this resource as a comment. Value: "orkut#comment"<br> |
| 74 | "links": [ # List of resources for the comment.<br> |
| 75 | { # Links to resources related to the parent object.<br> |
| 76 | "href": "A String", # URL of the link.<br> |
| 77 | "type": "A String", # Media type of the link.<br> |
| 78 | "rel": "A String", # Relation between the resource and the parent object.<br> |
| 79 | "title": "A String", # Title of the link.<br> |
| 80 | },<br> |
| 81 | ],<br> |
| 82 | "actor": { # The person who posted the comment.<br> |
| 83 | "url": "A String", # The URL of the author who posted the comment [not yet implemented]<br> |
| 84 | "image": { # Image data about the actor.<br> |
| 85 | "url": "A String", # A URL that points to a thumbnail photo of the author.<br> |
| 86 | },<br> |
| 87 | "displayName": "A String", # The name of the author, suitable for display.<br> |
| 88 | "id": "A String", # Unique identifier of the person who posted the comment. This is the person's OpenSocial ID.<br> |
| 89 | },<br> |
| 90 | "content": "A String", # The content of the comment in text/html<br> |
| 91 | "published": "A String", # The time the comment was initially published, in <a href="http://www.rfc-editor.org/rfc/rfc3339.txt">RFC 3339</a> format.<br> |
| 92 | "id": "A String", # The unique ID for the comment.<br> |
| 93 | }<br> |
| 94 | <br> |
| 95 | activityId: string, The ID of the activity to contain the new comment. (required)<br> |
| 96 | <br> |
| 97 | Returns:<br> |
| 98 | An object of the form<br> |
| 99 | <br> |
| 100 | {<br> |
| 101 | "inReplyTo": { # Link to the original activity where this comment was posted.<br> |
| 102 | "type": "A String", # Type of the post on activity stream being commented. Always text/html.<br> |
| 103 | "href": "A String", # Link to the post on activity stream being commented.<br> |
| 104 | "ref": "A String", # Unique identifier of the post on activity stream being commented.<br> |
| 105 | "rel": "inReplyTo", # Relationship between the comment and the post on activity stream being commented. Always inReplyTo.<br> |
| 106 | },<br> |
| 107 | "kind": "orkut#comment", # Identifies this resource as a comment. Value: "orkut#comment"<br> |
| 108 | "links": [ # List of resources for the comment.<br> |
| 109 | { # Links to resources related to the parent object.<br> |
| 110 | "href": "A String", # URL of the link.<br> |
| 111 | "type": "A String", # Media type of the link.<br> |
| 112 | "rel": "A String", # Relation between the resource and the parent object.<br> |
| 113 | "title": "A String", # Title of the link.<br> |
| 114 | },<br> |
| 115 | ],<br> |
| 116 | "actor": { # The person who posted the comment.<br> |
| 117 | "url": "A String", # The URL of the author who posted the comment [not yet implemented]<br> |
| 118 | "image": { # Image data about the actor.<br> |
| 119 | "url": "A String", # A URL that points to a thumbnail photo of the author.<br> |
| 120 | },<br> |
| 121 | "displayName": "A String", # The name of the author, suitable for display.<br> |
| 122 | "id": "A String", # Unique identifier of the person who posted the comment. This is the person's OpenSocial ID.<br> |
| 123 | },<br> |
| 124 | "content": "A String", # The content of the comment in text/html<br> |
| 125 | "published": "A String", # The time the comment was initially published, in <a href="http://www.rfc-editor.org/rfc/rfc3339.txt">RFC 3339</a> format.<br> |
| 126 | "id": "A String", # The unique ID for the comment.<br> |
| 127 | }</tt></dd></dl> |
Joe Gregorio | 761c456 | 2011-10-28 14:36:24 -0400 | [diff] [blame] | 128 | |
| 129 | <dl><dt><a name="Resource-list"><strong>list</strong></a> = method(self, **kwargs)</dt><dd><tt>Retrieves a list of comments, possibly filtered.<br> |
| 130 | <br> |
| 131 | Args:<br> |
| 132 | orderBy: string, Sort search results.<br> |
| 133 | Allowed values<br> |
| 134 | ascending - Use ascending sort order.<br> |
| 135 | descending - Use descending sort order.<br> |
| 136 | pageToken: string, A continuation token that allows pagination.<br> |
| 137 | maxResults: integer, The maximum number of activities to include in the response.<br> |
| 138 | activityId: string, The ID of the activity containing the comments. (required)<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 139 | hl: string, Specifies the interface language (host language) of your user interface.<br> |
| 140 | <br> |
| 141 | Returns:<br> |
| 142 | An object of the form<br> |
| 143 | <br> |
| 144 | {<br> |
| 145 | "nextPageToken": "A String", # The value of pageToken query parameter in comments.list request to get the next page, if there are more to retrieve.<br> |
| 146 | "items": [ # List of comments retrieved.<br> |
| 147 | {<br> |
| 148 | "inReplyTo": { # Link to the original activity where this comment was posted.<br> |
| 149 | "type": "A String", # Type of the post on activity stream being commented. Always text/html.<br> |
| 150 | "href": "A String", # Link to the post on activity stream being commented.<br> |
| 151 | "ref": "A String", # Unique identifier of the post on activity stream being commented.<br> |
| 152 | "rel": "inReplyTo", # Relationship between the comment and the post on activity stream being commented. Always inReplyTo.<br> |
| 153 | },<br> |
| 154 | "kind": "orkut#comment", # Identifies this resource as a comment. Value: "orkut#comment"<br> |
| 155 | "links": [ # List of resources for the comment.<br> |
| 156 | { # Links to resources related to the parent object.<br> |
| 157 | "href": "A String", # URL of the link.<br> |
| 158 | "type": "A String", # Media type of the link.<br> |
| 159 | "rel": "A String", # Relation between the resource and the parent object.<br> |
| 160 | "title": "A String", # Title of the link.<br> |
| 161 | },<br> |
| 162 | ],<br> |
| 163 | "actor": { # The person who posted the comment.<br> |
| 164 | "url": "A String", # The URL of the author who posted the comment [not yet implemented]<br> |
| 165 | "image": { # Image data about the actor.<br> |
| 166 | "url": "A String", # A URL that points to a thumbnail photo of the author.<br> |
| 167 | },<br> |
| 168 | "displayName": "A String", # The name of the author, suitable for display.<br> |
| 169 | "id": "A String", # Unique identifier of the person who posted the comment. This is the person's OpenSocial ID.<br> |
| 170 | },<br> |
| 171 | "content": "A String", # The content of the comment in text/html<br> |
| 172 | "published": "A String", # The time the comment was initially published, in <a href="http://www.rfc-editor.org/rfc/rfc3339.txt">RFC 3339</a> format.<br> |
| 173 | "id": "A String", # The unique ID for the comment.<br> |
| 174 | },<br> |
| 175 | ],<br> |
| 176 | "kind": "orkut#commentList", # Identifies this resource as a collection of comments. Value: "orkut#commentList"<br> |
| 177 | "previousPageToken": "A String", # The value of pageToken query parameter in comments.list request to get the previous page, if there are more to retrieve.<br> |
| 178 | }</tt></dd></dl> |
Joe Gregorio | 761c456 | 2011-10-28 14:36:24 -0400 | [diff] [blame] | 179 | |
| 180 | <dl><dt><a name="Resource-list_next"><strong>list_next</strong></a> = methodNext(self, previous_request, previous_response)</dt><dd><tt>Retrieves the next page of results.<br> |
| 181 | <br> |
| 182 | Args:<br> |
| 183 | previous_request: The request for the previous page.<br> |
| 184 | previous_response: The response from the request for the previous page.<br> |
| 185 | <br> |
| 186 | Returns:<br> |
| 187 | A request object that you can call 'execute()' on to request the next<br> |
| 188 | page. Returns None if there are no more items in the collection.</tt></dd></dl> |
| 189 | |
| 190 | <hr> |
| 191 | Data descriptors defined here:<br> |
| 192 | <dl><dt><strong>__dict__</strong></dt> |
| 193 | <dd><tt>dictionary for instance variables (if defined)</tt></dd> |
| 194 | </dl> |
| 195 | <dl><dt><strong>__weakref__</strong></dt> |
| 196 | <dd><tt>list of weak references to the object (if defined)</tt></dd> |
| 197 | </dl> |
| 198 | </td></tr></table> |
| 199 | </body></html> |