com.softicar.platform.common.container.tuple.Tuple0 Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of platform-common Show documentation
Show all versions of platform-common Show documentation
The SoftiCAR Platform is a lightweight, Java-based library to create interactive business web applications.
package com.softicar.platform.common.container.tuple;
/**
* This is the empty tuple.
*
* @author Oliver Richers
*/
public final class Tuple0 extends AbstractTuple {
public Tuple1 plus(T0 element) {
return new Tuple1<>(element);
}
@Override
public int size() {
return 0;
}
@Override
protected Object getElement(int index) {
throw new UnsupportedOperationException("Cannot access the elements of the empty tuple.");
}
}