public interface LinkGenerator
Generates links for a Grails application based on URL mapping rules and/or base context settings.
Modifiers | Name | Description |
---|---|---|
java.lang.String |
ATTRIBUTE_ABSOLUTE |
|
java.lang.String |
ATTRIBUTE_ACTION |
|
java.lang.String |
ATTRIBUTE_BASE |
|
java.lang.String |
ATTRIBUTE_CONTEXT_PATH |
|
java.lang.String |
ATTRIBUTE_CONTROLLER |
|
java.lang.String |
ATTRIBUTE_ELEMENT_ID |
|
java.lang.String |
ATTRIBUTE_EVENT |
|
java.lang.String |
ATTRIBUTE_FRAGMENT |
|
java.lang.String |
ATTRIBUTE_ID |
|
java.lang.String |
ATTRIBUTE_INCLUDE_CONTEXT |
|
java.lang.String |
ATTRIBUTE_MAPPING |
|
java.lang.String |
ATTRIBUTE_METHOD |
|
java.lang.String |
ATTRIBUTE_NAMESPACE |
|
java.lang.String |
ATTRIBUTE_PARAMS |
|
java.lang.String |
ATTRIBUTE_PLUGIN |
|
java.lang.String |
ATTRIBUTE_RELATIVE_URI |
|
java.lang.String |
ATTRIBUTE_RESOURCE |
|
java.lang.String |
ATTRIBUTE_URI |
|
java.lang.String |
ATTRIBUTE_URL |
|
java.util.Set<java.lang.String> |
LINK_ATTRIBUTES |
|
java.util.Map<java.lang.String, java.lang.String> |
REST_RESOURCE_ACTION_TO_HTTP_METHOD_MAP |
|
java.util.Map<java.lang.String, java.lang.String> |
REST_RESOURCE_HTTP_METHOD_TO_ACTION_MAP |
Type Params | Return Type | Name and description |
---|---|---|
|
public java.lang.String |
getContextPath() Obtains the context path from which this link generator is operating. |
|
public java.lang.String |
getServerBaseURL() The base URL of the server used for creating absolute links. |
|
public java.lang.String |
link(java.util.Map params) Generates a link to a controller, action or URI for the given named parameters. |
|
public java.lang.String |
link(java.util.Map params, java.lang.String encoding) Generates a link to a controller, action or URI for the given named parameters. |
|
public java.lang.String |
resource(java.util.Map params) Generates a link to a static resource for the given named parameters. |
Obtains the context path from which this link generator is operating.
The base URL of the server used for creating absolute links.
Generates a link to a controller, action or URI for the given named parameters. Possible named parameters include:
params
- The named parametersGenerates a link to a controller, action or URI for the given named parameters. Possible named parameters include:
params
- The named parametersencoding
- The character encoding to useGenerates a link to a static resource for the given named parameters. Possible named parameters include:
params
- The named parameters