KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > oddjob > monitor > model > PropertyModel


1 /*
2  * (c) Rob Gordon 2005
3  */

4 package org.oddjob.monitor.model;
5
6 import java.util.Map JavaDoc;
7 import java.util.Observable JavaDoc;
8
9 /**
10  * A Model for job properties.
11  *
12  * @author Rob Gordon.
13  *
14  */

15 public class PropertyModel extends Observable JavaDoc {
16
17     /** The map of properties. */
18     private Map JavaDoc properties;
19     
20     /**
21      * Called to update the properties.
22      *
23      * @param map A <String, String> map of the properties.
24      */

25     public void setProperties(Map JavaDoc properties) {
26         this.properties = properties;
27         setChanged();
28         notifyObservers();
29     }
30     
31     /**
32      * Get the property map.
33      *
34      * @return A <String, String> map of properties.
35      */

36     public Map JavaDoc getProperties() {
37         return properties;
38     }
39 }
40
Popular Tags