All Downloads are FREE. Search and download functionalities are using the official Maven repository.

me.xhsun.guildwars2wrapper.model.util.itemDetail.Consumable Maven / Gradle / Ivy

There is a newer version: 1.3.2
Show newest version
package me.xhsun.guildwars2wrapper.model.util.itemDetail;

import me.xhsun.guildwars2wrapper.model.util.comm.Type;

/**
 * For more info on Consumable detail API go here
* Item detail for consumable * * @author xhsun * @see ItemDetail item details * @since 2017-02-10 */ public class Consumable extends ItemDetail { public String getIcon() { return icon; } public Type getType() { return type; } public String getDescription() { return description; } public long getDuration() { return duration_ms; } public Unlock getUnlockType() { return unlock_type; } public int getColorID() { return color_id; } public int getRecipeID() { return recipe_id; } private String getName() { return name; } @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; Consumable that = (Consumable) o; return duration_ms == that.duration_ms && color_id == that.color_id && recipe_id == that.recipe_id && (icon != null ? icon.equals(that.icon) : that.icon == null) && type == that.type && (description != null ? description.equals(that.description) : that.description == null) && unlock_type == that.unlock_type && (name != null ? name.equals(that.name) : that.name == null); } @Override public int hashCode() { int result = icon != null ? icon.hashCode() : 0; result = 31 * result + (type != null ? type.hashCode() : 0); result = 31 * result + (description != null ? description.hashCode() : 0); result = 31 * result + (int) (duration_ms ^ (duration_ms >>> 32)); result = 31 * result + (unlock_type != null ? unlock_type.hashCode() : 0); result = 31 * result + color_id; result = 31 * result + recipe_id; result = 31 * result + (name != null ? name.hashCode() : 0); return result; } @Override public String toString() { return "Consumable{" + "icon='" + icon + '\'' + ", type=" + type + ", description='" + description + '\'' + ", duration_ms=" + duration_ms + ", unlock_type=" + unlock_type + ", color_id=" + color_id + ", recipe_id=" + recipe_id + ", name='" + name + '\'' + '}'; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy