Package org.jruby

Examples of org.jruby.RubyObject$VariableTableEntry


        }
    }

    public <T> T callMethod(Object receiver, String methodName, Object singleArg, Class<T> returnType) {
        try {
            RubyObject rubyReceiver = getReceiverObject(receiver);
            return call(MethodType.CALLMETHOD, returnType, rubyReceiver, methodName, null, null, singleArg);
        } catch (InvokeFailedException e) {
            throw e;
        } catch (Throwable e) {
            throw new InvokeFailedException(e);
View Full Code Here


        }
    }

    public <T> T callMethod(Object receiver, String methodName, Object[] args, Class<T> returnType) {
        try {
            RubyObject rubyReceiver = getReceiverObject(receiver);
            return call(MethodType.CALLMETHOD, returnType, rubyReceiver, methodName, null, null, args);
        } catch (InvokeFailedException e) {
            throw e;
        } catch (Throwable e) {
            throw new InvokeFailedException(e);
View Full Code Here

        }
    }

    public <T> T callMethod(Object receiver, String methodName, Object[] args, Block block, Class<T> returnType) {
        try {
            RubyObject rubyReceiver = getReceiverObject(receiver);
            return call(MethodType.CALLMETHOD_WITHBLOCK, returnType, rubyReceiver, methodName, block, null, args);
        } catch (InvokeFailedException e) {
            throw e;
        } catch (Throwable e) {
            throw new InvokeFailedException(e);
View Full Code Here

        }
    }

    public <T> T callMethod(Object receiver, String methodName, Class<T> returnType, EmbedEvalUnit unit) {
        try {
            RubyObject rubyReceiver = getReceiverObject(receiver);
            return call(MethodType.CALLMETHOD_NOARG, returnType, rubyReceiver, methodName, null, unit);
        } catch (InvokeFailedException e) {
            throw e;
        } catch (Throwable e) {
            throw new InvokeFailedException(e);
View Full Code Here

        }
    }
   
    public <T> T callMethod(Object receiver, String methodName, Object[] args, Class<T> returnType, EmbedEvalUnit unit) {
        try {
            RubyObject rubyReceiver = getReceiverObject(receiver);
            return call(MethodType.CALLMETHOD, returnType, rubyReceiver, methodName, null, unit, args);
        } catch (InvokeFailedException e) {
            throw e;
        } catch (Throwable e) {
            throw new InvokeFailedException(e);
View Full Code Here

        }
    }

    public <T> T callMethod(Object receiver, String methodName, Object[] args, Block block, Class<T> returnType, EmbedEvalUnit unit) {
        try {
            RubyObject rubyReceiver = getReceiverObject(receiver);
            return call(MethodType.CALLMETHOD_WITHBLOCK, returnType, rubyReceiver, methodName, block, unit, args);
        } catch (InvokeFailedException e) {
            throw e;
        } catch (Throwable e) {
            throw new InvokeFailedException(e);
View Full Code Here

        }
    }

    public <T> T callSuper(Object receiver, Object[] args, Class<T> returnType) {
        try {
            RubyObject rubyReceiver = getReceiverObject(receiver);
            return call(MethodType.CALLSUPER, returnType, rubyReceiver, null, null, null, args);
        } catch (InvokeFailedException e) {
            throw e;
        } catch (Throwable e) {
            throw new InvokeFailedException(e);
View Full Code Here

        }
    }

    public <T> T callSuper(Object receiver, Object[] args, Block block, Class<T> returnType) {
        try {
            RubyObject rubyReceiver = getReceiverObject(receiver);
            return call(MethodType.CALLSUPER_WITHBLOCK, returnType, rubyReceiver, null, block, null, args);
        } catch (InvokeFailedException e) {
            throw e;
        } catch (Throwable e) {
            throw new InvokeFailedException(e);
View Full Code Here

        }
    }

    public Object callMethod(Object receiver, String methodName, Object... args) {
        try {
            RubyObject rubyReceiver = getReceiverObject(receiver);
            if (args.length == 0) {
                return call(MethodType.CALLMETHOD_NOARG, Object.class, rubyReceiver, methodName, null, null);
            } else {
                return call(MethodType.CALLMETHOD, Object.class, rubyReceiver, methodName, null, null, args);
            }
View Full Code Here

    public Object callMethod(Object receiver, String methodName, Block block, Object... args) {
        try {
            if (args.length == 0) {
                throw new IllegalArgumentException("needs at least one argument in a method");
            }
            RubyObject rubyReceiver = getReceiverObject(receiver);
            return call(MethodType.CALLMETHOD_WITHBLOCK, Object.class, rubyReceiver, methodName, block, null, args);
        } catch (InvokeFailedException e) {
            throw e;
        } catch (Throwable e) {
            throw new InvokeFailedException(e);
View Full Code Here

TOP

Related Classes of org.jruby.RubyObject$VariableTableEntry

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.