Examples of StatusResponse


Examples of org.apache.james.imap.api.message.response.StatusResponse

        final StatusResponse response = factory.untaggedNo(message);
        responder.respond(response);
    }

    protected void okComplete(final ImapCommand command, final String tag, final ImapProcessor.Responder responder) {
        final StatusResponse response = factory.taggedOk(tag, command, HumanReadableText.COMPLETED);
        responder.respond(response);
    }

Examples of org.apache.james.imap.api.message.response.StatusResponse

        final StatusResponse response = factory.taggedOk(tag, command, HumanReadableText.COMPLETED);
        responder.respond(response);
    }

    protected void okComplete(final ImapCommand command, final String tag, final ResponseCode code, final ImapProcessor.Responder responder) {
        final StatusResponse response = factory.taggedOk(tag, command, HumanReadableText.COMPLETED, code);
        responder.respond(response);
    }

Examples of org.apache.james.imap.api.message.response.StatusResponse

        final StatusResponse response = factory.taggedOk(tag, command, HumanReadableText.COMPLETED, code);
        responder.respond(response);
    }

    protected void no(final ImapCommand command, final String tag, final ImapProcessor.Responder responder, final HumanReadableText displayTextKey) {
        final StatusResponse response = factory.taggedNo(tag, command, displayTextKey);
        responder.respond(response);
    }

Examples of org.apache.james.imap.api.message.response.StatusResponse

        final StatusResponse response = factory.taggedNo(tag, command, displayTextKey);
        responder.respond(response);
    }

    protected void no(final ImapCommand command, final String tag, final ImapProcessor.Responder responder, final HumanReadableText displayTextKey, final StatusResponse.ResponseCode responseCode) {
        final StatusResponse response = factory.taggedNo(tag, command, displayTextKey, responseCode);
        responder.respond(response);
    }

Examples of org.apache.james.imap.api.message.response.StatusResponse

        final StatusResponse response = factory.taggedNo(tag, command, displayTextKey, responseCode);
        responder.respond(response);
    }

    protected void taggedBad(final ImapCommand command, final String tag, final ImapProcessor.Responder responder, final HumanReadableText e) {
        StatusResponse response = factory.taggedBad(tag, command, e);

        responder.respond(response);
    }

Examples of org.apache.james.imap.api.message.response.StatusResponse

        responder.respond(response);
    }

    protected void bye(final ImapProcessor.Responder responder) {
        final StatusResponse response = factory.bye(HumanReadableText.BYE);
        responder.respond(response);
    }

Examples of org.apache.james.imap.api.message.response.StatusResponse

        final StatusResponse response = factory.bye(HumanReadableText.BYE);
        responder.respond(response);
    }

    protected void bye(final ImapProcessor.Responder responder, final HumanReadableText key) {
        final StatusResponse response = factory.bye(key);
        responder.respond(response);
    }

Examples of org.apache.james.imap.api.message.response.StatusResponse

                            }
                        }
                    }
                    session.popLineHandler();
                    if (!DONE.equals(line.toUpperCase(Locale.US))) {
                        StatusResponse response = getStatusResponseFactory().taggedBad(tag, command, HumanReadableText.INVALID_COMMAND);
                        responder.respond(response);
                    } else {
                        okComplete(command, tag, responder);

                    }
                    idleActive.set(false);
                }
            });

            // Check if we should send heartbeats
            if (heartbeatInterval > 0) {
                heartbeatExecutor.schedule(new Runnable() {

                    public void run() {
                        // check if we need to cancel the Runnable
                        // See IMAP-275
                        if (session.getState() != ImapSessionState.LOGOUT && idleActive.get()) {
                            // Send a heartbeat to the client to make sure we
                            // reset the idle timeout. This is kind of the same
                            // workaround as dovecot use.
                            //
                            // This is mostly needed because of the broken
                            // outlook client, but can't harm for other clients
                            // too.
                            // See IMAP-272
                            StatusResponse response = getStatusResponseFactory().untaggedOk(HumanReadableText.HEARTBEAT);
                            responder.respond(response);
                           
                            // schedule the heartbeat again for the next interval
                            heartbeatExecutor.schedule(this, heartbeatInterval, heartbeatIntervalUnit);
                        }

Examples of org.apache.james.imap.api.message.response.StatusResponse

    /**
     * @see org.hamcrest.Matcher#matches(java.lang.Object)
     */
    public boolean matches(Object o) {
        if (o instanceof StatusResponse) {
            StatusResponse sr = (StatusResponse) o;
            return this.serverResponseType.equals(sr.getServerResponseType());
        }
        return false;
    }

Examples of org.fao.geonet.domain.responses.StatusResponse

      while ((read = is.read(bytes)) != -1) {
        stream.write(bytes, 0, read);
      }
    } catch (Exception e) {
      return new StatusResponse(e.getMessage());
    } finally {
      if (stream != null) {
        stream.close();
      }
    }

    return new StatusResponse("Logo added.");
  }
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.