• 如果您觉得本站非常有看点,那么赶紧使用Ctrl+D 收藏吧

Java MessageHelper类的典型用法和代码示例

java 1次浏览

本文整理汇总了Java中nl.strohalm.cyclos.utils.MessageHelper的典型用法代码示例。如果您正苦于以下问题:Java MessageHelper类的具体用法?Java MessageHelper怎么用?Java MessageHelper使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。

MessageHelper类属于nl.strohalm.cyclos.utils包,在下文中一共展示了MessageHelper类的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: doEndTag

点赞 2

import nl.strohalm.cyclos.utils.MessageHelper; //导入依赖的package包/类
@Override
public int doEndTag() throws JspException {
    final JspWriter out = pageContext.getOut();

    try {
        if (!(items instanceof Page<?>)) {
            out.println("<!-- pagination tag: items is not a page -->");
            return EVAL_PAGE;
        }
        out.println("<span style='vertical-align:middle'>");
        final Page<?> page = (Page<?>) items;
        final HttpServletRequest request = (HttpServletRequest) pageContext.getRequest();

        final int currentPage = page.getCurrentPage() + 1;
        final int pageCount = page.getPageCount();

        if (!page.isEmpty()) {
            final MessageHelper messageHelper = SpringHelper.bean(pageContext.getServletContext(), MessageHelper.class);
            if (pageCount == 1) {
                out.println(messageHelper.message("global.pagination.single.page", page.getTotalCount()));
            } else {
                out.println(messageHelper.message("global.pagination.various.pages", page.getTotalCount()));
                if (currentPage > 1) {
                    out.println(pageLink(currentPage - 1, "<img src=\"" + request.getContextPath() + "/pages/images/previous.gif\" style=\"valign:bottom\" border=\"0\" title=\"" + messageHelper.message("global.pagination.tooltip.previous") + "\">"));
                }
                out.println(StringUtils.join(resolvePages(currentPage, pageCount), ' '));
                if (currentPage < pageCount) {
                    out.println(pageLink(currentPage + 1, "<img src=\"" + request.getContextPath() + "/pages/images/next.gif\" style=\"valign:bottom\" border=\"0\" title=\"" + messageHelper.message("global.pagination.tooltip.next") + "\">"));
                }
            }
        }
        out.println("</span>");
        return EVAL_PAGE;
    } catch (final IOException e) {
        throw new JspException(e);
    } finally {
        release();
    }

}
 

开发者ID:mateli,
项目名称:OpenCyclos,
代码行数:41,
代码来源:PaginationTag.java

示例2: ShouldValidateTPParameter

点赞 2

import nl.strohalm.cyclos.utils.MessageHelper; //导入依赖的package包/类
public ShouldValidateTPParameter(final ActionMapping mapping, final ActionForm actionForm, final HttpServletRequest request, final HttpServletResponse response, final DoPaymentDTO payment, final ChannelService channelService, final ElementService elementService, final TransferTypeService transferTypeService, final MessageHelper messageHelper) {
    this.mapping = mapping;
    this.actionForm = actionForm;
    this.request = request;
    this.response = response;
    this.payment = payment;
    this.channelService = channelService;
    this.elementService = elementService;
    this.transferTypeService = transferTypeService;
    this.messageHelper = messageHelper;
}
 

开发者ID:mateli,
项目名称:OpenCyclos,
代码行数:12,
代码来源:ConfirmWebShopPaymentAction.java

示例3: AbstractActionContext

点赞 2

import nl.strohalm.cyclos.utils.MessageHelper; //导入依赖的package包/类
public AbstractActionContext(final ActionMapping actionMapping, final ActionForm actionForm, final HttpServletRequest request, final HttpServletResponse response, final MessageHelper messageHelper, final User user) {
    if (actionMapping == null || request == null || response == null || messageHelper == null || user == null) {
        throw new NullPointerException();
    }

    this.actionMapping = actionMapping;
    form = actionForm;
    this.request = request;
    this.response = response;
    this.messageHelper = messageHelper;
    this.user = user;
}
 

开发者ID:mateli,
项目名称:OpenCyclos,
代码行数:13,
代码来源:AbstractActionContext.java

示例4: setMessageHelper

点赞 2

import nl.strohalm.cyclos.utils.MessageHelper; //导入依赖的package包/类
@Inject
public void setMessageHelper(final MessageHelper messageHelper) {
    this.messageHelper = messageHelper;
}
 

开发者ID:mateli,
项目名称:OpenCyclos,
代码行数:5,
代码来源:RequestProcessingFilter.java

示例5: setPageContext

点赞 2

import nl.strohalm.cyclos.utils.MessageHelper; //导入依赖的package包/类
@Override
public void setPageContext(final PageContext pageContext) {
    super.setPageContext(pageContext);
    permissionService = SpringHelper.bean(pageContext.getServletContext(), PermissionService.class);
    messageHelper = SpringHelper.bean(pageContext.getServletContext(), MessageHelper.class);
}
 

开发者ID:mateli,
项目名称:OpenCyclos,
代码行数:7,
代码来源:MenuTag.java

示例6: setPageContext

点赞 2

import nl.strohalm.cyclos.utils.MessageHelper; //导入依赖的package包/类
@Override
public void setPageContext(final PageContext pageContext) {
    super.setPageContext(pageContext);
    messageHelper = SpringHelper.bean(pageContext.getServletContext(), MessageHelper.class);
    settingsService = SpringHelper.bean(pageContext.getServletContext(), SettingsService.class);
}
 

开发者ID:mateli,
项目名称:OpenCyclos,
代码行数:7,
代码来源:CustomFieldTag.java

示例7: setPageContext

点赞 2

import nl.strohalm.cyclos.utils.MessageHelper; //导入依赖的package包/类
@Override
public void setPageContext(final PageContext pageContext) {
    super.setPageContext(pageContext);
    messageHelper = SpringHelper.bean(pageContext.getServletContext(), MessageHelper.class);
}
 

开发者ID:mateli,
项目名称:OpenCyclos,
代码行数:6,
代码来源:MultiDropDownTag.java

示例8: MobileActionContext

点赞 2

import nl.strohalm.cyclos.utils.MessageHelper; //导入依赖的package包/类
public MobileActionContext(final ActionMapping actionMapping, final ActionForm actionForm, final HttpServletRequest request, final HttpServletResponse response, final MessageHelper messageHelper, final MemberUser user) {
    super(actionMapping, actionForm, request, response, messageHelper, user);
}
 

开发者ID:mateli,
项目名称:OpenCyclos,
代码行数:4,
代码来源:MobileActionContext.java

示例9: setMessageHelper

点赞 2

import nl.strohalm.cyclos.utils.MessageHelper; //导入依赖的package包/类
@Inject
public final void setMessageHelper(final MessageHelper messageHelper) {
    this.messageHelper = messageHelper;
}
 

开发者ID:mateli,
项目名称:OpenCyclos,
代码行数:5,
代码来源:MobileBaseAction.java

示例10: ActionContext

点赞 2

import nl.strohalm.cyclos.utils.MessageHelper; //导入依赖的package包/类
public ActionContext(final ActionMapping actionMapping, final ActionForm actionForm, final HttpServletRequest request, final HttpServletResponse response, final User user, final MessageHelper messageHelper) {
    super(actionMapping, actionForm, request, response, messageHelper, user);
    permissionService = SpringHelper.bean(getServletContext(), PermissionService.class);
}
 

开发者ID:mateli,
项目名称:OpenCyclos,
代码行数:5,
代码来源:ActionContext.java


版权声明:本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系管理员进行删除。
喜欢 (0)