Java Doc for IntRangeSet.java in  » Development » PCJ » bak » pcj » set » 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 » Development » PCJ » bak.pcj.set 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


bak.pcj.set.AbstractIntSet
   bak.pcj.set.IntRangeSet

IntRangeSet
public class IntRangeSet extends AbstractIntSet implements IntSortedSet,Cloneable,Serializable(Code)
This class represents range based sets of int values. The implementation is optimized for cases where most set elements fall into ranges of consecutive int values.

Implementation of IntSortedSet is supported from PCJ 1.2. Prior to 1.2, only IntSet was implemented.
See Also:   IntRange
author:
   Søren Bak
version:
   1.3 20-08-2003 22:24
since:
   1.0




Constructor Summary
public  IntRangeSet()
     Creates a new empty range set.
public  IntRangeSet(int[] a)
     Creates a new empty range set containing specified values.
public  IntRangeSet(IntCollection c)
     Creates a new range set with the same elements as a specified collection.

Method Summary
public  booleanadd(int v)
    
public  booleanaddAll(IntRangeSet c)
     Adds all the elements of a specified range set to this set.
Parameters:
  c - the set whose elements to add to thisset.
public  booleanaddAll(IntRange range)
     Adds a specified range to this set.
Parameters:
  range - the range to add to this set.
public  booleanaddAll(int first, int last)
     Adds a specified range to this set.
Parameters:
  first - the first value of the range to add to this set.
Parameters:
  last - the last value of the range to add to this set.
public  booleanaddAll(int[] a)
     Adds an array of int values to this set.
public  voidclear()
    
public  Objectclone()
     Returns a clone of this range set.
public  booleancontains(int v)
    
public  booleancontainsAll(IntRange range)
     Indicates whether all elements of a specified range is contained in this set.
Parameters:
  range - the range whose elements to test forcontainment.
public  intfirst()
    
public  inthashCode()
    
public  IntSortedSetheadSet(int to)
    
public  booleanisEmpty()
    
public  IntIteratoriterator()
    
public  intlast()
    
public  IntRange[]ranges()
     Returns the ranges of this set.
public  booleanremove(int v)
    
public  intsize()
    
public  IntSortedSetsubSet(int from, int to)
    
public  IntSortedSettailSet(int from)
    
public  int[]toArray(int[] a)
    
public  StringtoString()
    
public  voidtrimToSize()
    


Constructor Detail
IntRangeSet
public IntRangeSet()(Code)
Creates a new empty range set.



IntRangeSet
public IntRangeSet(int[] a)(Code)
Creates a new empty range set containing specified values.
Parameters:
  a - the values that the new set should contain.
throws:
  NullPointerException - if a is null.



IntRangeSet
public IntRangeSet(IntCollection c)(Code)
Creates a new range set with the same elements as a specified collection.
Parameters:
  c - the collection whose elements to add to the newset.
throws:
  NullPointerException - if c is null.




Method Detail
add
public boolean add(int v)(Code)



addAll
public boolean addAll(IntRangeSet c)(Code)
Adds all the elements of a specified range set to this set.
Parameters:
  c - the set whose elements to add to thisset. true if this set was modifiedas a result of adding the elements of c;returns false otherwise.
throws:
  NullPointerException - if c is null.
See Also:   IntRangeSet.add(int)
See Also:   IntRangeSet.addAll(IntRange)
See Also:   IntRangeSet.addAll(IntCollection)
See Also:   IntRangeSet.addAll(int,int)
See Also:   IntRangeSet.addAll(int[])



addAll
public boolean addAll(IntRange range)(Code)
Adds a specified range to this set.
Parameters:
  range - the range to add to this set. true if this set was modifiedas a result of adding the elements ofrange; returns false otherwise.
throws:
  NullPointerException - if range is null.
See Also:   IntRangeSet.add(int)
See Also:   IntRangeSet.addAll(IntRangeSet)
See Also:   IntRangeSet.addAll(IntCollection)
See Also:   IntRangeSet.addAll(int,int)
See Also:   IntRangeSet.addAll(int[])



addAll
public boolean addAll(int first, int last)(Code)
Adds a specified range to this set.
Parameters:
  first - the first value of the range to add to this set.
Parameters:
  last - the last value of the range to add to this set. true if this set was modifiedas a result of adding the values firstto last; returns falseotherwise.
throws:
  IllegalArgumentException - if first > last.



addAll
public boolean addAll(int[] a)(Code)
Adds an array of int values to this set.
Parameters:
  a - the array of int values to add to this set.
throws:
  NullPointerException - if a is null.
See Also:   IntRangeSet.add(int)
See Also:   IntRangeSet.addAll(IntRange)
See Also:   IntRangeSet.addAll(IntRangeSet)
See Also:   IntRangeSet.addAll(IntCollection)
See Also:   IntRangeSet.addAll(int,int)



clear
public void clear()(Code)



clone
public Object clone()(Code)
Returns a clone of this range set. a clone of this range set.
since:
   1.1



contains
public boolean contains(int v)(Code)



containsAll
public boolean containsAll(IntRange range)(Code)
Indicates whether all elements of a specified range is contained in this set.
Parameters:
  range - the range whose elements to test forcontainment. true if all the elements of rangeare contained in this collection; returnsfalse otherwise.
throws:
  NullPointerException - if range is null.
See Also:   IntRangeSet.containsAll(IntCollection)



first
public int first()(Code)

since:
   1.2



hashCode
public int hashCode()(Code)



headSet
public IntSortedSet headSet(int to)(Code)

since:
   1.2



isEmpty
public boolean isEmpty()(Code)



iterator
public IntIterator iterator()(Code)



last
public int last()(Code)

since:
   1.2



ranges
public IntRange[] ranges()(Code)
Returns the ranges of this set. None of the ranges returned will overlap or be adjacent. the ranges of this set. The returned array isa fresh copy that can be modified withoutmodifying this set.



remove
public boolean remove(int v)(Code)



size
public int size()(Code)



subSet
public IntSortedSet subSet(int from, int to)(Code)

since:
   1.2



tailSet
public IntSortedSet tailSet(int from)(Code)

since:
   1.2



toArray
public int[] toArray(int[] a)(Code)



toString
public String toString()(Code)



trimToSize
public void trimToSize()(Code)



Methods inherited from bak.pcj.set.AbstractIntSet
public boolean equals(Object obj)(Code)(Java Doc)
public int hashCode()(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.