MCPcopy Create free account
hub / github.com/dirkvranckaert/AndroidDecompiler / buildPreBlockStatements

Method buildPreBlockStatements

astyle/src/ASResource.cpp:442–464  ·  view source on GitHub ↗

* Build the vector of pre-block statements. * Used by ONLY ASBeautifier.cpp * NOTE: Cannot be both a header and a preBlockStatement. * * @param preBlockStatements a reference to the vector to be built. */

Source from the content-addressed store, hash-verified

440 * @param preBlockStatements a reference to the vector to be built.
441 */
442void ASResource::buildPreBlockStatements(vector<const string*>* preBlockStatements, int fileType)
443{
444 preBlockStatements->push_back(&AS_CLASS);
445 if (fileType == C_TYPE)
446 {
447 preBlockStatements->push_back(&AS_STRUCT);
448 preBlockStatements->push_back(&AS_UNION);
449 preBlockStatements->push_back(&AS_NAMESPACE);
450 }
451 if (fileType == JAVA_TYPE)
452 {
453 preBlockStatements->push_back(&AS_INTERFACE);
454 preBlockStatements->push_back(&AS_THROWS);
455 }
456 if (fileType == SHARP_TYPE)
457 {
458 preBlockStatements->push_back(&AS_INTERFACE);
459 preBlockStatements->push_back(&AS_NAMESPACE);
460 preBlockStatements->push_back(&AS_WHERE);
461 preBlockStatements->push_back(&AS_STRUCT);
462 }
463 sort(preBlockStatements->begin(), preBlockStatements->end(), sortOnName);
464}
465
466/**
467 * Build the vector of pre-command headers.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected