Interface Request<T>

  • Type Parameters:
    T - The return type of objects in the corresponding response.
    All Known Implementing Classes:
    FakeRequest

    public interface Request<T>
    A Request represents a single method invocation on the server. It encapsulates the arguments provided to the Request factory method declared in a RequestContext as well as a set of object paths to return from the server. The returned data is provided to an optional Receiver object, specified by the to(Receiver) method.
    See Also:
    FakeRequest
    • Method Detail

      • fire

        void fire()
        Submit this request. Failures will be reported through the global uncaught exception handler, if any.
      • fire

        void fire​(Receiver<? super T> receiver)
        Convenience method equivalent to calling to(...).fire().
        Parameters:
        receiver - a Receiver instance
      • getRequestContext

        RequestContext getRequestContext()
        Returns the RequestContext associated with the Request.
      • with

        Request<T> with​(java.lang.String... propertyRefs)
        Request additional reference properties to fetch with the return value.
        Parameters:
        propertyRefs - a list of reference property names as Strings
        Returns:
        a Request instance of type T