Java Doc for NumberRange.java in  » GIS » GeoTools-2.4.1 » org » geotools » util » 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 » GIS » GeoTools 2.4.1 » org.geotools.util 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.geotools.util.NumberRange

All known Subclasses:   org.geotools.util.MeasurementRange,
NumberRange
public class NumberRange extends Range (Code)
A range of numbers. and are computed as usual, except that widening conversions will be applied as needed.
since:
   2.0
version:
   $Id: NumberRange.java 26601 2007-08-19 23:16:35Z desruisseaux $
author:
   Martin DesruisseauxNumberRange.getMinValueNumberRange.getMaxValue



Constructor Summary
public  NumberRange(byte minimum, byte maximum)
     Constructs an inclusive range of byte values.
public  NumberRange(byte minimum, boolean isMinIncluded, byte maximum, boolean isMaxIncluded)
     Constructs a range of byte values.
public  NumberRange(short minimum, short maximum)
     Constructs an inclusive range of short values.
public  NumberRange(short minimum, boolean isMinIncluded, short maximum, boolean isMaxIncluded)
     Constructs a range of short values.
public  NumberRange(int minimum, int maximum)
     Constructs an inclusive range of int values.
public  NumberRange(int minimum, boolean isMinIncluded, int maximum, boolean isMaxIncluded)
     Constructs a range of int values.
public  NumberRange(long minimum, long maximum)
     Constructs an inclusive range of long values.
public  NumberRange(long minimum, boolean isMinIncluded, long maximum, boolean isMaxIncluded)
     Constructs a range of long values.
public  NumberRange(float minimum, float maximum)
     Constructs an inclusive range of float values.
public  NumberRange(float minimum, boolean isMinIncluded, float maximum, boolean isMaxIncluded)
     Constructs a range of float values.
public  NumberRange(double minimum, double maximum)
     Constructs an inclusive range of double values.
public  NumberRange(double minimum, boolean isMinIncluded, double maximum, boolean isMaxIncluded)
     Constructs a range of double values.
 NumberRange(Class type, Comparable minimum, Comparable maximum)
     Constructs an inclusive range of Comparable objects.
public  NumberRange(Class type, Number minimum, Number maximum)
     Constructs an inclusive range of Number objects.
public  NumberRange(Class type, Number minimum, boolean isMinIncluded, Number maximum, boolean isMaxIncluded)
     Constructs a range of Number objects.
 NumberRange(Class type, Range range)
     Constructs a range with the same values than the specified range, casted to the specified type.
Parameters:
  type - The element class, usually one of Byte, Short,Integer, Long, Float or Double.
Parameters:
  range - The range to copy.
public  NumberRange(Range range)
     Constructs a range with the same type and the same values than the specified range. This is a copy constructor.
Parameters:
  range - The range to copy.

Method Summary
public  NumberRangecastTo(Class type)
     Casts this range to the specified type.
Parameters:
  type - The class to cast to.
public  booleancontains(Comparable value)
     Returns true if the specified value is within this range.
public  booleancontains(Number value)
     Returns true if the specified value is within this range.
public  booleancontains(Range range)
     Returns true if the supplied range is fully contained within this range.
 NumberRangeconvertAndCast(Range range, Class type)
     Casts the specified range to the specified type.
public  doublegetMaximum()
     Returns the as a double .
public  doublegetMaximum(boolean inclusive)
     Returns the with the specified inclusive or exclusive state.
public  doublegetMinimum()
     Returns the as a double .
public  doublegetMinimum(boolean inclusive)
     Returns the with the specified inclusive or exclusive state.
public  Rangeintersect(Range range)
     Returns the intersection of this range with the given range.
public  booleanintersects(Range range)
     Returns true if this range intersects the given range.
public  Range[]subtract(Range range)
     Returns the range of values that are in this range but not in the given range.
public  Rangeunion(Range range)
     Returns the union of this range with the given range.
public static  NumberRangewrap(Range range)
     Wraps the specified Range in a NumberRange object.


Constructor Detail
NumberRange
public NumberRange(byte minimum, byte maximum)(Code)
Constructs an inclusive range of byte values.
Parameters:
  minimum - The minimum value, inclusive.
