org.codehaus.jparsec
Class WithSource<T>

java.lang.Object
  extended by org.codehaus.jparsec.WithSource<T>

public final class WithSource<T>
extends Object

Parsed result with the matched source text.

Author:
Stepan Koltsov

Constructor Summary
WithSource(T value, String source)
           
 
Method Summary
 boolean equals(Object o)
           
 String getSource()
          Returns the underlying source text.
 T getValue()
          Returns the parsed result.
 int hashCode()
           
 String toString()
          Returns the underlying source text.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

WithSource

public WithSource(T value,
                  String source)
Method Detail

getValue

public T getValue()
Returns the parsed result.


getSource

public String getSource()
Returns the underlying source text. Never null.


toString

public String toString()
Returns the underlying source text.

Overrides:
toString in class Object

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2014. All rights reserved.