return false;
}
private int resetBeVerb(DEPState state)
{
DEPNode lambda = state.getLambda();
DEPNode beta = state.getBeta();
if (isOutOfDomain(state, lambda, beta))
return -1;
DEPNode beVerb = lambda.getHead();
String subj = lambda.getLabel();
int vType = 0;
if (beta.isPos(CTLibEn.POS_VBN))
vType = 1;
else if (beta.isPos(CTLibEn.POS_VBG))
vType = 2;
else if (beta.isPos(CTLibEn.POS_VBD))
{
String p2 = beta.getFeat(DEPLib.FEAT_POS2);
if (p2 != null && p2.equals(CTLibEn.POS_VBN)) vType = 1;
}
if (vType > 0 && subj != null && (DEPLibEn.isSubject(subj) || (subj.equals(DEPLibEn.DEP_ATTR) && hasNoDependent(beVerb, 1, beta.id, state))))
{
DEPNode gHead = beVerb.getHead();
// be - subj(lambda) - vb[ng](beta)
if (beVerb.isLemma(ENAux.BE) && beVerb.id < lambda.id && (gHead == null || gHead.id < beVerb.id))
{
int i, size = beta.id;
DEPNode node;
for (i=beVerb.id+1; i<size; i++)
{
node = state.getNode(i);
if (node.isDependentOf(beVerb))
node.setHead(beta);
}
clearPreviousDependents(beVerb, state);
beVerb.setHead(beta);