Search in sources :

Example 1 with Annotated

use of org.drools.core.rule.Annotated in project drools by kiegroup.

the class TypeDeclarationCache method createTypeDeclarationForBean.

private TypeDeclaration createTypeDeclarationForBean(Class<?> cls) {
    Annotated annotated = new Annotated.ClassAdapter(cls);
    TypeDeclaration typeDeclaration = TypeDeclaration.createTypeDeclarationForBean(cls, annotated, kbuilder.getBuilderConfiguration().getPropertySpecificOption());
    String namespace = ClassUtils.getPackage(cls);
    PackageRegistry pkgRegistry = kbuilder.getOrCreatePackageRegistry(new PackageDescr(namespace));
    processMvelBasedAccessors(kbuilder, pkgRegistry, annotated, typeDeclaration);
    return typeDeclaration;
}
Also used : Annotated(org.drools.core.rule.Annotated) PackageRegistry(org.drools.compiler.compiler.PackageRegistry) PackageDescr(org.drools.compiler.lang.descr.PackageDescr) TypeDeclaration(org.drools.core.rule.TypeDeclaration)

Aggregations

PackageRegistry (org.drools.compiler.compiler.PackageRegistry)1 PackageDescr (org.drools.compiler.lang.descr.PackageDescr)1 Annotated (org.drools.core.rule.Annotated)1 TypeDeclaration (org.drools.core.rule.TypeDeclaration)1