/** * Returns a deep clone of this {@link APreCondRuntimeErrorExpIR} node. * @return a deep clone of this {@link APreCondRuntimeErrorExpIR} node */ public APreCondRuntimeErrorExpIR clone() { return new APreCondRuntimeErrorExpIR( _sourceNode, _tag, _metaData, cloneNode(_type), _message ); }
/** * Creates a deep clone of this {@link APreCondRuntimeErrorExpIR} 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 APreCondRuntimeErrorExpIR} node */ public APreCondRuntimeErrorExpIR clone(Map<INode,INode> oldToNewMap) { APreCondRuntimeErrorExpIR node = new APreCondRuntimeErrorExpIR( _sourceNode, _tag, _metaData, cloneNode(_type, oldToNewMap), _message ); oldToNewMap.put(this, node); return node; }
APreCondRuntimeErrorExpIR runtimeError = new APreCondRuntimeErrorExpIR(); runtimeError.setType(new AErrorTypeIR()); runtimeError.setMessage(String.format("Precondition failure: pre_%s", node.getName()));