/** * Creates a deep clone of this {@link AConcatenationPattern} 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 AConcatenationPattern} node */ public AConcatenationPattern clone(Map<INode,INode> oldToNewMap) { AConcatenationPattern node = new AConcatenationPattern( _location, cloneList(_definitions, oldToNewMap), _resolved, cloneNode(_left, oldToNewMap), cloneNode(_right, oldToNewMap) ); oldToNewMap.put(this, node); return node; }
public static AConcatenationPattern newAConcatenationPattern(PPattern left, ILexLocation location, PPattern right) { AConcatenationPattern result = new AConcatenationPattern(); initPattern(result, location); result.setLeft(left); result.setRight(right); return result; }
/** * Returns a deep clone of this {@link AConcatenationPattern} node. * @return a deep clone of this {@link AConcatenationPattern} node */ public AConcatenationPattern clone() { return new AConcatenationPattern( _location, cloneList(_definitions), _resolved, cloneNode(_left), cloneNode(_right) ); }