- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 49 for classBody (0.14 sec)
-
platforms/jvm/language-groovy/src/testFixtures/resources/org/gradle/groovy/compile/AbstractGroovyCompilerIntegrationSpec/canUseAstTransformThatReferencesGroovyTestCase/src/main/groovy/TestCaseTransform.java
import org.codehaus.groovy.ast.ClassNode; import org.codehaus.groovy.control.SourceUnit; import org.codehaus.groovy.transform.ASTTransformation; import org.codehaus.groovy.transform.GroovyASTTransformation; @GroovyASTTransformation public class TestCaseTransform implements ASTTransformation { public void visit(ASTNode[] nodes, SourceUnit source) { ClassNode clazz = (ClassNode) nodes[1];
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Mon Aug 28 11:40:18 UTC 2023 - 1.1K bytes - Viewed (0) -
platforms/jvm/language-groovy/src/testFixtures/resources/org/gradle/groovy/compile/AbstractGroovyCompilerIntegrationSpec/canUseThirdPartyAstTransform/src/main/java/MagicFieldTransform.java
public void visit(ASTNode[] nodes, SourceUnit source) { ClassNode clazz = (ClassNode) nodes[1]; clazz.addField("magicField", Modifier.PUBLIC, ClassHelper.STRING_TYPE, new ConstantExpression("magicValue")); }
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Mon Aug 28 11:40:18 UTC 2023 - 707 bytes - Viewed (0) -
build-logic/kotlin-dsl-shared-runtime/src/main/kotlin/org/gradle/kotlin/dsl/internal/sharedruntime/codegen/ApiTypeProvider.kt
if (methodNode.access.isSynthetic) return false if (!hasSuperType) return true fun ArrayDeque<String>.addSuperTypesOf(classNode: ClassNode) { classNode.interfaces.forEach { push(it) } if (classNode.superName != null) push(classNode.superName) } val superTypeStack = ArrayDeque<String>().apply { addSuperTypesOf(delegate) }
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Tue Feb 06 19:56:10 UTC 2024 - 20.8K bytes - Viewed (0) -
platforms/core-configuration/base-services-groovy/src/main/java/org/gradle/groovy/scripts/internal/AstUtils.java
} } public static MethodNode getGeneratedClosureImplMethod(ClassNode classNode) { if (!classNode.implementsInterface(ClassHelper.GENERATED_CLOSURE_Type)) { throw new IllegalArgumentException("expecting generated closure class node"); } List<MethodNode> doCallMethods = classNode.getDeclaredMethods("doCall"); return doCallMethods.get(0); } /**
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Thu Sep 28 10:00:26 UTC 2023 - 11.7K bytes - Viewed (0) -
platforms/core-execution/workers/src/test/groovy/org/gradle/process/internal/worker/child/SerializableMockHelper.groovy
} } class ClassCollector implements ClassgenCallback { Class generated ClassLoader target void call(ClassVisitor classVisitor, ClassNode classNode) { def bytes = ((ClassWriter) classVisitor).toByteArray(); generated = target.defineClass(classNode.getName(), bytes, 0, bytes.length) }
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Fri Sep 22 09:36:27 UTC 2023 - 2.5K bytes - Viewed (0) -
platforms/jvm/language-groovy/src/main/java/org/gradle/api/internal/tasks/compile/ApiGroovyCompiler.java
} @Override public void call(SourceUnit source, GeneratorContext context, ClassNode classNode) { inspectClassNode(source, classNode); } private void inspectClassNode(SourceUnit sourceUnit, ClassNode classNode) { String classFqName = classNode.getName();
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Mon Aug 28 11:40:18 UTC 2023 - 20.7K bytes - Viewed (0) -
platforms/software/dependency-management/src/main/java/org/gradle/api/internal/catalog/SimpleGeneratedJavaClassCompiler.java
String classCode = classSource.getSource(); File file = sourceFile(srcDir, packageName, className); writeSourceFile(classCode, file); filesToCompile.add(file); } return filesToCompile; } private static void writeSourceFile(String classCode, File file) throws IOException { file.getParentFile().mkdirs();
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Tue Oct 10 21:10:11 UTC 2023 - 5.4K bytes - Viewed (0) -
subprojects/core/src/main/java/org/gradle/groovy/scripts/internal/SubsetScriptTransformer.java
iter.remove(); } } ClassNode scriptClass = AstUtils.getScriptClass(source); // Remove all the classes other than the main class source.getAST().getClasses().removeIf(classNode -> classNode != scriptClass); // Remove all the methods from the main class if (scriptClass != null) {
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Mon Mar 08 12:24:19 UTC 2021 - 3.8K bytes - Viewed (0) -
platforms/jvm/language-groovy/src/testFixtures/resources/org/gradle/groovy/compile/AbstractGroovyCompilerIntegrationSpec/canUseAstTransformWithAsm/src/main/groovy/GroovyMagicFieldTransform.groovy
import groovyjarjarasm.asm.MethodVisitor import groovyjarjarasm.asm.Opcodes import org.codehaus.groovy.ast.ASTNode import org.codehaus.groovy.ast.ClassHelper import org.codehaus.groovy.ast.ClassNode import org.codehaus.groovy.classgen.BytecodeExpression import org.codehaus.groovy.control.SourceUnit import org.codehaus.groovy.transform.ASTTransformation import org.codehaus.groovy.transform.GroovyASTTransformation @GroovyASTTransformation
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Mon Aug 28 11:40:18 UTC 2023 - 1K bytes - Viewed (0) -
subprojects/core/src/main/java/org/gradle/groovy/scripts/DefaultScriptCompilerFactory.java
* See the License for the specific language governing permissions and * limitations under the License. */ package org.gradle.groovy.scripts; import org.codehaus.groovy.ast.ClassNode; import org.gradle.api.Action; import org.gradle.api.internal.initialization.ClassLoaderScope; import org.gradle.groovy.scripts.internal.CompileOperation; import org.gradle.groovy.scripts.internal.CompiledScript;
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Sat Dec 09 15:05:17 UTC 2023 - 2.3K bytes - Viewed (0)