queueOverview.setStatus(WorkgroupQueue.Status.fromString(parser.nextText()));
/** * Converts a String into the corresponding status. Valid String values * that can be converted to a status are: "open", "active", and "closed". * * @param type the String value to covert. * @return the corresponding Type. */ public static Status fromString(String type) { if (type == null) { return null; } type = type.toLowerCase(Locale.US); if (OPEN.toString().equals(type)) { return OPEN; } else if (ACTIVE.toString().equals(type)) { return ACTIVE; } else if (CLOSED.toString().equals(type)) { return CLOSED; } else { return null; } }
queueOverview.setStatus(WorkgroupQueue.Status.fromString(parser.nextText()));
queueOverview.setStatus(WorkgroupQueue.Status.fromString(parser.nextText()));
queueOverview.setStatus(WorkgroupQueue.Status.fromString(parser.nextText()));
/** * Converts a String into the corresponding status. Valid String values * that can be converted to a status are: "open", "active", and "closed". * * @param type the String value to covert. * @return the corresponding Type. */ public static Status fromString(String type) { if (type == null) { return null; } type = type.toLowerCase(); if (OPEN.toString().equals(type)) { return OPEN; } else if (ACTIVE.toString().equals(type)) { return ACTIVE; } else if (CLOSED.toString().equals(type)) { return CLOSED; } else { return null; } }
/** * Converts a String into the corresponding status. Valid String values * that can be converted to a status are: "open", "active", and "closed". * * @param type the String value to covert. * @return the corresponding Type. */ public static Status fromString(String type) { if (type == null) { return null; } type = type.toLowerCase(); if (OPEN.toString().equals(type)) { return OPEN; } else if (ACTIVE.toString().equals(type)) { return ACTIVE; } else if (CLOSED.toString().equals(type)) { return CLOSED; } else { return null; } }
/** * Converts a String into the corresponding status. Valid String values * that can be converted to a status are: "open", "active", and "closed". * * @param type the String value to covert. * @return the corresponding Type. */ public static Status fromString(String type) { if (type == null) { return null; } type = type.toLowerCase(); if (OPEN.toString().equals(type)) { return OPEN; } else if (ACTIVE.toString().equals(type)) { return ACTIVE; } else if (CLOSED.toString().equals(type)) { return CLOSED; } else { return null; } }