KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > wings > template > STextAreaPropertyManager


1 /*
2  * $Id: STextAreaPropertyManager.java,v 1.3 2004/12/01 07:54:28 hengels Exp $
3  * Copyright 2000,2005 wingS development team.
4  *
5  * This file is part of wingS (http://www.j-wings.org).
6  *
7  * wingS is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU Lesser General Public License
9  * as published by the Free Software Foundation; either version 2.1
10  * of the License, or (at your option) any later version.
11  *
12  * Please see COPYING for the complete licence.
13  */

14 package org.wings.template;
15
16 import org.wings.SComponent;
17 import org.wings.STextArea;
18
19 /**
20  * @author <a HREF="mailto:haaf@mercatis.de">Armin Haaf</a>
21  * @version $Revision: 1.3 $
22  */

23 public class STextAreaPropertyManager
24         extends SComponentPropertyManager {
25     static final Class JavaDoc[] classes = {STextArea.class};
26
27     public STextAreaPropertyManager() {
28     }
29
30     public void setProperty(SComponent comp, String JavaDoc name, String JavaDoc value) {
31         STextArea c = (STextArea) comp;
32         if (name.equals("COLS"))
33             c.setColumns(Integer.parseInt(value));
34         else if (name.equals("ROWS"))
35             c.setRows(Integer.parseInt(value));
36         else
37             super.setProperty(comp, name, value);
38     }
39
40     public Class JavaDoc[] getSupportedClasses() {
41         return classes;
42     }
43 }
44
45
46
Popular Tags