Source Code Cross Referenced for CmsExportPoint.java in  » Content-Management-System » opencms » org » opencms » db » 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 » Content Management System » opencms » org.opencms.db 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * File   : $Source: /usr/local/cvs/opencms/src/org/opencms/db/CmsExportPoint.java,v $
003:         * Date   : $Date: 2008-02-27 12:05:42 $
004:         * Version: $Revision: 1.13 $
005:         *
006:         * This library is part of OpenCms -
007:         * the Open Source Content Management System
008:         *
009:         * Copyright (c) 2002 - 2008 Alkacon Software GmbH (http://www.alkacon.com)
010:         *
011:         * This library is free software; you can redistribute it and/or
012:         * modify it under the terms of the GNU Lesser General Public
013:         * License as published by the Free Software Foundation; either
014:         * version 2.1 of the License, or (at your option) any later version.
015:         *
016:         * This library is distributed in the hope that it will be useful,
017:         * but WITHOUT ANY WARRANTY; without even the implied warranty of
018:         * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
019:         * Lesser General Public License for more details.
020:         *
021:         * For further information about Alkacon Software GmbH, please see the
022:         * company website: http://www.alkacon.com
023:         *
024:         * For further information about OpenCms, please see the
025:         * project website: http://www.opencms.org
026:         * 
027:         * You should have received a copy of the GNU Lesser General Public
028:         * License along with this library; if not, write to the Free Software
029:         * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
030:         */
031:
032:        package org.opencms.db;
033:
034:        import org.opencms.main.OpenCms;
035:
036:        /**
037:         * Contains the data of a single export point.<p>
038:         *  
039:         * @author Alexander Kandzior 
040:         * 
041:         * @version $Revision: 1.13 $
042:         * 
043:         * @since 6.0.0
044:         */
045:        public class CmsExportPoint {
046:
047:            /** The configured destination path. */
048:            private String m_configuredDestination;
049:
050:            /** The destination path in the "real" file system, relative to the web application folder. */
051:            private String m_destinationPath;
052:
053:            /** The URI of the OpenCms VFS resource (folder) of the export point. */
054:            private String m_uri;
055:
056:            /**
057:             * Creates a new, empty export point.<p>
058:             */
059:            public CmsExportPoint() {
060:
061:                m_uri = "";
062:                m_configuredDestination = "";
063:                m_destinationPath = "";
064:            }
065:
066:            /**
067:             * Creates a new export point.<p>
068:             * 
069:             * @param uri the folder in the OpenCms VFS to write as export point
070:             * @param destination the destination folder in the "real" file system, 
071:             *     relative to the web application root
072:             */
073:            public CmsExportPoint(String uri, String destination) {
074:
075:                m_uri = uri;
076:                m_configuredDestination = destination;
077:                m_destinationPath = OpenCms
078:                        .getSystemInfo()
079:                        .getAbsoluteRfsPathRelativeToWebApplication(destination);
080:            }
081:
082:            /**
083:             * @see java.lang.Object#equals(java.lang.Object)
084:             */
085:            public boolean equals(Object obj) {
086:
087:                if (obj == this ) {
088:                    return true;
089:                }
090:                if (obj instanceof  CmsExportPoint) {
091:                    return ((CmsExportPoint) obj).m_uri.equals(m_uri);
092:                }
093:                return false;
094:            }
095:
096:            /**
097:             * Returns the configured destination path.<p>
098:             * 
099:             * The configured destination path is always relative to the 
100:             * web application path.<p>
101:             * 
102:             * @return the configured destination path
103:             * 
104:             * @see #getDestinationPath()
105:             */
106:            public String getConfiguredDestination() {
107:
108:                return m_configuredDestination;
109:            }
110:
111:            /**
112:             * Returns the destination path in the "real" file system.<p>
113:             * 
114:             * @return the destination
115:             */
116:            public String getDestinationPath() {
117:
118:                return m_destinationPath;
119:            }
120:
121:            /**
122:             * Returns the uri of the OpenCms VFS folder to write as export point.<p>
123:             * 
124:             * @return the uri
125:             */
126:            public String getUri() {
127:
128:                return m_uri;
129:            }
130:
131:            /**
132:             * @see java.lang.Object#hashCode()
133:             */
134:            public int hashCode() {
135:
136:                return getUri().hashCode();
137:            }
138:
139:            /**
140:             * Sets the configured destination path.<p>
141:             * 
142:             * The configured destination path is always relative to the 
143:             * web application path.<p>
144:             * 
145:             * This set method will automatically set the destination path as well.<p>
146:             * 
147:             * @param value the configured destination path
148:             * 
149:             */
150:            public void setConfiguredDestination(String value) {
151:
152:                m_configuredDestination = value;
153:                m_destinationPath = OpenCms.getSystemInfo()
154:                        .getAbsoluteRfsPathRelativeToWebApplication(
155:                                m_configuredDestination);
156:
157:            }
158:
159:            /**
160:             * Dummy method to expose the destination path as bean property.<p>
161:             * 
162:             * This is required by the {@link org.apache.commons.beanutils.BeanUtils} package in order to
163:             * enable using this Object with the digester.<p>
164:             * 
165:             * The method does not actually change the value of the destination path.
166:             * Use the <code>{@link #setConfiguredDestination(String)}</code> method instead.
167:             * 
168:             * @param value the destination path (will be ignored)
169:             */
170:            public void setDestinationPath(String value) {
171:
172:                if (value == null) {
173:                    // check required to avoid "unused parameter" warning
174:                }
175:            }
176:
177:            /**
178:             * Sets the uri of the OpenCms VFS folder to write as export point.<p>
179:             * 
180:             * @param value the uri to set
181:             */
182:            public void setUri(String value) {
183:
184:                m_uri = value;
185:            }
186:
187:            /**
188:             * @see java.lang.Object#toString()
189:             */
190:            public String toString() {
191:
192:                return "[" + getClass().getName() + ", uri: " + m_uri
193:                        + ", destination: " + m_destinationPath + "]";
194:            }
195:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.