protected T newInstance(final Class<? extends T> cls,final IIndexManager indexManager,final NT nt,final Properties properties){
  if (cls == null)   throw new IllegalArgumentException();
  if (indexManager == null)   throw new IllegalArgumentException();
  if (nt == null)   throw new IllegalArgumentException();
  if (properties == null)   throw new IllegalArgumentException();
  final Constructor<? extends T> ctor;
  try {
    ctor=cls.getConstructor(new Class[]{IIndexManager.class,String.class,Long.class,Properties.class});
  }
 catch (  Exception e) {
    throw new RuntimeException("No appropriate ctor?: cls=" + cls.getName() + " : "+ e,e);
  }
  final T r;
  try {
    r=ctor.newInstance(new Object[]{indexManager,nt.getName(),nt.getTimestamp(),properties});
    r.init();
    if (INFO) {
      log.info("new instance: " + r);
    }
    return r;
  }
 catch (  Exception ex) {
    throw new RuntimeException("Could not instantiate relation: " + ex,ex);
  }
}

protected T newInstance ( final Class < ? extends T > cls , final IIndexManager indexManager , final NT nt , final Properties properties ) { if ( cls == null ) throw new IllegalArgumentException ( ) ; if ( indexManager == null ) throw new IllegalArgumentException ( ) ; if ( nt == null ) throw new IllegalArgumentException ( ) ; if ( properties == null ) throw new IllegalArgumentException ( ) ; final Constructor < ? extends T > ctor ; try { ctor = cls . getConstructor ( new Class [ ] { IIndexManager . class , String . class , Long . class , Properties . class } ) ; } catch ( Exception e ) { throw new RuntimeException ( "No appropriate ctor?: cls=" + cls . getName ( ) + " : " + e , e ) ; } final T r ; try { r = ctor . newInstance ( new Object [ ] { indexManager , nt . getName ( ) , nt . getTimestamp ( ) , properties } ) ; r . init ( ) ; if ( INFO ) { log . info ( "new instance: " + r ) ; } return r ; } catch ( Exception ex ) { throw new RuntimeException ( "Could not instantiate relation: " + ex , ex ) ; } }
create a new view of the relation .
