public class MappingImpl extends Object implements HttpServletMapping
Constructor and Description |
---|
MappingImpl(String matchValue,
String pattern,
MappingMatch matchType,
String servletName) |
Modifier and Type | Method and Description |
---|---|
MappingMatch |
getMappingMatch()
Return the
MappingMatch for this instance |
String |
getMatchValue()
Return the portion of the URI path that caused this request to be matched.
|
String |
getPattern()
Return the String representation for the
url-pattern for this mapping. |
String |
getServletName()
Return the String representation for the
servlet-name for this mapping. |
public MappingImpl(String matchValue, String pattern, MappingMatch matchType, String servletName)
public String getMatchValue()
HttpServletMapping
Return the portion of the URI path that caused this request to be matched. If the HttpServletMapping.getMappingMatch()
value is
CONTEXT_ROOT
or DEFAULT
, this method must return the empty string. If the HttpServletMapping.getMappingMatch()
value is
EXACT
, this method must return the portion of the path that matched the servlet, omitting any leading slash. If the
HttpServletMapping.getMappingMatch()
value is EXTENSION
or PATH
, this method must return the value that matched
the '*'. See the class javadoc for examples.
getMatchValue
in interface HttpServletMapping
public String getPattern()
HttpServletMapping
Return the String representation for the url-pattern
for this mapping. If the HttpServletMapping.getMappingMatch()
value
is CONTEXT_ROOT
, this method must return the empty string. If the HttpServletMapping.getMappingMatch()
value is EXTENSION
, this method must return the pattern, without any leading slash. Otherwise, this method returns the
pattern exactly as specified in the descriptor or Java configuration.
getPattern
in interface HttpServletMapping
url-pattern
for this mapping.public String getServletName()
HttpServletMapping
Return the String representation for the servlet-name
for this mapping. If the Servlet providing the response
is the default servlet, the return from this method is the name of the default servlet, which is container specific.
getServletName
in interface HttpServletMapping
servlet-name
for this mapping.public MappingMatch getMappingMatch()
HttpServletMapping
Return the MappingMatch
for this instance
getMappingMatch
in interface HttpServletMapping
MappingMatch
for this instance.Copyright © 2020 JBoss by Red Hat. All rights reserved.