org.gcube.common.clients.config
Class Property<T>

java.lang.Object
  extended by org.gcube.common.clients.config.Property<T>
Type Parameters:
T - the type of the property value

public class Property<T>
extends Object

A custom configuration property for proxies.

Author:
Fabio Simeoni
See Also:
AbstractStatefulBuilder, AbstractStatelessBuilder

Field Summary
static String sticky_session
          The name of the sticky session property Property.
static String timeout
          The name of the call timeout Property.
 
Constructor Summary
Property(String name, T value)
          Creates an instance with a name and a value.
 
Method Summary
 String name()
          Returns the name of the property.
static Property<Boolean> sticky_session(boolean value)
          Return the sticky session Property.
static Property<Long> timeout(long value)
          Return the call timeout Property.
static Property<Long> timeout(long duration, TimeUnit unit)
          Return the call timeout Property.
 T value()
          Returns the value of the property.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

timeout

public static final String timeout
The name of the call timeout Property.

See Also:
Constant Field Values

sticky_session

public static final String sticky_session
The name of the sticky session property Property.

See Also:
Constant Field Values
Constructor Detail

Property

public Property(String name,
                T value)
Creates an instance with a name and a value.

Parameters:
name - the name
value - the value
Method Detail

timeout

public static Property<Long> timeout(long value)
Return the call timeout Property.

Parameters:
value - the property value
Returns:
the property

timeout

public static Property<Long> timeout(long duration,
                                     TimeUnit unit)
Return the call timeout Property.

Parameters:
duration - the duration of the timeout
unit - the time unit of the timeout
Returns:
the property

sticky_session

public static Property<Boolean> sticky_session(boolean value)
Return the sticky session Property.

Parameters:
value - the property value
Returns:
the property

name

public String name()
Returns the name of the property.

Returns:
the name

value

public T value()
Returns the value of the property.

Returns:
the value


Copyright © 2012. All Rights Reserved.