public IDisposable CreateSecurityScope(BaseSecurityContext s = null) { var old = this.SecurityContext; this.SecurityContext = s; return(new DisposableAction(() => { this.SecurityContext = old; })); }
/// <summary> /// Creates new Security Scope /// </summary> /// <param name="sc"></param> /// <returns></returns> public IDisposable CreateSecurityScope(BaseSecurityContext sc = null) { var current = this.SecurityContext; this.SecurityContext = sc; return(new DisposableAction(() => { this.SecurityContext = current; })); }
public AtomJavaScriptSerializer(BaseSecurityContext sc, bool json = true) { this.json = json; this.SecurityContext = sc; }