@fukurou
Java:
public class TrgArgue {
public UniqueItemSizeLimitedPriorityQueue commands = new UniqueItemSizeLimitedPriorityQueue();
public UniqueItemSizeLimitedPriorityQueue contextCommands = new UniqueItemSizeLimitedPriorityQueue();
public Boolean trgTolerance = false;
public int engageCommand(String s1){
// 0-> no engagement
// 1-> engaged boolean gate
// 2-> engaged argument
if (s1.isEmpty()){return 0;}
if (contextCommands.contains(s1)){
trgTolerance = true;
return 1;
}
// * commands.str
if (trgTolerance && !commands.contains(s1)){
trgTolerance = false;
return 0;
}
// counter point
return 2;
}
public void disable(){
// context commands are disabled till next engagement with a command
trgTolerance = false;
}
}