Package java.util

Examples of java.util.Stack.pop()


                    frgdColor = (Color)dcStack.pop();
                    fontObject = ((Integer)(dcStack.pop())).intValue();
                    penObject = ((Integer)(dcStack.pop())).intValue();
                    brushObject = ((Integer)(dcStack.pop())).intValue();
                    startY = ((Integer)(dcStack.pop())).intValue();
                    startX = ((Integer)(dcStack.pop())).intValue();
                    penWidth = ((Integer)(dcStack.pop())).intValue();
                    break;

                case WMFConstants.META_POLYBEZIER16:
                    try
View Full Code Here


                    fontObject = ((Integer)(dcStack.pop())).intValue();
                    penObject = ((Integer)(dcStack.pop())).intValue();
                    brushObject = ((Integer)(dcStack.pop())).intValue();
                    startY = ((Integer)(dcStack.pop())).intValue();
                    startX = ((Integer)(dcStack.pop())).intValue();
                    penWidth = ((Integer)(dcStack.pop())).intValue();
                    break;

                case WMFConstants.META_POLYBEZIER16:
                    try
                        {
View Full Code Here

        while (parent != null) {
            stk.push(parent.getName());
            parent = parent.getParent();
        }
        while (!stk.empty()) {
            buff.append("/" + stk.pop());
        }
        buff.append(getName());
        namingContextName = buff.toString();
        }
    }
View Full Code Here

        // create the String from the stack
        StringBuffer buff = new StringBuffer(150);
        if (!stack.isEmpty())
        {
            buff.append((String) stack.pop());
        }
        while (!stack.isEmpty())
        {
            buff.append('.');
            buff.append((String) stack.pop());
View Full Code Here

            buff.append((String) stack.pop());
        }
        while (!stack.isEmpty())
        {
            buff.append('.');
            buff.append((String) stack.pop());

        }

        String changednsuri = buff.toString();
        //remove any unexpected charactors   
View Full Code Here

            extensions = new Vector();
            extensions.addElement("jsp");
            extensions.addElement("jspx");
        }
        while (!dirs.isEmpty()) {
            String s = dirs.pop().toString();
            File f = new File(s);
            if (f.exists() && f.isDirectory()) {
                String[] files = f.list();
                String ext;
                for (int i = 0; (files != null) && i < files.length; i++) {
View Full Code Here

                int numops = operation.getNumberOfOperands();
                Eval[] ops = new Eval[numops];

                // storing the ops in reverse order since they are popping
                for (int j = numops - 1; j >= 0; j--) {
                    Eval p = (Eval) stack.pop();
                    ops[j] = p;
                }
                Eval opresult = invokeOperation(operation, ops, srcRowNum, srcColNum, workbook, sheet);
                stack.push(opresult);
            }
View Full Code Here

                Eval ptgEval = getEvalForPtg(ptg);
                stack.push(ptgEval);
            }
        }

        ValueEval value = ((ValueEval) stack.pop());
        if (!stack.isEmpty()) {
            throw new IllegalStateException("evaluation stack not empty");
        }
        value = dereferenceValue(value, srcRowNum, srcColNum);
        if (value instanceof BlankEval) {
View Full Code Here

                // by their trailing operators (e.g. UnionPtg)
                // TODO - put comment and throw exception in toFormulaString() of these classes
                continue;
            }
            if (ptg instanceof ParenthesisPtg) {
                String contents = (String)stack.pop();
                stack.push ("(" + contents + ")");
                continue;
            }
            if (ptg instanceof AttrPtg) {
                AttrPtg attrPtg = ((AttrPtg) ptg);
View Full Code Here

        if(stack.isEmpty()) {
            // inspection of the code above reveals that every stack.pop() is followed by a
            // stack.push(). So this is either an internal error or impossible.
            throw new IllegalStateException("Stack underflow");
        }
        String result = (String) stack.pop();
        if(!stack.isEmpty()) {
            // Might be caused by some tokens like AttrPtg and Mem*Ptg, which really shouldn't
            // put anything on the stack
            throw new IllegalStateException("too much stuff left on the stack");
        }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.