Clover coverage report - brownies library - 1.0-beta-1 Coverage timestamp: 月 8 16 2004 17:14:42 GMT+09:00 FRAMES NO FRAMES |
file stats: | LOC: | 125 |  | Methods: | 11
| NCLOC: | 57 |  | Classes: | 1
30 day Evaluation Version distributed via the Maven Jar Repository. Clover is not free. You have 30 days to evaluate it. Please visit http://www.thecortex.net/clover to obtain a licensed version of Clover
Source file | Conditionals | Statements | Methods | TOTAL
TipsLink.java | - | 0% | 0% | 0% |

1 |  |
     /*
2 |  |
      * Joey and its relative products are published under the terms
3 |  |
      * of the Apache Software License.
4 |  |
      */
5 |  |
     /*
6 |  |
      * Created on 2004/01/07
7 |  |
      */
8 |  |
     package org.asyrinx.brownie.tapestry.components.layer;
9 |  |
10 |  |
     import java.util.Map;
11 |  |
12 |  |
     import org.apache.tapestry.AbstractComponent;
13 |  |
     import org.apache.tapestry.IMarkupWriter;
14 |  |
     import org.apache.tapestry.IRequestCycle;
15 |  |
     import org.asyrinx.brownie.tapestry.script.IScriptUser;
16 |  |
     import org.asyrinx.brownie.tapestry.script.ScriptUsage;
17 |  |
     import org.asyrinx.brownie.tapestry.script.ScriptWriter;
18 |  |
19 |  |
     /**
20 |  |
      * @author akima
21 |  |
      */
22 |  |
     public abstract class TipsLink extends AbstractComponent implements IScriptUser {
23 |  |
24 |  |
         /**
25 |  |
          * @param scriptName
26 |  |
          */
27 | 0 |
         public TipsLink() {
28 | 0 |
             super();
29 | 0 |
             this.writer = new ScriptWriter(this, "TipsLink.script");
30 | 0 |
             this.writer.setUsage(ScriptUsage.ONCE_BY_CLASS);
31 |  |
         }
32 |  |
33 |  |
         private final ScriptWriter writer;
34 |  |
35 |  |
         private int x = 0;
36 |  |
37 |  |
         private int y = 10;
38 |  |
39 |  |
         private String position = "center";
40 |  |
41 |  |
         private String tipsId = null;
42 |  |
43 |  |
         /**
44 |  |
          * @see org.apache.tapestry.AbstractComponent#renderComponent(org.apache.tapestry.IMarkupWriter,
45 |  |
          *      org.apache.tapestry.IRequestCycle)
46 |  |
          */
47 | 0 |
         protected void renderComponent(IMarkupWriter markupWriter, IRequestCycle cycle) {
48 | 0 |
             this.writer.execute(cycle);
49 |  |
50 | 0 |
             markupWriter.begin("a");
51 | 0 |
             markupWriter.attribute("style", "TEXT-DECORATION:none");
52 | 0 |
             markupWriter.attribute("href", "javascript:void(0);");
53 | 0 |
             markupWriter.attribute("onclick", "return false;");
54 | 0 |
             markupWriter.attribute("onmouseover", "showTips('" + tipsId + "',event," + x
55 |  |
                     + "," + y + ",'" + position + "');");
56 | 0 |
             markupWriter.attribute("onmouseout", "hideTips('" + tipsId + "');");
57 | 0 |
             renderBody(markupWriter, cycle);
58 | 0 |
             markupWriter.end();
59 |  |
         }
60 |  |
61 |  |
         /**
62 |  |
          * @see org.asyrinx.brownie.tapestry.script.AbstractScriptComponent#prepareScriptSymbols(java.util.Map,
63 |  |
          *      org.apache.tapestry.IRequestCycle)
64 |  |
          */
65 | 0 |
         public void prepareScriptSymbols(Map symbols, IRequestCycle cycle) {
66 |  |
             //no symbols
67 |  |
         }
68 |  |
69 |  |
         /**
70 |  |
          * @return
71 |  |
          */
72 | 0 |
         public String getPosition() {
73 | 0 |
             return position;
74 |  |
         }
75 |  |
76 |  |
         /**
77 |  |
          * @return
78 |  |
          */
79 | 0 |
         public int getX() {
80 | 0 |
             return x;
81 |  |
         }
82 |  |
83 |  |
         /**
84 |  |
          * @return
85 |  |
          */
86 | 0 |
         public int getY() {
87 | 0 |
             return y;
88 |  |
         }
89 |  |
90 |  |
         /**
91 |  |
          * @param string
92 |  |
          */
93 | 0 |
         public void setPosition(String string) {
94 | 0 |
             position = string;
95 |  |
         }
96 |  |
97 |  |
         /**
98 |  |
          * @param i
99 |  |
          */
100 | 0 |
         public void setX(int i) {
101 | 0 |
             x = i;
102 |  |
         }
103 |  |
104 |  |
         /**
105 |  |
          * @param i
106 |  |
          */
107 | 0 |
         public void setY(int i) {
108 | 0 |
             y = i;
109 |  |
         }
110 |  |
111 |  |
         /**
112 |  |
          * @return
113 |  |
          */
114 | 0 |
         public String getTipsId() {
115 | 0 |
             return tipsId;
116 |  |
         }
117 |  |
118 |  |
         /**
119 |  |
          * @param string
120 |  |
          */
121 | 0 |
         public void setTipsId(String string) {
122 | 0 |
             tipsId = string;
123 |  |
         }
124 |  |
125 |  |
     }