/** * Called by the {@link ASeqBindIR} node from {@link ASeqBindIR#apply(IAnalysis)}. * @param node the calling {@link ASeqBindIR} node */ public void caseASeqBindIR(ASeqBindIR node) throws AnalysisException { _visitedNodes.add(node); inASeqBindIR(node); if(node.getPattern() != null && !_visitedNodes.contains(node.getPattern())) { node.getPattern().apply(this); } if(node.getSeq() != null && !_visitedNodes.contains(node.getSeq())) { node.getSeq().apply(this); } outASeqBindIR(node); }
/** * Returns a deep clone of this {@link ASeqBindIR} node. * @return a deep clone of this {@link ASeqBindIR} node */ public ASeqBindIR clone() { return new ASeqBindIR( _sourceNode, _tag, _metaData, cloneNode(_pattern), cloneNode(_seq) ); }
/** * Creates a new tree field only constructor {@code ASeqBindIR TAG=seq} node with the given nodes as children. * @deprecated This method should not be used, use AstFactory instead. * The basic child nodes are removed from their previous parents. * @param seq_ the {@link SExpIR} node for the {@code seq} child of this {@link ASeqBindIR} node */ public ASeqBindIR(SPatternIR pattern_, SExpIR seq_) { super(null,null,null,pattern_); this.setSeq(seq_); }
@Override public SBindIR caseASeqBind(ASeqBind node, IRInfo question) throws AnalysisException { PPattern pattern = node.getPattern(); SPatternIR patternCg = pattern.apply(question.getPatternVisitor(), question); PExp seq = node.getSeq(); SExpIR seqCg = seq.apply(question.getExpVisitor(), question); ASeqBindIR seqBind = new ASeqBindIR(); seqBind.setPattern(patternCg); seqBind.setSeq(seqCg); return seqBind; } }
node.getSeqBind().apply(this, question);
multipleSeqBind.setSeq(seqBind.getSeq());
} else patterns.add(node.getSeqBind().getPattern().clone());
/** * Essentially this.toString().equals(o.toString()). **/ @Override public boolean equals(Object o) { if (o != null && o instanceof ASeqBindIR) { return toString().equals(o.toString()); } return false; }
/** * Sets the {@code _seqBind} child of this {@link ACompSeqExpIR} node. * @param value the new {@code _seqBind} child of this {@link ACompSeqExpIR} node */ public void setSeqBind(ASeqBindIR value) { if (this._seqBind != null) { this._seqBind.parent(null); } if (value != null) { if (value.parent() != null) { value.parent().removeChild(value); } value.parent(this); } this._seqBind = value; }
node.getSeqBind().apply(this);
public String toString() { return (_first!=null?_first.toString():this.getClass().getSimpleName())+ (_setBind!=null?_setBind.toString():this.getClass().getSimpleName())+ (_seqBind!=null?_seqBind.toString():this.getClass().getSimpleName())+ (_setSeq!=null?_setSeq.toString():this.getClass().getSimpleName())+ (_predicate!=null?_predicate.toString():this.getClass().getSimpleName()); }
/** * Called by the {@link ASeqBindIR} node from {@link ASeqBindIR#apply(IIsaAnalysis)}. * @param node the calling {@link ASeqBindIR} node */ public void caseASeqBindIR(ASeqBindIR node) throws AnalysisException { _visitedNodes.add(node); inASeqBindIR(node); if(node.getPattern() != null && !_visitedNodes.contains(node.getPattern())) { node.getPattern().apply(this); } if(node.getSeq() != null && !_visitedNodes.contains(node.getSeq())) { node.getSeq().apply(this); } outASeqBindIR(node); }
node.getSeqBind().apply(this);
/** * Creates a deep clone of this {@link ASeqBindIR} node while putting all * old node-new node relations in the map {@code oldToNewMap}. * @param oldToNewMap the map filled with the old node-new node relation * @return a deep clone of this {@link ASeqBindIR} node */ public ASeqBindIR clone(Map<INode,INode> oldToNewMap) { ASeqBindIR node = new ASeqBindIR( _sourceNode, _tag, _metaData, cloneNode(_pattern, oldToNewMap), cloneNode(_seq, oldToNewMap) ); oldToNewMap.put(this, node); return node; }
/** * Creates a new complete constructor {@code ASeqBindIR} node with the given nodes as children. * @deprecated This method should not be used, use AstFactory instead. * The basic child nodes are removed from their previous parents. * @param seq_ the {@link SExpIR} node for the {@code seq} child of this {@link ASeqBindIR} node */ public ASeqBindIR(SourceNode sourceNode_, Object tag_, List<? extends ClonableString> metaData_, SPatternIR pattern_, SExpIR seq_) { super(sourceNode_,tag_,metaData_,pattern_); this.setSeq(seq_); }
/** * Called by the {@link ASeqBindIR} node from {@link ASeqBindIR#apply(IAnalysis)}. * @param node the calling {@link ASeqBindIR} node */ public void caseASeqBindIR(ASeqBindIR node, Q question) throws AnalysisException { _visitedNodes.add(node); inASeqBindIR(node, question); if(node.getPattern() != null && !_visitedNodes.contains(node.getPattern())) { node.getPattern().apply(this, question); } if(node.getSeq() != null && !_visitedNodes.contains(node.getSeq())) { node.getSeq().apply(this, question); } outASeqBindIR(node, question); }
mergeReturns(retVal,node.getSeqBind().apply(this));
/** * Called by the {@link ASeqBindIR} node from {@link ASeqBindIR#apply(IAnalysis)}. * @param node the calling {@link ASeqBindIR} node */ public A caseASeqBindIR(ASeqBindIR node, Q question) throws AnalysisException { _visitedNodes.add(node); A retVal = createNewReturnValue(node, question); mergeReturns(retVal,inASeqBindIR(node, question)); if(node.getPattern() != null && !_visitedNodes.contains(node.getPattern())) { mergeReturns(retVal,node.getPattern().apply(this, question)); } if(node.getSeq() != null && !_visitedNodes.contains(node.getSeq())) { mergeReturns(retVal,node.getSeq().apply(this, question)); } mergeReturns(retVal,outASeqBindIR(node, question)); return retVal; }
mergeReturns(retVal,node.getSeqBind().apply(this, question));
/** * Called by the {@link ASeqBindIR} node from {@link ASeqBindIR#apply(IAnalysis)}. * @param node the calling {@link ASeqBindIR} node */ public A caseASeqBindIR(ASeqBindIR node) throws AnalysisException { _visitedNodes.add(node); A retVal = createNewReturnValue(node); mergeReturns(retVal,inASeqBindIR(node)); if(node.getPattern() != null && !_visitedNodes.contains(node.getPattern())) { mergeReturns(retVal,node.getPattern().apply(this)); } if(node.getSeq() != null && !_visitedNodes.contains(node.getSeq())) { mergeReturns(retVal,node.getSeq().apply(this)); } mergeReturns(retVal,outASeqBindIR(node)); return retVal; }