1 package polyglot.ext.coffer.ast; 2 3 import polyglot.ext.jl.ast.*; 4 import polyglot.ext.coffer.types.*; 5 import polyglot.ast.*; 6 import polyglot.types.*; 7 import polyglot.visit.*; 8 import polyglot.util.*; 9 10 14 public class CanonicalKeySetNode_c extends Node_c implements CanonicalKeySetNode 15 { 16 protected KeySet keys; 17 18 public CanonicalKeySetNode_c(Position pos, KeySet keys) { 19 super(pos); 20 this.keys = keys; 21 } 22 23 public KeySet keys() { 24 return keys; 25 } 26 27 public CanonicalKeySetNode keys(KeySet keys) { 28 CanonicalKeySetNode_c n = (CanonicalKeySetNode_c) copy(); 29 n.keys = keys; 30 return n; 31 } 32 33 public void prettyPrint(CodeWriter w, PrettyPrinter tr) { 34 w.write(keys.toString()); 35 } 36 37 public void translate(CodeWriter w, Translator tr) { 38 throw new InternalCompilerError(position(), 39 "Cannot translate " + this + "."); 40 } 41 42 public String toString() { 43 return keys.toString(); 44 } 45 } 46 | Popular Tags |