gerrit_owners.PRED_$dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1 Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gerrit-owners Show documentation
Show all versions of gerrit-owners Show documentation
Gerrit Plugin that provides a Prolog predicate for enabling per directory code review requirements.
The newest version!
package gerrit_owners;
/*
'$dummy_1_src/main/prolog/gerrit_owners.pl'/1 defined in src/main/prolog/gerrit_owners.pl
This file is generated by Prolog Cafe.
PLEASE DO NOT EDIT!
*/
import com.googlecode.prolog_cafe.lang.*;
import com.googlecode.prolog_cafe.builtin.*;
import static gerrit_owners.PRED_$dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1.*;
final class PRED_$dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1 extends Predicate.P1 {
static final Operation $dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_sub_1 = new PRED_$dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_sub_1();
static final Operation $dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_1 = new PRED_$dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_1();
static final Operation $dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_2 = new PRED_$dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_2();
public PRED_$dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1(Term a1, Operation cont) {
this.arg1 = a1;
this.cont = cont;
}
@Override
public Operation exec(Prolog engine) {
engine.areg1 = arg1;
engine.cont = cont;
engine.setB0();
return engine.jtry1($dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_1, $dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_sub_1);
}
}
final class PRED_$dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_sub_1 extends Operation {
@Override
public Operation exec(Prolog engine) {
return engine.trust($dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_2);
}
}
final class PRED_$dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_1 extends Operation {
@Override
public Operation exec(Prolog engine) {
// '$dummy_1_src/main/prolog/gerrit_owners.pl'(A):-owner_approved(A),!,fail
Term a1, a2;
Operation p1, p2;
Operation cont;
a1 = engine.areg1;
cont = engine.cont;
// '$dummy_1_src/main/prolog/gerrit_owners.pl'(A):-['$get_level'(B),owner_approved(A),'$cut'(B),fail]
a2 = new VariableTerm(engine);
//START inline expansion of $get_level(a(2))
if (! a2.unify(new IntegerTerm(engine.B0), engine.trail)) {
return engine.fail();
}
//END inline expansion
p1 = new PRED_fail_0(cont);
p2 = new PRED_$cut_1(a2, p1);
return new PRED_owner_approved_1(a1, p2);
}
}
final class PRED_$dummy_1_src$002Fmain$002Fprolog$002Fgerrit_owners$002Epl_1_2 extends Operation {
@Override
public Operation exec(Prolog engine) {
// '$dummy_1_src/main/prolog/gerrit_owners.pl'(A):-true
Term a1;
Operation cont;
a1 = engine.areg1;
cont = engine.cont;
// '$dummy_1_src/main/prolog/gerrit_owners.pl'(A):-[]
return cont;
}
}