Package org.kie.builder.impl

Examples of org.kie.builder.impl.KieContainerImpl


    void afterBeanDiscovery(@Observes AfterBeanDiscovery abd,
                            BeanManager bm) {
        if ( kProject != null ) {
            // if kProjects null, processInjectionTarget was not called, so beans to create
           
            KieContainerImpl kContainer = new KieContainerImpl( kProject, null );
           
            if ( kBaseNames != null ) {
                for ( String kBaseQName : kBaseNames ) {
                    KieBaseModel kBaseModel = kProject.getKieBaseModel( kBaseQName );
                    if ( kBaseModel == null ) {
View Full Code Here


    }

    public void addKBaseBean(AfterBeanDiscovery abd,
                             KieCDIEntry entry) {
        ReleaseId releaseId = entry.getkGAV();
        KieContainerImpl kieContainer = classpathKContainer; // default to classpath, but allow it to be overriden
        if ( releaseId != null ) {
            kieContainer = (KieContainerImpl) gavs.get(releaseId);
            if ( kieContainer == null ) {
                log.error( "Unable to create KBase({}), could not retrieve KieContainer for ReleaseId {}",
                           entry.getKieTypeName(),
                           releaseId.toString() );
                return;
            }
        }
        KieProject kProject = kieContainer.getKieProject();

        String kBaseQName = entry.getKieTypeName();
        KieBaseModel kBaseModel = kProject.getKieBaseModel( kBaseQName );
        if ( kBaseModel == null ) {
            log.error( "Annotation @KBase({}) found, but no KieBaseModel exist.\nEither the required kproject.xml does not exist, was corrupted, or mising the KieBase entry",
View Full Code Here

    }

    public void addKSessionBean(AfterBeanDiscovery abd,
                                KieCDIEntry entry) {
        ReleaseId releaseId = entry.getkGAV();
        KieContainerImpl kieContainer = classpathKContainer; // default to classpath, but allow it to be overriden
        if ( releaseId != null ) {
            kieContainer = (KieContainerImpl) gavs.get(releaseId);
            if ( kieContainer == null ) {
                log.error( "Unable to create KSession({}), could not retrieve KieContainer for ReleaseId {}",
                           entry.getKieTypeName(),
                           releaseId.toString() );
                return;
            }
        }
        KieProject kProject = kieContainer.getKieProject();

        String kSessionName = entry.getKieTypeName();
        KieSessionModel kSessionModel = kProject.getKieSessionModel( kSessionName );
        if ( kSessionModel == null ) {
            log.error( "Annotation @KSession({}) found, but no KieSessioneModel exist.\nEither the required kproject.xml does not exist, was corrupted, or mising the KieBase entry",
View Full Code Here

    }

    public void addKBaseBean(AfterBeanDiscovery abd,
                             KieCDIEntry entry) {
        ReleaseId releaseId = entry.getkGAV();
        KieContainerImpl kieContainer = classpathKContainer; // default to classpath, but allow it to be overriden
        if ( releaseId != null ) {
            kieContainer = (KieContainerImpl) gavs.get(releaseId);
            if ( kieContainer == null ) {
                log.error( "Unable to create KBase({}), could not retrieve KieContainer for ReleaseId {}",
                           entry.getKieTypeName(),
                           releaseId.toString() );
                return;
            }
        }
        KieProject kProject = kieContainer.getKieProject();

        String kBaseQName = entry.getKieTypeName();
        KieBaseModel kBaseModel = kProject.getKieBaseModel( kBaseQName );
        if ( kBaseModel == null ) {
            log.error( "Annotation @KBase({}) found, but no KieBaseModel exist.\nEither the required kproject.xml does not exist, was corrupted, or mising the KieBase entry",
View Full Code Here

    }

    public void addKSessionBean(AfterBeanDiscovery abd,
                                KieCDIEntry entry) {
        ReleaseId releaseId = entry.getkGAV();
        KieContainerImpl kieContainer = classpathKContainer; // default to classpath, but allow it to be overriden
        if ( releaseId != null ) {
            kieContainer = (KieContainerImpl) gavs.get(releaseId);
            if ( kieContainer == null ) {
                log.error( "Unable to create KSession({}), could not retrieve KieContainer for ReleaseId {}",
                           entry.getKieTypeName(),
                           releaseId.toString() );
                return;
            }
        }
        KieProject kProject = kieContainer.getKieProject();

        String kSessionName = entry.getKieTypeName();
        KieSessionModel kSessionModel = kProject.getKieSessionModel( kSessionName );
        if ( kSessionModel == null ) {
            log.error( "Annotation @KSession({}) found, but no KieSessioneModel exist.\nEither the required kproject.xml does not exist, was corrupted, or mising the KieBase entry",
View Full Code Here

    }

    public void addKContainerBean(AfterBeanDiscovery abd,
                                  KieCDIEntry entry) {       
        ReleaseId releaseId = entry.getReleaseId();
        KieContainerImpl kieContainer = classpathKContainer; // default to classpath, but allow it to be overriden
        if ( releaseId != null ) { //&& !StringUtils.isEmpty( releaseId.getGroupId() ) && !StringUtils.isEmpty( releaseId.getArtifactId() ) && !StringUtils.isEmpty( releaseId.getArtifactId())) {
            kieContainer = (KieContainerImpl) gavs.get(releaseId);
            if ( kieContainer == null ) {
                log.error( "Could not retrieve KieContainer for ReleaseId {}",
                           entry.getValue(),
View Full Code Here

   
   
    public void addKBaseBean(AfterBeanDiscovery abd,
                             KieCDIEntry entry) {
        ReleaseId releaseId = entry.getReleaseId();
        KieContainerImpl kieContainer = classpathKContainer; // default to classpath, but allow it to be overriden
        if ( releaseId != null ) {
            kieContainer = (KieContainerImpl) gavs.get(releaseId);
            if ( kieContainer == null ) {
                log.error( "Unable to create @KBase({}), could not retrieve KieContainer for ReleaseId {}",
                           entry.getValue(),
                           releaseId.toString() );
                return;
            }
        }
        KieProject kProject = kieContainer.getKieProject();

        KieBaseModel kBaseModel = null;
        String kBaseQName = entry.getValue();
        if ( StringUtils.isEmpty( kBaseQName  )) {
            kBaseModel = kProject.getDefaultKieBaseModel();
View Full Code Here

    }

    public void addKSessionBean(AfterBeanDiscovery abd,
                                KieCDIEntry entry) {
        ReleaseId releaseId = entry.getReleaseId();
        KieContainerImpl kieContainer = classpathKContainer; // default to classpath, but allow it to be overriden
        if ( releaseId != null ) {
            kieContainer = (KieContainerImpl) gavs.get(releaseId);
            if ( kieContainer == null ) {
                log.error( "Unable to create KSession({}), could not retrieve KieContainer for ReleaseId {}",
                           entry.getValue(),
                           releaseId.toString() );
                return;
            }
        }
        KieProject kProject = kieContainer.getKieProject();

        String kSessionName = entry.getValue();
        KieSessionModel kSessionModel = null;
        if ( StringUtils.isEmpty( kSessionName  )) {
            kSessionModel = ( entry.getType() == KieSession.class ) ? kProject.getDefaultKieSession() : kProject.getDefaultStatelessKieSession();
View Full Code Here

TOP

Related Classes of org.kie.builder.impl.KieContainerImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.