Interface GeolocationRequest

  • All Implemented Interfaces:

    
    public interface GeolocationRequest
    
                        

    A pending one-shot Geolocation.get(...) request observed by the test controller. Tests can inspect the options the facade was called with, and resolve the request manually via respondWith or respondWith.

    Since:

    1.1

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      abstract GeolocationOptions options() The options the application passed to get(...
      abstract boolean isPending() Whether this request still awaits a response.
      abstract void respondWith(GeolocationPosition position) Resolves the request with the given position.
      abstract void respondWith(GeolocationError error) Resolves the request with the given error.
      • Methods inherited from class java.lang.Object

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

    • Method Detail

      • options

        @Nullable() abstract GeolocationOptions options()

        The options the application passed to get(...), or null.

      • isPending

         abstract boolean isPending()

        Whether this request still awaits a response.

      • respondWith

         abstract void respondWith(GeolocationPosition position)

        Resolves the request with the given position. Throws IllegalStateException if the request was already resolved.

      • respondWith

         abstract void respondWith(GeolocationError error)

        Resolves the request with the given error. Throws IllegalStateException if the request was already resolved.