Examples of addMsg()


Examples of com.tll.common.data.Status.addMsg()

          ListingCache.clearHandler(sessionId, listingId);
          if(!request.getRetainStateOnClear()) {
            ListingCache.clearState(sessionId, listingId);
          }
          listingStatus = ListingStatus.NOT_CACHED;
          status.addMsg("Cleared listing data for " + listingId, MsgLevel.INFO, MsgAttr.STATUS.flag);
        }
        else if(listingOp == ListingOp.CLEAR_ALL) {
          // clear all
          if(log.isDebugEnabled()) log.debug("Clearing ALL listings...");
          ListingCache.clearHandler(sessionId, listingId);
View Full Code Here

Examples of com.tll.common.data.Status.addMsg()

          ListingCache.clearHandler(sessionId, listingId);
          if(!request.getRetainStateOnClear()) {
            ListingCache.clearAll(request.getRetainStateOnClear());
          }
          listingStatus = ListingStatus.NOT_CACHED;
          status.addMsg("Cleared ALL listing data", MsgLevel.INFO, MsgAttr.STATUS.flag);
        }
        else if(handler != null && !status.hasErrors()) {
          // cache listing handler
          if(log.isDebugEnabled()) log.debug("[Re-]Caching listing '" + listingId + "'...");
          ListingCache.storeHandler(sessionId, listingId, handler);
View Full Code Here

Examples of com.tll.common.data.Status.addMsg()

    final Status status = new Status();
    final Payload p = new Payload(status);
    final Map<String, Object> data = new HashMap<String, Object>();

    if(StringUtil.isEmpty(emailAddress)) {
      status.addMsg("An email address must be specified.", MsgLevel.ERROR, MsgAttr.STATUS.flag);
    }
    else {
      final ForgotPasswordServiceContext context = getContext();
      try {
        final IForgotPasswordHandler handler = context.getForgotPasswordHandler();
View Full Code Here

Examples of com.tll.common.data.Status.addMsg()

        data.put("password", rp);
        final MailManager mailManager = context.getMailManager();
        final MailRouting mr = mailManager.buildAppSenderMailRouting(user.getEmailAddress());
        final IMailContext mailContext = mailManager.buildTextTemplateContext(mr, EMAIL_TEMPLATE_NAME, data);
        mailManager.sendEmail(mailContext);
        status.addMsg("Password reminder email was sent.", MsgLevel.INFO, MsgAttr.STATUS.flag);
      }
      catch(final EntityNotFoundException nfe) {
        exceptionToStatus(nfe, status);
        context.getExceptionHandler().handleException(nfe);
      }
View Full Code Here

Examples of com.tll.common.data.Status.addMsg()

    final com.tll.server.AdminContext sac =
      (com.tll.server.AdminContext) rc.getSession().getAttribute(
          com.tll.server.AdminContext.KEY);
    if(sac == null) {
      // presume not logged in yet
      status.addMsg("Admin Context not found.", MsgLevel.INFO, MsgAttr.STATUS.flag);
      return new AdminContextPayload(status, ac.isDebug(), ac.getEnvironment(), null, null);
    }

    final Marshaler entityMarshaller = mec.getMarshaler();
    assert entityMarshaller != null : "No marshaler present";
View Full Code Here

Examples of com.tll.common.data.Status.addMsg()

    // NOTE: we want a distinct copy of the account here so we separately
    // marshall the account as opposed to grabbing the nested account from the
    // just marshaled user
    final Model account = entityMarshaller.marshalEntity(sac.getUser().getAccount(), MarshalOptions.NON_RELATIONAL);

    status.addMsg("Admin Context retrieved.", MsgLevel.INFO, MsgAttr.STATUS.flag);
    return new AdminContextPayload(status, ac.isDebug(), ac.getEnvironment(), user, account);
  }

  @Override
  public AdminContextPayload changeCurrentAccount(ModelKey accountRef) {
View Full Code Here

Examples of com.tll.common.data.Status.addMsg()

    assert delegate != null && em != null && sac != null;

    final ModelPayload ep = delegate.load(new LoadRequest<PrimaryKeySearch>(new PrimaryKeySearch(accountRef)));
    final Status status = ep.getStatus();

    status.addMsg("Admin Context current account retrieved for " + accountRef.descriptor(), MsgLevel.INFO,
        MsgAttr.STATUS.flag);
    return new AdminContextPayload(status, ep.getModel());
  }
}
View Full Code Here

Examples of com.tll.common.data.Status.addMsg()

    Class<? extends Account> accountClass;
    try {
      accountClass = (Class<? extends Account>) pc.getEntityTypeResolver().resolveEntityClass(request.getEntityType());
    }
    catch(final ClassCastException e) {
      s.addMsg("Invalid account type.", MsgLevel.ERROR, MsgAttr.STATUS.flag);
      return p;
    }
    Model maccount = request.getAccount();
    if(maccount == null) {
      s.addMsg("No account specified.", MsgLevel.ERROR, MsgAttr.STATUS.flag);
View Full Code Here

Examples of com.tll.common.data.Status.addMsg()

      s.addMsg("Invalid account type.", MsgLevel.ERROR, MsgAttr.STATUS.flag);
      return p;
    }
    Model maccount = request.getAccount();
    if(maccount == null) {
      s.addMsg("No account specified.", MsgLevel.ERROR, MsgAttr.STATUS.flag);
      return p;
    }
    final Collection<Model> maios = request.getAccountInterfaces();
    if(maios == null) {
      s.addMsg("No account interface options specified.", MsgLevel.ERROR, MsgAttr.STATUS.flag);
View Full Code Here

Examples of com.tll.common.data.Status.addMsg()

      s.addMsg("No account specified.", MsgLevel.ERROR, MsgAttr.STATUS.flag);
      return p;
    }
    final Collection<Model> maios = request.getAccountInterfaces();
    if(maios == null) {
      s.addMsg("No account interface options specified.", MsgLevel.ERROR, MsgAttr.STATUS.flag);
      return p;
    }
    final Collection<Model> musers = request.getUsers();

    try {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.