RequestStatusUtil (Google App Engine API for Java)

com.google.appengine.api.search

Class RequestStatusUtil

  • java.lang.Object
    • com.google.appengine.api.search.RequestStatusUtil


  • public final class RequestStatusUtil
    extends java.lang.Object
    Collection of utility methods for SearchServicePb.RequestStatus.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method and Description
      static SearchServicePb.RequestStatus newInvalidRequestStatus(java.lang.IllegalArgumentException e)
      Creates a RequestStatus message suitable for reporting an invalid request.
      static SearchServicePb.RequestStatus newStatus(SearchServicePb.SearchServiceError.ErrorCode code)
      Creates a SearchServicePb.RequestStatus from the given code.
      static SearchServicePb.RequestStatus newStatus(SearchServicePb.SearchServiceError.ErrorCode code, java.lang.String message)
      Creates a SearchServicePb.RequestStatus from the given code and message.
      static SearchServicePb.RequestStatus.Builder newStatusBuilder(SearchServicePb.SearchServiceError.ErrorCode code, java.lang.String message)
      Creates a SearchServicePb.RequestStatus.Builder from the given code and message.
      static SearchServicePb.RequestStatus newUnknownIndexStatus(SearchServicePb.IndexSpec indexSpec)
      Creates a RequestStatus message suitable for reporting an unknown index.
      static Code toCanonicalCode(SearchServicePb.SearchServiceError.ErrorCode appCode)
      Converts SearchServicePb.SearchServiceError.ErrorCode to canonical error code.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RequestStatusUtil

        public RequestStatusUtil()
    • Method Detail

      • toCanonicalCode

        public static Code toCanonicalCode(SearchServicePb.SearchServiceError.ErrorCode appCode)
        Converts SearchServicePb.SearchServiceError.ErrorCode to canonical error code.
      • newStatusBuilder

        public static SearchServicePb.RequestStatus.Builder newStatusBuilder(SearchServicePb.SearchServiceError.ErrorCode code,
                                                                             java.lang.String message)
        Creates a SearchServicePb.RequestStatus.Builder from the given code and message.
      • newStatus

        public static SearchServicePb.RequestStatus newStatus(SearchServicePb.SearchServiceError.ErrorCode code,
                                                              java.lang.String message)
        Creates a SearchServicePb.RequestStatus from the given code and message.
      • newStatus

        public static SearchServicePb.RequestStatus newStatus(SearchServicePb.SearchServiceError.ErrorCode code)
        Creates a SearchServicePb.RequestStatus from the given code.
      • newInvalidRequestStatus

        public static SearchServicePb.RequestStatus newInvalidRequestStatus(java.lang.IllegalArgumentException e)
        Creates a RequestStatus message suitable for reporting an invalid request.
      • newUnknownIndexStatus

        public static SearchServicePb.RequestStatus newUnknownIndexStatus(SearchServicePb.IndexSpec indexSpec)
        Creates a RequestStatus message suitable for reporting an unknown index. We use SearchServicePb.SearchServiceError.ErrorCode#OK because the unknown index isn't an error condition but just a notice to the user.

Monitor your resources on the go

Get the Google Cloud Console app to help you manage your projects.

Send feedback about...

App Engine standard environment for Java