- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
public enum AddressType implements UrlValue {
/**
* {@code STREET_ADDRESS} indicates a precise street address.
*/
STREET_ADDRESS("street_address"),
/**
* {@code ROUTE} indicates a named route (such as "US 101").
*/
ROUTE("route"),
...
/**
* Indicates an unknown address type returned by the server. The Java Client for Google Maps
* Services should be updated to support the new value.
*/
UNKNOWN("unknown");
private final String addressType;
AddressType(final String addressType) {
this.addressType = addressType;
}
@Override
public String toString() {
return addressType;
}
guest 23.10.2015 10:56 # 0
В целом конечно спорный момент. Менять toString в ENUM это вообще как бы неочевидное поведение.