1    package com.instantbank.servicing.control.web;
2    
3    import java.util.HashMap;
4    import java.io.Serializable;
5    
6    /**
7     *  Screen structure
8     *
9     * @author Instant-bank (Consuelo Franky)
10    * @created September 2002
11    */
12   public class Screen
13       implements Serializable {
14   
15     /**
16      * name of screen
17      */
18     private String name;
19   
20     /**
21      * parameters of screen; each one is (String key, Parameter value)
22      */
23     private HashMap parameters;
24   
25   
26     /**
27      *  Constructor for the Screen object
28      *
29      * @param name name of screen
30      * @param parameters parameters of screen
31      */
32     public Screen(String name, HashMap parameters) {
33       this.name = name;
34       this.parameters = parameters;
35     }
36   
37   
38     /**
39      *  Gets the parameters attribute of the Screen object
40      *
41      * @return The parameters value
42      */
43     public HashMap getParameters() {
44       return parameters;
45     }
46   
47   
48     /**
49      *  Gets the parameter attribute of the Screen object
50      *
51      * @param key name of parameter
52      * @return The parameter value
53      */
54     public Parameter getParameter(String key) {
55       return (Parameter)parameters.get(key);
56     }
57   
58   
59     /**
60      *  textual representation of screen
61      *
62      * @return text
63      */
64     public String toString() {
65       return "[Screen: name=" + name
66         + ", parameters=" + parameters + "]";
67     }
68   }
69   
70