public class Traits extends Object
Traits.TraitHeader enum. Trait is an interesting piece of information about a monitored site, such as the name of
the web server implementation that is serving the site, the technology used in the serving application, etc.| Modifier and Type | Class and Description |
|---|---|
static class |
Traits.TraitHeader
The enumeration of HTTP response headers that are considered to bear interesting information about a monitored
site.
|
| Modifier and Type | Method and Description |
|---|---|
static Traits |
collect(org.apache.http.HttpResponse httpResponse,
long timestamp)
Collects the traits from the given
HttpResponse. |
static Traits |
empty(long timestamp)
Returns a new empty
Traits. |
boolean |
equals(Object obj) |
Map<Traits.TraitHeader,String> |
getItems() |
long |
getTimestamp() |
int |
hashCode() |
String |
toString() |
public static Traits collect(org.apache.http.HttpResponse httpResponse, long timestamp)
HttpResponse.
Header keys tha occur multiple times, are concantenated into a single comma-separated string in alphabetical order.
httpResponse - the HTTP reponse to collect traits fromtimestamp - the UNIX timestamp when the response was receivedTraitspublic Map<Traits.TraitHeader,String> getItems()
Map of trait headerspublic long getTimestamp()
Traits were collectedpublic boolean equals(Object obj)
equals in class ObjectObject.equals(java.lang.Object)public int hashCode()
hashCode in class ObjectObject.hashCode()public String toString()
toString in class ObjectObject.toString()Copyright © 2015 Red Hat. All rights reserved.