/** * The slow version for when concatenating a Java array of a different type. * * @param context * @param original * @param additional * @return */ public IRubyObject concatArrays(ThreadContext context, JavaArray original, IRubyObject additional) { return ArrayUtils.concatArraysDirect(context, original.getValue(), additional); }
/** * The slow version for when concatenating a Java array of a different type. * * @param context * @param original * @param additional * @return */ public IRubyObject concatArrays(ThreadContext context, JavaArray original, IRubyObject additional) { return ArrayUtils.concatArraysDirect(context, original.getValue(), additional); }
/** * The slow version for when concatenating a Java array of a different type. * * @param context * @param original * @param additional * @return */ public IRubyObject concatArrays(ThreadContext context, JavaArray original, IRubyObject additional) { return ArrayUtils.concatArraysDirect(context, original.getValue(), additional); }
/** * The slow version for when concatenating a Java array of a different type. * * @param context * @param original * @param additional * @return */ public IRubyObject concatArrays(ThreadContext context, JavaArray original, IRubyObject additional) { return ArrayUtils.concatArraysDirect(context, original.getValue(), additional); }
@JRubyMethod(name = "+") public IRubyObject op_plus(ThreadContext context, IRubyObject other) { final Object array = getObject(); if ( other instanceof ArrayJavaProxy ) { final Object otherArray = ((ArrayJavaProxy) other).getObject(); final Class<?> componentType = array.getClass().getComponentType(); if ( componentType.isAssignableFrom( otherArray.getClass().getComponentType() ) ) { return ArrayUtils.concatArraysDirect(context, array, otherArray); } } return ArrayUtils.concatArraysDirect(context, array, other); }
@JRubyMethod(name = "+") public IRubyObject op_plus(ThreadContext context, IRubyObject other) { final Object array = getObject(); if ( other instanceof ArrayJavaProxy ) { final Object otherArray = ((ArrayJavaProxy) other).getObject(); final Class<?> componentType = array.getClass().getComponentType(); if ( componentType.isAssignableFrom( otherArray.getClass().getComponentType() ) ) { return ArrayUtils.concatArraysDirect(context, array, otherArray); } } return ArrayUtils.concatArraysDirect(context, array, other); }
@JRubyMethod(name = "+") public IRubyObject op_plus(ThreadContext context, IRubyObject other) { if (other instanceof ArrayJavaProxy) { Object otherArray = ((ArrayJavaProxy)other).getObject(); if (getObject().getClass().getComponentType().isAssignableFrom(otherArray.getClass().getComponentType())) { return ArrayUtils.concatArraysDirect(context, getObject(), otherArray); } } return ArrayUtils.concatArraysDirect(context, getObject(), other); }
@JRubyMethod(name = "+") public IRubyObject op_plus(ThreadContext context, IRubyObject other) { if (other instanceof ArrayJavaProxy) { Object otherArray = ((ArrayJavaProxy)other).getObject(); if (getObject().getClass().getComponentType().isAssignableFrom(otherArray.getClass().getComponentType())) { return ArrayUtils.concatArraysDirect(context, getObject(), otherArray); } } return ArrayUtils.concatArraysDirect(context, getObject(), other); }
/** * Contatenate two Java arrays into a new one. The component type of the * additional array must be assignable to the component type of the * original array. * * @param context * @param original * @param additional * @return */ public IRubyObject concatArrays(ThreadContext context, JavaArray original, JavaArray additional) { return ArrayUtils.concatArraysDirect(context, original.getValue(), additional.getValue()); }
/** * Contatenate two Java arrays into a new one. The component type of the * additional array must be assignable to the component type of the * original array. * * @param context * @param original * @param additional * @return */ public IRubyObject concatArrays(ThreadContext context, JavaArray original, JavaArray additional) { return ArrayUtils.concatArraysDirect(context, original.getValue(), additional.getValue()); }
/** * Contatenate two Java arrays into a new one. The component type of the * additional array must be assignable to the component type of the * original array. * * @param context * @param original * @param additional * @return */ public IRubyObject concatArrays(ThreadContext context, JavaArray original, JavaArray additional) { return ArrayUtils.concatArraysDirect(context, original.getValue(), additional.getValue()); }
/** * Contatenate two Java arrays into a new one. The component type of the * additional array must be assignable to the component type of the * original array. * * @param context * @param original * @param additional * @return */ public IRubyObject concatArrays(ThreadContext context, JavaArray original, JavaArray additional) { return ArrayUtils.concatArraysDirect(context, original.getValue(), additional.getValue()); }