Beispiel #1
0
 public void set(int id, int address) {
   if (map.containsKey(id)) {
     map.put(id, address);
   } else if (superEnvironment != null) {
     superEnvironment.set(id, address);
   }
 }
Beispiel #2
0
 public int get(int id) {
   if (map.containsKey(id)) {
     return map.get(id);
   } else if (superEnvironment != null) {
     return superEnvironment.get(id);
   }
   return -1;
 }