Main Page | Packages | Class Hierarchy | Class List | Directories | File List | Class Members | Related Pages

HashIdProcedimento.java

Go to the documentation of this file.
00001 package plp.orientadaObjetos1.memoria.colecao;
00002 
00003 import java.util.Enumeration;
00004 import java.util.Hashtable;
00005 
00006 import plp.orientadaObjetos1.comando.Procedimento;
00007 import plp.orientadaObjetos1.expressao.leftExpression.Id;
00008 
00013 public class HashIdProcedimento {
00014 
00018     private Hashtable tabela;
00019 
00023     public HashIdProcedimento() {
00024         this.tabela = new Hashtable();
00025     }
00026 
00035     public Procedimento put(Id id, Procedimento procedimento) {
00036         Object result = tabela.put(id, procedimento);
00037         if (result == null) {
00038             return null;
00039         }
00040         else {
00041             return (Procedimento) result;
00042         }
00043     }
00044 
00051     public Procedimento get(Id id) {
00052         Object result = tabela.get(id);
00053         if (result == null) {
00054             return null;
00055         }
00056         else {
00057             return (Procedimento) result;
00058         }
00059     }
00060 
00067     public Enumeration keys() {
00068         return tabela.keys();
00069     }
00070 
00071 }

Generated on Mon Aug 8 20:20:46 2005 for Linguagem OO1 - Generics by  doxygen 1.4.4