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

com.icthh.xm.lep.api.LepMethod Maven / Gradle / Ivy

There is a newer version: 4.0.21
Show newest version
package com.icthh.xm.lep.api;

import com.icthh.xm.commons.lep.api.LepBaseKey;

public interface LepMethod {

    // This method brakes encapsulation. Pls remove usage of this method from LEP scripts.
    @Deprecated(forRemoval = true)
    Object getTarget();

    MethodSignature getMethodSignature();

    Object[] getMethodArgValues();

    default  T getParameter(String name, Class type) {
        Integer parameterIndex = getMethodSignature().getParameterIndex(name);
        if (parameterIndex == null) {
            throw new IllegalStateException("Can't find parameter '" + name + "' for method: "
                + getMethodSignature().toString());
        }
        return type.cast(getMethodArgValues()[parameterIndex]);
    }

    LepBaseKey getLepBaseKey();

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy