public void InitBase(EventHandlerServiceInited initedCallback, EventHandlerServiceError errorCallback) { this._onInitCallback = initedCallback; this._onErrorCallback = errorCallback; this._transactions = new Dictionary <string, Transaction>(); this._transactionsQueue = new Queue <string>(); } // InitBase
public static void InitService(UCSSprotocols protocol, string serviceName, string host, EventHandlerServiceInited initedCallback = null, EventHandlerServiceError errorCallback = null) { if (string.IsNullOrEmpty(serviceName)) { throw new System.ArgumentNullException("serviceName"); } if (string.IsNullOrEmpty(host)) { throw new System.ArgumentNullException("host"); } if (UCSS.Instance._initedProtocols.Count > 0 && UCSS.Instance._initedProtocols.ContainsKey(serviceName)) { throw new System.InvalidOperationException("serviceName [" + serviceName + "] already exists in CSS"); } BaseProtocol selectedProtocol = null; switch (protocol) { case UCSSprotocols.amf: break; default: throw new System.InvalidOperationException("protocol [" + protocol + "] is NOT found in InitService"); } if (selectedProtocol != null) { UCSS.Instance._initedProtocols.Add(serviceName, selectedProtocol); } //Debug.Log("CSS.Instance._initedProtocols = " + UCSS.Instance._initedProtocols.Count); } // InitService
public static void InitService(UCSSprotocols protocol, UCSSservices serviceName, string host, EventHandlerServiceInited initedCallback = null, EventHandlerServiceError errorCallback = null) { UCSS.InitService(protocol, serviceName.ToString(), host, initedCallback, errorCallback); }
public void InitBase(EventHandlerServiceInited initiedCallback, EventHandlerServiceError errorCallback) { this._onInitCallback = initiedCallback; this._onErrorCallback = errorCallback; this._transactions = new Dictionary<string, Transaction>(); this._transactionsQueue = new Queue<string>(); }
public static void InitService(UCSSprotocols protocol, string serviceName, string host, EventHandlerServiceInited initedCallback = null, EventHandlerServiceError errorCallback = null) { if (string.IsNullOrEmpty(serviceName)) { throw new System.ArgumentNullException("serviceName"); } if (string.IsNullOrEmpty(host)) { throw new System.ArgumentNullException("host"); } if (UCSS.Instance._initedProtocols.Count > 0 && UCSS.Instance._initedProtocols.ContainsKey(serviceName)) { throw new System.InvalidOperationException("serviceName [" + serviceName + "] already exists in CSS"); } BaseProtocol selectedProtocol = null; switch (protocol) { case UCSSprotocols.amf: break; default: throw new System.InvalidOperationException("protocol [" + protocol + "] is NOT found in InitService"); } if (selectedProtocol != null) { UCSS.Instance._initedProtocols.Add(serviceName, selectedProtocol); } //Debug.Log("CSS.Instance._initedProtocols = " + UCSS.Instance._initedProtocols.Count); }