Tuple
Emil Forslund edited this page Oct 20, 2016
·
1 revision
A collection of Tuple classes that represent sets of a fixed length where every element has a specific type. You can read more about tuples here. Most of the classes in this library have been auto generated for performance reasons.
public final class Example {
public void operate(Tuple3<String, Boolean, Integer> tuple) {
System.out.println("String : " + tuple.get0());
System.out.println("Boolean : " + tuple.get1());
System.out.println("Integer : " + tuple.get2());
}
...
}
To create an instance of Tuple
, use the following utility class:
Tuple1<String> a = Tuples.of("foo");
Tuple2<String, Boolean> b = Tuples.of("bar", false);
To use Tuple in your own projects, add the following to your pom.xml
-file.
<dependency>
<groupId>com.speedment.common</groupId>
<artifactId>tuple</artifactId>
<version>1.0.1</version>
</dependency>
Speedment is available under the Apache 2 license.
Want to learn more about the enterprise version? Visit www.speedment.com!