Package septogeddon.pluginquery.http
Class HTTPHandler
java.lang.Object
septogeddon.pluginquery.http.HTTPHandler
Utilities for PluginQuery HTTP Handler
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic HTTPHeader
parseHeader
(String headerName, Object rawValue) Parse header raw value into HTTPHeaderstatic void
setParser
(String headerName, BiFunction<String, Object, HTTPHeader> factory) Set a parser for specific headerstatic void
setParser
(String headerName, Function<Object, HTTPHeader> factory) Set a parser for specific header
-
Constructor Details
-
HTTPHandler
public HTTPHandler()
-
-
Method Details
-
setParser
Set a parser for specific header- Parameters:
headerName
- the header name, null for global (all headers)factory
- the HTTPHeader factory
-
setParser
Set a parser for specific header- Parameters:
headerName
- the header name, null for global (all headers)factory
- the HTTPHeader factory
-
parseHeader
Parse header raw value into HTTPHeader- Parameters:
headerName
- the header namerawValue
- the header value- Returns:
- parsed HTTPHeader
-