# Class ResolverImpl

java.lang.Object
org.apache.catalina.valves.rewrite.Resolver
org.apache.catalina.valves.rewrite.ResolverImpl

public class ResolverImpl extends Resolver
Implementation of the Resolver interface for the rewrite valve.

## Field Summary

Fields
Modifier and Type
Field
Description
`protected final Request`
`request`
The request being processed.

## Constructor Summary

Constructors
Constructor
Description
`ResolverImpl(Request request)`
Deprecated.
Will be removed in Tomcat 12 onwards.
`ResolverImpl(Request request, Log containerLog)`
Construct a new resolver for the given request.

## Method Summary

Modifier and Type
Method
Description
`Charset`
`getUriCharset()`
Return the URI character set.
`String`
`resolve(String key)`
The following are not implemented: SERVER_ADMIN API_VERSION IS_SUBREQ
`String`
`resolveEnv(String key)`
Resolve an environment variable key to a string value.
`String`
`resolveHttp(String key)`
Resolve an HTTP header key to a string value.
`boolean`
`resolveResource(int type, String name)`
Resolve a resource check.
`String`
`resolveSsl(String key)`
Resolve an SSL variable key to a string value.

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### request

protected final Request request
The request being processed.

## Constructor Details

### ResolverImpl

@Deprecated public ResolverImpl(Request request)
Deprecated.
Will be removed in Tomcat 12 onwards. Use `ResolverImpl(Request, Log)`
Create a resolver for the given request.

Parameters:
  `request` - The request

### ResolverImpl

public ResolverImpl(Request request, Log containerLog)
Construct a new resolver for the given request.

Parameters:
  `request` - The request being processed
  `containerLog` - The container log for debug output

## Method Details

### resolve

public String resolve(String key)
The following are not implemented:

- SERVER_ADMIN
- API_VERSION
- IS_SUBREQ

Specified by:
  `resolve` in class `Resolver`
Parameters:
  `key` - The key to resolve
Returns:
  The resolved string value

### resolveEnv

public String resolveEnv(String key)
Description copied from class: `Resolver`
Resolve an environment variable key to a string value.

Overrides:
  `resolveEnv` in class `Resolver`
Parameters:
  `key` - The key to resolve
Returns:
  The resolved string value

### resolveSsl

public String resolveSsl(String key)
Description copied from class: `Resolver`
Resolve an SSL variable key to a string value.

Specified by:
  `resolveSsl` in class `Resolver`
Parameters:
  `key` - The key to resolve
Returns:
  The resolved string value

### resolveHttp

public String resolveHttp(String key)
Description copied from class: `Resolver`
Resolve an HTTP header key to a string value.

Specified by:
  `resolveHttp` in class `Resolver`
Parameters:
  `key` - The key to resolve
Returns:
  The resolved string value

### resolveResource

public boolean resolveResource(int type, String name)
Description copied from class: `Resolver`
Resolve a resource check.

Specified by:
  `resolveResource` in class `Resolver`
Parameters:
  `type` - The type of resource check (0=directory, 1=file, 2=non-empty file)
  `name` - The resource name
Returns:
  True if the resource matches the specified type

### getUriCharset

public Charset getUriCharset()
Description copied from class: `Resolver`
Return the URI character set.

Specified by:
  `getUriCharset` in class `Resolver`
Returns:
  The URI character set