Java Doc for ArrayUnsignedByteList.java in  » Library » Apache-commons-primitives-1.0 » org » apache » commons » collections » primitives » 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 » Library » Apache commons primitives 1.0 » org.apache.commons.collections.primitives 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.apache.commons.collections.primitives.AbstractShortCollection
      org.apache.commons.collections.primitives.RandomAccessShortList
         org.apache.commons.collections.primitives.ArrayUnsignedByteList

ArrayUnsignedByteList
public class ArrayUnsignedByteList extends RandomAccessShortList implements ShortList,Serializable(Code)
A ShortList backed by an array of unsigned byte values. This list stores short values in the range [ ArrayUnsignedByteList.MIN_VALUE , ArrayUnsignedByteList.MAX_VALUE ] in 8-bits per element. Attempts to use elements outside this range may cause an IllegalArgumentException IllegalArgumentException to be thrown.

This implementation supports all optional methods.
since:
   Commons Primitives 1.0
version:
   $Revision: 1.3 $ $Date: 2003/10/16 20:49:36 $
author:
   Rodney Waldhoff



Field Summary
final public static  shortMAX_VALUE
     The maximum possible unsigned 8-bit value.
final public static  shortMIN_VALUE
     The minimum possible unsigned 8-bit value.

Constructor Summary
public  ArrayUnsignedByteList()
     Construct an empty list with the default initial capacity.
public  ArrayUnsignedByteList(int initialCapacity)
     Construct an empty list with the given initial capacity.
public  ArrayUnsignedByteList(ShortCollection that)
     Constructs a list containing the elements of the given collection, in the order they are returned by that collection's iterator.

Method Summary
public  voidadd(int index, short element)
     Inserts the specified element at the specified position (optional operation).
public  voidensureCapacity(int mincap)
     Increases my capacity, if necessary, to ensure that I can hold at least the number of elements specified by the minimum capacity argument without growing.
public  shortget(int index)
     Returns the element at the specified position within me.
public  shortremoveElementAt(int index)
     Removes the element at the specified position in (optional operation).
public  shortset(int index, short element)
     Replaces the element at the specified position in me with the specified element (optional operation).
public  intsize()
    
public  voidtrimToSize()
     Reduce my capacity, if necessary, to match my current ArrayUnsignedByteList.size size .

Field Detail
MAX_VALUE
final public static short MAX_VALUE(Code)
The maximum possible unsigned 8-bit value.



MIN_VALUE
final public static short MIN_VALUE(Code)
The minimum possible unsigned 8-bit value.




Constructor Detail
ArrayUnsignedByteList
public ArrayUnsignedByteList()(Code)
Construct an empty list with the default initial capacity.



ArrayUnsignedByteList
public ArrayUnsignedByteList(int initialCapacity)(Code)
Construct an empty list with the given initial capacity.
throws:
  IllegalArgumentException - when initialCapacity is negative



ArrayUnsignedByteList
public ArrayUnsignedByteList(ShortCollection that)(Code)
Constructs a list containing the elements of the given collection, in the order they are returned by that collection's iterator.
See Also:   ShortList.addAll(org.apache.commons.collections.primitives.ShortCollection)
Parameters:
  that - the non-null collection of ints to add
throws:
  NullPointerException - if that is null




Method Detail
add
public void add(int index, short element)(Code)
Inserts the specified element at the specified position (optional operation). Shifts the element currently at that position (if any) and any subsequent elements to the right, increasing their indices. Throws IllegalArgumentException if element is less than ArrayUnsignedByteList.MIN_VALUE or greater than ArrayUnsignedByteList.MAX_VALUE .
Parameters:
  index - the index at which to insert the element
Parameters:
  element - the value to insert
throws:
  UnsupportedOperationException - when this operation is not supported
throws:
  IllegalArgumentException - if some aspect of the specified element prevents it from being added to me
throws:
  IndexOutOfBoundsException - if the specified index is out of range



ensureCapacity
public void ensureCapacity(int mincap)(Code)
Increases my capacity, if necessary, to ensure that I can hold at least the number of elements specified by the minimum capacity argument without growing.



get
public short get(int index)(Code)
Returns the element at the specified position within me. By construction, the returned value will be between ArrayUnsignedByteList.MIN_VALUE and ArrayUnsignedByteList.MAX_VALUE , inclusive.
Parameters:
  index - the index of the element to return the value of the element at the specified position
throws:
  IndexOutOfBoundsException - if the specified index is out of range



removeElementAt
public short removeElementAt(int index)(Code)
Removes the element at the specified position in (optional operation). Any subsequent elements are shifted to the left, subtracting one from their indices. Returns the element that was removed. By construction, the returned value will be between ArrayUnsignedByteList.MIN_VALUE and ArrayUnsignedByteList.MAX_VALUE , inclusive.
Parameters:
  index - the index of the element to remove the value of the element that was removed
throws:
  UnsupportedOperationException - when this operation is not supported
throws:
  IndexOutOfBoundsException - if the specified index is out of range



set
public short set(int index, short element)(Code)
Replaces the element at the specified position in me with the specified element (optional operation). Throws IllegalArgumentException if element is less than ArrayUnsignedByteList.MIN_VALUE or greater than ArrayUnsignedByteList.MAX_VALUE .
Parameters:
  index - the index of the element to change
Parameters:
  element - the value to be stored at the specified position the value previously stored at the specified position
throws:
  UnsupportedOperationException - when this operation is not supported
throws:
  IndexOutOfBoundsException - if the specified index is out of range



size
public int size()(Code)



trimToSize
public void trimToSize()(Code)
Reduce my capacity, if necessary, to match my current ArrayUnsignedByteList.size size .



Methods inherited from org.apache.commons.collections.primitives.RandomAccessShortList
public void add(int index, short element)(Code)(Java Doc)
public boolean add(short element)(Code)(Java Doc)
public boolean addAll(int index, ShortCollection collection)(Code)(Java Doc)
public boolean equals(Object that)(Code)(Java Doc)
abstract public short get(int index)(Code)(Java Doc)
protected int getModCount()(Code)(Java Doc)
public int hashCode()(Code)(Java Doc)
protected void incrModCount()(Code)(Java Doc)
public int indexOf(short element)(Code)(Java Doc)
public ShortIterator iterator()(Code)(Java Doc)
public int lastIndexOf(short element)(Code)(Java Doc)
public ShortListIterator listIterator()(Code)(Java Doc)
public ShortListIterator listIterator(int index)(Code)(Java Doc)
public short removeElementAt(int index)(Code)(Java Doc)
public short set(int index, short element)(Code)(Java Doc)
abstract public int size()(Code)(Java Doc)
public ShortList subList(int fromIndex, int toIndex)(Code)(Java Doc)
public String toString()(Code)(Java Doc)

Methods inherited from org.apache.commons.collections.primitives.AbstractShortCollection
public boolean add(short element)(Code)(Java Doc)
public boolean addAll(ShortCollection c)(Code)(Java Doc)
public void clear()(Code)(Java Doc)
public boolean contains(short element)(Code)(Java Doc)
public boolean containsAll(ShortCollection c)(Code)(Java Doc)
public boolean isEmpty()(Code)(Java Doc)
abstract public ShortIterator iterator()(Code)(Java Doc)
public boolean removeAll(ShortCollection c)(Code)(Java Doc)
public boolean removeElement(short element)(Code)(Java Doc)
public boolean retainAll(ShortCollection c)(Code)(Java Doc)
abstract public int size()(Code)(Java Doc)
public short[] toArray()(Code)(Java Doc)
public short[] toArray(short[] a)(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(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.