Minor Update
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-widget-common-event@111794 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
cb365a5a61
commit
64a38b61b4
|
@ -0,0 +1,40 @@
|
|||
package org.gcube.portlets.user.td.widgetcommonevent.shared.geospatial;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author "Giancarlo Panichi" <a
|
||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
||||
*
|
||||
*/
|
||||
public enum GeospatialCoordinatesType {
|
||||
C_SQUARE("C-Square"), OCEAN_AREA("Ocean Area");
|
||||
|
||||
/**
|
||||
* @param text
|
||||
*/
|
||||
private GeospatialCoordinatesType(final String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
private final String id;
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public static GeospatialCoordinatesType getGeospatialCoordinatesTypeFromId(
|
||||
String id) {
|
||||
if (id.compareTo(C_SQUARE.id) == 0) {
|
||||
return C_SQUARE;
|
||||
} else {
|
||||
if (id.compareTo(OCEAN_AREA.id) == 0) {
|
||||
return OCEAN_AREA;
|
||||
} else {
|
||||
return null;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in New Issue