
com.flightstats.http.Response Maven / Gradle / Ivy
package com.flightstats.http;
import com.google.common.collect.Iterables;
import com.google.common.collect.Multimap;
import lombok.Value;
import java.util.Collection;
@Value
public class Response {
int code;
String body;
Multimap headers;
public String getHeader(String location) {
Collection headers = this.headers.get(location);
return headers == null ? null : Iterables.getFirst(headers, null);
}
public Collection getHeaders(String location) {
return headers.get(location);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy