Package org.ggp.base.util.gdl.grammar

Examples of org.ggp.base.util.gdl.grammar.GdlRule


            if ( constant.getValue().equals("does") )
            {
                for ( GdlRule rule : getInstantiations(GdlPool.getConstant("legal")) )
                {
                    GdlSentence head = GdlPool.getRelation(GdlPool.getConstant("does"), rule.getHead().getBody());
                    GdlRule equivalentDoesRule = GdlPool.getRule(head);
                    instantiations.get(constant).add(equivalentDoesRule);
                }
            }
            else
            {
View Full Code Here


    private Map<GdlConstant, List<GdlRule>> recordTemplates(List<Gdl> description)
    {
        Map<GdlConstant, List<GdlRule>> templates = new HashMap<GdlConstant, List<GdlRule>>();
        for ( Gdl gdl : description )
        {
            GdlRule rule = (gdl instanceof GdlRule) ? (GdlRule) gdl : GdlPool.getRule((GdlSentence) gdl);
            GdlConstant name = rule.getHead().getName();

            if ( !name.getValue().equals("base") )
            {
                if ( !templates.containsKey(name) )
                {
View Full Code Here

TOP

Related Classes of org.ggp.base.util.gdl.grammar.GdlRule

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.