Tabnine Logo
Status.isConnectorError
Code IndexAdd Tabnine to your IDE (free)

How to use
isConnectorError
method
in
org.restlet.data.Status

Best Java code snippets using org.restlet.data.Status.isConnectorError (Showing top 15 results out of 315)

origin: org.restlet.osgi/org.restlet

/**
 * Indicates if the status is a connector error status, meaning "The
 * connector failed to send or receive an apparently valid message".
 * 
 * @return True if the status is a connector error status.
 */
public boolean isConnectorError() {
  return isConnectorError(getCode());
}
origin: org.restlet/org.restlet

/**
 * Indicates if the status is a connector error status, meaning "The
 * connector failed to send or receive an apparently valid message".
 * 
 * @return True if the status is a connector error status.
 */
public boolean isConnectorError() {
  return isConnectorError(getCode());
}
origin: DeviceConnect/DeviceConnect-Android

/**
 * Indicates if the status is a connector error status, meaning "The
 * connector failed to send or receive an apparently valid message".
 * 
 * @return True if the status is a connector error status.
 */
public boolean isConnectorError() {
  return isConnectorError(getCode());
}
origin: org.restlet/org.restlet

/**
 * Indicates if the status is an error (client or server) status.
 * 
 * @param code
 *            The code of the status.
 * @return True if the status is an error (client or server) status.
 */
public static boolean isError(int code) {
  return isClientError(code) || isServerError(code)
      || isConnectorError(code);
}
origin: DeviceConnect/DeviceConnect-Android

/**
 * Indicates if the status is an error (client or server) status.
 * 
 * @param code
 *            The code of the status.
 * @return True if the status is an error (client or server) status.
 */
public static boolean isError(int code) {
  return isClientError(code) || isServerError(code)
      || isConnectorError(code);
}
origin: org.restlet.osgi/org.restlet

/**
 * Indicates if the status is an error (client or server) status.
 * 
 * @param code
 *            The code of the status.
 * @return True if the status is an error (client or server) status.
 */
public static boolean isError(int code) {
  return isClientError(code) || isServerError(code)
      || isConnectorError(code) || isGlobalError(code);
}
origin: org.restlet.osgi/org.restlet

/**
 * Indicates if an error is recoverable, meaning that simply retrying after
 * a delay could result in a success. Tests {@link #isConnectorError()} and
 * if the status is {@link #CLIENT_ERROR_REQUEST_TIMEOUT} or
 * {@link #SERVER_ERROR_GATEWAY_TIMEOUT} or
 * {@link #SERVER_ERROR_SERVICE_UNAVAILABLE}.
 * 
 * @return True if the error is recoverable.
 */
public boolean isRecoverableError() {
  return isConnectorError()
      || equals(Status.CLIENT_ERROR_REQUEST_TIMEOUT)
      || equals(Status.SERVER_ERROR_GATEWAY_TIMEOUT)
      || equals(Status.SERVER_ERROR_SERVICE_UNAVAILABLE);
}
origin: DeviceConnect/DeviceConnect-Android

/**
 * Indicates if an error is recoverable, meaning that simply retrying after
 * a delay could result in a success. Tests {@link #isConnectorError()} and
 * if the status is {@link #CLIENT_ERROR_REQUEST_TIMEOUT} or
 * {@link #SERVER_ERROR_GATEWAY_TIMEOUT} or
 * {@link #SERVER_ERROR_SERVICE_UNAVAILABLE}.
 * 
 * @return True if the error is recoverable.
 */
public boolean isRecoverableError() {
  return isConnectorError()
      || equals(Status.CLIENT_ERROR_REQUEST_TIMEOUT)
      || equals(Status.SERVER_ERROR_GATEWAY_TIMEOUT)
      || equals(Status.SERVER_ERROR_SERVICE_UNAVAILABLE);
}
origin: org.restlet.osgi/org.restlet

