Java Doc for UnifiedClassLoader.java in  » EJB-Server-JBoss-4.2.1 » jmx » org » jboss » mx » loading » 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 » EJB Server JBoss 4.2.1 » jmx » org.jboss.mx.loading 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.jboss.mx.loading.RepositoryClassLoader
   org.jboss.mx.loading.UnifiedClassLoader

All known Subclasses:   org.jboss.mx.loading.UnifiedClassLoader3,
UnifiedClassLoader
public class UnifiedClassLoader extends RepositoryClassLoader implements UnifiedClassLoaderMBean,Translatable(Code)
A ClassLoader which loads classes from a single URL in conjunction with the LoaderRepository . Notice that this classloader does not work independently of the repository. A repository reference must be provided via the constructor or the classloader must be explicitly registered to the repository before any attempt to load a class. At this point this is little more than an abstract class maintained as the interface for class loaders as the algorithm of the UnifiedLoaderRepository fails with deadlocks, and several other class loading exceptions in multi- threaded environments.
author:
   Marc Fleury
author:
   Christoph G. Jung
author:
   Scott Stark
author:
   Juha Lindfors
author:
   Bill Burke
version:
   $Revision: 57200 $


Field Summary
protected  URLorigURL
     An optional URL from which url may have been copied.
protected  URLurl
    

Constructor Summary
public  UnifiedClassLoader(URL url)
     Construct a UnifiedClassLoader without registering it to the classloader repository.
public  UnifiedClassLoader(URL url, URL origURL)
     Construct a UnifiedClassLoader without registering it to the classloader repository.
public  UnifiedClassLoader(URL url, URL origURL, ClassLoader parent)
     Construct a UnifiedClassLoader without registering with the classloader repository.
public  UnifiedClassLoader(URL url, LoaderRepository repository)
     Construct a UnifiedClassLoader and registers it to the given repository.
public  UnifiedClassLoader(URL url, URL origURL, LoaderRepository repository)
     Construct a UnifiedClassLoader and registers it to the given repository.
public  UnifiedClassLoader(URL url, MBeanServer server, ObjectName repositoryName)
     UnifiedClassLoader constructor that can be used to register with a particular Loader Repository identified by ObjectName.
public  UnifiedClassLoader(URL url, URL origURL, MBeanServer server, ObjectName repositoryName)
     UnifiedClassLoader constructor that can be used to register with a particular Loader Repository identified by ObjectName.

Method Summary
public  ObjectNamegetObjectName()
     Obtain the ObjectName under which the UCL can be registered with the JMX server.
public  URLgetOrigURL()
     Get the original URL associated with the UCL.
protected  PermissionCollectiongetPermissions(CodeSource cs)
     Override the permissions accessor to use the CodeSource based on the original URL if one exists.
protected  ProtectionDomaingetProtectionDomain()
     Determine the protection domain.
public  URLgetURL()
     Get the URL associated with the UCL.
public  voidunregister()
    

Field Detail
origURL
protected URL origURL(Code)
An optional URL from which url may have been copied. It is used to allow the security permissions to be based on a static url namespace.



url
protected URL url(Code)
One URL per ClassLoader in our case




Constructor Detail
UnifiedClassLoader
public UnifiedClassLoader(URL url)(Code)
Construct a UnifiedClassLoader without registering it to the classloader repository.
Parameters:
  url - the single URL to load classes from.



UnifiedClassLoader
public UnifiedClassLoader(URL url, URL origURL)(Code)
Construct a UnifiedClassLoader without registering it to the classloader repository.
Parameters:
  url - the single URL to load classes from.
Parameters:
  origURL - the possibly null original URL from which url maybe a local copy or nested jar.



UnifiedClassLoader
public UnifiedClassLoader(URL url, URL origURL, ClassLoader parent)(Code)
Construct a UnifiedClassLoader without registering with the classloader repository.
Parameters:
  url - the single URL to load classes from.
Parameters:
  origURL - the possibly null original URL from which url maybe a local copy or nested jar.
Parameters:
  parent - the parent class loader to use



UnifiedClassLoader
public UnifiedClassLoader(URL url, LoaderRepository repository)(Code)
Construct a UnifiedClassLoader and registers it to the given repository.
Parameters:
  url - The single URL to load classes from.
Parameters:
  repository - the repository this classloader delegates to



UnifiedClassLoader
public UnifiedClassLoader(URL url, URL origURL, LoaderRepository repository)(Code)
Construct a UnifiedClassLoader and registers it to the given repository.
Parameters:
  url - The single URL to load classes from.
Parameters:
  origURL - the possibly null original URL from which url maybe a local copy or nested jar.
Parameters:
  repository - the repository this classloader delegates tobe a local copy or nested jar.



UnifiedClassLoader
public UnifiedClassLoader(URL url, MBeanServer server, ObjectName repositoryName) throws Exception(Code)
UnifiedClassLoader constructor that can be used to register with a particular Loader Repository identified by ObjectName.
Parameters:
  url - an URL value
Parameters:
  server - a MBeanServer value
Parameters:
  repositoryName - an ObjectName value
exception:
  Exception - if an error occurs



