Source Code Cross Referenced for FrameSetBase.java in  » IDE-Netbeans » visualweb.api.designer » com » sun » rave » web » ui » component » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE Netbeans » visualweb.api.designer » com.sun.rave.web.ui.component 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
003:         *
004:         * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
005:         *
006:         * The contents of this file are subject to the terms of either the GNU
007:         * General Public License Version 2 only ("GPL") or the Common
008:         * Development and Distribution License("CDDL") (collectively, the
009:         * "License"). You may not use this file except in compliance with the
010:         * License. You can obtain a copy of the License at
011:         * http://www.netbeans.org/cddl-gplv2.html
012:         * or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the
013:         * specific language governing permissions and limitations under the
014:         * License.  When distributing the software, include this License Header
015:         * Notice in each file and include the License file at
016:         * nbbuild/licenses/CDDL-GPL-2-CP.  Sun designates this
017:         * particular file as subject to the "Classpath" exception as provided
018:         * by Sun in the GPL Version 2 section of the License file that
019:         * accompanied this code. If applicable, add the following below the
020:         * License Header, with the fields enclosed by brackets [] replaced by
021:         * your own identifying information:
022:         * "Portions Copyrighted [year] [name of copyright owner]"
023:         *
024:         * Contributor(s):
025:         *
026:         * The Original Software is NetBeans. The Initial Developer of the Original
027:         * Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
028:         * Microsystems, Inc. All Rights Reserved.
029:         *
030:         * If you wish your version of this file to be governed by only the CDDL
031:         * or only the GPL Version 2, indicate your decision by adding
032:         * "[Contributor] elects to include this software in this distribution
033:         * under the [CDDL or GPL Version 2] license." If you do not indicate a
034:         * single choice of license, a recipient has the option to distribute
035:         * your version of this file under either the CDDL, the GPL Version 2 or
036:         * to extend the choice of license to its licensees as provided above.
037:         * However, if you add GPL Version 2 code and therefore, elected the GPL
038:         * Version 2 license, then the option applies only if the new code is
039:         * made subject to such option by the copyright holder.
040:         */
041:        package com.sun.rave.web.ui.component;
042:
043:        import java.io.IOException;
044:        import javax.faces.component.UIComponent;
045:        import javax.faces.context.FacesContext;
046:        import javax.faces.el.MethodBinding;
047:        import javax.faces.el.ValueBinding;
048:
049:        /**
050:         * <span style="color: rgb(0, 0, 0);">Use
051:         * the <code>ui:frameSet</code>
052:         * tag to define a new set of frames in the rendered HTML page. <br>
053:         * When using <code>ui:frameSet</code>
054:         * and <code>ui:frame</code>
055:         * tags in
056:         * your application, you must also set the <code>ui:page</code>
057:         * tag's
058:         * frame attribute to "true".<br>
059:         * </span><br
060:         *  style="color: rgb(0, 0, 0);">
061:         * <h3 style="color: rgb(0, 0, 0);">HTML
062:         * Elements and Layout</h3>
063:         * <span style="color: rgb(0, 0, 0);">The
064:         * rendered HTML page contains
065:         * an XHTML-compliant <code>&lt;frameset&gt;</code>
066:         * element. </span><br
067:         *  style="color: rgb(0, 0, 0);">
068:         * <br style="color: rgb(0, 0, 0);">
069:         * <h3 style="color: rgb(0, 0, 0);">Theme
070:         * Identifiers</h3>
071:         * <span style="color: rgb(0, 0, 0);">What
072:         * theme elements apply?</span><br
073:         *  style="color: rgb(0, 0, 0);">
074:         * <br style="color: rgb(0, 0, 0);">
075:         * <h3 style="color: rgb(0, 0, 0);">Client
076:         * Side Javascript Functions</h3>
077:         * <span style="color: rgb(0, 0, 0);">None.&nbsp;
078:         * </span><br
079:         *  style="color: rgb(0, 0, 0);">
080:         * <br style="color: rgb(0, 0, 0);">
081:         * <h3 style="color: rgb(0, 0, 0);">Examples</h3>
082:         * <p style="color: rgb(0, 0, 0);"></p>
083:         * <h4 style="color: rgb(0, 0, 0);">Example
084:         * 1: Creating a
085:         * frameset of two rows and two columns<br>
086:         * </h4>
087:         * <code style="color: rgb(0, 0, 0);">&lt;?xml
088:         * version="1.0"
089:         * encoding="UTF-8"?&gt;<br>
090:         * &lt;jsp:root version="1.2" xmlns:f="http://java.sun.com/jsf/core"
091:         * xmlns:h="http://java.sun.com/jsf/html"
092:         * xmlns:jsp="http://java.sun.com/JSP/Page"
093:         * xmlns:ui="http://www.sun.com/web/ui"&gt;<br>
094:         * &nbsp;&nbsp;&nbsp; &lt;jsp:directive.page
095:         * contentType="text/html;charset=ISO-8859-1"
096:         * pageEncoding="UTF-8"/&gt;&lt;f:view&gt;<br>
097:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
098:         * &lt;ui:page frame="true"&gt;<br>
099:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
100:         * &lt;ui:html&gt;<br>
101:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
102:         * &lt;ui:head title="blah" /&gt;<br>
103:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
104:         * &lt;ui:frameSet rows="10%,*" cols="10%,*" style="color:blue"
105:         * styleClass="blue" toolTip="blah"&gt;<br>
106:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
107:         * &lt;ui:frame toolTip="blah" url="../faces/hyperlink/hyperlink.jsp"
108:         * frameBorder="true" noResize="false"/&gt;<br>
109:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
110:         * &lt;ui:frame toolTip="blah1" url="../faces/hyperlink/nextpage.jsp"
111:         * frameBorder="true" noResize="false"/&gt;<br>
112:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
113:         * <br>
114:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
115:         * &lt;ui:frame toolTip="blah2" url="http://www.google.com"
116:         * frameBorder="true" noResize="false"/&gt;<br>
117:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
118:         * &lt;ui:frame toolTip="blah3" url="http://www.yahoo.com"
119:         * frameBorder="true" noResize="false"/&gt;<br>
120:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
121:         * &lt;/ui:frameSet&gt;<br>
122:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
123:         * &lt;/ui:html&gt;<br>
124:         * &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
125:         * &lt;/ui:page&gt;<br>
126:         * &nbsp;&nbsp;&nbsp; &lt;/f:view&gt;<br>
127:         * &lt;/jsp:root&gt;</code>
128:         * <p>Auto-generated component class.
129:         * Do <strong>NOT</strong> modify; all changes
130:         * <strong>will</strong> be lost!</p>
131:         */
132:
133:        public abstract class FrameSetBase extends
134:                javax.faces.component.UIComponentBase {
135:
136:            /**
137:             * <p>Construct a new <code>FrameSetBase</code>.</p>
138:             */
139:            public FrameSetBase() {
140:                super ();
141:                setRendererType("com.sun.rave.web.ui.FrameSet");
142:            }
143:
144:            /**
145:             * <p>Return the identifier of the component family to which this
146:             * component belongs.  This identifier, in conjunction with the value
147:             * of the <code>rendererType</code> property, may be used to select
148:             * the appropriate {@link Renderer} for this component instance.</p>
149:             */
150:            public String getFamily() {
151:                return "com.sun.rave.web.ui.FrameSet";
152:            }
153:
154:            // border
155:            private int border = Integer.MIN_VALUE;
156:            private boolean border_set = false;
157:
158:            /**
159:             * <p>The width, in pixels, of the space around frames. The frameSpacing 
160:             *         attribute and the border attribute set the same property in different 
161:             *         browsers.  Set frameSpacing and border to the same value.</p>
162:             */
163:            public int getBorder() {
164:                if (this .border_set) {
165:                    return this .border;
166:                }
167:                ValueBinding _vb = getValueBinding("border");
168:                if (_vb != null) {
169:                    Object _result = _vb.getValue(getFacesContext());
170:                    if (_result == null) {
171:                        return Integer.MIN_VALUE;
172:                    } else {
173:                        return ((Integer) _result).intValue();
174:                    }
175:                }
176:                return Integer.MIN_VALUE;
177:            }
178:
179:            /**
180:             * <p>The width, in pixels, of the space around frames. The frameSpacing 
181:             *         attribute and the border attribute set the same property in different 
182:             *         browsers.  Set frameSpacing and border to the same value.</p>
183:             * @see #getBorder()
184:             */
185:            public void setBorder(int border) {
186:                this .border = border;
187:                this .border_set = true;
188:            }
189:
190:            // borderColor
191:            private String borderColor = null;
192:
193:            /**
194:             * <p>The bordercolor attribute allows you to set the color of the frame 
195:             *          borders using a hex value or a color name.</p>
196:             */
197:            public String getBorderColor() {
198:                if (this .borderColor != null) {
199:                    return this .borderColor;
200:                }
201:                ValueBinding _vb = getValueBinding("borderColor");
202:                if (_vb != null) {
203:                    return (String) _vb.getValue(getFacesContext());
204:                }
205:                return null;
206:            }
207:
208:            /**
209:             * <p>The bordercolor attribute allows you to set the color of the frame 
210:             *          borders using a hex value or a color name.</p>
211:             * @see #getBorderColor()
212:             */
213:            public void setBorderColor(String borderColor) {
214:                this .borderColor = borderColor;
215:            }
216:
217:            // cols
218:            private String cols = null;
219:
220:            /**
221:             * <p>Defines the number and size of columns in a frameset. The size can be 
222:             *          specified in pixels, percentage of the page width, or with an 
223:             *          asterisk (*).  Specifying * causes the columns to use available space.
224:             *          See the HTML specification for the frameset element for more details.</p>
225:             */
226:            public String getCols() {
227:                if (this .cols != null) {
228:                    return this .cols;
229:                }
230:                ValueBinding _vb = getValueBinding("cols");
231:                if (_vb != null) {
232:                    return (String) _vb.getValue(getFacesContext());
233:                }
234:                return null;
235:            }
236:
237:            /**
238:             * <p>Defines the number and size of columns in a frameset. The size can be 
239:             *          specified in pixels, percentage of the page width, or with an 
240:             *          asterisk (*).  Specifying * causes the columns to use available space.
241:             *          See the HTML specification for the frameset element for more details.</p>
242:             * @see #getCols()
243:             */
244:            public void setCols(String cols) {
245:                this .cols = cols;
246:            }
247:
248:            // frameBorder
249:            private boolean frameBorder = false;
250:            private boolean frameBorder_set = false;
251:
252:            /**
253:             * <p>Flag indicating whether frames should have borders or not. If 
254:             *          frameBorder is true, decorative borders are drawn. If frameBorder is  
255:             *          false, a space between frames shows up as the background color of the
256:             *          page.  To show no border or space between frames, you should set 
257:             *          frameBorder to false, and set frameSpacing and border to 0.</p>
258:             */
259:            public boolean isFrameBorder() {
260:                if (this .frameBorder_set) {
261:                    return this .frameBorder;
262:                }
263:                ValueBinding _vb = getValueBinding("frameBorder");
264:                if (_vb != null) {
265:                    Object _result = _vb.getValue(getFacesContext());
266:                    if (_result == null) {
267:                        return false;
268:                    } else {
269:                        return ((Boolean) _result).booleanValue();
270:                    }
271:                }
272:                return false;
273:            }
274:
275:            /**
276:             * <p>Flag indicating whether frames should have borders or not. If 
277:             *          frameBorder is true, decorative borders are drawn. If frameBorder is  
278:             *          false, a space between frames shows up as the background color of the
279:             *          page.  To show no border or space between frames, you should set 
280:             *          frameBorder to false, and set frameSpacing and border to 0.</p>
281:             * @see #isFrameBorder()
282:             */
283:            public void setFrameBorder(boolean frameBorder) {
284:                this .frameBorder = frameBorder;
285:                this .frameBorder_set = true;
286:            }
287:
288:            // frameSpacing
289:            private int frameSpacing = Integer.MIN_VALUE;
290:            private boolean frameSpacing_set = false;
291:
292:            /**
293:             * <p>The width, in pixels, of the space around frames. The frameSpacing attribute 
294:             *         and the border attribute set the same property in different browsers.  
295:             *         Set frameSpacing and border to the same value.</p>
296:             */
297:            public int getFrameSpacing() {
298:                if (this .frameSpacing_set) {
299:                    return this .frameSpacing;
300:                }
301:                ValueBinding _vb = getValueBinding("frameSpacing");
302:                if (_vb != null) {
303:                    Object _result = _vb.getValue(getFacesContext());
304:                    if (_result == null) {
305:                        return Integer.MIN_VALUE;
306:                    } else {
307:                        return ((Integer) _result).intValue();
308:                    }
309:                }
310:                return Integer.MIN_VALUE;
311:            }
312:
313:            /**
314:             * <p>The width, in pixels, of the space around frames. The frameSpacing attribute 
315:             *         and the border attribute set the same property in different browsers.  
316:             *         Set frameSpacing and border to the same value.</p>
317:             * @see #getFrameSpacing()
318:             */
319:            public void setFrameSpacing(int frameSpacing) {
320:                this .frameSpacing = frameSpacing;
321:                this .frameSpacing_set = true;
322:            }
323:
324:            // rows
325:            private String rows = null;
326:
327:            /**
328:             * <p>Defines the number and size of rows in a frameset. The size can be 
329:             *          specified in pixels, percentage of the page length, or with an 
330:             *          asterisk (*).  Specifying * causes the rows to use available space.
331:             *          See the HTML specification for the frameset element for more details.</p>
332:             */
333:            public String getRows() {
334:                if (this .rows != null) {
335:                    return this .rows;
336:                }
337:                ValueBinding _vb = getValueBinding("rows");
338:                if (_vb != null) {
339:                    return (String) _vb.getValue(getFacesContext());
340:                }
341:                return null;
342:            }
343:
344:            /**
345:             * <p>Defines the number and size of rows in a frameset. The size can be 
346:             *          specified in pixels, percentage of the page length, or with an 
347:             *          asterisk (*).  Specifying * causes the rows to use available space.
348:             *          See the HTML specification for the frameset element for more details.</p>
349:             * @see #getRows()
350:             */
351:            public void setRows(String rows) {
352:                this .rows = rows;
353:            }
354:
355:            // style
356:            private String style = null;
357:
358:            /**
359:             * <p>CSS style(s) to be applied when this component is rendered.</p>
360:             */
361:            public String getStyle() {
362:                if (this .style != null) {
363:                    return this .style;
364:                }
365:                ValueBinding _vb = getValueBinding("style");
366:                if (_vb != null) {
367:                    return (String) _vb.getValue(getFacesContext());
368:                }
369:                return null;
370:            }
371:
372:            /**
373:             * <p>CSS style(s) to be applied when this component is rendered.</p>
374:             * @see #getStyle()
375:             */
376:            public void setStyle(String style) {
377:                this .style = style;
378:            }
379:
380:            // styleClass
381:            private String styleClass = null;
382:
383:            /**
384:             * <p>CSS style class(es) to be applied when this component is rendered.</p>
385:             */
386:            public String getStyleClass() {
387:                if (this .styleClass != null) {
388:                    return this .styleClass;
389:                }
390:                ValueBinding _vb = getValueBinding("styleClass");
391:                if (_vb != null) {
392:                    return (String) _vb.getValue(getFacesContext());
393:                }
394:                return null;
395:            }
396:
397:            /**
398:             * <p>CSS style class(es) to be applied when this component is rendered.</p>
399:             * @see #getStyleClass()
400:             */
401:            public void setStyleClass(String styleClass) {
402:                this .styleClass = styleClass;
403:            }
404:
405:            // toolTip
406:            private String toolTip = null;
407:
408:            /**
409:             * <p>Display the text as a tooltip for this component</p>
410:             */
411:            public String getToolTip() {
412:                if (this .toolTip != null) {
413:                    return this .toolTip;
414:                }
415:                ValueBinding _vb = getValueBinding("toolTip");
416:                if (_vb != null) {
417:                    return (String) _vb.getValue(getFacesContext());
418:                }
419:                return null;
420:            }
421:
422:            /**
423:             * <p>Display the text as a tooltip for this component</p>
424:             * @see #getToolTip()
425:             */
426:            public void setToolTip(String toolTip) {
427:                this .toolTip = toolTip;
428:            }
429:
430:            /**
431:             * <p>Restore the state of this component.</p>
432:             */
433:            public void restoreState(FacesContext _context, Object _state) {
434:                Object _values[] = (Object[]) _state;
435:                super .restoreState(_context, _values[0]);
436:                this .border = ((Integer) _values[1]).intValue();
437:                this .border_set = ((Boolean) _values[2]).booleanValue();
438:                this .borderColor = (String) _values[3];
439:                this .cols = (String) _values[4];
440:                this .frameBorder = ((Boolean) _values[5]).booleanValue();
441:                this .frameBorder_set = ((Boolean) _values[6]).booleanValue();
442:                this .frameSpacing = ((Integer) _values[7]).intValue();
443:                this .frameSpacing_set = ((Boolean) _values[8]).booleanValue();
444:                this .rows = (String) _values[9];
445:                this .style = (String) _values[10];
446:                this .styleClass = (String) _values[11];
447:                this .toolTip = (String) _values[12];
448:            }
449:
450:            /**
451:             * <p>Save the state of this component.</p>
452:             */
453:            public Object saveState(FacesContext _context) {
454:                Object _values[] = new Object[13];
455:                _values[0] = super .saveState(_context);
456:                _values[1] = new Integer(this .border);
457:                _values[2] = this .border_set ? Boolean.TRUE : Boolean.FALSE;
458:                _values[3] = this .borderColor;
459:                _values[4] = this .cols;
460:                _values[5] = this .frameBorder ? Boolean.TRUE : Boolean.FALSE;
461:                _values[6] = this .frameBorder_set ? Boolean.TRUE
462:                        : Boolean.FALSE;
463:                _values[7] = new Integer(this .frameSpacing);
464:                _values[8] = this .frameSpacing_set ? Boolean.TRUE
465:                        : Boolean.FALSE;
466:                _values[9] = this .rows;
467:                _values[10] = this .style;
468:                _values[11] = this .styleClass;
469:                _values[12] = this.toolTip;
470:                return _values;
471:            }
472:
473:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.