View Javadoc

1   /*--------------------------------------------------------------------------
2    *  Copyright 2007 utgenome.org
3    *
4    *  Licensed under the Apache License, Version 2.0 (the "License");
5    *  you may not use this file except in compliance with the License.
6    *  You may obtain a copy of the License at
7    *
8    *     http://www.apache.org/licenses/LICENSE-2.0
9    *
10   *  Unless required by applicable law or agreed to in writing, software
11   *  distributed under the License is distributed on an "AS IS" BASIS,
12   *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   *  See the License for the specific language governing permissions and
14   *  limitations under the License.
15   *--------------------------------------------------------------------------*/
16  //--------------------------------------
17  // UTGBMedaka Project
18  //
19  // AvailableTrackInfo.java
20  // Since: Aug 8, 2007
21  //
22  // $URL$ 
23  // $Author$
24  //--------------------------------------
25  package org.utgenome.gwt.utgb.client.track.bean;
26  
27  import java.util.Map;
28  import java.util.TreeMap;
29  
30  import com.google.gwt.user.client.rpc.IsSerializable;
31  
32  public class TrackBean implements IsSerializable, Comparable<TrackBean> {
33  	private String trackName = "";
34  	private String className;
35  	private int height;
36  	private Boolean pack = null;
37  	private String description = "";
38  	private String developer = "";
39  
40  	/**
41  	 */
42  	private Map<String, String> property = new TreeMap<String, String>();
43  
44  	/**
45  	 * @param trackName
46  	 * @param className
47  	 * @param height
48  	 * @param pack
49  	 * @param description
50  	 * @param developer
51  	 */
52  	public TrackBean(String trackName, String className, int height, boolean pack, String description, String developer) {
53  		this.trackName = trackName;
54  		this.className = className;
55  		this.height = height;
56  		this.pack = new Boolean(pack);
57  		this.description = description;
58  		this.developer = developer;
59  	}
60  
61  	public TrackBean() {
62  	}
63  
64  	public String getName() {
65  		return trackName;
66  	}
67  
68  	public void setName(String trackName) {
69  		this.trackName = trackName;
70  	}
71  
72  	public String getClassName() {
73  		return className;
74  	}
75  
76  	public void setClassName(String className) {
77  		this.className = className;
78  	}
79  
80  	public int getHeight() {
81  		return height;
82  	}
83  
84  	public void setHeight(int height) {
85  		this.height = height;
86  	}
87  
88  	public Boolean getPack() {
89  		return pack;
90  	}
91  
92  	public void setPack(Boolean pack) {
93  		this.pack = pack;
94  	}
95  
96  	public String getDescription() {
97  		return description;
98  	}
99  
100 	public void setDescription(String description) {
101 		this.description = description;
102 	}
103 
104 	public String getDeveloper() {
105 		return developer;
106 	}
107 
108 	public void setDeveloper(String developer) {
109 		this.developer = developer;
110 	}
111 
112 	public void putProperty(String key, String value) {
113 		this.property.put(key, value);
114 	}
115 
116 	public Map<String, String> getProperty() {
117 		return this.property;
118 	}
119 
120 	public int compareTo(TrackBean o) {
121 		if (o == null)
122 			return 1;
123 		return trackName.compareTo(o.trackName);
124 	}
125 }