public ExecutionContext CreateCopy() { if (!this.isNewCapture) { throw new InvalidOperationException(Environment.GetResourceString("InvalidOperation_CannotCopyUsedContext")); } ExecutionContext context = new ExecutionContext { isNewCapture = true, _syncContext = (this._syncContext == null) ? null : this._syncContext.CreateCopy(), _hostExecutionContext = (this._hostExecutionContext == null) ? null : this._hostExecutionContext.CreateCopy() }; if (this._securityContext != null) { context._securityContext = this._securityContext.CreateCopy(); context._securityContext.ExecutionContext = context; } if (this._logicalCallContext != null) { System.Runtime.Remoting.Messaging.LogicalCallContext logicalCallContext = this.LogicalCallContext; context.LogicalCallContext = (System.Runtime.Remoting.Messaging.LogicalCallContext)logicalCallContext.Clone(); } if (this._illogicalCallContext != null) { System.Runtime.Remoting.Messaging.IllogicalCallContext illogicalCallContext = this.IllogicalCallContext; context.IllogicalCallContext = (System.Runtime.Remoting.Messaging.IllogicalCallContext)illogicalCallContext.Clone(); } return(context); }
public static void LogicalSetData(String name, Object data) { IllogicalCallContext ilcc = Thread.CurrentThread.GetIllogicalCallContext(); ilcc.FreeNamedDataSlot(name); LogicalCallContext lcc = Thread.CurrentThread.GetLogicalCallContext(); lcc.SetData(name, data); }
public object Clone() { IllogicalCallContext context = new IllogicalCallContext(); if (this.HasUserData) { IDictionaryEnumerator enumerator = this.m_Datastore.GetEnumerator(); while (enumerator.MoveNext()) { context.Datastore[(string) enumerator.Key] = enumerator.Value; } } return context; }
public object Clone() { IllogicalCallContext context = new IllogicalCallContext(); if (this.HasUserData) { IDictionaryEnumerator enumerator = this.m_Datastore.GetEnumerator(); while (enumerator.MoveNext()) { context.Datastore[(string)enumerator.Key] = enumerator.Value; } } return(context); }
public static void SetData(String name, Object data) { if (data is ILogicalThreadAffinative) { LogicalSetData(name, data); } else { LogicalCallContext lcc = Thread.CurrentThread.GetLogicalCallContext(); lcc.FreeNamedDataSlot(name); IllogicalCallContext ilcc = Thread.CurrentThread.GetIllogicalCallContext(); ilcc.SetData(name, data); } }
public IllogicalCallContext CreateCopy() { IllogicalCallContext illogicalCallContext = new IllogicalCallContext(); illogicalCallContext.HostContext = this.HostContext; if (this.HasUserData) { IDictionaryEnumerator enumerator = this.m_Datastore.GetEnumerator(); while (enumerator.MoveNext()) { illogicalCallContext.Datastore[(object)(string)enumerator.Key] = enumerator.Value; } } return(illogicalCallContext); }
public Object Clone() { IllogicalCallContext ilcc = new IllogicalCallContext(); if (HasUserData) { IDictionaryEnumerator de = m_Datastore.GetEnumerator(); while (de.MoveNext()) { ilcc.Datastore[(String)de.Key] = de.Value; } } return(ilcc); }
public IllogicalCallContext CreateCopy() { IllogicalCallContext ilcc = new IllogicalCallContext(); ilcc.HostContext = this.HostContext; if (HasUserData) { IDictionaryEnumerator de = this.m_Datastore.GetEnumerator(); while (de.MoveNext()) { ilcc.Datastore[(String)de.Key] = de.Value; } } return(ilcc); }
public IllogicalCallContext CreateCopy() { IllogicalCallContext ilcc = new IllogicalCallContext(); ilcc.HostContext = this.HostContext; if (HasUserData) { IDictionaryEnumerator de = this.m_Datastore.GetEnumerator(); while (de.MoveNext()) { ilcc.Datastore[(String)de.Key] = de.Value; } } return ilcc; }
public Reader(IllogicalCallContext ctx) { m_ctx = ctx; }
public Object Clone() { IllogicalCallContext ilcc = new IllogicalCallContext(); if (HasUserData) { IDictionaryEnumerator de = m_Datastore.GetEnumerator(); while (de.MoveNext()) { ilcc.Datastore[(String)de.Key] = de.Value; } } return ilcc; }
public Reader(IllogicalCallContext ctx) { m_ctx = ctx; }
/*========================================================================= ** Get data on the illogical call context ** =========================================================================*/ private static Object IllogicalGetData(String name) { IllogicalCallContext ilcc = Thread.CurrentThread.GetIllogicalCallContext(); return(ilcc.GetData(name)); }
internal IllogicalCallContext GetIllogicalCallContext() { if (m_IllogicalCallContext == null) { m_IllogicalCallContext = new IllogicalCallContext(); } return m_IllogicalCallContext; }