List of usage examples for org.apache.wicket.request IRequestMapper getCompatibilityScore
int getCompatibilityScore(Request request);
From source file:de.alpharogroup.wicket.base.request.mapper.HighScoreRequestMapper.java
License:Apache License
/** * {@inheritDoc}/*from ww w . jav a 2s . c o m*/ */ @Override public int getCompatibilityScore(final Request request) { int score = Integer.MIN_VALUE; for (final IRequestMapper requestMapper : this.requestMappers) { score = Math.max(score, requestMapper.getCompatibilityScore(request)); } return score; }
From source file:de.alpharogroup.wicket.base.request.mapper.HighScoreRequestMapper.java
License:Apache License
/** * Initialize request mappers./* w w w .j a v a 2s .c om*/ * * @param request * the request * @return the collection */ private Collection<RequestMapperBean> initializeRequestMappers(final Request request) { final Set<RequestMapperBean> mapperBeans = new TreeSet<>(getComparator()); for (final IRequestMapper requestMapper : this.requestMappers) { mapperBeans.add(new RequestMapperBean(requestMapper, requestMapper.getCompatibilityScore(request))); } return mapperBeans; }