org.terrier.utility
Class Wrapper<T>

java.lang.Object
  extended by org.terrier.utility.Wrapper<T>
Type Parameters:
T - type that is wrapped
Direct Known Subclasses:
SplitAwareWrapper, Wrapper.IntObjectWrapper

public class Wrapper<T>
extends java.lang.Object

Generic mutatble Wrapper class - allows non-mutatable class to be wrapped in mutatable classes, and re-accessed later.

Since:
2.2
Author:
Richard McCreadie

Nested Class Summary
static class Wrapper.IntObjectWrapper<K>
          IntObjectWrapper class
 
Field Summary
protected  T o
           
 
Constructor Summary
Wrapper()
          default constructor
Wrapper(T O)
          constructor
 
Method Summary
 Wrapper<T> createWrapper(T O)
          get created wrapper
 T getObject()
          return object
 void setObject(T O)
          set object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

o

protected T o
Constructor Detail

Wrapper

public Wrapper()
default constructor


Wrapper

public Wrapper(T O)
constructor

Parameters:
O -
Method Detail

getObject

public T getObject()
return object

Returns:
object

setObject

public void setObject(T O)
set object

Parameters:
O -

createWrapper

public Wrapper<T> createWrapper(T O)
get created wrapper

Parameters:
O -
Returns:
wrapper


Terrier 3.5. Copyright © 2004-2011 University of Glasgow