Source Code Cross Referenced for VirtualWindow.java in  » Web-Framework » webonswing » net » ar » webonswing » wrapping » 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 » Web Framework » webonswing » net.ar.webonswing.wrapping 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        //WebOnSwing - Web Application Framework
002:        //Copyright (C) 2003 Fernando Damian Petrola
003:        //	
004:        //This library is free software; you can redistribute it and/or
005:        //modify it under the terms of the GNU Lesser General Public
006:        //License as published by the Free Software Foundation; either
007:        //version 2.1 of the License, or (at your option) any later version.
008:        //	
009:        //This library is distributed in the hope that it will be useful,
010:        //but WITHOUT ANY WARRANTY; without even the implied warranty of
011:        //MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
012:        //Lesser General Public License for more details.
013:        //	
014:        //You should have received a copy of the GNU Lesser General Public
015:        //License along with this library; if not, write to the Free Software
016:        //Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
017:
018:        package net.ar.webonswing.wrapping;
019:
020:        import java.awt.*;
021:        import java.io.*;
022:        import java.util.List;
023:
024:        import net.ar.webonswing.helpers.*;
025:        import net.ar.webonswing.managers.contributors.*;
026:        import net.ar.webonswing.managers.persistence.*;
027:        import net.ar.webonswing.visitor.*;
028:
029:        public class VirtualWindow implements  VisualWindow, Serializable,
030:                Virtualizable {
031:            protected PersistenceContributionContainer thePersistenceContainer;
032:            protected String theWindowClassName;
033:            protected transient VisualWindow theOriginalWindow;
034:            protected String theVirtualName;
035:
036:            public VirtualWindow(VisualWindow aWindow, String aWindowName,
037:                    String aWindowClassName,
038:                    PersistenceContributionContainer aPersistenceContainer) {
039:                theOriginalWindow = aWindow;
040:                theVirtualName = aWindowName;
041:                theOriginalWindow.setName(aWindowName);
042:                theWindowClassName = aWindowClassName;
043:                thePersistenceContainer = aPersistenceContainer;
044:            }
045:
046:            protected void restoreOriginal() {
047:                if (theOriginalWindow == null) {
048:                    theOriginalWindow = (VisualWindow) WosHelper
049:                            .createClassInstance(theWindowClassName);
050:                    new ComponentStandardizer()
051:                            .standardizeWindowHierarchy(theOriginalWindow);
052:                    thePersistenceContainer.restoreAllValues(theOriginalWindow
053:                            .getRootComponent());
054:                }
055:            }
056:
057:            public void accept(Visitor aVisitor) {
058:                restoreOriginal();
059:                theOriginalWindow.accept(aVisitor);
060:            }
061:
062:            public void addChild(VisualComponent aChild) {
063:                restoreOriginal();
064:                theOriginalWindow.addChild(aChild);
065:            }
066:
067:            public void doLayout() {
068:                restoreOriginal();
069:                theOriginalWindow.doLayout();
070:            }
071:
072:            public boolean equals(Object obj) {
073:                restoreOriginal();
074:                return theOriginalWindow.equals(obj);
075:            }
076:
077:            public VisualComponent findComponent(String aComponentName) {
078:                restoreOriginal();
079:                return theOriginalWindow.findComponent(aComponentName);
080:            }
081:
082:            public Rectangle getBounds() {
083:                restoreOriginal();
084:                return theOriginalWindow.getBounds();
085:            }
086:
087:            public VisualComponent getChildAt(int aPosition) {
088:                restoreOriginal();
089:                return theOriginalWindow.getChildAt(aPosition);
090:            }
091:
092:            public int getChildCount() {
093:                restoreOriginal();
094:                return theOriginalWindow.getChildCount();
095:            }
096:
097:            public List getChilds() {
098:                restoreOriginal();
099:                return theOriginalWindow.getChilds();
100:            }
101:
102:            public Object getClientProperty(Object aKey) {
103:                restoreOriginal();
104:                return theOriginalWindow.getClientProperty(aKey);
105:            }
106:
107:            public ComponentContributor getContributor() {
108:                restoreOriginal();
109:                return theOriginalWindow.getContributor();
110:            }
111:
112:            public Object getLockObject() {
113:                restoreOriginal();
114:                return theOriginalWindow.getLockObject();
115:            }
116:
117:            public String getName() {
118:                return theVirtualName;
119:            }
120:
121:            public VisualComponent getParent() {
122:                restoreOriginal();
123:                return theOriginalWindow.getParent();
124:            }
125:
126:            public VisualComponent getRootComponent() {
127:                restoreOriginal();
128:                return theOriginalWindow.getRootComponent();
129:            }
130:
131:            public VisualComponent getTopParent() {
132:                restoreOriginal();
133:                return theOriginalWindow.getTopParent();
134:            }
135:
136:            public String getTypeId() {
137:                restoreOriginal();
138:                return theOriginalWindow.getTypeId();
139:            }
140:
141:            public String getUIClassID() {
142:                restoreOriginal();
143:                return theOriginalWindow.getUIClassID();
144:            }
145:
146:            public int hashCode() {
147:                restoreOriginal();
148:                return theOriginalWindow.hashCode();
149:            }
150:
151:            public void putClientProperty(Object aKey, Object aValue) {
152:                restoreOriginal();
153:                theOriginalWindow.putClientProperty(aKey, aValue);
154:            }
155:
156:            public void removeChild(VisualComponent aChild) {
157:                restoreOriginal();
158:                theOriginalWindow.removeChild(aChild);
159:            }
160:
161:            public void setBounds(Rectangle aRectangle) {
162:                restoreOriginal();
163:                theOriginalWindow.setBounds(aRectangle);
164:            }
165:
166:            public void setChilds(List list) {
167:                restoreOriginal();
168:                theOriginalWindow.setChilds(list);
169:            }
170:
171:            public void setContributor(ComponentContributor contributor) {
172:                restoreOriginal();
173:                theOriginalWindow.setContributor(contributor);
174:            }
175:
176:            public void setName(String string) {
177:                restoreOriginal();
178:                theOriginalWindow.setName(string);
179:            }
180:
181:            public void setParent(VisualComponent id) {
182:                restoreOriginal();
183:                theOriginalWindow.setParent(id);
184:            }
185:
186:            public void setRootComponent(VisualComponent aRootComponent) {
187:                restoreOriginal();
188:                theOriginalWindow.setRootComponent(aRootComponent);
189:            }
190:
191:            public String toString() {
192:                restoreOriginal();
193:                return theOriginalWindow.toString();
194:            }
195:
196:            public VisualWindow newInstance() {
197:                restoreOriginal();
198:                return theOriginalWindow.newInstance();
199:            }
200:
201:            public Object getVirtualInstance(
202:                    PersistenceContributionContainer aPersistenceContainer) {
203:                restoreOriginal();
204:                return ((Virtualizable) theOriginalWindow)
205:                        .getVirtualInstance(aPersistenceContainer);
206:            }
207:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.