All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.minecraftforge.gdi.transformer.property.PropertyHandler.groovy Maven / Gradle / Ivy

Go to download

Groovy Compiler Plugin to improve building Groovy based DSLs, like those used in Gradle.

The newest version!
/*
 * Copyright (c) Forge Development LLC and contributors
 * SPDX-License-Identifier: LGPL-2.1-only
 */

package net.minecraftforge.gdi.transformer.property

import groovy.transform.CompileStatic
import net.minecraftforge.gdi.transformer.DSLPropertyTransformer
import org.codehaus.groovy.ast.AnnotationNode
import org.codehaus.groovy.ast.MethodNode

/**
 * Interface used to handle implementing {@link net.minecraftforge.gdi.annotations.DSLProperty} methods.
 * @see DSLPropertyTransformer#HANDLERS
 */
@CompileStatic
interface PropertyHandler {
    /**
     * Handles the DSL property.
     * @param methodNode the method declaring the property
     * @param annotation the DSL property annotation
     * @param propertyName the name of the property
     * @param utils a utility class for adding methods
     * @return if this handler handled the property type
     */
    boolean handle(MethodNode methodNode, AnnotationNode annotation, String propertyName, DSLPropertyTransformer.Utils utils)
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy