1233 firstWord = summary.strip().split(None, 1)[0].lower() |
1233 firstWord = summary.strip().split(None, 1)[0].lower() |
1234 if functionName == '__init__': |
1234 if functionName == '__init__': |
1235 if firstWord != 'constructor': |
1235 if firstWord != 'constructor': |
1236 self.__error(docstringContext.start() + lineNumber, 0, |
1236 self.__error(docstringContext.start() + lineNumber, 0, |
1237 "D232", 'constructor') |
1237 "D232", 'constructor') |
1238 elif functionName.startswith('__'): |
1238 elif functionName.startswith(('__', 'on_')): |
1239 if firstWord != 'private': |
1239 if firstWord != 'private': |
1240 self.__error(docstringContext.start() + lineNumber, 0, |
1240 self.__error(docstringContext.start() + lineNumber, 0, |
1241 "D232", 'private') |
1241 "D232", 'private') |
1242 elif functionName.startswith('_'): |
1242 elif functionName.startswith('_') or \ |
|
1243 functionName.endswith('Event'): |
1243 if firstWord != 'protected': |
1244 if firstWord != 'protected': |
1244 self.__error(docstringContext.start() + lineNumber, 0, |
1245 self.__error(docstringContext.start() + lineNumber, 0, |
1245 "D232", 'protected') |
1246 "D232", 'protected') |
1246 else: |
1247 else: |
1247 if firstWord != 'public': |
1248 if firstWord != 'public': |