From 70234433d33cfb403e24f1ec72b8e6c5fccb261f Mon Sep 17 00:00:00 2001 From: Andrey Kamaev Date: Thu, 6 Sep 2012 14:55:48 +0400 Subject: [PATCH] Reduce verbosity of Java API generators --- modules/java/generator/gen_java.py | 4 ++-- modules/java/generator/gen_javadoc.py | 3 --- modules/java/generator/rst_parser.py | 1 - 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/modules/java/generator/gen_java.py b/modules/java/generator/gen_java.py index 8c4ee6c..0471b49 100644 --- a/modules/java/generator/gen_java.py +++ b/modules/java/generator/gen_java.py @@ -987,14 +987,14 @@ extern "C" { msg = "// Return type '%s' is not supported, skipping the function\n\n" % fi.ctype self.skipped_func_list.append(c_decl + "\n" + msg) j_code.write( " "*4 + msg ) - print "SKIP:", c_decl, "\n\tdue to RET type", fi.ctype + print "SKIP:", c_decl.strip(), "\t due to RET type", fi.ctype return for a in fi.args: if a.ctype not in type_dict: msg = "// Unknown type '%s' (%s), skipping the function\n\n" % (a.ctype, a.out or "I") self.skipped_func_list.append(c_decl + "\n" + msg) j_code.write( " "*4 + msg ) - print "SKIP:", c_decl, "\n\tdue to ARG type", a.ctype, "/" + (a.out or "I") + print "SKIP:", c_decl.strip(), "\t due to ARG type", a.ctype, "/" + (a.out or "I") return self.ported_func_list.append(c_decl) diff --git a/modules/java/generator/gen_javadoc.py b/modules/java/generator/gen_javadoc.py index ecf6f3c..97eac70 100644 --- a/modules/java/generator/gen_javadoc.py +++ b/modules/java/generator/gen_javadoc.py @@ -222,7 +222,6 @@ class JavadocGenerator(object): return (doc + " */").replace("::",".") def printSummary(self): - print print "Javadoc Generator Summary:" print " Total markers: %s" % self.markers_processed print " Undocumented markers: %s" % (self.markers_processed - self.markers_documented) @@ -256,7 +255,6 @@ if __name__ == "__main__": parser.print_help() exit(0) - print "Parsing documentation..." parser = rst_parser.RstParser(hdr_parser.CppHeaderParser()) for m in options.modules: parser.parse(m, os.path.join(selfpath, "../../" + m)) @@ -268,7 +266,6 @@ if __name__ == "__main__": generator.show_warnings = options.warnings generator.show_errors = options.errors - print "Generating javadoc comments for " + ", ".join(options.modules) for path in args: folder = os.path.abspath(path) for jfile in [f for f in glob.glob(os.path.join(folder,"*.java")) if not f.endswith("-jdoc.java")]: diff --git a/modules/java/generator/rst_parser.py b/modules/java/generator/rst_parser.py index f622f6a..f4437f0 100644 --- a/modules/java/generator/rst_parser.py +++ b/modules/java/generator/rst_parser.py @@ -612,7 +612,6 @@ class RstParser(object): return s def printSummary(self): - print print "RST Parser Summary:" print " Total sections: %s" % self.sections_total print " Skipped sections: %s" % self.sections_skipped -- 2.7.4