data-miner-manager-tester/src/main/java/org/gcube/portlets/user/dataminermanagertester/shared/config/ProtocolType.java

44 lines
815 B
Java

package org.gcube.portlets.user.dataminermanagertester.shared.config;
/**
*
* @author Giancarlo Panichi
*
*
*/
public enum ProtocolType {
HTTPS("https"), HTTP("http");
private ProtocolType(final String id) {
this.id = id;
***REMOVED***
private final String id;
@Override
public String toString() {
return id;
***REMOVED***
public String getLabel() {
return id;
***REMOVED***
public boolean compareId(String identificator) {
if (identificator.compareTo(id) == 0) {
return true;
***REMOVED*** else {
return false;
***REMOVED***
***REMOVED***
public static ProtocolType getTypeFromId(String id) {
for (ProtocolType testType : values()) {
if (testType.id.compareToIgnoreCase(id) == 0) {
return testType;
***REMOVED***
***REMOVED***
return null;
***REMOVED***
***REMOVED***