Java Doc for ArrayStack.java in  » Sevlet-Container » apache-tomcat-6.0.14 » org » apache » tomcat » util » digester » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Sevlet Container » apache tomcat 6.0.14 » org.apache.tomcat.util.digester 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.util.ArrayList
   org.apache.tomcat.util.digester.ArrayStack

ArrayStack
public class ArrayStack extends ArrayList (Code)

Imported copy of the ArrayStack class from Commons Collections, which was the only direct dependency from Digester.

WARNNG - This class is public solely to allow it to be used from subpackages of org.apache.commons.digester. It should not be considered part of the public API of Commons Digester. If you want to use such a class yourself, you should use the one from Commons Collections directly.

An implementation of the java.util.Stack API that is based on an ArrayList instead of a Vector, so it is not synchronized to protect against multi-threaded access. The implementation is therefore operates faster in environments where you do not need to worry about multiple thread contention.

Unlike Stack, ArrayStack accepts null entries.


See Also:   java.util.Stack
since:
   Digester 1.6 (from Commons Collections 1.0)



Constructor Summary
public  ArrayStack()
     Constructs a new empty ArrayStack.
public  ArrayStack(int initialSize)
     Constructs a new empty ArrayStack with an initial size.

Method Summary
public  booleanempty()
     Return true if this stack is currently empty.
public  Objectpeek()
     Returns the top item off of this stack without removing it.
public  Objectpeek(int n)
     Returns the n'th item down (zero-relative) from the top of this stack without removing it.
public  Objectpop()
     Pops the top item off of this stack and return it.
public  Objectpush(Object item)
     Pushes a new item onto the top of this stack.
public  intsearch(Object object)
     Returns the one-based position of the distance from the top that the specified object exists on this stack, where the top-most element is considered to be at distance 1.


Constructor Detail
ArrayStack
public ArrayStack()(Code)
Constructs a new empty ArrayStack. The initial size is controlled by ArrayList and is currently 10.



ArrayStack
public ArrayStack(int initialSize)(Code)
Constructs a new empty ArrayStack with an initial size.
Parameters:
  initialSize - the initial size to use
throws:
  IllegalArgumentException - if the specified initial sizeis negative




Method Detail
empty
public boolean empty()(Code)
Return true if this stack is currently empty.

This method exists for compatibility with java.util.Stack. New users of this class should use isEmpty instead. true if the stack is currently empty




peek
public Object peek() throws EmptyStackException(Code)
Returns the top item off of this stack without removing it. the top item on the stack
throws:
  EmptyStackException - if the stack is empty



peek
public Object peek(int n) throws EmptyStackException(Code)
Returns the n'th item down (zero-relative) from the top of this stack without removing it.
Parameters:
  n - the number of items down to go the n'th item on the stack, zero relative
throws:
  EmptyStackException - if there are not enough items on thestack to satisfy this request



pop
public Object pop() throws EmptyStackException(Code)
Pops the top item off of this stack and return it. the top item on the stack
throws:
  EmptyStackException - if the stack is empty



push
public Object push(Object item)(Code)
Pushes a new item onto the top of this stack. The pushed item is also returned. This is equivalent to calling add.
Parameters:
  item - the item to be added the item just pushed



search
public int search(Object object)(Code)
Returns the one-based position of the distance from the top that the specified object exists on this stack, where the top-most element is considered to be at distance 1. If the object is not present on the stack, return -1 instead. The equals() method is used to compare to the items in this stack.
Parameters:
  object - the object to be searched for the 1-based depth into the stack of the object, or -1 if not found



Methods inherited from java.util.ArrayList
public boolean add(E e)(Code)(Java Doc)
public void add(int index, E element)(Code)(Java Doc)
public boolean addAll(Collection<? extends E> c)(Code)(Java Doc)
public boolean addAll(int index, Collection<? extends E> c)(Code)(Java Doc)
public void clear()(Code)(Java Doc)
public Object clone()(Code)(Java Doc)
public boolean contains(Object o)(Code)(Java Doc)
public void ensureCapacity(int minCapacity)(Code)(Java Doc)
public E get(int index)(Code)(Java Doc)
public int indexOf(Object o)(Code)(Java Doc)
public boolean isEmpty()(Code)(Java Doc)
public Iterator<E> iterator()(Code)(Java Doc)
public int lastIndexOf(Object o)(Code)(Java Doc)
public ListIterator<E> listIterator(int index)(Code)(Java Doc)
public ListIterator<E> listIterator()(Code)(Java Doc)
public E remove(int index)(Code)(Java Doc)
public boolean remove(Object o)(Code)(Java Doc)
public boolean removeAll(Collection c)(Code)(Java Doc)
protected void removeRange(int fromIndex, int toIndex)(Code)(Java Doc)
public boolean retainAll(Collection c)(Code)(Java Doc)
public E set(int index, E element)(Code)(Java Doc)
public int size()(Code)(Java Doc)
public List<E> subList(int fromIndex, int toIndex)(Code)(Java Doc)
public Object[] toArray()(Code)(Java Doc)
public T[] toArray(T[] a)(Code)(Java Doc)
public void trimToSize()(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.