Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.myfaces.shared_orchestra.util
Class ArrayUtils

    java.lang.Object
      org.apache.myfaces.shared_orchestra.util.ArrayUtils

    public class ArrayUtils

extends java.lang.Object

Utility class for managing arrays

Version:
  $Revision: 472630 $ $Date: 2006-11-08 21:40:03 +0100 (Mi, 08 Nov 2006) $
Author:
  Anton Koinov (latest modification by $Author: grantsmith $)

Field Summary
`static java.lang.Object[]` | `EMPTY_OBJECT_ARRAY`
`static java.lang.String[]` | `EMPTY_STRING_ARRAY`

Constructor Summary
`protected` | `ArrayUtils()`

Method Summary
`static java.lang.Class` | `commonClass(java.lang.Class c1, java.lang.Class c2)`
`static java.lang.Object` | `concat(java.lang.Object[] arrs)` Concatenates arrays into one.
`static java.lang.Object` | `concat(java.lang.Object toArray, int totalLen, java.lang.Object[] arrs)`
`static java.lang.Object` | `concat(java.lang.Object arr1, java.lang.Object arr2)` Concatenates two arrays into one.
`static java.lang.Object` | `concat(java.lang.Object arr1, java.lang.Object arr2, java.lang.Object arr3)`
`static java.lang.Object` | `concat(java.lang.Object arr1, java.lang.Object arr2, java.lang.Object arr3, java.lang.Object arr4)`
`static java.lang.Object` | `concat(java.lang.Object arr1, java.lang.Object arr2, java.lang.Object arr3, java.lang.Object arr4, java.lang.Object arr5)`
`static java.lang.Object` | `concatSameType(java.lang.Object toArray, java.lang.Object[] arrs)`
`static boolean` | `contains(java.lang.Object[] array, java.lang.Object value)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### EMPTY_OBJECT_ARRAY

    public static final java.lang.Object[] EMPTY_OBJECT_ARRAY

### EMPTY_STRING_ARRAY

    public static final java.lang.String[] EMPTY_STRING_ARRAY

Constructor Detail

### ArrayUtils

    protected ArrayUtils()

Method Detail

### commonClass

    public static java.lang.Class commonClass(java.lang.Class c1,
                                              java.lang.Class c2)

### concat

    public static java.lang.Object concat(java.lang.Object arr1,
                                          java.lang.Object arr2)

  Concatenates two arrays into one. If arr1 is null or empty, returns arr2. If arr2 is null or empty, returns arr1. May return null if both arrays are null, or one is empty and the other null.
  The concatenated array has componentType which is compatible with both input arrays (or Object[])

  Parameters:
    `arr1` - input array
    `arr2` - input array
  Returns:
    Object the concatenated array, elements of arr1 first

### concat

    public static java.lang.Object concat(java.lang.Object[] arrs)

  Concatenates arrays into one. Any null or empty arrays are ignored. If all arrays are null or empty, returns null. Elements will be ordered in the order in which the arrays are supplied.

  Parameters:
    `arrs` - array of arrays
  Returns:
    the concatenated array

### concat

    public static java.lang.Object concat(java.lang.Object toArray,
                                          int totalLen,
                                          java.lang.Object[] arrs)

### concat

    public static java.lang.Object concat(java.lang.Object arr1,
                                          java.lang.Object arr2,
                                          java.lang.Object arr3)

### concat

    public static java.lang.Object concat(java.lang.Object arr1,
                                          java.lang.Object arr2,
                                          java.lang.Object arr3,
                                          java.lang.Object arr4)

### concat

    public static java.lang.Object concat(java.lang.Object arr1,
                                          java.lang.Object arr2,
                                          java.lang.Object arr3,
                                          java.lang.Object arr4,
                                          java.lang.Object arr5)

### concatSameType

    public static java.lang.Object concatSameType(java.lang.Object toArray,
                                                  java.lang.Object[] arrs)

### contains

    public static boolean contains(java.lang.Object[] array,
                                   java.lang.Object value)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009 The Apache Software Foundation. All Rights Reserved.