org.jboss.msc.value
Class ConstructedValue<T>
java.lang.Object
   org.jboss.msc.value.ConstructedValue<T>
org.jboss.msc.value.ConstructedValue<T>
- Type Parameters:
- T- the value type
- All Implemented Interfaces: 
- Value<T>
- public final class ConstructedValue<T> 
- extends Object- implements Value<T>
A value which is created on demand from a constructor.  Each call to getValue() will create a new instance,
 so if the same instance should be returned, this should be used in conjunction with CachedValue.
- Author:
- David M. Lloyd
 
| Method Summary | 
|  T | getValue()Get the actual value.
 | 
 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
 
ConstructedValue
public ConstructedValue(Value<Constructor<T>> constructorValue,
                        List<? extends Value<?>> parameters)
- Construct a new instance.
 
- Parameters:
- constructorValue- the constructor to use
- parameters- the parameters ot pass to the constructor
 
getValue
public T getValue()
           throws IllegalStateException
- Get the actual value.
 
- 
- Specified by:
- getValuein interface- Value<T>
 
- 
- Returns:
- the actual value
- Throws:
- IllegalStateException- if the value is time-sensitive and the current state does not allow retrieval.
 
Copyright © 2010 JBoss, a division of Red Hat, Inc.