Search in sources :

Example 26 with StringFunctionAtom

use of org.apache.stanbol.rules.manager.atoms.StringFunctionAtom in project stanbol by apache.

the class RuleParserImpl method upperCaseAtom.

public final UpperCaseAtom upperCaseAtom() throws ParseException {
    StringFunctionAtom arg;
    jj_consume_token(UPPERCASE);
    jj_consume_token(LPAR);
    arg = stringFunctionAtom();
    jj_consume_token(RPAR);
    {
        if (true)
            return new UpperCaseAtom(arg);
    }
    throw new Error("Missing return statement in function");
}
Also used : StringFunctionAtom(org.apache.stanbol.rules.manager.atoms.StringFunctionAtom) UpperCaseAtom(org.apache.stanbol.rules.manager.atoms.UpperCaseAtom)

Example 27 with StringFunctionAtom

use of org.apache.stanbol.rules.manager.atoms.StringFunctionAtom in project stanbol by apache.

the class RuleParserImpl method createLabelAtom.

public final StringFunctionAtom createLabelAtom() throws ParseException {
    StringFunctionAtom stringFunctionAtom;
    jj_consume_token(CREATE_LABEL);
    jj_consume_token(LPAR);
    stringFunctionAtom = stringFunctionAtom();
    jj_consume_token(RPAR);
    {
        if (true)
            return new CreateLabelAtom(stringFunctionAtom);
    }
    throw new Error("Missing return statement in function");
}
Also used : StringFunctionAtom(org.apache.stanbol.rules.manager.atoms.StringFunctionAtom) CreateLabelAtom(org.apache.stanbol.rules.manager.atoms.CreateLabelAtom)

Example 28 with StringFunctionAtom

use of org.apache.stanbol.rules.manager.atoms.StringFunctionAtom in project stanbol by apache.

the class RuleParserImpl method newLiteralAtom.

public final NewLiteralAtom newLiteralAtom() throws ParseException {
    IObjectAtom arg1;
    StringFunctionAtom arg2;
    jj_consume_token(NEW_LITERAL);
    jj_consume_token(LPAR);
    arg1 = iObject();
    jj_consume_token(COMMA);
    arg2 = stringFunctionAtom();
    jj_consume_token(RPAR);
    {
        if (true)
            return new NewLiteralAtom(arg1, arg2);
    }
    throw new Error("Missing return statement in function");
}
Also used : StringFunctionAtom(org.apache.stanbol.rules.manager.atoms.StringFunctionAtom) NewLiteralAtom(org.apache.stanbol.rules.manager.atoms.NewLiteralAtom) IObjectAtom(org.apache.stanbol.rules.manager.atoms.IObjectAtom)

Example 29 with StringFunctionAtom

use of org.apache.stanbol.rules.manager.atoms.StringFunctionAtom in project stanbol by apache.

the class RuleParserImpl method concatAtom.

public final ConcatAtom concatAtom() throws ParseException {
    StringFunctionAtom arg1;
    StringFunctionAtom arg2;
    jj_consume_token(CONCAT);
    jj_consume_token(LPAR);
    arg1 = stringFunctionAtom();
    jj_consume_token(COMMA);
    arg2 = stringFunctionAtom();
    jj_consume_token(RPAR);
    {
        if (true)
            return new ConcatAtom(arg1, arg2);
    }
    throw new Error("Missing return statement in function");
}
Also used : StringFunctionAtom(org.apache.stanbol.rules.manager.atoms.StringFunctionAtom) ConcatAtom(org.apache.stanbol.rules.manager.atoms.ConcatAtom)

Example 30 with StringFunctionAtom

use of org.apache.stanbol.rules.manager.atoms.StringFunctionAtom in project stanbol by apache.

the class RuleParserImpl method endsWithAtom.

public final ComparisonAtom endsWithAtom() throws ParseException {
    RuleAtom ruleAtom;
    StringFunctionAtom arg;
    StringFunctionAtom stringFunctionAtom;
    jj_consume_token(ENDS_WITH);
    jj_consume_token(LPAR);
    arg = stringFunctionAtom();
    jj_consume_token(COMMA);
    stringFunctionAtom = stringFunctionAtom();
    jj_consume_token(RPAR);
    {
        if (true)
            return new EndsWithAtom(arg, stringFunctionAtom);
    }
    throw new Error("Missing return statement in function");
}
Also used : StringFunctionAtom(org.apache.stanbol.rules.manager.atoms.StringFunctionAtom) EndsWithAtom(org.apache.stanbol.rules.manager.atoms.EndsWithAtom) RuleAtom(org.apache.stanbol.rules.base.api.RuleAtom)

Aggregations

StringFunctionAtom (org.apache.stanbol.rules.manager.atoms.StringFunctionAtom)38 ArrayList (java.util.ArrayList)15 Expression (org.apache.clerezza.rdf.core.sparql.query.Expression)11 ClerezzaSparqlObject (org.apache.stanbol.rules.adapters.clerezza.ClerezzaSparqlObject)11 ConstructQuery (org.apache.clerezza.rdf.core.sparql.query.ConstructQuery)10 SPARQLObject (org.apache.stanbol.rules.base.api.SPARQLObject)10 RuleAtomCallExeption (org.apache.stanbol.rules.base.api.RuleAtomCallExeption)9 SPARQLFunction (org.apache.stanbol.rules.adapters.sparql.SPARQLFunction)8 IRI (org.apache.clerezza.commons.rdf.IRI)7 FunctionCall (org.apache.clerezza.rdf.core.sparql.query.FunctionCall)7 IObjectAtom (org.apache.stanbol.rules.manager.atoms.IObjectAtom)6 BuiltInCall (org.apache.clerezza.rdf.core.sparql.query.BuiltInCall)4 UnavailableRuleObjectException (org.apache.stanbol.rules.base.api.UnavailableRuleObjectException)4 UnsupportedTypeForExportException (org.apache.stanbol.rules.base.api.UnsupportedTypeForExportException)4 NumericFunctionAtom (org.apache.stanbol.rules.manager.atoms.NumericFunctionAtom)4 ArgumentSWRLAtom (org.apache.stanbol.rules.adapters.swrl.ArgumentSWRLAtom)3 HigherOrderSWRLAtom (org.apache.stanbol.rules.adapters.swrl.HigherOrderSWRLAtom)3 OWLDataFactory (org.semanticweb.owlapi.model.OWLDataFactory)3 SWRLArgument (org.semanticweb.owlapi.model.SWRLArgument)3 SWRLAtom (org.semanticweb.owlapi.model.SWRLAtom)3