UnifiedClassLoader
public UnifiedClassLoader(URL url, URL origURL, MBeanServer server, ObjectName repositoryName) throws Exception(Code)
UnifiedClassLoader constructor that can be used to register with a particular Loader Repository identified by ObjectName.
Parameters:
  url - an URL value
Parameters:
  origURL - the possibly null original URL from which url maybe a local copy or nested jar.
Parameters:
  server - a MBeanServer value
Parameters:
  repositoryName - an ObjectName value
exception:
  Exception - if an error occurs




Method Detail
getObjectName
public ObjectName getObjectName() throws MalformedObjectNameException(Code)
Obtain the ObjectName under which the UCL can be registered with the JMX server. This creates a name of the form "jmx.loading:UCL=hashCode" since we don't currently care that UCL be easily queriable.



getOrigURL
public URL getOrigURL()(Code)
Get the original URL associated with the UCL. This may be null.



getPermissions
protected PermissionCollection getPermissions(CodeSource cs)(Code)
Override the permissions accessor to use the CodeSource based on the original URL if one exists. This allows the security policy to be defined in terms of the static URL namespace rather than the local copy or nested URL. This builds a PermissionCollection from: 1. The origURL CodeSource 2. The argument CodeSource 3. The Policy.getPermission(origURL CodeSource) This is necessary because we cannot define the CodeSource the SecureClassLoader uses to register the class under.
Parameters:
  cs - the location and signatures of the codebase.



getProtectionDomain
protected ProtectionDomain getProtectionDomain()(Code)
Determine the protection domain. If we are a copy of the original deployment, use the original url as the codebase. the protection domain



getURL
public URL getURL()(Code)
Get the URL associated with the UCL.



unregister
public void unregister()(Code)



Fields inherited from org.jboss.mx.loading.RepositoryClassLoader
protected ReentrantLock loadLock(Code)(Java Doc)
protected ClassLoader parent(Code)(Java Doc)
protected LoaderRepository repository(Code)(Java Doc)
protected Exception unregisterTrace(Code)(Java Doc)

Methods inherited from org.jboss.mx.loading.RepositoryClassLoader
protected void acquire()(Code)(Java Doc)
public void addToClassBlackList(String name)(Code)(Java Doc)
public void addToResourceBlackList(String name)(Code)(Java Doc)
public void addURL(URL url)(Code)(Java Doc)
protected boolean attempt(long waitMS)(Code)(Java Doc)
public void clearBlackLists()(Code)(Java Doc)
public void clearClassBlackList()(Code)(Java Doc)
public void clearResourceBlackList()(Code)(Java Doc)
protected void definePackage(String className)(Code)(Java Doc)
final public boolean equals(Object other)(Code)(Java Doc)
protected Class findClass(String name) throws ClassNotFoundException(Code)(Java Doc)
protected Class findClassLocally(String name) throws ClassNotFoundException(Code)(Java Doc)
public Enumeration findResources(String name) throws IOException(Code)(Java Doc)
public Enumeration findResourcesLocally(String name) throws IOException(Code)(Java Doc)
public int getAddedOrder()(Code)(Java Doc)
public URL[] getAllURLs()(Code)(Java Doc)
public URL[] getClasspath()(Code)(Java Doc)
public LoaderRepository getLoaderRepository()(Code)(Java Doc)
abstract public ObjectName getObjectName() throws MalformedObjectNameException(Code)(Java Doc)
public Package getPackage(String name)(Code)(Java Doc)
public Package[] getPackages()(Code)(Java Doc)
protected ProtectionDomain getProtectionDomain(URL codesourceUrl)(Code)(Java Doc)
public URL getResource(String name)(Code)(Java Doc)
public URL getResourceLocally(String name)(Code)(Java Doc)
public URL getURL()(Code)(Java Doc)
public URL[] getURLs()(Code)(Java Doc)
final public int hashCode()(Code)(Java Doc)
public boolean isClassBlackListed(String name)(Code)(Java Doc)
public boolean isResourceBlackListed(String name)(Code)(Java Doc)
protected byte[] loadByteCode(String classname) throws ClassNotFoundException, IOException(Code)(Java Doc)
protected byte[] loadByteCode(URL classURL) throws ClassNotFoundException, IOException(Code)(Java Doc)
public Class loadClass(String name, boolean resolve) throws ClassNotFoundException(Code)(Java Doc)
public Class loadClassBefore(String name) throws ClassNotFoundException(Code)(Java Doc)
public synchronized Class loadClassImpl(String name, boolean resolve, int stopAt) throws ClassNotFoundException(Code)(Java Doc)
public Class loadClassLocally(String name, boolean resolve) throws ClassNotFoundException(Code)(Java Doc)
protected void release()(Code)(Java Doc)
public void removeFromClassBlackList(String name)(Code)(Java Doc)
public void removeFromResourceBlackList(String name)(Code)(Java Doc)
public void setAddedOrder(int addedOrder)(Code)(Java Doc)
public void setRepository(LoaderRepository repository)(Code)(Java Doc)
public String toString()(Code)(Java Doc)
public void unregister()(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.