Package java.util

Examples of java.util.Stack.empty()


        while (e.hasMoreElements()) {
            reverse.push(e.nextElement());
        }

        while (!reverse.empty()) {
            ret.append("'" + reverse.pop() + "'");

            if (!reverse.empty()) {
                ret.append(" accessed by ");
            }
View Full Code Here


        }

        while (!reverse.empty()) {
            ret.append("'" + reverse.pop() + "'");

            if (!reverse.empty()) {
                ret.append(" accessed by ");
            }
        }

        return ret.toString();
View Full Code Here

  // Add the line number
  formatLineNumber(++lineNumber);

  // Now "reopen" the elements that we closed...
  while (!tempStack.empty()) {
    StartElementInfo elem = (StartElementInfo) tempStack.pop();
    AttributeCollection attr = (AttributeCollection)elem.getAttributes();
    AttributeCollection newAttr = new AttributeCollection(namePool);

    for (int acount = 0; acount < attr.getLength(); acount++) {
View Full Code Here

  // Add the line number
  formatLineNumber(++lineNumber);

  // Now "reopen" the elements that we closed...
  while (!tempStack.empty()) {
    StartElementInfo elem = (StartElementInfo) tempStack.pop();
    AttributeCollection attr = (AttributeCollection)elem.getAttributes();
    AttributeCollection newAttr = new AttributeCollection(namePool);

    for (int acount = 0; acount < attr.getLength(); acount++) {
View Full Code Here

        if( !statements.containsKey(sql) ) {
            return false;
        }
        stack = (Stack)statements.get(sql);
        return !stack.empty();
    }

    /**
     * Grabs a statement matching the specified SQL from the pool.
     * @param sql the SQL for which a statement is desired
View Full Code Here

        StringBuffer buff = new StringBuffer();
        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

      nfa_stack.push(state);
    }

  /* Main loop. */
  while (false == nfa_stack.empty())
    {
      state = (CNfa) nfa_stack.pop();
     
      if (CUtility.OLD_DUMP_DEBUG)
        {
View Full Code Here

                    actDir = actDir.getParentDir();
                }

                DirectoryInfoModel child = this;

                while (!stack.empty()) {
                    actDir = (DirectoryInfo) stack.pop();

                    child = child.addDirectory(actDir);
                }
            }
View Full Code Here

        if ((stack = (Stack) m_namespaces.get(prefix)) == null)
        {
            m_namespaces.put(prefix, stack = new Stack());
        }

        if (!stack.empty() && uri.equals(stack.peek()))
        {
            return false;
        }

        stack.push(uri);
View Full Code Here

    private String peekWidgetIdFor(Object object) {
        String widgetId = null;

        Stack stack = getWidgetIdStackFor(object, false);
       
        if (stack != null && !stack.empty()) {
            widgetId = (String) stack.peek();
        }
       
        return widgetId;
    }
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.