META-INF.ocpsoft-pretty-faces-3.3.3.xsd Maven / Gradle / Ivy
The newest version!
PrettyFaces Configuration XSD Schema
The PrettyFaces configuration file root element.
A PrettyFaces URL Mapping.
Specify the pattern for which this URL will be
matched.
Any EL expressions #{someBean.paramName} found within
the pattern will be processed as value injections.
The URL will be parsed and the value found at the
location of the EL expression will be injected into
the location specified in that EL expression. Note:
EL expressions will not match over the ‘/’ character.
Additionally, each expression may specify a name, or
only a name: #{myParam:someBean.paramName},
#{myParam} - this provides parameter access to
non-JSF applications by adding the extracted value to
the HttpServletRequest property Map.
In order to take advantage of outbound-URL rewriting,
the parameter name specified must match the parameter
name used internally in the application.
The pattern for which this url-mapping will match
and filter incoming requests, and the pattern with
which to generate outbound links.
Specify any number of pattern validators for
this mapping. Validators may be attached to
individual parameters in each dynamic URL.
A pattern validator for this mapping.
Validators may be attached to individual
parameters in each dynamic URL.
The value index of the pattern on
which this validator will operate.
Eg:
The IDs of the JSF Validator objects
to attach and process before bean
value injection.
The validation method used to check
the value before bean value injection.
The pretty:mappingId or #{bean.method}
to evaluate, should validation fail.
Specify the pattern for which this URL will be
matched.
Any EL expressions #{someBean.paramName} found
within the pattern will be processed as value
injections. The URL will be parsed and the
value found at the location of the EL
expression will be injected into the location
specified in that EL expression. Note: EL
expressions will not match over the ‘/’
character.
Additionally, each expression may specify a
name, or only a name:
#{myParam:someBean.paramName}, #{myParam} -
this provides parameter access to non-JSF
applications by adding the extracted value to
the HttpServletRequest property Map.
In order to take advantage of outbound-URL
rewriting, the parameter name specified must
match the parameter name used internally in the
application.
Defines a managed query parameter of the form
http://site.com/url?key=somevalue, where if the
parameter exists, the value will be injected into the
specified managed bean. This also handles JSF
commandLink and AJAX <f:param> values.
Defines a managed query parameter of the form
http://site.com/url?key=somevalue, where if the
parameter exists, the value will be injected into
the specified managed bean. This also handles JSF
commandLink and AJAX <f:param>
values.
The managed parameter name. This value
corresponds to the named key
HttpServletRequest.getRequestParameter(...)
when extracting HTTP Request Parameters.
Optional boolean (default true), if set
to false this query parameter will not be
injected on form postbacks.
The pretty:mappingId or #{bean.method} to
evaluate, should validation fail.
The IDs of the JSF Validator objects to
attach and process before bean value
injection.
The validation method used to check the
value before bean value injection.
Specify the URI displayed by this mapping, by either
calling an el Method (must return an object for which
the toString() method will return the view Id) or by
returning a literal String value. The ViewId may be
any resource located within the current Servlet
Context: E.g. PrettyFaces can also forward to a
non-Faces servlet.
Specify an action method to be called after URL
parameters have been parsed and assigned into beans.
an action method to be called after URL parameters
have been parsed and assigned into beans.
Whether child mappings inherit
this action or not.
The unique identifier by which this url-mapping will be
referenced in the application (e.g.: link components,
navigation outcomes, etc...)
Enable or disable outbound URL rewriting for this
mapping (default: 'true' / enabled.) If enabled, any
links matching the viewId specified will be rewritten
(if possible) using parameters mapping to named path
parameters specified in the pattern.
Eg, given the following mapping: <url-mapping
id="singleItem" outbound="true"> <pattern
value="/store/#{cat:catBean.category}/#{pid:productBean.productId}"
/>
<viewId>/faces/store/viewProduct.jsf</viewId>
</url-mapping>
The following outbound rewrite will occur:
/faces/product/viewProduct.jsf?cat=foods&pid=1234 =>
/store/foods/1234
Optional boolean (default true), if set to false path
parameters will not be injected on form postbacks.
A Rewrite Engine rule.
Specify an entire URL to replace the current URL.
This will
overwrite the context-path and
query-parameters. This attribute must
be combined
with redirect="301" (default) or redirect="302", but
"302" is recommended to prevent adverse SEO effects.
Example:
Note: You must provide a fully qualified URL,
including scheme name
- such as 'http://", 'ftp://',
'mailto:' ... and so on.
Note: Regular expression backreferences to the match="" attribute are supported in the URL, so $ and / may change the value of the result.
Enable or disable inbound URL rewriting for this
rule
(default is 'true' / enabled.)
Inbound URL rewriting intercepts
incoming
HttpServletRequests. Setting this value to false
means that
this rule will be ignored on incoming
requests.
Describes, via a regular expression pattern,
when
this 'rewrite' rule should trigger on an
inbound or outbound URL. If
empty, this rule
will match all URLs.
Example: match="^/foo/.*$" -
will trigger only
on urls with of the form: /context-path/foo/bar
For more information on regular expressions,
read:
http://ocpsoft.com/opensource/guide-to-regular-expressions-in-java-part-1/
Enable or disable outbound URL rewriting for
this
rule (default is 'true' / enabled.)
Outbound URL rewriting
intercepts calls to
public String HttpServletResponse.encodeURL(...)
and will rewrite any requested URLs according to
the rules
specified.
For examples, html link and form component URLs
generated
by a framework like JavaServer Faces
are encoded using this method,
and will be
rewritten if an appropriate rewrite rule, with
outbound="true", is triggered.
Specify a custom processor class to perform
custom URL rewriting.
This class must implement
the interface:
'com.ocpsoft.pretty.rewrite.Processor'
Example:
import com.ocpsoft.pretty.rewrite.Processor; import
com.ocpsoft.pretty.config.rewrite.RewriteRule;
public class
CustomClassProcessor implements
Processor { public static final
String RESULT =
"I PROCESSED!";
public String process(final RewriteRule
rewrite, final
String url) { return RESULT; } }
Specifies which type of redirect should be
issued
when this rule triggers.
'301' or 'Permanent' (default): will issue
a
redirect notifying of a permanent address
change; search engines
index through 301
redirects to maintain existing search rank, even
when a page is moved. The new address is
considered to be the new
location of the
resource.
'302' or 'Temporary': will issue a
temporary
redirect; search engines do not index through
302
redirects. The new URL is considered to be
an alternate/duplicate
resource - simply a
different page the server wants the browser to
see.
'Chain': will redirect internally after all
other chaining rules
have triggered.
301 and 302 redirects are issued immediately
upon a
rule triggering. Chaining is issued via
an internal Servlet forward
once all chaining
rules have executed on the request.
The regular expression substitution value of the
"match" attribute.
This effectively enables a
"search and replace" functionality.
Example:
Will match the following URL:
'/context-path/foo/subst', and will
substitute
the following URL: '/context-path/bar/subst' in
its place.
For more information on regular expressions,
read:
http://ocpsoft.com/opensource/guide-to-regular-expressions-in-java-part-1/
Change the entire URL (excluding context-path and
query-parameters) to 'UPPERCASE' or 'lowercase'.
Examples:
Ignore
(default): ../context-path/Ignore/Example -->
../context-path/Ignore/Example
Uppercase:
../context-path/Uppercase/Example -->
../context-path/UPPERCASE/EXAMPLE
Lowercase:
../context-path/Lowercase/Example -->
../context-path/lowercase/example
Control whether trailing slashes on a URL should
be appended if missing, or removed if present.
Examples:
Ignore
(default): ../context-path/ignore/slash/
-->
../context-path/remove/slash/
../context-path/ignore/slash -->
../context-path/remove/slash
Append: ../context-path/append/slash
-->
../context-path/append/slash/
Remove:
../context-path/remove/slash/ -->
../context-path/remove/slash/
© 2015 - 2024 Weber Informatics LLC | Privacy Policy