Package org.jboss.util.loading

Examples of org.jboss.util.loading.ContextClassLoaderSwitcher$NewInstance


  
   // Constructors --------------------------------------------------

   public WebServer()
   {
      @SuppressWarnings("unchecked")
      ContextClassLoaderSwitcher clSwitcher = (ContextClassLoaderSwitcher) AccessController.doPrivileged(ContextClassLoaderSwitcher.INSTANTIATOR);
      this.tclSwitcher = clSwitcher;
   }
View Full Code Here


      if (cache == null)
      {
         // We are likely going to cause creation and start of a cache here;
         // we don't want to leak the TCCL to cache/jgroups threads, so
         // we switch it to our classloader
         @SuppressWarnings("unchecked")
         ContextClassLoaderSwitcher switcher = (ContextClassLoaderSwitcher) AccessController.doPrivileged(ContextClassLoaderSwitcher.INSTANTIATOR);
         ContextClassLoaderSwitcher.SwitchContext switchContext = switcher.getSwitchContext(getClass().getClassLoader());
         try
         {
            if (cacheObjectName == null)
            {
               CacheManager cm = CacheManagerLocator.getCacheManagerLocator().getCacheManager(null);
View Full Code Here

  
   CacheManagerManagedCache(Cache<K, V> delegate)
   {
      assert delegate != null : "delegate is null";
      this.delegate = delegate;
      @SuppressWarnings("unchecked")
      ContextClassLoaderSwitcher unchecked = (ContextClassLoaderSwitcher) AccessController.doPrivileged(ContextClassLoaderSwitcher.INSTANTIATOR);
      this.switcher = unchecked;
   }
View Full Code Here

      if (cache == null)
      {
         // We are likely going to cause creation and start of a cache here;
         // we don't want to leak the TCCL to cache/jgroups threads, so
         // we switch it to our classloader
         @SuppressWarnings("unchecked")
         ContextClassLoaderSwitcher switcher = (ContextClassLoaderSwitcher) AccessController.doPrivileged(ContextClassLoaderSwitcher.INSTANTIATOR);
         ContextClassLoaderSwitcher.SwitchContext switchContext = switcher.getSwitchContext(getClass().getClassLoader());
         try
         {
            // Determine if our cache is a PojoCache or a plain Cache
            if (cacheObjectName == null)
            {
View Full Code Here

      if (cache == null)
      {
         // We are likely going to cause creation and start of a cache here;
         // we don't want to leak the TCCL to cache/jgroups threads, so
         // we switch it to our classloader
         ContextClassLoaderSwitcher switcher = (ContextClassLoaderSwitcher) AccessController.doPrivileged(ContextClassLoaderSwitcher.INSTANTIATOR);
         ContextClassLoaderSwitcher.SwitchContext switchContext = switcher.getSwitchContext(getClass().getClassLoader());
         try
         {
            // Determine if our cache is a PojoCache or a plain Cache
            if (cacheObjectName == null)
            {
View Full Code Here

      if (cache == null)
      {
         // We are likely going to cause creation and start of a cache here;
         // we don't want to leak the TCCL to cache/jgroups threads, so
         // we switch it to our classloader
         ContextClassLoaderSwitcher switcher = (ContextClassLoaderSwitcher) AccessController.doPrivileged(ContextClassLoaderSwitcher.INSTANTIATOR);
         ContextClassLoaderSwitcher.SwitchContext switchContext = switcher.getSwitchContext(getClass().getClassLoader());
         try
         {
            // Determine if our cache is a PojoCache or a plain Cache
            if (cacheObjectName == null)
            {
View Full Code Here

      if (cache == null)
      {
         // We are likely going to cause creation and start of a cache here;
         // we don't want to leak the TCCL to cache/jgroups threads, so
         // we switch it to our classloader
         @SuppressWarnings("unchecked")
         ContextClassLoaderSwitcher switcher = (ContextClassLoaderSwitcher) AccessController.doPrivileged(ContextClassLoaderSwitcher.INSTANTIATOR);
         ContextClassLoaderSwitcher.SwitchContext switchContext = switcher.getSwitchContext(getClass().getClassLoader());
         try
         {
            if (cacheObjectName == null)
            {
               CacheManager cm = CacheManagerLocator.getCacheManagerLocator().getCacheManager(null);
View Full Code Here

      if (cache == null)
      {
         // We are likely going to cause creation and start of a cache here;
         // we don't want to leak the TCCL to cache/jgroups threads, so
         // we switch it to our classloader
         @SuppressWarnings("unchecked")
         ContextClassLoaderSwitcher switcher = (ContextClassLoaderSwitcher) AccessController.doPrivileged(ContextClassLoaderSwitcher.INSTANTIATOR);
         ContextClassLoaderSwitcher.SwitchContext switchContext = switcher.getSwitchContext(getClass().getClassLoader());
         try
         {
            if (cacheObjectName == null)
            {
               CacheManager cm = CacheManagerLocator.getCacheManagerLocator().getCacheManager(null);
View Full Code Here

  
   CacheManagerManagedCache(Cache<K, V> delegate)
   {
      assert delegate != null : "delegate is null";
      this.delegate = delegate;
      @SuppressWarnings("unchecked")
      ContextClassLoaderSwitcher unchecked = (ContextClassLoaderSwitcher) AccessController.doPrivileged(ContextClassLoaderSwitcher.INSTANTIATOR);
      this.switcher = unchecked;
   }
View Full Code Here

  
   PojoCacheManagerManagedPojoCache(PojoCache delegate)
   {
      assert delegate != null : "delegate is null";
      this.delegate = delegate;
      @SuppressWarnings("unchecked")
      ContextClassLoaderSwitcher unchecked = (ContextClassLoaderSwitcher) AccessController.doPrivileged(ContextClassLoaderSwitcher.INSTANTIATOR);
      this.switcher = unchecked;
   }
View Full Code Here

TOP

Related Classes of org.jboss.util.loading.ContextClassLoaderSwitcher$NewInstance

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.