com.github.housepower.jdbc.misc.Container Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of clickhouse-native-jdbc Show documentation
Show all versions of clickhouse-native-jdbc Show documentation
ClickHouse Native Protocol JDBC implementation
package com.github.housepower.jdbc.misc;
public class Container {
private final T left;
private final T right;
private boolean isLeft = true;
public Container(T left, T right) {
this.left = left;
this.right = right;
}
public void select(boolean isRight) {
isLeft = (isLeft == isRight) ? !isRight : isLeft;
}
public T get() {
return isLeft ? left : right;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy