Package com.yahoo.messagebus.network.rpc
Class RPCServiceAddress
java.lang.Object
com.yahoo.messagebus.network.rpc.RPCServiceAddress
- All Implemented Interfaces:
ServiceAddress
Implements the
ServiceAddress
interface for the RPC network.- Author:
- Haavard Pettersen
-
Constructor Summary
ConstructorDescriptionRPCServiceAddress
(RPCServiceAddress blueprint) RPCServiceAddress
(String serviceName, com.yahoo.jrt.Spec connectionSpec) Constructs a service address from the given specifications.RPCServiceAddress
(String serviceName, String connectionSpec) -
Method Summary
Modifier and TypeMethodDescriptionboolean
com.yahoo.jrt.Spec
Returns the connection spec for the remote service.Returns the name of the remove service.Returns the name of the remote session.Returns the RPC target to be used when communicating with the remove service.int
hashCode()
boolean
Returns whether or not this service address is malformed.void
Sets the RPC target to be used when communicating with the remote service.
-
Constructor Details
-
RPCServiceAddress
Constructs a service address from the given specifications. The last component of the service is stored as the session name.- Parameters:
serviceName
- The full service name of the address.connectionSpec
- The connection specification.
-
RPCServiceAddress
-
RPCServiceAddress
-
-
Method Details
-
equals
-
hashCode
public int hashCode() -
isMalformed
public boolean isMalformed()Returns whether or not this service address is malformed.- Returns:
- True if malformed.
-
getServiceName
Returns the name of the remove service.- Returns:
- The service name.
-
getSessionName
Returns the name of the remote session.- Returns:
- The session name.
-
getConnectionSpec
public com.yahoo.jrt.Spec getConnectionSpec()Returns the connection spec for the remote service.- Returns:
- The connection spec.
-
setTarget
Sets the RPC target to be used when communicating with the remote service.- Parameters:
target
- The target to set.
-
getTarget
Returns the RPC target to be used when communicating with the remove service.- Returns:
- The target to use.
-