Code example for Objects.ToStringHelper

0
   public int getPowerState() { 
      return this.powerState; 
   } 
 
   @Override 
   public int hashCode() { 
      return Objects.hashCode(taskState, vmState, powerState); 
   } 
 
   @Override 
   public boolean equals(Object obj) { 
      if (this == obj) return true; 
      if (obj == null || getClass() != obj.getClass()) return false; 
      ServerExtendedStatus that = ServerExtendedStatus.class.cast(obj); 
      return Objects.equal(this.taskState, that.taskState) 
               && Objects.equal(this.vmState, that.vmState) 
               && Objects.equal(this.powerState, that.powerState); 
   } 
    
   protected ToStringHelper string() {