Code example for Stack

Methods: push

0
Stack s = (Stack)local.get();
 
            if (s == null)
            { 
                s = new Stack();
                local.set (s);
            } 
 
            s.push (role);
        } 
 
 
        public static void pop () 
        { 
            Stack s = (Stack)local.get();
 
            if ((s == null) || s.empty())
                return; 
 
            s.pop();