static void Main(string[] args) { Example example = new Example(); example.Test(); ContextBound contextBound = new ContextBound(); contextBound.Test("ContentBound Test\n"); example.Sync(contextBound); Console.ReadLine(); }
/// <summary> /// 访问上下文绑定对象测试 /// </summary> /// <param name="contextBound"></param> public void Sync(ContextBound contextBound) { contextBound.Test("Example call on contextBound\n"); }