private static FailureType getById(String id) {
   for (FailureType type : FailureType.values()) {
     if (type.id.equals(id)) {
       return type;
     }
   }
   throw new IllegalArgumentException("Unknown failure ID: " + id);
 }
 public static String getIdsAsString() {
   FailureType[] types = FailureType.values();
   StringBuilder builder = new StringBuilder();
   for (int i = 0; i < types.length; i++) {
     builder.append(types[i].id);
     if (i < types.length - 1) {
       builder.append(", ");
     }
   }
   return builder.toString();
 }
 public FailureOperation(
     String message,
     FailureType type,
     SimulatorAddress workerAddress,
     String agentAddress,
     String hzAddress,
     String workerId,
     String testId,
     TestSuite testSuite,
     String cause) {
   this.message = message;
   this.type = type.name();
   this.workerAddress = (workerAddress == null) ? null : workerAddress.toString();
   this.agentAddress = agentAddress;
   this.hzAddress = hzAddress;
   this.workerId = workerId;
   this.testId = testId;
   this.testSuite = testSuite;
   this.cause = cause;
 }
 public FailureType getType() {
   return FailureType.valueOf(type);
 }