if (status.isServerError()) {
  level = Level.WARNING;
} else if (status.isConnectorError()) {
  level = Level.INFO;
} else if (status.isClientError()) {
origin: org.restlet.jee/org.restlet.ext.platform

if (e.getStatus().isConnectorError()) {
  throw new RuntimeException("Restlet Cloud communication error. Please check the root cause below.", e);
} else if (e.getStatus().isClientError()) {
origin: org.restlet.osgi/org.restlet.ext.platform

if (e.getStatus().isConnectorError()) {
  throw new RuntimeException("Restlet Cloud communication error. Please check the root cause below.", e);
} else if (e.getStatus().isClientError()) {
origin: org.restlet.gae/org.restlet.ext.platform

if (e.getStatus().isConnectorError()) {
  throw new RuntimeException("Restlet Cloud communication error. Please check the root cause below.", e);
} else if (e.getStatus().isClientError()) {
origin: org.restlet.jee/org.restlet.ext.apispark

if (e.getStatus().isConnectorError()) {
  throw new RuntimeException("APISpark communication error. Please check the root cause below.", e);
} else if (e.getStatus().isClientError()) {
origin: org.restlet.osgi/org.restlet

/**
 * Invoked when an error or an exception is caught during initialization,
 * handling or releasing. By default, updates the responses's status with
 * the result of {@link org.restlet.service.StatusService#toStatus(Throwable, Resource)}.
 * 
 * @param throwable
 *            The caught error or exception.
 */
protected void doCatch(Throwable throwable) {
  Level level = Level.INFO;
  Status status = getStatusService().toStatus(throwable, this);
  if (status.isServerError()) {
    level = Level.SEVERE;
  } else if (status.isConnectorError()) {
    level = Level.INFO;
  } else if (status.isClientError()) {
    level = Level.FINE;
  }
  getLogger().log(level, "Exception or error caught in server resource",
      throwable);
  if (getResponse() != null) {
    getResponse().setStatus(status);
    Representation errorEntity = getStatusService().toRepresentation(
        status, this);
    getResponse().setEntity(errorEntity);
  }
}
origin: org.restlet.jse/org.restlet.ext.platform

if (e.getStatus().isConnectorError()) {
  throw new RuntimeException("Restlet Cloud communication error. Please check the root cause below.", e);
} else if (e.getStatus().isClientError()) {
org.restlet.dataStatusisConnectorError

Javadoc

Indicates if the status is a connector error status, meaning "The connector failed to send or receive an apparently valid message".

Popular methods of Status

  • getCode
    Returns the corresponding code (HTTP or WebDAV or custom code).
  • isSuccess
    Indicates if the status is a success status, meaning "The action was successfully received, understo
  • equals
    Indicates if the status is equal to a given one.
  • isError
    Indicates if the status is an error (client or server) status.
  • getDescription
    Returns the description. This value is typically used by the org.restlet.service.StatusService to bu
  • <init>
    Constructor.
  • isClientError
    Indicates if the status is a client error status, meaning "The request contains bad syntax or cannot
  • valueOf
    Returns the status associated to a code. If an existing constant exists then it is returned, otherwi
  • getThrowable
    Returns the related error or exception.
  • toString
    Returns the reason phrase of the status followed by its HTTP code.
  • getReasonPhrase
    Returns the reason phrase of this status. When supported by the HTTP server connector, this is retur
  • getName
    Returns the name of this status.
  • getReasonPhrase,
  • getName,
  • isRedirection,
  • isServerError,
  • isInformational,
  • getUri,
  • checkReasonPhrase,
  • isGlobalError,
  • checkDescription

Popular in Java

  • Making http requests using okhttp
  • getSupportFragmentManager (FragmentActivity)
  • requestLocationUpdates (LocationManager)
  • getSystemService (Context)
  • InputStreamReader (java.io)
    A class for turning a byte stream into a character stream. Data read from the source input stream is
  • BigInteger (java.math)
    An immutable arbitrary-precision signed integer.FAST CRYPTOGRAPHY This implementation is efficient f
  • Date (java.sql)
    A class which can consume and produce dates in SQL Date format. Dates are represented in SQL as yyyy
  • Date (java.util)
    A specific moment in time, with millisecond precision. Values typically come from System#currentTime
  • Dictionary (java.util)
    Note: Do not use this class since it is obsolete. Please use the Map interface for new implementatio
  • HttpServlet (javax.servlet.http)
    Provides an abstract class to be subclassed to create an HTTP servlet suitable for a Web site. A sub
  • Top PhpStorm plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now