Class NativeService

java.lang.Object
org.angular.ts.ng.NativeService

@JsType(isNative=true, name="ng.NativeService", namespace="<global>") public class NativeService extends Object
Native bridge service used to call host-platform methods, receive replies, subscribe to native events, and access the active adapter.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    boolean
    Public NativeService.available member exposed by the AngularTS namespace contract.
    jsinterop.base.JsPropertyMap<elemental2.core.JsArray<String>>
    Public NativeService.capabilities member exposed by the AngularTS namespace contract.
    double
    Public NativeService.protocolVersion member exposed by the AngularTS namespace contract.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    <Name, Method>
    elemental2.promise.Promise<NativeCapabilityResult<Name,Method>>
    call(Name target, Method method, NativeCapabilityParameters<Name,Method> params, NativeCallOptions options)
    Public NativeService.call member exposed by the AngularTS namespace contract.
    void
    Public NativeService.dispose member exposed by the AngularTS namespace contract.
    <Name, Event>
    org.angular.ts.ng.NativeService.Subscription
    on(Name target, Event event, NativeEventHandler<NativeCapabilityEventPayload<Name,Event>> handler)
    Public NativeService.on member exposed by the AngularTS namespace contract.
    void
    receive(Object message)
    Public NativeService.receive member exposed by the AngularTS namespace contract.
    boolean
    supports(String target, String method)
    Public NativeService.supports member exposed by the AngularTS namespace contract.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • available

      public boolean available
      Public NativeService.available member exposed by the AngularTS namespace contract.
    • capabilities

      public jsinterop.base.JsPropertyMap<elemental2.core.JsArray<String>> capabilities
      Public NativeService.capabilities member exposed by the AngularTS namespace contract.
    • protocolVersion

      public double protocolVersion
      Public NativeService.protocolVersion member exposed by the AngularTS namespace contract.
  • Constructor Details

    • NativeService

      public NativeService()
  • Method Details

    • call

      public <Name, Method> elemental2.promise.Promise<NativeCapabilityResult<Name,Method>> call(Name target, Method method, NativeCapabilityParameters<Name,Method> params, NativeCallOptions options)
      Public NativeService.call member exposed by the AngularTS namespace contract.
      Parameters:
      target - Value supplied for the target parameter.
      method - Value supplied for the method parameter.
      params - Value supplied for the params parameter.
      options - Value supplied for the options parameter.
      Returns:
      Method result.
    • dispose

      public void dispose()
      Public NativeService.dispose member exposed by the AngularTS namespace contract.
    • on

      public <Name, Event> org.angular.ts.ng.NativeService.Subscription on(Name target, Event event, NativeEventHandler<NativeCapabilityEventPayload<Name,Event>> handler)
      Public NativeService.on member exposed by the AngularTS namespace contract.
      Parameters:
      target - Value supplied for the target parameter.
      event - Value supplied for the event parameter.
      handler - Value supplied for the handler parameter.
      Returns:
      Method result.
    • receive

      public void receive(Object message)
      Public NativeService.receive member exposed by the AngularTS namespace contract.
      Parameters:
      message - Value supplied for the message parameter.
    • supports

      public boolean supports(String target, String method)
      Public NativeService.supports member exposed by the AngularTS namespace contract.
      Parameters:
      target - Value supplied for the target parameter.
      method - Value supplied for the method parameter.
      Returns:
      Method result.