All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.drools.rule.builder.EntryPointBuilder Maven / Gradle / Ivy

There is a newer version: 10.0.0
Show newest version
package org.drools.rule.builder;

import org.drools.lang.descr.BaseDescr;
import org.drools.lang.descr.EntryPointDescr;
import org.drools.rule.EntryPoint;
import org.drools.rule.Pattern;
import org.drools.rule.RuleConditionElement;

/**
 * A class capable of building entry point instances
 * 
 * @author etirelli
 *
 */
public class EntryPointBuilder
    implements
    RuleConditionBuilder {

    public RuleConditionElement build(RuleBuildContext context,
                                      BaseDescr descr) {
        return build( context,
                      descr,
                      null );
    }

    public RuleConditionElement build(RuleBuildContext context,
                                      BaseDescr descr,
                                      Pattern prefixPattern) {
        final EntryPointDescr entryDescr = (EntryPointDescr) descr;

        return new EntryPoint( entryDescr.getEntryId() );
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy