// get the trait classDef
ClassDefinition tdef = ruleBase.getTraitRegistry().getTrait( trait.getName() );
ClassDefinition cdef = ruleBase.getTraitRegistry().getTraitable( coreKlass.getName() );
if ( tdef == null ) {
throw new RuntimeDroolsException( "Unable to find Trait definition for class " + trait.getName() + ". It should have been DECLARED as a trait" );
}
if ( cdef == null ) {
throw new RuntimeDroolsException( "Unable to find Core class definition for class " + coreKlass.getName() + ". It should have been DECLARED as a trait" );
}
String proxyName = getProxyName( tdef, cdef );
String wrapperName = getPropertyWrapperName( tdef, cdef );