Use EnumAddressee instead of String to identify mail carriers

This commit is contained in:
mezz committed 2014-09-12 21:26:33 -07:00
1 parent d6c3c8093c
commit dff81eb85c
6 files changed
+20 -29

No files matched your search

@@ -26,24 +26,22 @@ import forestry.plugins.PluginMail;
public class PostalCarrier implements IPostalCarrier {
private final String uid;
private final String iconID;
private final EnumAddressee type;
public PostalCarrier(EnumAddressee type) {
uid = type.toString().toLowerCase(Locale.ENGLISH);
iconID = "mail/carrier." + uid;
iconID = "mail/carrier." + type;
this.type = type;
}
@Override
public String getUID() {
return uid;
public EnumAddressee getType() {
return type;
}
@Override
public String getName() {
return StringUtil.localize("gui.addressee." + uid);
return StringUtil.localize("gui.addressee." + type);
}
@Override