intarsys runtime library

de.intarsys.tools.number
Class NumberParser

java.lang.Object
  extended by de.intarsys.tools.number.NumberParser

public class NumberParser
extends Object

A parser able to read a definition of numbers.

The parser supports single numbers, enumeration of numbers and intervals.

 S ::= NumberString
 NumberString ::= ( Number | Interval) [ ";" (Number | Interval) ]*
 Interval ::= Number "-" Number
 Number ::= a valid number literal
 


Method Summary
 boolean isInteger()
           
static NumberWrapper parse(String value)
           
static NumberWrapper parseInteger(String value)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

parse

public static NumberWrapper parse(String value)
                           throws IOException
Throws:
IOException

parseInteger

public static NumberWrapper parseInteger(String value)
                                  throws IOException
Throws:
IOException

isInteger

public boolean isInteger()

intarsys runtime library

Copyright © 2012 intarsys consulting GmbH. All Rights Reserved.