public Participant(Domain domain, string participantID) { Interlocked.Increment(ref safeInstanceCount); ///TEST this.domainID = domain.GetDomainID(); this.participantID = participantID; this.domain = domain; this.inProcessTransport.Start(); SetupCyclicThread(); }
/// /// <param name="domain"></param> /// <param name="participantID"></param> internal Participant GetParticipant(Domain domain, string participantID) { string hashKey = domain.GetDomainID() + " " + participantID; if (!instances.ContainsKey(hashKey)) { Participant newInst = new Participant(domain, participantID); Domain tDomain = newInst.getDomain(); if (tDomain != null) { instances.Add(hashKey, newInst); } else { return(null); } } return(instances[hashKey]); }
/// /// <param name="domain"></param> /// <param name="participantID"></param> internal Participant GetParticipant(Domain domain, string participantID) { string hashKey = domain.GetDomainID() + " " + participantID; if (!instances.ContainsKey(hashKey)) { Participant newInst = new Participant(domain, participantID); Domain tDomain = newInst.getDomain(); if (tDomain != null) { instances.Add(hashKey, newInst); } else { return null; } } return instances[hashKey]; }