org.crsh.plugin
Class PropertyDescriptor<T>

java.lang.Object
  extended by org.crsh.plugin.PropertyDescriptor<T>

public abstract class PropertyDescriptor<T>
extends Object

Version:
$Revision$
Author:
Julien Viet

Field Summary
static Map<String,PropertyDescriptor<?>> ALL
          .
 T defaultValue
          .
 String description
          .
private static Map<String,PropertyDescriptor<?>> INTERNAL_ALL
          .
 String name
          .
 Class<T> type
          .
static PropertyDescriptor<Integer> VFS_REFRESH_PERIOD
          .
static PropertyDescriptor<TimeUnit> VFS_REFRESH_UNIT
          .
 
Constructor Summary
protected PropertyDescriptor(Class<T> type, String name, T defaultValue, String description)
           
 
Method Summary
protected abstract  T doParse(String s)
           
 T parse(String s)
           
 Property<T> toProperty(String s)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INTERNAL_ALL

private static final Map<String,PropertyDescriptor<?>> INTERNAL_ALL
.


ALL

public static final Map<String,PropertyDescriptor<?>> ALL
.


VFS_REFRESH_UNIT

public static final PropertyDescriptor<TimeUnit> VFS_REFRESH_UNIT
.


VFS_REFRESH_PERIOD

public static final PropertyDescriptor<Integer> VFS_REFRESH_PERIOD
.


type

public final Class<T> type
.


name

public final String name
.


defaultValue

public final T defaultValue
.


description

public final String description
.

Constructor Detail

PropertyDescriptor

protected PropertyDescriptor(Class<T> type,
                             String name,
                             T defaultValue,
                             String description)
Method Detail

parse

public final T parse(String s)
              throws NullPointerException,
                     IllegalArgumentException
Throws:
NullPointerException
IllegalArgumentException

toProperty

public final Property<T> toProperty(String s)
                             throws NullPointerException,
                                    IllegalArgumentException
Throws:
NullPointerException
IllegalArgumentException

doParse

protected abstract T doParse(String s)


Copyright © 2011 eXo Platform SAS. All Rights Reserved.