Home
last modified time | relevance | path

Searched refs:addMethod (Results 1 – 25 of 111) sorted by relevance

12345

/external/javaparser/javaparser-testing/src/test/java/com/github/javaparser/builders/
DNodeWithParametersBuildersTest.java42 MethodDeclaration addMethod = cu.addClass("test").addMethod("foo", Modifier.PUBLIC); in testAddParameter() local
43 addMethod.addParameter(int.class, "yay"); in testAddParameter()
44 Parameter myNewParam = addMethod.addAndGetParameter(List.class, "myList"); in testAddParameter()
47 assertEquals(2, addMethod.getParameters().size()); in testAddParameter()
48 assertEquals("yay", addMethod.getParameter(0).getNameAsString()); in testAddParameter()
49 assertEquals("List", addMethod.getParameter(1).getType().toString()); in testAddParameter()
50 assertEquals(myNewParam, addMethod.getParameter(1)); in testAddParameter()
55 MethodDeclaration addMethod = cu.addClass("test").addMethod("foo", Modifier.PUBLIC); in testGetParamByName() local
56 Parameter addAndGetParameter = addMethod.addAndGetParameter(int.class, "yay"); in testGetParamByName()
57 assertEquals(addAndGetParameter, addMethod.getParameterByName("yay").get()); in testGetParamByName()
[all …]
DNodeWithMembersBuildersTest.java50 MethodDeclaration addMethod = classDeclaration.addMethod("foo", Modifier.PUBLIC); in testAddMethod() local
52 assertEquals(addMethod, classDeclaration.getMember(0)); in testAddMethod()
53 assertEquals("foo", addMethod.getNameAsString()); in testAddMethod()
77 MethodDeclaration addMethod = classDeclaration.addMethod("foo", Modifier.PUBLIC); in testGetMethodsWithName() local
78 …MethodDeclaration addMethod2 = classDeclaration.addMethod("foo", Modifier.PUBLIC).addParameter(int… in testGetMethodsWithName()
81 assertTrue(methodsByName.contains(addMethod)); in testGetMethodsWithName()
87 MethodDeclaration addMethod = classDeclaration.addMethod("foo", Modifier.PUBLIC); in testGetMethods() local
88 …MethodDeclaration addMethod2 = classDeclaration.addMethod("foo", Modifier.PUBLIC).addParameter(int… in testGetMethods()
93 assertTrue(methods.contains(addMethod)); in testGetMethods()
99 classDeclaration.addMethod("foo", Modifier.PUBLIC); in testGetMethodsWithParameterTypes()
[all …]
DNodeWithThrownExceptionsBuildersTest.java40 MethodDeclaration addMethod = cu.addClass("test").addMethod("foo", Modifier.PUBLIC); in testThrows() local
41 addMethod.addThrownException(IllegalStateException.class); in testThrows()
42 assertEquals(1, addMethod.getThrownExceptions().size()); in testThrows()
43 assertEquals(true, addMethod.isThrown(IllegalStateException.class)); in testThrows()
44 addMethod.addThrownException(parseClassOrInterfaceType("Test")); in testThrows()
45 assertEquals(2, addMethod.getThrownExceptions().size()); in testThrows()
46 assertEquals("Test", addMethod.getThrownException(1).toString()); in testThrows()
/external/javapoet/src/test/java/com/squareup/javapoet/
DTypeSpecTest.java61 .addMethod(MethodSpec.methodBuilder("toString") in basic()
127 .addMethod(MethodSpec.methodBuilder("doSomething") in anonymousInnerClass()
136 .addMethod(MethodSpec.methodBuilder("call") in anonymousInnerClass()
173 .addMethod(MethodSpec.constructorBuilder() in annotatedParameters()
242 .addMethod(MethodSpec.methodBuilder("fooBar") in retrofitStyleInterface()
356 .addMethod(MethodSpec.methodBuilder("toString") in enumWithSubclassing()
366 .addMethod(MethodSpec.constructorBuilder() in enumWithSubclassing()
370 .addMethod(MethodSpec.constructorBuilder() in enumWithSubclassing()
412 .addMethod(MethodSpec.methodBuilder("fold") in enumsMayDefineAbstractMethods()
417 .addMethod(MethodSpec.methodBuilder("fold") in enumsMayDefineAbstractMethods()
[all …]
DJavaFileTest.java48 .addMethod(beyond) in importStaticReadmeExample()
109 .addMethod(MethodSpec.constructorBuilder() in importStaticMixed()
143 .addMethod(MethodSpec.methodBuilder("main") in importStaticDynamic()
242 return TypeSpec.classBuilder(name).addMethod(method).build(); in importStaticTypeSpec()
595 .addMethod(MethodSpec.methodBuilder("main") in defaultPackage()
/external/grpc-grpc-java/core/src/test/java/io/grpc/
DServerServiceDefinitionTest.java71 .addMethod(method1, methodHandler1) in addMethod_twoArg()
72 .addMethod(method2, methodHandler2) in addMethod_twoArg()
91 .addMethod(method1, methodHandler1); in addMethod_duplicateName()
93 ssd.addMethod(diffMethod1, methodHandler2) in addMethod_duplicateName()
101 .addMethod(methodDef1); in buildMisaligned_extraMethod()
110 .addMethod(diffMethod1, methodHandler1); in buildMisaligned_diffMethodInstance()
126 .addMethod(methodDef1) in builderWithServiceName()
127 .addMethod(methodDef2) in builderWithServiceName()
DServerInterceptorsTest.java88 .addMethod(flowMethod, handler).build(); in setUp()
149 .addMethod(flowMethod, handler) in correctHandlerCalled()
150 .addMethod(flowMethod2, handler2).build(); in correctHandlerCalled()
219 .addMethod(flowMethod, handler).build(); in ordered()
261 .addMethod(flowMethod, handler).build(); in orderedForward()
334 .addMethod(wrappedMethod, handler2).build(); in typedMarshalledMessages()
/external/grpc-grpc-java/core/src/main/java/io/grpc/internal/
DReflectionLongAdderCounter.java32 private static final Method addMethod; field in ReflectionLongAdderCounter
67 addMethod = addMethodLookup;
72 addMethod = null;
103 addMethod.invoke(instance, delta); in add()
/external/dagger2/compiler/src/main/java/dagger/internal/codegen/writer/
DTypeWriter.java49 public MethodWriter addMethod(TypeWriter returnType, String name) { in addMethod() method in TypeWriter
55 public MethodWriter addMethod(TypeMirror returnType, String name) { in addMethod() method in TypeWriter
62 public MethodWriter addMethod(TypeName returnType, String name) { in addMethod() method in TypeWriter
68 public MethodWriter addMethod(Class<?> returnType, String name) { in addMethod() method in TypeWriter
/external/javaparser/javaparser-testing/src/test/java/com/github/javaparser/printer/
DPrettyPrintVisitorTest.java181 cu.addClass("X").addMethod("abc").setJavadocComment("line1\n line2 *\n * line3"); in multilineJavadocGetsFormatted()
198 cu.addClass("X").addMethod("abc").setJavadocComment(""); in emptyJavadocGetsFormatted()
212 cu.addClass("X").addMethod("abc").setJavadocComment("\n\n\n ab\n\n\n cd\n\n\n"); in multilineJavadocWithLotsOfEmptyLinesGetsFormattedNeatly()
229 cu.addClass("X").addMethod("abc").setJavadocComment("line1"); in singlelineJavadocGetsFormatted()
244 cu.addClass("X").addMethod("abc").setComment(new LineComment(" line1 \n ")); in singlelineCommentGetsFormatted()
/external/javaparser/javaparser-testing/src/test/java/com/github/javaparser/remove/
DNodeRemovalTest.java63 MethodDeclaration addMethod = testClass.addMethod("testM"); in testRemoveStatementFromMethodBody() local
64 BlockStmt methodBody = addMethod.createBody(); in testRemoveStatementFromMethodBody()
/external/jacoco/org.jacoco.report.test/src/org/jacoco/report/internal/html/page/
DClassPageTest.java39 node.addMethod(new MethodCoverageImpl("a", "()V", null)); in setup()
40 node.addMethod(new MethodCoverageImpl("b", "()V", null)); in setup()
41 node.addMethod(new MethodCoverageImpl("c", "()V", null)); in setup()
/external/javaparser/javaparser-symbol-solver-testing/src/test/resources/javaparser_methodcalls_expected_output/
Dcom_github_javaparser_ast_body_FieldDeclaration.txt38 …Line 206) parentClass.addMethod("get" + fieldNameUpper, PUBLIC) ==> com.github.javaparser.ast.node…
39 …Line 208) parentEnum.addMethod("get" + fieldNameUpper, PUBLIC) ==> com.github.javaparser.ast.nodeT…
58 …Line 239) parentClass.addMethod("set" + fieldNameUpper, PUBLIC) ==> com.github.javaparser.ast.node…
59 …Line 241) parentEnum.addMethod("set" + fieldNameUpper, PUBLIC) ==> com.github.javaparser.ast.nodeT…
/external/tensorflow/tensorflow/java/src/gen/java/org/tensorflow/processor/
DOperatorProcessor.java314 .addMethod(ctorBuilder.build()); in buildGroupClass()
369 .addMethod(ctorBuilder.build()); in buildTopClass()
371 opsBuilder.addMethod( in buildTopClass()
383 opsBuilder.addMethod( in buildTopClass()
398 opsBuilder.addMethod( in buildTopClass()
412 opsBuilder.addMethod( in buildTopClass()
422 opsBuilder.addMethod( in buildTopClass()
/external/dagger2/compiler/src/main/java/dagger/internal/codegen/
DComponentWriter.java71 ? componentWriter.addMethod( in createBuilder()
79 : componentWriter.addMethod(builderWriter, "builder"); in createBuilder()
89 componentWriter.addMethod(componentDefinitionTypeName(), "create"); in addFactoryMethods()
/external/grpc-grpc-java/interop-testing/src/generated/main/grpc/io/grpc/testing/integration/
DTestServiceGrpc.java413 .addMethod( in bindService()
420 .addMethod( in bindService()
427 .addMethod( in bindService()
434 .addMethod( in bindService()
441 .addMethod( in bindService()
448 .addMethod( in bindService()
455 .addMethod( in bindService()
462 .addMethod( in bindService()
858 .addMethod(getEmptyCallMethod()) in getServiceDescriptor()
859 .addMethod(getUnaryCallMethod()) in getServiceDescriptor()
[all …]
/external/flatbuffers/tests/MyGame/Example/
DMonsterStorageGrpc.java254 .addMethod( in bindService()
261 .addMethod( in bindService()
268 .addMethod( in bindService()
275 .addMethod( in bindService()
460 .addMethod(getStoreMethod()) in getServiceDescriptor()
461 .addMethod(getRetrieveMethod()) in getServiceDescriptor()
462 .addMethod(getGetMaxHitPointMethod()) in getServiceDescriptor()
463 .addMethod(getGetMinMaxHitPointsMethod()) in getServiceDescriptor()
/external/javaparser/javaparser-core-generators/src/main/java/com/github/javaparser/generator/
DGenerator.java61addMethod(containingClassOrInterface, callable, () -> containingClassOrInterface.addMember(callabl… in addOrReplaceWhenSameSignature()
70 addMethod(containingClassOrInterface, callable, in replaceWhenSameSignature()
76 private void addMethod( in addMethod() method in Generator
/external/grpc-grpc-java/core/src/main/java/io/grpc/
DServerServiceDefinition.java100 public <ReqT, RespT> Builder addMethod( in addMethod() method in ServerServiceDefinition.Builder
102 return addMethod(ServerMethodDefinition.create( in addMethod()
108 public <ReqT, RespT> Builder addMethod(ServerMethodDefinition<ReqT, RespT> def) { in addMethod() method in ServerServiceDefinition.Builder
/external/grpc-grpc-java/services/src/generated/main/grpc/io/grpc/channelz/v1/
DChannelzGrpc.java320 .addMethod( in bindService()
327 .addMethod( in bindService()
334 .addMethod( in bindService()
341 .addMethod( in bindService()
348 .addMethod( in bindService()
355 .addMethod( in bindService()
739 .addMethod(getGetTopChannelsMethod()) in getServiceDescriptor()
740 .addMethod(getGetServersMethod()) in getServiceDescriptor()
741 .addMethod(getGetServerSocketsMethod()) in getServiceDescriptor()
742 .addMethod(getGetChannelMethod()) in getServiceDescriptor()
[all …]
/external/grpc-grpc-java/core/src/test/java/io/grpc/util/
DMutableHandlerRegistryTest.java83 .addMethod(flowMethod, flowHandler) in setUp()
92 .addMethod(coupleMethod, coupleHandler) in setUp()
93 .addMethod(fewMethod, fewHandler) in setUp()
172 .addMethod(anotherMethod, flowHandler).build(); in replaceAndLookup()
/external/grpc-grpc-java/benchmarks/src/generated/main/grpc/io/grpc/benchmarks/proto/
DBenchmarkServiceGrpc.java275 .addMethod( in bindService()
282 .addMethod( in bindService()
289 .addMethod( in bindService()
296 .addMethod( in bindService()
303 .addMethod( in bindService()
568 .addMethod(getUnaryCallMethod()) in getServiceDescriptor()
569 .addMethod(getStreamingCallMethod()) in getServiceDescriptor()
570 .addMethod(getStreamingFromClientMethod()) in getServiceDescriptor()
571 .addMethod(getStreamingFromServerMethod()) in getServiceDescriptor()
572 .addMethod(getStreamingBothWaysMethod()) in getServiceDescriptor()
DWorkerServiceGrpc.java237 .addMethod( in bindService()
244 .addMethod( in bindService()
251 .addMethod( in bindService()
258 .addMethod( in bindService()
519 .addMethod(getRunServerMethod()) in getServiceDescriptor()
520 .addMethod(getRunClientMethod()) in getServiceDescriptor()
521 .addMethod(getCoreCountMethod()) in getServiceDescriptor()
522 .addMethod(getQuitWorkerMethod()) in getServiceDescriptor()
/external/javaparser/javaparser-symbol-solver-testing/src/test/test_sourcecode/javaparser_new_src/javaparser-core/com/github/javaparser/ast/body/
DFieldDeclaration.java206 getter = parentClass.addMethod("get" + fieldNameUpper, PUBLIC); in createGetter()
208 getter = parentEnum.addMethod("get" + fieldNameUpper, PUBLIC); in createGetter()
239 setter = parentClass.addMethod("set" + fieldNameUpper, PUBLIC); in createSetter()
241 setter = parentEnum.addMethod("set" + fieldNameUpper, PUBLIC); in createSetter()
/external/grpc-grpc-java/testing-proto/src/generated/main/grpc/io/grpc/testing/protobuf/
DSimpleServiceGrpc.java233 .addMethod( in bindService()
240 .addMethod( in bindService()
247 .addMethod( in bindService()
254 .addMethod( in bindService()
504 .addMethod(getUnaryRpcMethod()) in getServiceDescriptor()
505 .addMethod(getClientStreamingRpcMethod()) in getServiceDescriptor()
506 .addMethod(getServerStreamingRpcMethod()) in getServiceDescriptor()
507 .addMethod(getBidiStreamingRpcMethod()) in getServiceDescriptor()

12345