Joe Gregorio | afc45f2 | 2011-02-20 16:11:28 -0500 | [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 | |
Joe Gregorio | 9384170 | 2011-03-02 16:12:05 -0800 | [diff] [blame] | 17 | <dl><dt><a name="Resource-insert"><strong>insert</strong></a> = method(self, **kwargs)</dt><dd><tt>Inserts a response for the specified submission in the specified topic within the specified series.<br> |
Joe Gregorio | afc45f2 | 2011-02-20 16:11:28 -0500 | [diff] [blame] | 18 | <br> |
| 19 | Args:<br> |
Joe Gregorio | ad258e2 | 2011-02-22 22:53:30 -0500 | [diff] [blame] | 20 | seriesId: integer, The decimal ID of the Series. (required)<br> |
Joe Gregorio | ad258e2 | 2011-02-22 22:53:30 -0500 | [diff] [blame] | 21 | topicId: integer, The decimal ID of the Topic within the Series. (required)<br> |
Joe Gregorio | 761c456 | 2011-10-28 14:36:24 -0400 | [diff] [blame] | 22 | unauthToken: string, User identifier for unauthenticated usage mode<br> |
Joe Gregorio | ad258e2 | 2011-02-22 22:53:30 -0500 | [diff] [blame] | 23 | parentSubmissionId: integer, The decimal ID of the parent Submission within the Series. (required)<br> |
Joe Gregorio | 20a5aa9 | 2011-04-01 17:44:25 -0400 | [diff] [blame] | 24 | body: object, The request body. (required)<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 25 | The object takes the form of:<br> |
| 26 | <br> |
| 27 | {<br> |
| 28 | "kind": "moderator#submission",<br> |
| 29 | "attribution": {<br> |
| 30 | "displayName": "A String",<br> |
| 31 | "location": "A String",<br> |
| 32 | "avatarUrl": "A String",<br> |
| 33 | },<br> |
| 34 | "created": "A String",<br> |
| 35 | "text": "A String",<br> |
| 36 | "topics": [<br> |
| 37 | {<br> |
| 38 | "id": {<br> |
| 39 | "seriesId": "A String",<br> |
| 40 | "topicId": "A String",<br> |
| 41 | },<br> |
| 42 | },<br> |
| 43 | ],<br> |
| 44 | "author": "A String",<br> |
| 45 | "translations": [<br> |
| 46 | {<br> |
| 47 | "lang": "A String",<br> |
| 48 | "text": "A String",<br> |
| 49 | },<br> |
| 50 | ],<br> |
| 51 | "parentSubmissionId": {<br> |
| 52 | "seriesId": "A String",<br> |
| 53 | "submissionId": "A String",<br> |
| 54 | },<br> |
| 55 | "vote": {<br> |
| 56 | "vote": "A String",<br> |
| 57 | "flag": "A String",<br> |
| 58 | },<br> |
| 59 | "attachmentUrl": "A String",<br> |
| 60 | "geo": {<br> |
| 61 | "latitude": 3.140000,<br> |
| 62 | "location": "A String",<br> |
| 63 | "longitude": 3.140000,<br> |
| 64 | },<br> |
| 65 | "id": {<br> |
| 66 | "seriesId": "A String",<br> |
| 67 | "submissionId": "A String",<br> |
| 68 | },<br> |
| 69 | "counters": {<br> |
| 70 | "noneVotes": 42,<br> |
| 71 | "minusVotes": 42,<br> |
| 72 | "plusVotes": 42,<br> |
| 73 | },<br> |
| 74 | }<br> |
| 75 | <br> |
| 76 | anonymous: boolean, Set to true to mark the new submission as anonymous.<br> |
| 77 | <br> |
| 78 | Returns:<br> |
| 79 | An object of the form<br> |
| 80 | <br> |
| 81 | {<br> |
| 82 | "kind": "moderator#submission",<br> |
| 83 | "attribution": {<br> |
| 84 | "displayName": "A String",<br> |
| 85 | "location": "A String",<br> |
| 86 | "avatarUrl": "A String",<br> |
| 87 | },<br> |
| 88 | "created": "A String",<br> |
| 89 | "text": "A String",<br> |
| 90 | "topics": [<br> |
| 91 | {<br> |
| 92 | "id": {<br> |
| 93 | "seriesId": "A String",<br> |
| 94 | "topicId": "A String",<br> |
| 95 | },<br> |
| 96 | },<br> |
| 97 | ],<br> |
| 98 | "author": "A String",<br> |
| 99 | "translations": [<br> |
| 100 | {<br> |
| 101 | "lang": "A String",<br> |
| 102 | "text": "A String",<br> |
| 103 | },<br> |
| 104 | ],<br> |
| 105 | "parentSubmissionId": {<br> |
| 106 | "seriesId": "A String",<br> |
| 107 | "submissionId": "A String",<br> |
| 108 | },<br> |
| 109 | "vote": {<br> |
| 110 | "vote": "A String",<br> |
| 111 | "flag": "A String",<br> |
| 112 | },<br> |
| 113 | "attachmentUrl": "A String",<br> |
| 114 | "geo": {<br> |
| 115 | "latitude": 3.140000,<br> |
| 116 | "location": "A String",<br> |
| 117 | "longitude": 3.140000,<br> |
| 118 | },<br> |
| 119 | "id": {<br> |
| 120 | "seriesId": "A String",<br> |
| 121 | "submissionId": "A String",<br> |
| 122 | },<br> |
| 123 | "counters": {<br> |
| 124 | "noneVotes": 42,<br> |
| 125 | "minusVotes": 42,<br> |
| 126 | "plusVotes": 42,<br> |
| 127 | },<br> |
| 128 | }</tt></dd></dl> |
Joe Gregorio | afc45f2 | 2011-02-20 16:11:28 -0500 | [diff] [blame] | 129 | |
Joe Gregorio | 9384170 | 2011-03-02 16:12:05 -0800 | [diff] [blame] | 130 | <dl><dt><a name="Resource-list"><strong>list</strong></a> = method(self, **kwargs)</dt><dd><tt>Lists or searches the responses for the specified submission within the specified series and returns the search results.<br> |
Joe Gregorio | afc45f2 | 2011-02-20 16:11:28 -0500 | [diff] [blame] | 131 | <br> |
| 132 | Args:<br> |
Joe Gregorio | ad258e2 | 2011-02-22 22:53:30 -0500 | [diff] [blame] | 133 | sort: string, Sort order.<br> |
| 134 | seriesId: integer, The decimal ID of the Series. (required)<br> |
| 135 | author: string, Restricts the results to submissions by a specific author.<br> |
| 136 | submissionId: integer, The decimal ID of the Submission within the Series. (required)<br> |
| 137 | q: string, Search query.<br> |
| 138 | max_results: integer, Maximum number of results to return.<br> |
| 139 | hasAttachedVideo: boolean, Specifies whether to restrict to submissions that have videos attached.<br> |
Joe Gregorio | b417caf | 2011-12-08 12:04:24 -0500 | [diff] [blame] | 140 | start_index: integer, Index of the first result to be retrieved.<br> |
| 141 | <br> |
| 142 | Returns:<br> |
| 143 | An object of the form<br> |
| 144 | <br> |
| 145 | {<br> |
| 146 | "items": [<br> |
| 147 | {<br> |
| 148 | "kind": "moderator#submission",<br> |
| 149 | "attribution": {<br> |
| 150 | "displayName": "A String",<br> |
| 151 | "location": "A String",<br> |
| 152 | "avatarUrl": "A String",<br> |
| 153 | },<br> |
| 154 | "created": "A String",<br> |
| 155 | "text": "A String",<br> |
| 156 | "topics": [<br> |
| 157 | {<br> |
| 158 | "id": {<br> |
| 159 | "seriesId": "A String",<br> |
| 160 | "topicId": "A String",<br> |
| 161 | },<br> |
| 162 | },<br> |
| 163 | ],<br> |
| 164 | "author": "A String",<br> |
| 165 | "translations": [<br> |
| 166 | {<br> |
| 167 | "lang": "A String",<br> |
| 168 | "text": "A String",<br> |
| 169 | },<br> |
| 170 | ],<br> |
| 171 | "parentSubmissionId": {<br> |
| 172 | "seriesId": "A String",<br> |
| 173 | "submissionId": "A String",<br> |
| 174 | },<br> |
| 175 | "vote": {<br> |
| 176 | "vote": "A String",<br> |
| 177 | "flag": "A String",<br> |
| 178 | },<br> |
| 179 | "attachmentUrl": "A String",<br> |
| 180 | "geo": {<br> |
| 181 | "latitude": 3.140000,<br> |
| 182 | "location": "A String",<br> |
| 183 | "longitude": 3.140000,<br> |
| 184 | },<br> |
| 185 | "id": {<br> |
| 186 | "seriesId": "A String",<br> |
| 187 | "submissionId": "A String",<br> |
| 188 | },<br> |
| 189 | "counters": {<br> |
| 190 | "noneVotes": 42,<br> |
| 191 | "minusVotes": 42,<br> |
| 192 | "plusVotes": 42,<br> |
| 193 | },<br> |
| 194 | },<br> |
| 195 | ],<br> |
| 196 | "kind": "moderator#submissionList",<br> |
| 197 | }</tt></dd></dl> |
Joe Gregorio | afc45f2 | 2011-02-20 16:11:28 -0500 | [diff] [blame] | 198 | |
| 199 | <hr> |
| 200 | Data descriptors defined here:<br> |
| 201 | <dl><dt><strong>__dict__</strong></dt> |
| 202 | <dd><tt>dictionary for instance variables (if defined)</tt></dd> |
| 203 | </dl> |
| 204 | <dl><dt><strong>__weakref__</strong></dt> |
| 205 | <dd><tt>list of weak references to the object (if defined)</tt></dd> |
| 206 | </dl> |
| 207 | </td></tr></table> |
| 208 | </body></html> |