> +import com.google.inject.name.Named;
> +
> +/**
> + * Information of an error.
> + *
> + * @author Sergi Castro
> + * @author Ignasi Barrera
> + */
> +public class BaseResponse {
> +
> + public static enum Status {
> + OK, ERROR;
> +
> + public static Status fromValue(String value) {
> + Optional<Status> status = Enums.getIfPresent(Status.class,
> value.toUpperCase());
> + checkArgument(status.isPresent(), "%s is not a valid value", value);
Also print which values _are_ valid in the error?
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-labs/pull/49/files#r9165364