Source Code Cross Referenced for WSDLException.java in  » Portal » Open-Portal » com » sun » portal » providers » simplewebservice » wsdl » impl » 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 » Portal » Open Portal » com.sun.portal.providers.simplewebservice.wsdl.impl 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /**
002:         * $Id: WSDLException.java,v 1.5 2003/06/03 10:49:24 sy131129 Exp $
003:         * Copyright 2002-2003 Sun Microsystems, Inc. All
004:         * rights reserved. Use of this product is subject
005:         * to license terms. Federal Acquisitions:
006:         * Commercial Software -- Government Users
007:         * Subject to Standard License Terms and
008:         * Conditions.
009:         *
010:         * Sun, Sun Microsystems, the Sun logo, and Sun ONE
011:         * are trademarks or registered trademarks of Sun Microsystems,
012:         * Inc. in the United States and other countries.
013:         */package com.sun.portal.providers.simplewebservice.wsdl.impl;
014:
015:        import java.io.PrintWriter;
016:        import java.io.StringWriter;
017:
018:        /**
019:         * The WSDLException is thrown from the WSDLReader Class if
020:         * some problem occured while reading the WSDL.
021:         *
022:         */
023:        public class WSDLException extends Exception {
024:
025:            public static final String INVALID_URL = "INVALID_URL";
026:            public static final String INVALID_WSDL = "INVALID_WSDL";
027:            public static final String PARSER_ERROR = "PARSER_ERROR";
028:            public static final String OTHER_ERROR = "OTHER_ERROR";
029:            public static final String CONFIGURATION_ERROR = "CONFIGURATION_ERROR";
030:
031:            private Throwable targetThrowable = null;
032:            private String faultCode = null;
033:
034:            /**
035:             * Public Constructor.
036:             *
037:             * @param faultCode the WSDLException faultCode.
038:             * @param message the WSDLException message.
039:             * @param targetThrowable the target throwable for the WSDLException.
040:             */
041:            public WSDLException(String faultCode, String message,
042:                    Throwable targetThrowable) {
043:                super (message);
044:                this .faultCode = faultCode;
045:                this .targetThrowable = targetThrowable;
046:            }
047:
048:            /**
049:             * Public Constructor.
050:             * @param faultCode the WSDLException faultCode.
051:             * @param message the WSDLException message.
052:             */
053:            public WSDLException(String faultCode, String message) {
054:                this (faultCode, message, null);
055:            }
056:
057:            /**
058:             * Gets the fault code associated with this Exception.
059:             * 
060:             * @return the fault code.
061:             */
062:            public String getFaultCode() {
063:                return faultCode;
064:            }
065:
066:            /**
067:             * Gets the target Throwable associated with this Exception.
068:             * 
069:             * @return the target Throwable.
070:             */
071:            public Throwable getTargetException() {
072:                return targetThrowable;
073:            }
074:
075:            /**
076:             * Gets the message associated with this Exception.
077:             * 
078:             * @return the WSDLException message.
079:             */
080:            public String getMessage() {
081:                StringBuffer strBuf = new StringBuffer();
082:
083:                strBuf.append("WSDLException");
084:
085:                String this Msg = super .getMessage();
086:
087:                String targetMsg = (targetThrowable != null) ? targetThrowable
088:                        .getMessage() : null;
089:
090:                if (this Msg != null
091:                        && (targetMsg == null || !this Msg.equals(targetMsg))) {
092:                    strBuf.append(": " + this Msg);
093:                }
094:
095:                if (targetMsg != null) {
096:                    strBuf.append(": " + targetMsg);
097:                }
098:
099:                if (faultCode != null) {
100:                    strBuf.append("\n faultCode: " + faultCode);
101:                }
102:
103:                return strBuf.toString();
104:            }
105:
106:            /**
107:             * Gets the String representation for this Exception.
108:             * 
109:             * @return the Exception String representation.
110:             */
111:            public String toString() {
112:                StringWriter sw = new StringWriter();
113:                PrintWriter pw = new PrintWriter(sw);
114:
115:                pw.print(getMessage() + ": ");
116:
117:                if (targetThrowable != null) {
118:                    pw.print("\n ");
119:                    targetThrowable.printStackTrace(pw);
120:                }
121:
122:                return sw.toString();
123:            }
124:        }
ww_w._j__a__v__a___2__s___.___co__m___ | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.