IPhotonApplication IPhotonApplicationControl.OnStart(string instanceName, string applicationName, IPhotonApplicationSink photonApplicationSink);
public IPhotonApplication OnStart(string instanceName, string applicationName, IPhotonApplicationSink sink, IControlListeners controlListners, IPhotonApplicationsCounter applicationsCounter, string unmanagedLogDirectory) { this.ApplicationName = applicationName; this.PhotonInstanceName = instanceName; this.ApplicationSink = sink; this.UnmanagedLogPath = unmanagedLogDirectory; this.ControlListeners = controlListners; return(this); }
/// <summary> /// Called when the application starts. /// </summary> /// <param name="instanceName"> /// The instance name. /// </param> /// <param name="applicationName"> /// Name/ID of the application. /// </param> /// <param name="sink"> /// The PhotonApplicationSink. /// </param> /// <param name="listenerControl"> /// The listener Control. /// </param> /// <param name="unmanagedLogDirectory"> /// Photon's log path. /// </param> /// <returns> /// PhotonApplication object. /// </returns> public IPhotonApplication OnStart(string instanceName, string applicationName, IPhotonApplicationSink sink, IControlListeners listenerControl, IPhotonApplicationsCounter applicationsCounter, string unmanagedLogDirectory) { // this app does not inherit from Photon.SocketServer.Application, so it's missing the ApplicationPath // get the ApplicationPath "manually": Environment.CurrentDirectory is overwritten when the next app starts, so copy the value this.applicationId = applicationName; return(this); }
/// <summary> /// Called when the application starts. /// </summary> /// <param name="instanceName"> /// The instance name. /// </param> /// <param name="applicationName"> /// Name/ID of the application. /// </param> /// <param name="sink"> /// The PhotonApplicationSink. /// </param> /// <param name="listenerControl"> /// The listener Control. /// </param> /// <param name="unmanagedLogDirectory"> /// Photon's log path. /// </param> /// <returns> /// PhotonApplication object. /// </returns> public IPhotonApplication OnStart(string instanceName, string applicationName, IPhotonApplicationSink sink, IControlListeners listenerControl, string unmanagedLogDirectory) { // this app does not inherit from Photon.SocketServer.Application, so it's missing the ApplicationPath // get the ApplicationPath "manually": Environment.CurrentDirectory is overwritten when the next app starts, so copy the value this.applicationId = applicationName; return this; }