AsyncWcfLib

ActorOutput(TOC) Members

ActorOutput(TOC) overview

Public Instance Constructors

ActorOutput(TOC) Constructor

Creates an output port for an actor.

Public Instance Properties

AddressList (inherited from ActorPort)To support networks without DNS server, the WcfRouter sends a list of all IP-Adresses of a host.May be null, when no info from WcfRouter has been received yet.
AppIdentification (inherited from ActorPort) The AppIdentification is composed from AppName, HostName, AppInstance and processId to for a unique string
AppInstance (inherited from ActorPort) Unique instance number of the application (unique in a plant or on a host, depending on WcfDefault.IsAppIdUniqueInPlant).
AppName (inherited from ActorPort) Unique name of an application or service in the users WcfContract.Namespace.
AppVersion (inherited from ActorPort) Assembly version of the application.
CifComponentName (inherited from ActorPort) Assembly name of an important CifComponent containig some messages
CifVersion (inherited from ActorPort) Assembly version of the important CifComponent
HostName (inherited from ActorPort) Host running the application
IsMultithreaded (inherited from ActorPort) Multithreaded partners do not use a message input queue. All threads may directly call InputHandler delegates. Default = false.
IsOutputConnected (inherited from ActorOutput) When true: Sending of requests is possible
IsServiceName (inherited from ActorPort) IsServiceName=true : A service name must be unique in the plant, independant of host or application. IsServiceName=false: A client name must for unique identification be combined with application name, host name, instance- or process id.
LastRequestIdSent (inherited from ActorPort) The request id given to the last message sent from this client. The request id is incremented by the client for each request. The same id is returned in the response from the service. It is used to detect programming erors leading to request/response mismatch.
LastSentId (inherited from ActorPort) The send id given to the last message sent from this sender. It is used to detect missing messages on the receiving side.
Logger (inherited from ActorPort) Set your logging object here (null by default). It is passed to the logging methods of WcfTrc.ITracePlugin. You will use it when writing your own adapter class based on WcfTrc.ITracePlugin. The adapter class is needed to redirect trace output to your own logging/tracing framework.
MustConnectOutput (inherited from ActorOutput) When true: TryConnect() must be called (first connect or reconnect)
Name (inherited from ActorPort) Identification in Trace and name of endpoint address in App.config file.
OutputClientId (inherited from ActorOutput) The OutputClientId used on the connected service to identify this client. OutputClientId is generated by the service on first connect or service restart. It remains stable on reconnect or client restart.
OutputContextOutputContext is an object of type TOC defined by the application.The OutputContext is not sent over the network.The OutputContext remains untouched by the library. The application may initialize and use it.
OutputSidePartner (inherited from ActorOutput) OutputSidePartner is an IActorPortId interface to the service (or its proxy) that is linked to this output. It returns null, as long as we are not linked (OutputState==WcfState.Unlinked). It is used to return identification data like Uri, AppVersion... (see IActorPortId).
OutputState (inherited from ActorOutput)Gets or sets the state of the outgoing connection.May be called from any thread.Setting OutputState to WcfState.Ok or WcfState.Connecting reconnects a previously disconnected link.These states may be set only after an initial call to TryConnect from the active services internal thread.Setting other states will disconnect the WCF client from network.
OutstandingResponsesCount (inherited from ActorOutput) The number of requests not yet responded by the service connected to this output.
ProcessId (inherited from ActorPort) Process id of the application, given by the operating system (unique on a host at a certain time).
TimeoutSeconds (inherited from ActorPort) After a service has no message received for TimeoutSeconds, it may render the connection to this client as disconnected. 0 means no timeout. The client should send at least 2 messages each TimeoutSeconds-period in order to keep the correct connection state on the service. A Service is trying to notify 2 messages each TimeoutSeconds-period in order to check a dual-Http connection.
TraceConnect (inherited from ActorPort) Trace switch: Traces connect/disconnect messages (not to the router). Default = true;
TraceReceive (inherited from ActorPort) Trace switch: Traces all received messages. Default = false;
TraceSend (inherited from ActorPort) Trace switch: Traces all sent messages. Default = false;
Uri (inherited from ActorPort)Universal resource identifier to reach the input of the service or client.E.g. RouterService: http://localhost:40000/AsyncWcfLib/RouterService

Public Instance Methods

ClockSecondsPassed (inherited from ActorPort) Check if time has passed.
Disconnect (inherited from ActorOutput) Shutdown the outgoing connection. Send a disconnect message to the partner.
Equals (inherited from Object)
GetHashCode (inherited from Object)
GetType (inherited from Object)
LinkOutputTo (inherited from ActorOutput) Link output to application-internal service.
LinkOutputToRemoteService (inherited from ActorOutput)Overloaded. Link output to remote service. Look for the service Uri at WcfRouter on local host. WcfRouter may have synchronized its service register with peer routers on other hosts.
PostInput (inherited from ActorPort) Used by the library to post a request or response message to the input of this partner. May be called on any thread. Usage: Internal: Post a message into this partners input queue. Serviceside: Sender.PostInput() sends a response from client-stub to the remote client. Clientside: Post a response into this clients input queue.
SendOut (inherited from ActorOutput)Overloaded. Send a request message to the partner on the outgoing connection. At least a WcfIdleMessage will asynchronously be received through 'PostInput', when the partner has processed the request. Usage: Clientside: Send a request to the connected remote service. Internal: Send a message to the connected partner running on another thread synchronization context. Serviceside: Sender.SendOut() sends a request from client-proxy to the internal service.
StartClockSeconds (inherited from ActorPort) Start the timer. Use ClockSecondsPassed() to check whether time has passed.
ToString (inherited from ActorPort)Overloaded. Trace or display status info
TryConnect (inherited from ActorOutput) 'TryConnect' opens the outgoing connection to the previously linked partner. The method is accessible by the owner of this ActorOutput object only. No interface exposes the method. TryConnect picks up the synchronization context and must be called on the sending thread only! The connect-process runs asynchronous and may involve an address lookup at the WcfRouter. A WcfPartnerMessage is received, after the connection has been established. A WcfErrorMessage is received, when the partner is not reachable.

Protected Instance Fields

m_Connected (inherited from ActorPort) False when not connected or disconnected. Prevents message passing during shutdown.
m_RedirectIncoming (inherited from ActorPort) Incoming messages are directly redirected to this partner (used library intern)

Protected Instance Methods

Finalize (inherited from Object)
MemberwiseClone (inherited from Object)
OnConnectDisconnect (inherited from ActorPort) Message is passed to users connect/disconnect event handler, may be overloaded and call a WcfMessageHandler<TSC>

See Also

ActorOutput<TOC> Class | SourceForge.AsyncWcfLib Namespace