Package org.openqa.selenium.remote.codec
Class AbstractHttpCommandCodec
java.lang.Object
org.openqa.selenium.remote.codec.AbstractHttpCommandCodec
- All Implemented Interfaces:
CommandCodec<HttpRequest>
- Direct Known Subclasses:
W3CHttpCommandCodec
A command codec that adheres to the W3C's WebDriver wire protocol.
- See Also:
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAllow commands to have aliases.amendParameters(String name, Map<String, ?> parameters) decode(HttpRequest encodedCommand) Decodes a command.protected voiddefineCommand(String name, AbstractHttpCommandCodec.CommandSpec spec) voiddefineCommand(String name, HttpMethod method, String pathPattern) Defines a new command mapping.protected static AbstractHttpCommandCodec.CommandSpecEncodes a command.protected static AbstractHttpCommandCodec.CommandSpecbooleanisSupported(String commandName) protected static AbstractHttpCommandCodec.CommandSpec
-
Constructor Details
-
AbstractHttpCommandCodec
public AbstractHttpCommandCodec()
-
-
Method Details
-
delete
-
get
-
post
-
isSupported
- Specified by:
isSupportedin interfaceCommandCodec<HttpRequest>- Returns:
- Whether this
CommandCodecsupports the given command name.
-
encode
Description copied from interface:CommandCodecEncodes a command.- Specified by:
encodein interfaceCommandCodec<HttpRequest>- Parameters:
command- the command to encode.- Returns:
- the encoded command.
-
amendParameters
-
decode
Description copied from interface:CommandCodecDecodes a command.- Specified by:
decodein interfaceCommandCodec<HttpRequest>- Parameters:
encodedCommand- the command to decode.- Returns:
- the decoded command.
-
defineCommand
Defines a new command mapping.- Specified by:
defineCommandin interfaceCommandCodec<HttpRequest>- Parameters:
name- The command name.method- The HTTP method to use for the command.pathPattern- The URI path pattern for the command. When encoding a command, each path segment prefixed with a ":" will be replaced with the corresponding parameter from the encoded command.
-
alias
Description copied from interface:CommandCodecAllow commands to have aliases.- Specified by:
aliasin interfaceCommandCodec<HttpRequest>- Parameters:
commandName- The command being added.isAnAliasFor- The command name that this is an alias for.
-
defineCommand
-