info.magnolia.voting.voters
Class RequestParametersVoter
java.lang.Object
info.magnolia.voting.voters.BaseVoterImpl<T>
info.magnolia.voting.voters.AbstractBoolVoter<javax.servlet.http.HttpServletRequest>
info.magnolia.voting.voters.RequestParametersVoter
- All Implemented Interfaces:
- Voter<javax.servlet.http.HttpServletRequest>
public class RequestParametersVoter
- extends AbstractBoolVoter<javax.servlet.http.HttpServletRequest>
Voter that checks for a specific GET parameter and an optional value. If no value is specified the voter just checks
for the existence of the parameter no matter what value is set.
Parameters (as Magnolia's configuration nodes):
- parameterName: the name of the parameter, e.g.
mgnlPreview
(required)
- parameterValue: the expected value (optional)
RequestParametersVoter
public RequestParametersVoter()
boolVote
protected boolean boolVote(javax.servlet.http.HttpServletRequest request)
- Specified by:
boolVote
in class AbstractBoolVoter<javax.servlet.http.HttpServletRequest>
getParameterName
public String getParameterName()
setParameterName
public void setParameterName(String parameterName)
getParameterValue
public String getParameterValue()
setParameterValue
public void setParameterValue(String parameterValue)
toString
public String toString()
- Overrides:
toString
in class AbstractBoolVoter<javax.servlet.http.HttpServletRequest>
Copyright © 2003-2014 Magnolia International Ltd.. All Rights Reserved.