Parameters:
  maximum - The maximum value, inclusive.



NumberRange
public NumberRange(byte minimum, boolean isMinIncluded, byte maximum, boolean isMaxIncluded)(Code)
Constructs a range of byte values.
Parameters:
  minimum - The minimum value.
Parameters:
  isMinIncluded - Defines whether the minimum value is included in the Range.
Parameters:
  maximum - The maximum value.
Parameters:
  isMaxIncluded - Defines whether the maximum value is included in the Range.



NumberRange
public NumberRange(short minimum, short maximum)(Code)
Constructs an inclusive range of short values.
Parameters:
  minimum - The minimum value, inclusive.
Parameters:
  maximum - The maximum value, inclusive.



NumberRange
public NumberRange(short minimum, boolean isMinIncluded, short maximum, boolean isMaxIncluded)(Code)
Constructs a range of short values.
Parameters:
  minimum - The minimum value.
Parameters:
  isMinIncluded - Defines whether the minimum value is included in the Range.
Parameters:
  maximum - The maximum value.
Parameters:
  isMaxIncluded - Defines whether the maximum value is included in the Range.



NumberRange
public NumberRange(int minimum, int maximum)(Code)
Constructs an inclusive range of int values.
Parameters:
  minimum - The minimum value, inclusive.
Parameters:
  maximum - The maximum value, inclusive.



NumberRange
public NumberRange(int minimum, boolean isMinIncluded, int maximum, boolean isMaxIncluded)(Code)
Constructs a range of int values.
Parameters:
  minimum - The minimum value.
Parameters:
  isMinIncluded - Defines whether the minimum value is included in the Range.
Parameters:
  maximum - The maximum value.
Parameters:
  isMaxIncluded - Defines whether the maximum value is included in the Range.



NumberRange
public NumberRange(long minimum, long maximum)(Code)
Constructs an inclusive range of long values.
Parameters:
  minimum - The minimum value, inclusive.
Parameters:
  maximum - The maximum value, inclusive.



NumberRange
public NumberRange(long minimum, boolean isMinIncluded, long maximum, boolean isMaxIncluded)(Code)
Constructs a range of long values.
Parameters:
  minimum - The minimum value.
Parameters:
  isMinIncluded - Defines whether the minimum value is included in the Range.
Parameters:
  maximum - The maximum value.
Parameters:
  isMaxIncluded - Defines whether the maximum value is included in the Range.



NumberRange
public NumberRange(float minimum, float maximum)(Code)
Constructs an inclusive range of float values.
Parameters:
  minimum - The minimum value, inclusive.
Parameters:
  maximum - The maximum value, inclusive.



NumberRange
public NumberRange(float minimum, boolean isMinIncluded, float maximum, boolean isMaxIncluded)(Code)
Constructs a range of float values.
Parameters:
  minimum - The minimum value.
Parameters:
  isMinIncluded - Defines whether the minimum value is included in the Range.
Parameters:
  maximum - The maximum value.
Parameters:
  isMaxIncluded - Defines whether the maximum value is included in the Range.



NumberRange
public NumberRange(double minimum, double maximum)(Code)
Constructs an inclusive range of double values.
Parameters:
  minimum - The minimum value, inclusive.
Parameters:
  maximum - The maximum value, inclusive.



NumberRange
public NumberRange(double minimum, boolean isMinIncluded, double maximum, boolean isMaxIncluded)(Code)
Constructs a range of double values.
Parameters:
  minimum - The minimum value.
Parameters:
  isMinIncluded - Defines whether the minimum value is included in the Range.
Parameters:
  maximum - The maximum value.
Parameters:
  isMaxIncluded - Defines whether the maximum value is included in the Range.



NumberRange
NumberRange(Class type, Comparable minimum, Comparable maximum)(Code)
Constructs an inclusive range of Comparable objects. This constructor is used by RangeSet.newRange only.
Parameters:
  type - The element class, usually one of Byte, Short,Integer, Long, Float or Double.
Parameters:
  minimum - The minimum value, inclusive.
Parameters:
  maximum - The maximum value, inclusive.



