Home
last modified time | relevance | path

Searched refs:addCode (Results 1 – 25 of 45) sorted by relevance

12

/external/kotlinpoet/kotlinpoet/src/test/java/com/squareup/kotlinpoet/
DExternalDeclarationsTest.kt38 .addCode("return kotlin.js.definedExternally") in externalFunDeclarationWithDefinedExternally()
52 .addCode("kotlin.js.definedExternally") in externalFunDeclarationWithDefinedExternally2()
86 .addCode("return kotlin.js.definedExternally") in implicitExternalFunDeclarationWithDefinedExternally()
105 .addCode("kotlin.js.definedExternally") in implicitExternalFunDeclarationWithDefinedExternally2()
DLineWrappingTest.kt146 funSpecBuilder.addCode("«call(") in parameterWrapping()
149 funSpecBuilder.addCode(if (i > 0) ", %S" else "%S", i) in parameterWrapping()
151 funSpecBuilder.addCode(")»\n") in parameterWrapping()
DFileSpecTest.kt139 .addCode("return wrap(INGREDIENTS)\n") in importTopLevel()
718 .addCode("%T.out.println(%S);\n", System::class, "Hello World!") in defaultPackage()
921 .addCode("println(INGREDIENTS)\n") in generalBuilderEqualityTest()
1006 .addCode( in defaultPackageMemberImport()
1146 .addCode("\n") in simpleScriptTest()
1148 .addCode("\n") in simpleScriptTest()
1153 .addCode("\n") in simpleScriptTest()
1155 .addCode("\n") in simpleScriptTest()
DTypeSpecTest.kt145 .addCode("/* code snippets */\n") in anonymousInnerClass()
227 .addCode("/* code snippets */\n") in anonymousClassWithMultipleSuperTypes()
311 .addCode("/* code snippets */\n") in annotatedParameters()
546 .addCode("return %S\n", "paper airplane!") in enumWithSubclassing()
569 .addCode("this(%S)\n", "fist") in enumWithSubclassing()
749 ….getter(FunSpec.getterBuilder().addCode("println(%S)\nreturn field", "contents observed!").build()) in noConstructorPropertiesWithCustomGetter()
786 .addCode("println(%S)\nfield = value", "contents changed!").build(), in noConstructorPropertiesWithCustomSetter()
2139 .addCode(funBody) in codeBlocks()
2249 .addCode("if (3 < 4) {\n⇥%T.out.println(%S);\n⇤}\n", System::class, "hello") in inlineIndent()
2822 .addCode("/* do something tricky with the topping */\n") in tryCatch()
[all …]
DFunSpecTest.kt1083 .addCode("codeWithNoNewline()") in ensureTrailingNewline()
1099 .addCode("codeWithNoNewline()\n") // Have a newline already, so ensure we're not adding one in ensureTrailingNewlineWithExistingNewline()
1115 .addCode("return codeWithNoNewline()") in ensureTrailingNewlineWithExpressionBody()
1128 … .addCode("return codeWithNoNewline()\n") // Have a newline already, so ensure we're not adding one in ensureTrailingNewlineWithExpressionBodyAndExistingNewline()
/external/dagger2/java/dagger/internal/codegen/writing/
DOptionalFactories.java160 .addCode("$L // safe covariant cast\n", AnnotationSpecs.suppressWarnings(UNCHECKED)) in absentOptionalProviderMethod()
345 .addCode(
358 .addCode(
376 .addCode(
391 .addCode(
402 .addCode(
412 .addCode(
452 .addCode("return $L;", optionalKind.presentExpression(CodeBlock.of("input")))
DMembersInjectorGenerator.java156 createMethodBuilder.addCode( in topLevelTypes()
194 createMethodBuilder.addCode( in topLevelTypes()
196 createMethodBuilder.addCode(");"); in topLevelTypes()
203 injectMembersBuilder.addCode( in topLevelTypes()
DComponentImplementation.java926 constructor.addCode(CodeBlocks.concat(componentRequirementInitializations)); in addConstructorAndInitializationMethods()
963 constructor.addCode(CodeBlocks.concat(shardInitializations)); in addConstructorAndInitializationMethods()
992 methodBuilder.addCode( in addCancellationListenerImplementation()
1006 methodBuilder.addCode(CodeBlocks.concat(cancellationStatements)).build(); in addCancellationListenerImplementation()
1022 cancelParentStatement().ifPresent(methodBuilder::addCode); in addCancellationListenerImplementation()
1070 .addCode(CodeBlocks.concat(partition)) in createPartitionedMethods()
DSwitchingProviders.java209 .addCode(getOnlyElement(switchCodeBlockPartitions))
228 .addCode(switchCodeBlockPartitions.get(i))
DExperimentalSwitchingProviders.java246 .addCode(getOnlyElement(switchCodeBlockPartitions))
265 .addCode(switchCodeBlockPartitions.get(i))
DHjarSourceFileGenerator.java101 skeleton.addCode(completeMethod.code); in skeletonMethod()
/external/javapoet/src/test/java/com/squareup/javapoet/
DTypeSpecTest.java66 .addCode("return $S;\n", "taco") in basic()
132 .addCode("/* code snippets */\n") in anonymousInnerClass()
142 .addCode("return $L;\n", aSimpleThung) in anonymousInnerClass()
191 .addCode("/* code snippets */\n") in annotatedParameters()
361 .addCode("return $S;\n", "paper airplane!") in enumWithSubclassing()
369 .addCode("this.handPosition = handPosition;\n") in enumWithSubclassing()
372 .addCode("this($S);\n", "fist") in enumWithSubclassing()
464 .addCode("return $S;\n", "west side") in enumWithMembersButNoConstructorCall()
562 .addCode("return 0;\n") in typeVariables()
572 .addCode("throw new $T($S);\n", UnsupportedOperationException.class, "TODO") in typeVariables()
[all …]
/external/dagger2/java/dagger/grpc/server/processor/
DProxyModuleGenerator.java91 .addCode( in provideServiceDefinitionContribution()
96 method.addCode( in provideServiceDefinitionContribution()
101 method.addCode(".build();"); in provideServiceDefinitionContribution()
/external/connectedappssdk/processor/src/main/java/com/google/android/enterprise/connectedapps/processor/
DBundlerGenerator.java138 .addCode(methodCode.build()) in addWriteToParcelMethod()
195 .addCode(methodCode.build()) in addReadFromParcelMethod()
250 .addCode(methodCode.build()) in addCreateArrayMethod()
295 .addCode(methodCode.build()) in addWriteToBundleMethod()
356 .addCode(methodCode.build()) in addReadFromBundleMethod()
DInternalCrossProfileClassGenerator.java242 .addCode(methodCode.build()) in addBlockingCrossProfileTypeMethod()
294 .addCode(methodCode.build()) in addCrossProfileCallbackCrossProfileTypeMethod()
345 .addCode(methodCode.build()) in addFutureCrossProfileTypeMethod()
DInternalProviderClassGenerator.java155 .addCode(methodCode.build()) in addCallMethod()
/external/dagger2/java/dagger/hilt/android/processor/internal/androidentrypoint/
DApplicationGenerator.java161 .addCode(componentBuilder()) in creatorType()
195 .addCode(injectCodeBlock()) in onCreateMethod()
210 .addCode(injectCodeBlock()) in customInjectMethod()
/external/okhttp/okhttp/src/main/java/com/squareup/okhttp/internal/framed/
DHuffman.java166 addCode(i, CODES[i], CODE_LENGTHS[i]); in buildTree()
170 private void addCode(int sym, int code, byte len) { in addCode() method in Huffman
/external/okhttp/repackaged/okhttp/src/main/java/com/android/okhttp/internal/framed/
DHuffman.java167 addCode(i, CODES[i], CODE_LENGTHS[i]); in buildTree()
171 private void addCode(int sym, int code, byte len) { in addCode() method in Huffman
/external/grpc-grpc-java/okhttp/third_party/okhttp/main/java/io/grpc/okhttp/internal/framed/
DHuffman.java170 addCode(i, CODES[i], CODE_LENGTHS[i]); in buildTree()
175 private void addCode(int sym, int code, byte len) { in addCode() method in Huffman
/external/auto/value/src/main/java/com/google/auto/value/extension/toprettystring/processor/
DToPrettyStringExtension.java105 method.addCode("return $S", context.autoValueClass().getSimpleName() + " {"); in toPrettyStringMethodSpecs()
107 method.addCode(implementation.toStringCodeBlock.build()); in toPrettyStringMethodSpecs()
110 method.addCode(" + $S", "\n"); in toPrettyStringMethodSpecs()
112 method.addCode(" + $S;\n", "}"); in toPrettyStringMethodSpecs()
291 .addCode(methodBody.get()) in createMethod()
/external/cronet/base/android/jni_generator/java/src/org/chromium/jni_generator/
DJniProcessor.java462 builder.addCode("return ($T)", interfaceMethod.getReturnType()); in createNativeWrapperMethod()
466 builder.addCode("$T.$N(", mGenJniClassName, staticNativeMethod); in createNativeWrapperMethod()
474 builder.addCode(String.join(", ", paramNames) + ");\n"); in createNativeWrapperMethod()
/external/python/cpython2/Lib/compiler/
Dpyassem.py510 lnotab.addCode(self.opnum[opname])
518 lnotab.addCode(self.opnum[opname], lo, hi)
610 def addCode(self, *args): member in LineAddrTable
/external/dagger2/java/dagger/internal/codegen/javapoet/
DCodeBlocks.java109 .addCode(body) in anonymousProvider()
/external/kotlinpoet/kotlinpoet/src/main/java/com/squareup/kotlinpoet/
DFileSpec.kt432 public fun addCode(format: String, vararg args: Any?): Builder = apply { in <lambda>() method in com.squareup.kotlinpoet.<lambda>.Builder
446 public fun addCode(codeBlock: CodeBlock): Builder = apply { in <lambda>() method in com.squareup.kotlinpoet.<lambda>.Builder

12