Converts CMIS value of ID type into JCR value of String type.

@param values CMIS values of Id type
@return JCR values of String type
775205
private String[] asIDs( List<Object> values ) {
        ValueFactory<String> factory = valueFactories.getStringFactory();
        String[] res = new String[values.size()];
        for (int i = 0; i < res.length; i++) {
            res[i] = factory.create(values.get(i));
        }
        return res;
    }
237297
public String[] buildValueWhereArgs(Collection<ColumnValue> values) {
		List<String> selectionArgs = new ArrayList<String>();
		for (ColumnValue value : values) {
			if (value != null && value.getValue() != null) {
				if (value.getTolerance() != null) {
					String[] toleranceArgs = getValueToleranceRange(value);
					selectionArgs.add(toleranceArgs[0]);
					selectionArgs.add(toleranceArgs[1]);
				} else {
					selectionArgs.add(value.getValue().toString());
				}
			}
		}
		return selectionArgs.isEmpty() ? null : selectionArgs
				.toArray(new String[] {});
	}
163331
public static String[] jcrPermissions( String cmisPermission ) {
        switch (cmisPermission) {
            case "cmis:read" :
                return new String[] {
                    Privilege.JCR_READ,
                    Privilege.JCR_READ_ACCESS_CONTROL
                };
            case "cmis:write" : 
                return new String[] {
                    Privilege.JCR_WRITE,
                    Privilege.JCR_READ_ACCESS_CONTROL,
                    Privilege.JCR_MODIFY_ACCESS_CONTROL,
                    Privilege.JCR_NODE_TYPE_MANAGEMENT,
                    Privilege.JCR_RETENTION_MANAGEMENT,
                    Privilege.JCR_VERSION_MANAGEMENT
                };
            case "cmis:all" :
                return new String[] {Privilege.JCR_ALL};
            default :
                    return null;
        }
    }
263573
public String[] buildColumnsAs(List<TColumn> columns, String[] values) {

		String[] columnsArray = buildColumnsArray(columns);

		return buildColumnsAs(columnsArray, values);
	}
581673
private List<String> createListFromValue(String value) {

        if (value == null) {
            return null;
        }
        List<String> result = CmsStringUtil.splitAsList(value, VALUE_LIST_DELIMITER);
        if (value.indexOf(VALUE_LIST_DELIMITER_REPLACEMENT) != -1) {
            List<String> tempList = new ArrayList<String>(result.size());
            Iterator<String> i = result.iterator();
            while (i.hasNext()) {
                String item = i.next();
                tempList.add(rebuildDelimiter(item, VALUE_LIST_DELIMITER, VALUE_LIST_DELIMITER_REPLACEMENT));
            }
            result = tempList;
        }

        return result;
    }
193424
public static String getStringFromCollection(Collection<String> values) {
        StringBuilder builder = new StringBuilder();
        if (values != null) {
            for (String value : values) {
                builder.append(value).append(',');
            }
            if (builder.charAt(builder.length() - 1) == ',')
                builder.deleteCharAt(builder.length() - 1);
        }
        return builder.toString();
    }
381094
public static long[] unWrap(Long... values) {
		if (null == values) {
			return null;
		}
		final int length = values.length;
		if (0 == length) {
			return new long[0];
		}

		final long[] array = new long[length];
		for (int i = 0; i < length; i++) {
			array[i] = values[i].longValue();
		}
		return array;
	}
223847
static
	private <E> List<E> toJavaList(List<E> values, int rows, int columns){
		List<E> result = new ArrayList<>(values.size());

		for(int i = 0; i < values.size(); i++){
			int row = i / columns;
			int column = i % columns;

			E value = values.get((column * rows) + row);

			result.add(value);
		}

		return result;
	}
1044964
protected static DataBuffer createValueBuffer(float[] values) {
        checkNotNull(values);
        if (values.length == 0){
            return Nd4j.createBuffer(1);
        }
        return Nd4j.createBuffer(values);
    }
22955
public static String escape (Object[] values)
    {
        StringBuilder buf = new StringBuilder();
        for (int ii = 0; ii < values.length; ii++) {
            if (ii > 0) {
                buf.append(", ");
            }
            buf.append(escape(String.valueOf(values[ii])));
        }
        return buf.toString();
    }
630275
protected Object[] cast(Collection values) {
        Object[] res = new Object[values.size()];
        int i = 0;
        for (Object value : values) {
            res[i++] = cast(value);
        }
        return res;
    }
708221
public void createValueCells(Object... values) {
        for (Object value : values) {
            if (value == null) {
                this.createCell("");
                continue;
            }

            if (value instanceof String) {
                this.createCell((String) value);
            } else if (value instanceof Date) {
                this.createCell((Date) value);
            } else if (ValidationObjUtil.isIntType(value.getClass())) {
                long longValue = Long.valueOf(value + "");
                this.createCell(longValue);
            } else if (ValidationObjUtil.isDoubleType(value.getClass())) {
                double doubleValue = Double.valueOf(value + "");
                this.createCell(doubleValue);
            } else {
                this.createCell(value);
            }
        }
    }
660172
public PersistenceUnit<T> mappingFile(String ... values)
   {
      if (values != null)
      {
         for(String name: values)
         {
            childNode.createChild("mapping-file").text(name);
         }
      }
      return this;
   }
1081884
public static String makeJSONArrayString(Object[] values) {
        // Since they won't change during a run, compute the JSON value for the
        // summary data fields (an array where all field names are wrapped in quotes
        StringBuilder buf = new StringBuilder();
        int numVals = values.length;

        buf.append("[");
        for (int i = 0; i < numVals; i++) {
            buf.append(QUOTE);
            buf.append(values[i].toString());
            buf.append(QUOTE);
            if (i < numVals - 1) {
                buf.append(COMMA);
            }
        }
        buf.append("]");

        return buf.toString();
    }
793935
@SuppressWarnings({ "unchecked", "checkstyle:illegaltype" })
	Collection<V> copyValues(Collection<V> values) {
		final Object backEnd = DataViewDelegate.undelegate(values);
		if (backEnd instanceof List<?>) {
			return Lists.newArrayList(values);
		}
		if (backEnd instanceof TreeSet<?>) {
			TreeSet<V> c = (TreeSet<V>) backEnd;
			c = Sets.newTreeSet(c.comparator());
			c.addAll(values);
			return c;
		}
		if (backEnd instanceof LinkedHashSet<?>) {
			return Sets.newLinkedHashSet(values);
		}
		if (backEnd instanceof Set<?>) {
			return Sets.newHashSet(values);
		}
		throw new IllegalStateException("Unsupported type of the backend multimap: " + values.getClass()); //$NON-NLS-1$
	}
929098
public static <T extends Enum<?>> T enumFromString(final String value, final T[] values) {
        if (value == null) {
            return null;
        }

        for (T v : values) {
            if (v.toString().equalsIgnoreCase(value)) {
                return v;
            }
        }

        return null;
    }
776712
public static <E> List<E> newArrayList(E... values) {
    List<E> list = new ArrayList<E>(values.length);
    for (E e : values) {
      list.add(e);
    }
    return list;
  }