ActorProxyFactory.createActorProxy 方法

定义

重载

createActorProxy(Class<T> actorInterfaceType, ActorId actorId)

Creates a proxy to the actor object that implements an actor interface.

createActorProxy(Class<T> actorInterfaceType, ActorId actorId, String applicationName, String serviceName, String listenerName)

Creates a proxy to the actor object that implements an actor interface.

createActorProxy(Class<T> actorInterfaceType, URI serviceUri, ActorId actorId)

Creates a proxy to the actor object that implements an actor interface.

createActorProxy(Class<T> actorInterfaceType, URI serviceUri, ActorId actorId, String listenerName)

Creates a proxy to the actor object that implements an actor interface.

createActorProxy(Class<T> actorInterfaceType, ActorId actorId)

Creates a proxy to the actor object that implements an actor interface.

public public<T extends Actor> T createActorProxy(Class<T> actorInterfaceType, ActorId actorId)

参数

actorInterfaceType
Class<T>

The actor interface implemented by the remote actor object. The returned proxy object will implement this interface.

actorId
ActorId

Actor Id of the proxy actor object. Methods called on this proxy will result in requests being sent to the actor with this id.

返回

public<T extends Actor> T

An actor proxy object that implements ActorProxy and Actor Interface.

createActorProxy(Class<T> actorInterfaceType, ActorId actorId, String applicationName, String serviceName, String listenerName)

Creates a proxy to the actor object that implements an actor interface.

public public<T extends Actor> T createActorProxy(Class<T> actorInterfaceType, ActorId actorId, String applicationName, String serviceName, String listenerName)

参数

actorInterfaceType
Class<T>

The actor interface implemented by the remote actor object. The returned proxy object will implement this interface.

actorId
ActorId

Actor Id of the proxy actor object. Methods called on this proxy will result in requests being sent to the actor with this id.

applicationName
String

Name of the Service Fabric application that contains the actor service hosting the actor objects. This parameter can be null if the client is running as part of that same Service Fabric application. For more information, see Remarks.

serviceName
String

Name of the Service Fabric service as configured by ActorServiceAttribute on the actor implementation. By default, the name of the service is derived from the name of the actor interface. However ActorServiceAttribute is required when an actor implements more than one actor interfaces or an actor interface derives from another actor interface as the determination of the serviceName cannot be made automatically.

listenerName
String

By default an actor service has only one listener for clients to connect to and communicate with. However it is possible to configure an actor service with more than one listeners, the listenerName parameter specifies the name of the listener to connect to.

返回

public<T extends Actor> T

An actor proxy object that implements ActorProxy and Actor Interface.

例外

URISyntaxException

Throws exception when invalid URI format is passed as applicationName

createActorProxy(Class<T> actorInterfaceType, URI serviceUri, ActorId actorId)

Creates a proxy to the actor object that implements an actor interface.

public public<T extends Actor> T createActorProxy(Class<T> actorInterfaceType, URI serviceUri, ActorId actorId)

参数

actorInterfaceType
Class<T>

The actor interface implemented by the remote actor object. The returned proxy object will implement this interface.

serviceUri
URI

Uri of the actor service.

actorId
ActorId

Actor Id of the proxy actor object. Methods called on this proxy will result in requests being sent to the actor with this id.

返回

public<T extends Actor> T

An actor proxy object that implements ActorProxy and Actor Interface.

createActorProxy(Class<T> actorInterfaceType, URI serviceUri, ActorId actorId, String listenerName)

Creates a proxy to the actor object that implements an actor interface.

public public<T extends Actor> T createActorProxy(Class<T> actorInterfaceType, URI serviceUri, ActorId actorId, String listenerName)

参数

actorInterfaceType
Class<T>

The actor interface implemented by the remote actor object. The returned proxy object will implement this interface.

serviceUri
URI

Uri of the actor service.

actorId
ActorId

Actor Id of the proxy actor object. Methods called on this proxy will result in requests being sent to the actor with this id.

listenerName
String

By default an actor service has only one listener for clients to connect to and communicate with. However it is possible to configure an actor service with more than one listeners, the listenerName parameter specifies the name of the listener to connect to.

返回

public<T extends Actor> T

An actor proxy object that implements ActorProxy and Actor Interface.

适用于