Пример #1
0
        private static void Pop(OAuthScope scope)
        {
            Stack <OAuthScope> scopeStack = (Stack <OAuthScope>)Workbench.Current.Items[OAUTH_SCOPE_KEY];

            if (scopeStack != null)
            {
                scopeStack.Pop();
            }
        }
Пример #2
0
        private static void Push(OAuthScope scope)
        {
            Stack <OAuthScope> scopeStack = (Stack <OAuthScope>)Workbench.Current.Items[OAUTH_SCOPE_KEY];

            if (scopeStack == null)
            {
                scopeStack = new Stack <OAuthScope>();
                Workbench.Current.Items[OAUTH_SCOPE_KEY] = scopeStack;
            }
            scopeStack.Push(scope);
        }