org.gcube.data.trees.patterns
Class URIPattern

java.lang.Object
  extended by org.gcube.data.trees.patterns.AbstractPattern
      extended by org.gcube.data.trees.patterns.LeafPattern<URI,Constraint<? super URI>>
          extended by org.gcube.data.trees.patterns.URIPattern
All Implemented Interfaces:
Serializable, Pattern

public class URIPattern
extends LeafPattern<URI,Constraint<? super URI>>

A Pattern that matches the value of Leaf against a given URI Constraint.

Author:
Fabio Simeoni
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.gcube.data.trees.patterns.LeafPattern
constraint
 
Constructor Summary
URIPattern(Constraint<? super URI> c)
          Creates an instance with a given constraint.
 
Method Summary
 String name()
          Returns the name of the pattern.
 String toString()
          
protected  URI valueOf(String s)
          Returns the typed equivalent of a leaf's value.
 
Methods inherited from class org.gcube.data.trees.patterns.LeafPattern
constraint, equals, hashCode, matches, prune
 
Methods inherited from class org.gcube.data.trees.patterns.AbstractPattern
idPattern, setIdPattern
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

URIPattern

public URIPattern(Constraint<? super URI> c)
Creates an instance with a given constraint.

Parameters:
c - the constraint.
Method Detail

valueOf

protected URI valueOf(String s)
               throws Exception
Returns the typed equivalent of a leaf's value.

Specified by:
valueOf in class LeafPattern<URI,Constraint<? super URI>>
Parameters:
s - the value
Returns:
the typed value
Throws:
Exception

toString

public String toString()

Overrides:
toString in class LeafPattern<URI,Constraint<? super URI>>

name

public String name()
Description copied from class: LeafPattern
Returns the name of the pattern.

Specified by:
name in class LeafPattern<URI,Constraint<? super URI>>
Returns:
the name


Copyright © 2012. All Rights Reserved.