Source Code Cross Referenced for CflowMetaData.java in  » Aspect-oriented » aspectwerkz-2.0 » org » codehaus » aspectwerkz » reflect » 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 » Aspect oriented » aspectwerkz 2.0 » org.codehaus.aspectwerkz.reflect 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /**************************************************************************************
002:         * Copyright (c) Jonas BonŽr, Alexandre Vasseur. All rights reserved.                 *
003:         * http://aspectwerkz.codehaus.org                                                    *
004:         * ---------------------------------------------------------------------------------- *
005:         * The software in this package is published under the terms of the LGPL license      *
006:         * a copy of which has been included with this distribution in the license.txt file.  *
007:         **************************************************************************************/package org.codehaus.aspectwerkz.reflect;
008:
009:        /**
010:         * Holds a tuple that consists of the class info and the info for a specific method.
011:         *
012:         * @author <a href="mailto:jboner@codehaus.org">Jonas BonŽr </a>
013:         * @author <a href="mailto:alex@gnilux.com">Alexandre Vasseur </a>
014:         */
015:        public class CflowMetaData {
016:            /**
017:             * The class name.
018:             */
019:            private final String m_className;
020:
021:            /**
022:             * The class info.
023:             */
024:            private ClassInfo m_classMetaData;
025:
026:            /**
027:             * The method info.
028:             */
029:            private final MethodInfo m_methodMetaData;
030:
031:            /**
032:             * Creates a new ClassNameMethodInfoTuple.
033:             *
034:             * @param classMetaData  the class metaData
035:             * @param methodMetaData the method info
036:             */
037:            public CflowMetaData(final ClassInfo classMetaData,
038:                    final MethodInfo methodMetaData) {
039:                m_className = classMetaData.getName();
040:                m_classMetaData = classMetaData;
041:                m_methodMetaData = methodMetaData;
042:            }
043:
044:            /**
045:             * Returns the class info.
046:             *
047:             * @return the class info
048:             */
049:            public ClassInfo getClassInfo() {
050:                return m_classMetaData;
051:            }
052:
053:            /**
054:             * Returns the class name.
055:             *
056:             * @return the class name
057:             */
058:            public String getClassName() {
059:                return m_className;
060:            }
061:
062:            /**
063:             * Returns the method info.
064:             *
065:             * @return the method info
066:             */
067:            public MethodInfo getMethodInfo() {
068:                return m_methodMetaData;
069:            }
070:
071:            // --- over-ridden methods ---
072:            public String toString() {
073:                return '[' + super .toString() + ": " + ',' + m_className + ','
074:                        + m_classMetaData + ',' + m_methodMetaData + ']';
075:            }
076:
077:            public int hashCode() {
078:                int result = 17;
079:                result = (37 * result) + hashCodeOrZeroIfNull(m_className);
080:                result = (37 * result) + hashCodeOrZeroIfNull(m_classMetaData);
081:                result = (37 * result) + hashCodeOrZeroIfNull(m_methodMetaData);
082:                return result;
083:            }
084:
085:            protected static int hashCodeOrZeroIfNull(final Object o) {
086:                if (null == o) {
087:                    return 19;
088:                }
089:                return o.hashCode();
090:            }
091:
092:            public boolean equals(final Object o) {
093:                if (this  == o) {
094:                    return true;
095:                }
096:                if (!(o instanceof  CflowMetaData)) {
097:                    return false;
098:                }
099:                final CflowMetaData obj = (CflowMetaData) o;
100:                return areEqualsOrBothNull(obj.m_className, this .m_className)
101:                        && areEqualsOrBothNull(obj.m_classMetaData,
102:                                this .m_classMetaData)
103:                        && areEqualsOrBothNull(obj.m_methodMetaData,
104:                                this .m_methodMetaData);
105:            }
106:
107:            protected static boolean areEqualsOrBothNull(final Object o1,
108:                    final Object o2) {
109:                if (null == o1) {
110:                    return (null == o2);
111:                }
112:                return o1.equals(o2);
113:            }
114:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.