Examples of VersionAwareMarshaller


Examples of org.infinispan.marshall.VersionAwareMarshaller

   @SuppressWarnings("unchecked")
   public <T> T construct(Class<T> componentType) {
      if (componentType.isInterface()) {
         Class componentImpl;
         if (componentType.equals(StreamingMarshaller.class)) {
            VersionAwareMarshaller versionAwareMarshaller = getInstance(VersionAwareMarshaller.class);
            return componentType.cast(versionAwareMarshaller);
         } else {
            // add an "Impl" to the end of the class name and try again
            componentImpl = loadClass(componentType.getName() + "Impl");
         }
View Full Code Here

Examples of org.infinispan.marshall.VersionAwareMarshaller

   @Override
   public <T> T construct(Class<T> componentType) {
      if (componentType.isInterface()) {
         Class componentImpl;
         if (componentType.equals(StreamingMarshaller.class)) {
            VersionAwareMarshaller versionAwareMarshaller = Util.getInstance(VersionAwareMarshaller.class);
            return componentType.cast(versionAwareMarshaller);
         } else if (componentType.equals(InvocationContextContainer.class)) {
            componentImpl = InvocationContextContainerImpl.class;
         } else {
            // add an "Impl" to the end of the class name and try again
View Full Code Here

Examples of org.infinispan.marshall.VersionAwareMarshaller

   @SuppressWarnings("unchecked")
   public <T> T construct(Class<T> componentType) {
      if (componentType.isInterface()) {
         Class componentImpl;
         if (componentType.equals(StreamingMarshaller.class)) {
            VersionAwareMarshaller versionAwareMarshaller = getInstance(VersionAwareMarshaller.class);
            return componentType.cast(versionAwareMarshaller);
         } else {
            // add an "Impl" to the end of the class name and try again
            componentImpl = loadClass(componentType.getName() + "Impl", configuration.getClassLoader());
         }
View Full Code Here

Examples of org.infinispan.marshall.core.VersionAwareMarshaller

      if (isVersionAwareMarshaller) {
         if (componentName.equals(GLOBAL_MARSHALLER))
            comp = new GlobalMarshaller((VersionAwareMarshaller) configMarshaller);
         else if (componentName.equals(CACHE_MARSHALLER))
            comp = new CacheMarshaller(new VersionAwareMarshaller());
         else
            throw new CacheException("Don't know how to handle type " + componentType);
      } else {
         comp = configMarshaller;
      }
View Full Code Here

Examples of org.jboss.cache.marshall.VersionAwareMarshaller

   public VersionAwareMarshaller getMarshaller()
   {
      if (marshaller_ == null)
      {
         marshaller_ = new VersionAwareMarshaller(getRegionManager(), inactiveOnStartup, useRegionBasedMarshalling, getReplicationVersion());
      }
      return marshaller_;
   }
View Full Code Here

Examples of org.jboss.cache.marshall.VersionAwareMarshaller

      buddyGroupsIParticipateIn.put(newGroup.getGroupName(), newGroup);

      // Integrate state transfer from the data owner of the buddy group
      Fqn integrationBase = new Fqn(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN,
              newGroup.getGroupName());
      VersionAwareMarshaller marshaller = null;
      if (cache.getUseRegionBasedMarshalling())
      {
         marshaller = cache.getMarshaller();
      }

      for (Iterator it = state.entrySet().iterator(); it.hasNext();)
      {
         Map.Entry entry = (Map.Entry) it.next();
         Fqn fqn = (Fqn) entry.getKey();
         String fqnS = fqn.toString();
         if (marshaller == null || !marshaller.isInactive(fqn.toString()))
         {
            ClassLoader cl = (marshaller == null) ? null : marshaller.getClassLoader(fqnS);
            Fqn integrationRoot = new Fqn(integrationBase, fqn);
            cache._setState((byte[]) entry.getValue(), integrationRoot, cl);
         }
      }
   }
View Full Code Here

Examples of org.jboss.cache.marshall.VersionAwareMarshaller

   public void testConstructionOrder1()
   {
      Class<Marshaller> componentToTest = Marshaller.class;
      Marshaller m = cr.getOrCreateComponent(null, componentToTest);
      assert m instanceof VersionAwareMarshaller;
      VersionAwareMarshaller vam = (VersionAwareMarshaller) m;
      vam.initReplicationVersions();
      m = (Marshaller) TestingUtil.extractField(vam, "defaultMarshaller");
      assert m instanceof CacheMarshaller210;
   }
View Full Code Here

Examples of org.jboss.cache.marshall.VersionAwareMarshaller

   {
      Class<Marshaller> componentToTest = Marshaller.class;
      configuration.setMarshallerClass(CacheMarshaller200.class.getName());
      Marshaller m = cr.getOrCreateComponent(null, componentToTest);
      assert m instanceof VersionAwareMarshaller;
      VersionAwareMarshaller vam = (VersionAwareMarshaller) m;
      vam.initReplicationVersions();
      m = (Marshaller) TestingUtil.extractField(vam, "defaultMarshaller");
      assert m instanceof CacheMarshaller200;
   }
View Full Code Here

Examples of org.jboss.cache.marshall.VersionAwareMarshaller

   public VersionAwareMarshaller getMarshaller()
   {
      if (marshaller_ == null)
      {
         marshaller_ = new VersionAwareMarshaller(getRegionManager(), inactiveOnStartup, useRegionBasedMarshalling, getReplicationVersion());
      }
      return marshaller_;
   }
View Full Code Here

Examples of org.jboss.cache.marshall.VersionAwareMarshaller

   public VersionAwareMarshaller getMarshaller()
   {
      if (marshaller_ == null)
      {
         marshaller_ = new VersionAwareMarshaller(getRegionManager(), inactiveOnStartup, useRegionBasedMarshalling, getReplicationVersion());
      }
      return marshaller_;
   }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.