public void apply (final InFlowWorkItem wi) throws ApplyException { if (this.childExpressionId == null) return; getExpressionPool().apply(this.childExpressionId, wi); }
public void apply (final InFlowWorkItem wi) throws ApplyException { this.childCount = getChildren().size(); this.storeItself(); //log.debug("apply() childCount is "+this.childCount); java.util.Iterator it = getChildren().iterator(); while (it.hasNext()) { final FlowExpressionId fei = (FlowExpressionId)it.next(); getExpressionPool().apply(fei, wi); } }
public void run () { final FlowExpressionId fei = (FlowExpressionId)o; final InFlowWorkItem workitem = (InFlowWorkItem)wi.clone(); try { getExpressionPool().apply(fei, workitem); } catch (final Throwable t) { log.info ("Failed to apply child", t); ListExpression.this.childResults.put(ii, t); } } }).start();
/** * Applies the given child. This task is delegated to the sync expression * where all the synchronization (as the name implies) takes place. */ public synchronized void applyChild (final SynchableExpression se, final FlowExpressionId child, final InFlowWorkItem wi) throws ApplyException { if (this.isSyncOver()) return; se.getExpressionPool().apply(child, wi); }
public void apply (final InFlowWorkItem wi) throws ApplyException { if (log.isDebugEnabled()) log.debug("apply() children : "+this.getChildren().size()); if (this.getChildren().size() < 1) { applyWithRawValue(wi); return; } final FlowExpressionId fei = (FlowExpressionId)getChildren().get(0); getExpressionPool().apply(fei, wi); }
public void apply (final InFlowWorkItem wi) throws ApplyException { if (getChildren().size() < 1) { applyToParent(wi); return; } final double d = Math.random(); final int index = (int)(d * (double)getChildren().size()); if (log.isDebugEnabled()) log.debug("apply() d is "+d+" index is "+index); final FlowExpressionId nextId = (FlowExpressionId)getChildren().get(index); getExpressionPool().apply(nextId, wi); }
public void apply (final InFlowWorkItem wi) throws ApplyException { if (getChildren().size() < 2) { throw new ApplyException ("'cons' and 'xons' must have 2 children. "+ getChildren().size()+" found."); } final FlowExpressionId fei = (FlowExpressionId)getChildren().get(0); getExpressionPool().apply(fei, wi); }
public void apply (final InFlowWorkItem wi) throws ApplyException { this.results = new java.util.ArrayList(this.childrenCount()); if (this.getChildren().size() < childrenCount()) throw new ApplyException("not enough children"); final FlowExpressionId fei = (FlowExpressionId)getChildren().get(0); getExpressionPool().apply(fei, wi); }
public void apply (final InFlowWorkItem wi) throws ApplyException { //log.debug("apply()"); if (this.getChildren().size() < 1) { ValueUtils.setResult(wi, new IntegerAttribute(0)); applyToParent(wi); return; } final FlowExpressionId fei = (FlowExpressionId)getChildren().get(0); getExpressionPool().apply(fei, wi); }
public void apply (final InFlowWorkItem wi) throws ApplyException { //log.debug("apply()"); if (getChildExpressionId() == null) { applyToParent(wi); return; } getExpressionPool().apply(getChildExpressionId(), wi); }
public void apply (final InFlowWorkItem wi) throws ApplyException { //log.debug("apply()"); if (getChildren() == null || getChildren().size() < 1) { applyToParent(wi); return; } setCurrentId(0); this.storeItself(); getExpressionPool().apply ((FlowExpressionId)getChildren().get(getCurrentId()), wi); }
getExpressionPool().apply(fei, wi);
getExpressionPool().apply(fei, wi);
public void run () { try { final FlowExpression child = getExpressionPool() .fetch(ForgetExpression.this.getChildExpressionId()); child.setParent(null); getExpressionPool().apply(child.getId(), forgottenWi); } catch (final Throwable t) { log.info ("apply() error in forgotten child (branch)", t); } } }).start();
public void apply (final InFlowWorkItem wi) throws ApplyException { //this.debugDump(); if (log.isDebugEnabled()) { log.debug("apply() "+getId()); log.debug("apply() environmentId "+getEnvironmentId()); log.debug("apply() has child ? "+(getChildExpressionId() != null)); } if (getChildExpressionId() == null) { try { this.reply(wi); } catch (final ReplyException e) { throw new ApplyException ("Failed to determine or set value", e); } } else { getExpressionPool().apply(getChildExpressionId(), wi); } }
getExpressionPool().apply(next, wi);
private void applyNextChild (final InFlowWorkItem wi) throws ApplyException { //log.debug("applyNextChild() childIndex : "+this.childIndex); final Object child = this.getChildren().get(this.childIndex); this.childIndex++; this.storeItself(); if (child instanceof String) { final String s = substituteText((String)child, wi); //log.debug("applyNextChild() s is >"+s+"<"); this.tag(wi); ValueUtils.setResult(wi, new StringAttribute(s)); try { this.reply(wi); } catch (final ReplyException e) { throw new ApplyException("failed to go beyond next child", e); } return; } getExpressionPool().apply((FlowExpressionId)child, wi); }
"redoing '"+theDoName()+"'"); getExpressionPool().apply(child.getId(), this.appliedItem);
public void apply (final InFlowWorkItem wi) throws ApplyException { if (getChildExpressionId() == null) // // no child { log.debug("apply() no child."); final String s = lookupAttribute(A_VALUE, wi); if (s != null) { ValueUtils.setResult(wi, new StringAttribute(s)); try { reply(wi); } catch (final ReplyException e) { throw new ApplyException ("failure", e); } return; } applyToParent(wi); return; } // // one child getExpressionPool().apply(getChildExpressionId(), wi); }
public void apply (final InFlowWorkItem wi) throws ApplyException { if (this.getChildExpressionId() == null) return; // // prepare self this.appliedItem = (InFlowWorkItem)wi.clone(); fetchRawChild(); // // bind self as a variable this.doName = lookupAttribute(A_NAME, wi); String variableName = V_DO; if (doName != null) variableName += doName; this.bindVariable(variableName, this.getId()); this.storeItself(); // // apply child getExpressionPool().apply(this.getChildExpressionId(), wi); }