NumberRange
public NumberRange(Class type, Number minimum, Number maximum)(Code)
Constructs an inclusive range of Number objects.
Parameters:
  type - The element class, usually one of Byte, Short,Integer, Long, Float or Double.
Parameters:
  minimum - The minimum value, inclusive.
Parameters:
  maximum - The maximum value, inclusive.



NumberRange
public NumberRange(Class type, Number minimum, boolean isMinIncluded, Number maximum, boolean isMaxIncluded)(Code)
Constructs a range of Number objects.
Parameters:
  type - The element class, usually one of Byte, Short,Integer, Long, Float or Double.
Parameters:
  minimum - The minimum value.
Parameters:
  isMinIncluded - Defines whether the minimum value is included in the Range.
Parameters:
  maximum - The maximum value.
Parameters:
  isMaxIncluded - Defines whether the maximum value is included in the Range.



NumberRange
NumberRange(Class type, Range range) throws ClassCastException(Code)
Constructs a range with the same values than the specified range, casted to the specified type.
Parameters:
  type - The element class, usually one of Byte, Short,Integer, Long, Float or Double.
Parameters:
  range - The range to copy. The elements must be Number instances.
throws:
  ClassCastException - if some elements are not instances of Number.



NumberRange
public NumberRange(Range range) throws ClassCastException(Code)
Constructs a range with the same type and the same values than the specified range. This is a copy constructor.
Parameters:
  range - The range to copy. The elements must be Number instances.
throws:
  ClassCastException - if some elements are not instances of Number.
since:
   2.4




Method Detail
castTo
public NumberRange castTo(Class type)(Code)
Casts this range to the specified type.
Parameters:
  type - The class to cast to. Must be one of Byte, Short,Integer, Long, Float or Double. The casted range, or this if this range already usesthe specified type.



contains
public boolean contains(Comparable value)(Code)
Returns true if the specified value is within this range.



contains
public boolean contains(Number value)(Code)
Returns true if the specified value is within this range.



contains
public boolean contains(Range range)(Code)
Returns true if the supplied range is fully contained within this range.



convertAndCast
NumberRange convertAndCast(Range range, Class type)(Code)
Casts the specified range to the specified type. If this class is associated to a unit of measurement, then this method convert the range units to the same units than this instance. This method is overriden by MeasurementRange only in the way described above.
Parameters:
  type - The class to cast to. Must be one of Byte, Short,Integer, Long, Float or Double. The casted range, or range if no cast is needed.



getMaximum
public double getMaximum()(Code)
Returns the as a double . If this range is unbounded, then Double.POSITIVE_INFINITY is returned.



getMaximum
public double getMaximum(boolean inclusive)(Code)
Returns the with the specified inclusive or exclusive state. If this range is unbounded, then Double.POSITIVE_INFINITY is returned.
Parameters:
  inclusive - true for the maximum value inclusive,or false for the maximum value exclusive. The maximum value, inclusive or exclusive as requested.



getMinimum
public double getMinimum()(Code)
Returns the as a double . If this range is unbounded, then Double.NEGATIVE_INFINITY is returned.



getMinimum
public double getMinimum(boolean inclusive)(Code)
Returns the with the specified inclusive or exclusive state. If this range is unbounded, then Double.NEGATIVE_INFINITY is returned.
Parameters:
  inclusive - true for the minimum value inclusive,or false for the minimum value exclusive. The minimum value, inclusive or exclusive as requested.



intersect
public Range intersect(Range range)(Code)
Returns the intersection of this range with the given range. Widening conversions will be applied as needed. NumberRange



intersects
public boolean intersects(Range range)(Code)
Returns true if this range intersects the given range.



subtract
public Range[] subtract(Range range)(Code)
Returns the range of values that are in this range but not in the given range. NumberRange



union
public Range union(Range range)(Code)
Returns the union of this range with the given range. Widening conversions will be applied as needed. NumberRange



wrap
public static NumberRange wrap(Range range)(Code)
Wraps the specified Range in a NumberRange object. If the specified range is already an instance of NumberRange , then it is returned unchanged.
Parameters:
  range - The range to wrap The same range than range as a NumberRange object.



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