99 <tr> |
99 <tr> |
100 <td><a href="#AnnotationsChecker.__error">__error</a></td> |
100 <td><a href="#AnnotationsChecker.__error">__error</a></td> |
101 <td>Private method to record an issue.</td> |
101 <td>Private method to record an issue.</td> |
102 </tr> |
102 </tr> |
103 <tr> |
103 <tr> |
104 <td><a href="#AnnotationsChecker.__generateTree">__generateTree</a></td> |
|
105 <td>Private method to generate an AST for our source.</td> |
|
106 </tr> |
|
107 <tr> |
|
108 <td><a href="#AnnotationsChecker.__ignoreCode">__ignoreCode</a></td> |
104 <td><a href="#AnnotationsChecker.__ignoreCode">__ignoreCode</a></td> |
109 <td>Private method to check if the message code should be ignored.</td> |
105 <td>Private method to check if the message code should be ignored.</td> |
110 </tr> |
106 </tr> |
111 <tr> |
107 <tr> |
112 <td><a href="#AnnotationsChecker.__reportInvalidSyntax">__reportInvalidSyntax</a></td> |
|
113 <td>Private method to report a syntax error.</td> |
|
114 </tr> |
|
115 <tr> |
|
116 <td><a href="#AnnotationsChecker.run">run</a></td> |
108 <td><a href="#AnnotationsChecker.run">run</a></td> |
117 <td>Public method to check the given source against annotation issues.</td> |
109 <td>Public method to check the given source against annotation issues.</td> |
118 </tr> |
110 </tr> |
119 </table> |
111 </table> |
120 <h3>Static Methods</h3> |
112 <h3>Static Methods</h3> |
123 <tr><td>None</td></tr> |
115 <tr><td>None</td></tr> |
124 </table> |
116 </table> |
125 |
117 |
126 <a NAME="AnnotationsChecker.__init__" ID="AnnotationsChecker.__init__"></a> |
118 <a NAME="AnnotationsChecker.__init__" ID="AnnotationsChecker.__init__"></a> |
127 <h4>AnnotationsChecker (Constructor)</h4> |
119 <h4>AnnotationsChecker (Constructor)</h4> |
128 <b>AnnotationsChecker</b>(<i>source, filename, select, ignore, expected, repeat, args</i>) |
120 <b>AnnotationsChecker</b>(<i>source, filename, tree, select, ignore, expected, repeat, args</i>) |
129 |
121 |
130 <p> |
122 <p> |
131 Constructor |
123 Constructor |
132 </p> |
124 </p> |
133 <dl> |
125 <dl> |
137 source code to be checked |
129 source code to be checked |
138 </dd> |
130 </dd> |
139 <dt><i>filename</i> (str)</dt> |
131 <dt><i>filename</i> (str)</dt> |
140 <dd> |
132 <dd> |
141 name of the source file |
133 name of the source file |
|
134 </dd> |
|
135 <dt><i>tree</i> (ast.Module)</dt> |
|
136 <dd> |
|
137 AST tree of the source code |
142 </dd> |
138 </dd> |
143 <dt><i>select</i> (list of str)</dt> |
139 <dt><i>select</i> (list of str)</dt> |
144 <dd> |
140 <dd> |
145 list of selected codes |
141 list of selected codes |
146 </dd> |
142 </dd> |
206 <dt><i>args</i> (list)</dt> |
202 <dt><i>args</i> (list)</dt> |
207 <dd> |
203 <dd> |
208 arguments for the message |
204 arguments for the message |
209 </dd> |
205 </dd> |
210 </dl> |
206 </dl> |
211 <a NAME="AnnotationsChecker.__generateTree" ID="AnnotationsChecker.__generateTree"></a> |
|
212 <h4>AnnotationsChecker.__generateTree</h4> |
|
213 <b>__generateTree</b>(<i></i>) |
|
214 |
|
215 <p> |
|
216 Private method to generate an AST for our source. |
|
217 </p> |
|
218 <dl> |
|
219 <dt>Return:</dt> |
|
220 <dd> |
|
221 generated AST |
|
222 </dd> |
|
223 </dl> |
|
224 <dl> |
|
225 <dt>Return Type:</dt> |
|
226 <dd> |
|
227 ast.Module |
|
228 </dd> |
|
229 </dl> |
|
230 <a NAME="AnnotationsChecker.__ignoreCode" ID="AnnotationsChecker.__ignoreCode"></a> |
207 <a NAME="AnnotationsChecker.__ignoreCode" ID="AnnotationsChecker.__ignoreCode"></a> |
231 <h4>AnnotationsChecker.__ignoreCode</h4> |
208 <h4>AnnotationsChecker.__ignoreCode</h4> |
232 <b>__ignoreCode</b>(<i>code</i>) |
209 <b>__ignoreCode</b>(<i>code</i>) |
233 |
210 |
234 <p> |
211 <p> |
251 <dt>Return Type:</dt> |
228 <dt>Return Type:</dt> |
252 <dd> |
229 <dd> |
253 bool |
230 bool |
254 </dd> |
231 </dd> |
255 </dl> |
232 </dl> |
256 <a NAME="AnnotationsChecker.__reportInvalidSyntax" ID="AnnotationsChecker.__reportInvalidSyntax"></a> |
|
257 <h4>AnnotationsChecker.__reportInvalidSyntax</h4> |
|
258 <b>__reportInvalidSyntax</b>(<i></i>) |
|
259 |
|
260 <p> |
|
261 Private method to report a syntax error. |
|
262 </p> |
|
263 <a NAME="AnnotationsChecker.run" ID="AnnotationsChecker.run"></a> |
233 <a NAME="AnnotationsChecker.run" ID="AnnotationsChecker.run"></a> |
264 <h4>AnnotationsChecker.run</h4> |
234 <h4>AnnotationsChecker.run</h4> |
265 <b>run</b>(<i></i>) |
235 <b>run</b>(<i></i>) |
266 |
236 |
267 <p> |
237 <p> |