Added Direction enum

This commit is contained in:
Luca Frosini 2021-10-20 15:23:25 +02:00
parent 633ff9c3ab
commit b454e52e67
1 changed files with 20 additions and 0 deletions

View File

@ -0,0 +1,20 @@
package org.gcube.informationsystem.base.reference;
/**
* @author Luca Frosini (ISTI - CNR)
*/
public enum Direction {
IN, OUT, BOTH;
public Direction opposite() {
if(this.equals(IN)) {
return OUT;
}else if(this.equals(OUT)) {
return IN;
} else {
return BOTH;
}
}
}