• Home
  • Raw
  • Download

Lines Matching refs:file

35 static void writeHeader(GeneratedFile* file, const string& title,  in writeHeader()  argument
38 *file in writeHeader()
49 *file << " <meta name=\"description\" content=\""; in writeHeader()
54 if (i) *file << " "; in writeHeader()
55 *file << desc[i]; in writeHeader()
57 *file << "…\">\n"; in writeHeader()
59 *file << "</head>\n\n" in writeHeader()
61 *file << "<div class='renderscript'>\n"; in writeHeader()
64 static void writeFooter(GeneratedFile* file) { in writeFooter() argument
65 *file << "</div>\n"; in writeFooter()
66 *file << "\n\n</body>\n"; in writeFooter()
67 *file << "</html>\n"; in writeFooter()
203 static bool generateHtmlParagraphs(GeneratedFile* file, const vector<string>& description) { in generateHtmlParagraphs() argument
209 *file << "</p>\n"; in generateHtmlParagraphs()
214 *file << "<p> "; in generateHtmlParagraphs()
221 *file << s << "\n"; in generateHtmlParagraphs()
224 *file << "</p>\n"; in generateHtmlParagraphs()
229 static void writeSummaryTableStart(GeneratedFile* file, const string& label, bool labelIsHeading) { in writeSummaryTableStart() argument
231 *file << "<h2 style='margin-bottom: 0px;'>" << label << "</h2>\n"; in writeSummaryTableStart()
233 *file << "<table class='jd-sumtable'><tbody>\n"; in writeSummaryTableStart()
235 *file << " <tr><th colspan='2'>" << label << "</th></tr>\n"; in writeSummaryTableStart()
239 static void writeSummaryTableEnd(GeneratedFile* file) { in writeSummaryTableEnd() argument
240 *file << "</tbody></table>\n"; in writeSummaryTableEnd()
275 static void writeSummaryTable(GeneratedFile* file, const ostringstream* entries, const char* name, in writeSummaryTable() argument
283 writeSummaryTableStart(file, prefix + name, labelAsHeader); in writeSummaryTable()
284 *file << s; in writeSummaryTable()
285 writeSummaryTableEnd(file); in writeSummaryTable()
289 static void writeSummaryTables(GeneratedFile* file, const map<string, Constant*>& constants, in writeSummaryTables() argument
297 writeSummaryTable(file, &constantStream, "Constants", deprecatedSelector, labelAsHeader); in writeSummaryTables()
303 writeSummaryTable(file, &typeStream, "Types", deprecatedSelector, labelAsHeader); in writeSummaryTables()
309 writeSummaryTable(file, &functionStream, "Functions", deprecatedSelector, labelAsHeader); in writeSummaryTables()
312 static void writeHtmlVersionTag(GeneratedFile* file, VersionInfo info, in writeHtmlVersionTag() argument
347 *file << (addSpacing ? " " : "") << s << "\n"; in writeHtmlVersionTag()
351 static void writeDetailedTypeSpecification(GeneratedFile* file, const TypeSpecification* spec) { in writeDetailedTypeSpecification() argument
355 *file << "<p>A typedef of: " << spec->getSimpleType() in writeDetailedTypeSpecification()
359 writeHtmlVersionTag(file, spec->getVersionInfo(), false); in writeDetailedTypeSpecification()
360 *file << "</p>\n"; in writeDetailedTypeSpecification()
364 *file << "<p>"; in writeDetailedTypeSpecification()
365 writeHtmlVersionTag(file, spec->getVersionInfo(), false); in writeDetailedTypeSpecification()
366 *file << "</p>\n"; in writeDetailedTypeSpecification()
370 *file << "<p>An enum with the following values:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\n"; in writeDetailedTypeSpecification()
371 writeHtmlVersionTag(file, spec->getVersionInfo(), false); in writeDetailedTypeSpecification()
372 *file << "</p>\n"; in writeDetailedTypeSpecification()
374 *file << " <table class='jd-tagtable'><tbody>\n"; in writeDetailedTypeSpecification()
378 *file << " <tr><th>" << values[i] << "</th><td>"; in writeDetailedTypeSpecification()
380 *file << valueComments[i]; in writeDetailedTypeSpecification()
382 *file << "</td></tr>\n"; in writeDetailedTypeSpecification()
384 *file << " </tbody></table><br/>\n"; in writeDetailedTypeSpecification()
388 *file << "<p>A structure with the following fields:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"; in writeDetailedTypeSpecification()
389 writeHtmlVersionTag(file, spec->getVersionInfo(), false); in writeDetailedTypeSpecification()
390 *file << "</p>\n"; in writeDetailedTypeSpecification()
392 *file << " <table class='jd-tagtable'><tbody>\n"; in writeDetailedTypeSpecification()
396 *file << " <tr><th>" << fields[i] << "</th><td>"; in writeDetailedTypeSpecification()
398 *file << fieldComments[i]; in writeDetailedTypeSpecification()
400 *file << "</td></tr>\n"; in writeDetailedTypeSpecification()
402 *file << " </tbody></table><br/>\n"; in writeDetailedTypeSpecification()
408 static void writeDetailedConstantSpecification(GeneratedFile* file, ConstantSpecification* c) { in writeDetailedConstantSpecification() argument
409 *file << " <tr><td>"; in writeDetailedConstantSpecification()
410 *file << "Value: " << c->getValue() << "\n"; in writeDetailedConstantSpecification()
411 writeHtmlVersionTag(file, c->getVersionInfo(), true); in writeDetailedConstantSpecification()
412 *file << " </td></tr>\n"; in writeDetailedConstantSpecification()
413 *file << "<br/>\n"; in writeDetailedConstantSpecification()
416 static bool writeOverviewForFile(GeneratedFile* file, const SpecFile& specFile) { in writeOverviewForFile() argument
418 *file << "<h2>" << specFile.getBriefDescription() << "</h2>\n"; in writeOverviewForFile()
419 if (!generateHtmlParagraphs(file, specFile.getFullDescription())) { in writeOverviewForFile()
425 writeSummaryTables(file, specFile.getDocumentedConstants(), specFile.getDocumentedTypes(), in writeOverviewForFile()
432 GeneratedFile file; in generateOverview() local
433 if (!file.start(directory, OVERVIEW_HTML_FILE_NAME)) { in generateOverview()
440 writeHeader(&file, "Runtime API Reference", in generateOverview()
444 if (!writeOverviewForFile(&file, *specFile)) { in generateOverview()
449 writeFooter(&file); in generateOverview()
450 file.close(); in generateOverview()
455 GeneratedFile file; in generateAlphabeticalIndex() local
456 if (!file.start(directory, INDEX_HTML_FILE_NAME)) { in generateAlphabeticalIndex()
459 writeHeader(&file, "Index", SpecFile("")); in generateAlphabeticalIndex()
461 writeSummaryTables(&file, systemSpecification.getConstants(), systemSpecification.getTypes(), in generateAlphabeticalIndex()
464 writeSummaryTables(&file, systemSpecification.getConstants(), systemSpecification.getTypes(), in generateAlphabeticalIndex()
467 writeFooter(&file); in generateAlphabeticalIndex()
468 file.close(); in generateAlphabeticalIndex()
472 static void writeDeprecatedWarning(GeneratedFile* file, Definition* definition) { in writeDeprecatedWarning() argument
474 *file << " <p><b>Deprecated.</b> "; in writeDeprecatedWarning()
478 *file << s; in writeDeprecatedWarning()
480 *file << "Do not use."; in writeDeprecatedWarning()
482 *file << "</p>\n"; in writeDeprecatedWarning()
486 static bool writeDetailedConstant(GeneratedFile* file, Constant* constant) { in writeDetailedConstant() argument
492 *file << "<a name='android_rs:" << name << "'></a>\n"; in writeDetailedConstant()
493 *file << "<div class='jd-details'>\n"; in writeDetailedConstant()
494 *file << " <h4 class='jd-details-title'>\n"; in writeDetailedConstant()
495 *file << " <span class='sympad'>" << name << "</span>\n"; in writeDetailedConstant()
496 *file << " <span class='normal'>: " << constant->getSummary() << "</span>\n"; in writeDetailedConstant()
497 *file << " </h4>\n"; in writeDetailedConstant()
499 *file << " <div class='jd-details-descr'>\n"; in writeDetailedConstant()
500 *file << " <table class='jd-tagtable'><tbody>\n"; in writeDetailedConstant()
505 *file << " <h5 class='jd-tagtitle'>Variant:</h5>\n"; in writeDetailedConstant()
507 writeDetailedConstantSpecification(file, spec); in writeDetailedConstant()
509 *file << " </tbody></table>\n"; in writeDetailedConstant()
510 *file << " </div>\n"; in writeDetailedConstant()
512 *file << " <div class='jd-tagdata jd-tagdescr'>\n"; in writeDetailedConstant()
514 writeDeprecatedWarning(file, constant); in writeDetailedConstant()
515 if (!generateHtmlParagraphs(file, constant->getDescription())) { in writeDetailedConstant()
518 *file << " </div>\n"; in writeDetailedConstant()
520 *file << "</div>\n"; in writeDetailedConstant()
521 *file << "\n"; in writeDetailedConstant()
525 static bool writeDetailedType(GeneratedFile* file, Type* type) { in writeDetailedType() argument
531 *file << "<a name='android_rs:" << name << "'></a>\n"; in writeDetailedType()
532 *file << "<div class='jd-details'>\n"; in writeDetailedType()
533 *file << " <h4 class='jd-details-title'>\n"; in writeDetailedType()
534 *file << " <span class='sympad'>" << name << "</span>\n"; in writeDetailedType()
535 *file << " <span class='normal'>: " << type->getSummary() << "</span>\n"; in writeDetailedType()
536 *file << " </h4>\n"; in writeDetailedType()
538 *file << " <div class='jd-details-descr'>\n"; in writeDetailedType()
540 writeDetailedTypeSpecification(file, spec); in writeDetailedType()
543 writeDeprecatedWarning(file, type); in writeDetailedType()
544 if (!generateHtmlParagraphs(file, type->getDescription())) { in writeDetailedType()
548 *file << " </div>\n"; in writeDetailedType()
549 *file << "</div>\n"; in writeDetailedType()
550 *file << "\n"; in writeDetailedType()
554 static bool writeDetailedFunction(GeneratedFile* file, Function* function) { in writeDetailedFunction() argument
560 *file << "<a name='android_rs:" << name << "'></a>\n"; in writeDetailedFunction()
561 *file << "<div class='jd-details'>\n"; in writeDetailedFunction()
562 *file << " <h4 class='jd-details-title'>\n"; in writeDetailedFunction()
563 *file << " <span class='sympad'>" << name << "</span>\n"; in writeDetailedFunction()
564 *file << " <span class='normal'>: " << function->getSummary() << "</span>\n"; in writeDetailedFunction()
565 *file << " </h4>\n"; in writeDetailedFunction()
567 *file << " <div class='jd-details-descr'>\n"; in writeDetailedFunction()
572 *file << " <table class='jd-tagtable'><tbody>\n"; in writeDetailedFunction()
574 *file << " <tr>\n"; in writeDetailedFunction()
575 *file << " <td>" << i.second.htmlDeclaration << "</td>\n"; in writeDetailedFunction()
576 *file << " <td>"; in writeDetailedFunction()
577 writeHtmlVersionTag(file, i.second.info, true); in writeDetailedFunction()
578 *file << " </td>\n"; in writeDetailedFunction()
579 *file << " </tr>\n"; in writeDetailedFunction()
581 *file << " </tbody></table>\n"; in writeDetailedFunction()
582 *file << " </div>\n"; in writeDetailedFunction()
585 *file << " <div class='jd-tagdata'>"; in writeDetailedFunction()
586 *file << " <h5 class='jd-tagtitle'>Parameters</h5>\n"; in writeDetailedFunction()
587 *file << " <table class='jd-tagtable'><tbody>\n"; in writeDetailedFunction()
589 *file << " <tr><th>" << p->name << "</th><td>" << p->documentation << "</td></tr>\n"; in writeDetailedFunction()
591 *file << " </tbody></table>\n"; in writeDetailedFunction()
592 *file << " </div>\n"; in writeDetailedFunction()
597 *file << " <div class='jd-tagdata'>"; in writeDetailedFunction()
598 *file << " <h5 class='jd-tagtitle'>Returns</h5>\n"; in writeDetailedFunction()
599 *file << " <table class='jd-tagtable'><tbody>\n"; in writeDetailedFunction()
600 *file << " <tr><td>" << ret << "</td></tr>\n"; in writeDetailedFunction()
601 *file << " </tbody></table>\n"; in writeDetailedFunction()
602 *file << " </div>\n"; in writeDetailedFunction()
605 *file << " <div class='jd-tagdata jd-tagdescr'>\n"; in writeDetailedFunction()
606 writeDeprecatedWarning(file, function); in writeDetailedFunction()
607 if (!generateHtmlParagraphs(file, function->getDescription())) { in writeDetailedFunction()
610 *file << " </div>\n"; in writeDetailedFunction()
612 *file << "</div>\n"; in writeDetailedFunction()
613 *file << "\n"; in writeDetailedFunction()
624 GeneratedFile file; in writeDetailedDocumentationFile() local
627 if (!file.start(directory, fileName)) { in writeDetailedDocumentationFile()
633 writeHeader(&file, title, specFile); in writeDetailedDocumentationFile()
635 file << "<h2>Overview</h2>\n"; in writeDetailedDocumentationFile()
636 if (!generateHtmlParagraphs(&file, specFile.getFullDescription())) { in writeDetailedDocumentationFile()
641 file << "<h2>Summary</h2>\n"; in writeDetailedDocumentationFile()
646 writeSummaryTables(&file, constants, types, functions, NON_DEPRECATED_ONLY, false); in writeDetailedDocumentationFile()
647 writeSummaryTables(&file, constants, types, functions, DEPRECATED_ONLY, false); in writeDetailedDocumentationFile()
651 file << "<h2>Constants</h2>\n"; in writeDetailedDocumentationFile()
653 if (!writeDetailedConstant(&file, i.second)) { in writeDetailedDocumentationFile()
659 file << "<h2>Types</h2>\n"; in writeDetailedDocumentationFile()
661 if (!writeDetailedType(&file, i.second)) { in writeDetailedDocumentationFile()
667 file << "<h2>Functions</h2>\n"; in writeDetailedDocumentationFile()
669 if (!writeDetailedFunction(&file, i.second)) { in writeDetailedDocumentationFile()
675 writeFooter(&file); in writeDetailedDocumentationFile()
676 file.close(); in writeDetailedDocumentationFile()
685 static void generateSnippet(GeneratedFile* file, const string& fileName, const string& title) { in generateSnippet() argument
687 *file << offset << "<li><a href=\"<?cs var:toroot ?>guide/topics/renderscript/reference/" in generateSnippet()
689 *file << offset << " <span class=\"en\">" << title << "</span>\n"; in generateSnippet()
690 *file << offset << "</a></li>\n"; in generateSnippet()
697 GeneratedFile file; in generateAndroidTableOfContentSnippet() local
698 if (!file.start(directory, "guide_toc.cs")) { in generateAndroidTableOfContentSnippet()
701 file << "<!-- Copy and paste the following lines into the RenderScript section of\n"; in generateAndroidTableOfContentSnippet()
702 file << " platform/frameworks/base/docs/html/guide/guide_toc.cs\n\n"; in generateAndroidTableOfContentSnippet()
705 file << offset << "<li class=\"nav-section\">\n"; in generateAndroidTableOfContentSnippet()
706 file << offset << " <div class=\"nav-section-header\">\n"; in generateAndroidTableOfContentSnippet()
707 file << offset << " <a href=\"<?cs var:toroot ?>guide/topics/renderscript/reference/" << in generateAndroidTableOfContentSnippet()
709 file << offset << " <span class=\"en\">Runtime API Reference</span>\n"; in generateAndroidTableOfContentSnippet()
710 file << offset << " </a></div>\n"; in generateAndroidTableOfContentSnippet()
711 file << offset << " <ul>\n"; in generateAndroidTableOfContentSnippet()
716 generateSnippet(&file, fileName, specFile->getBriefDescription()); in generateAndroidTableOfContentSnippet()
719 generateSnippet(&file, INDEX_HTML_FILE_NAME, "Index"); in generateAndroidTableOfContentSnippet()
721 file << offset << " </ul>\n"; in generateAndroidTableOfContentSnippet()
722 file << offset << "</li>\n"; in generateAndroidTableOfContentSnippet()