Java Code Examples for org.neo4j.driver.Value#size()

The following examples show how to use org.neo4j.driver.Value#size() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: AdditionalTypes.java    From sdn-rx with Apache License 2.0 5 votes vote down vote up
static boolean[] asBooleanArray(Value value) {
	boolean[] array = new boolean[value.size()];
	int i = 0;
	for (Boolean v : value.values(Value::asBoolean)) {
		array[i++] = v;
	}
	return array;
}
 
Example 2
Source File: AdditionalTypes.java    From sdn-rx with Apache License 2.0 5 votes vote down vote up
static char[] asCharArray(Value value) {
	char[] array = new char[value.size()];
	int i = 0;
	for (Character v : value.values(AdditionalTypes::asCharacter)) {
		array[i++] = v;
	}
	return array;
}
 
Example 3
Source File: AdditionalTypes.java    From sdn-rx with Apache License 2.0 5 votes vote down vote up
static double[] asDoubleArray(Value value) {
	double[] array = new double[value.size()];
	int i = 0;
	for (double v : value.values(Value::asDouble)) {
		array[i++] = v;
	}
	return array;
}
 
Example 4
Source File: AdditionalTypes.java    From sdn-rx with Apache License 2.0 5 votes vote down vote up
static float[] asFloatArray(Value value) {
	float[] array = new float[value.size()];
	int i = 0;
	for (float v : value.values(AdditionalTypes::asFloat)) {
		array[i++] = v;
	}
	return array;
}
 
Example 5
Source File: AdditionalTypes.java    From sdn-rx with Apache License 2.0 5 votes vote down vote up
static int[] asIntArray(Value value) {
	int[] array = new int[value.size()];
	int i = 0;
	for (int v : value.values(Value::asInt)) {
		array[i++] = v;
	}
	return array;
}
 
Example 6
Source File: AdditionalTypes.java    From sdn-rx with Apache License 2.0 5 votes vote down vote up
static long[] asLongArray(Value value) {
	long[] array = new long[value.size()];
	int i = 0;
	for (long v : value.values(Value::asLong)) {
		array[i++] = v;
	}
	return array;
}
 
Example 7
Source File: AdditionalTypes.java    From sdn-rx with Apache License 2.0 5 votes vote down vote up
static short[] asShortArray(Value value) {
	short[] array = new short[value.size()];
	int i = 0;
	for (short v : value.values(AdditionalTypes::asShort)) {
		array[i++] = v;
	}
	return array;
}
 
Example 8
Source File: SpatialTypes.java    From sdn-rx with Apache License 2.0 5 votes vote down vote up
static Point[] asPointArray(Value value) {
	Point[] array = new Point[value.size()];
	int i = 0;
	for (Point v : value.values(SpatialTypes::asSpringDataPoint)) {
		array[i++] = v;
	}
	return array;
}
 
Example 9
Source File: AdditionalTypes.java    From sdn-rx with Apache License 2.0 4 votes vote down vote up
static String[] asStringArray(Value value) {
	String[] array = new String[value.size()];
	return value.asList(Value::asString).toArray(array);
}