public class UserAgentQuery
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static java.util.List<UserAgent> |
getAllUserAgents(BrowserType type,
java.time.LocalDate earliest,
java.time.LocalDate latest,
java.lang.String... browserNames)
Returns all user agents that match the given criteria, or an empty list if there are no matching agents found.
|
static UserAgent |
getRandomUserAgent(BrowserType type,
java.time.LocalDate earliest,
java.time.LocalDate latest,
java.lang.String... browserNames)
Returns a random user agent that matches the given criteria, or null if there are no matching agents found
|
@Nullable public static UserAgent getRandomUserAgent(@Nullable BrowserType type, @Nullable java.time.LocalDate earliest, @Nullable java.time.LocalDate latest, @NotNull java.lang.String... browserNames)
type - The type of user agent (null to match any)earliest - The earliest date of the user agent (null for no early release limit)latest - The latest date of the user agent (null for no latest release limit)browserNames - The names of the browsers (empty to match all browsers)@NotNull public static java.util.List<UserAgent> getAllUserAgents(@Nullable BrowserType type, @Nullable java.time.LocalDate earliest, @Nullable java.time.LocalDate latest, @NotNull java.lang.String... browserNames)
type - The type of user agent (null to match any)earliest - The earliest date of the user agent (null for no early release limit)latest - The latest date of the user agent (null for no latest release limit)browserNames - The names of the browsers (empty to match all browsers)