Examples of MarshallingConfiguration


Examples of org.jboss.marshalling.MarshallingConfiguration

   private final ConcurrentWeakKeyHashMap<Thread, PerThreadInstanceHolder> marshallerTL =
         new ConcurrentWeakKeyHashMap<Thread, PerThreadInstanceHolder>();

   public AbstractJBossMarshaller() {
      // Class resolver now set when marshaller/unmarshaller will be created
      baseCfg = new MarshallingConfiguration();
      baseCfg.setExceptionListener(new DebuggingExceptionListener());
      baseCfg.setClassExternalizerFactory(new SerializeWithExtFactory());
      baseCfg.setInstanceCount(DEF_INSTANCE_COUNT);
      baseCfg.setClassCount(DEF_CLASS_COUNT);
      baseCfg.setVersion(3);
View Full Code Here

Examples of org.jboss.marshalling.MarshallingConfiguration

   protected MarshallerFactory factory;

   public GenericJBossMarshaller() {
      factory = Marshalling.getMarshallerFactory("river");

      configuration = new MarshallingConfiguration();
      configuration.setCreator(new SunReflectiveCreator());
      configuration.setExceptionListener(new DebuggingExceptionListener());
      // ContextClassResolver provides same functionality as MarshalledValueInputStream
      configuration.setClassResolver(new ContextClassResolver());
      configuration.setVersion(2);
View Full Code Here

Examples of org.jboss.marshalling.MarshallingConfiguration

      }
   };

   public AbstractJBossMarshaller() {
      // Class resolver now set when marshaller/unmarshaller will be created
      baseCfg = new MarshallingConfiguration();
      baseCfg.setExternalizerCreator(new SunReflectiveCreator());
      baseCfg.setExceptionListener(new DebuggingExceptionListener());
      baseCfg.setClassExternalizerFactory(new SerializeWithExtFactory());
      baseCfg.setInstanceCount(DEF_INSTANCE_COUNT);
      baseCfg.setClassCount(DEF_CLASS_COUNT);
View Full Code Here

Examples of org.jboss.marshalling.MarshallingConfiguration

            throw new IllegalStateException("Failed to start server", e);
        }
        final Unmarshaller unmarshaller;
        final ByteInput byteInput;
        try {
            final MarshallingConfiguration configuration = new MarshallingConfiguration();
            configuration.setVersion(2);
            configuration.setClassTable(ModularClassTable.getInstance());
            unmarshaller = factory.createUnmarshaller(configuration);
            byteInput = Marshalling.createByteInput(initialInput);
            unmarshaller.start(byteInput);
            final ServerTask task = unmarshaller.readObject(ServerTask.class);
            unmarshaller.finish();
View Full Code Here

Examples of org.jboss.marshalling.MarshallingConfiguration

      }
   };

   public AbstractJBossMarshaller() {
      // Class resolver now set when marshaller/unmarshaller will be created
      baseCfg = new MarshallingConfiguration();
      baseCfg.setExternalizerCreator(new SunReflectiveCreator());
      baseCfg.setExceptionListener(new DebuggingExceptionListener());
      baseCfg.setClassExternalizerFactory(new SerializeWithExtFactory());
      baseCfg.setInstanceCount(DEF_INSTANCE_COUNT);
      baseCfg.setClassCount(DEF_CLASS_COUNT);
View Full Code Here

Examples of org.jboss.marshalling.MarshallingConfiguration

    */
   private final ConcurrentMap<Class<?>, Boolean> isMarshallableMap = new ConcurrentWeakKeyHashMap<Class<?>, Boolean>();

   public AbstractJBossMarshaller() {
      // Class resolver now set when marshaller/unmarshaller will be created
      baseCfg = new MarshallingConfiguration();
      baseCfg.setExternalizerCreator(new SunReflectiveCreator());
      baseCfg.setExceptionListener(new DebuggingExceptionListener());
      baseCfg.setClassExternalizerFactory(new SerializeWithExtFactory());
      baseCfg.setInstanceCount(DEF_INSTANCE_COUNT);
      baseCfg.setClassCount(DEF_CLASS_COUNT);
View Full Code Here

Examples of org.jboss.marshalling.MarshallingConfiguration

    private static class JBossMarshaller implements Marshaller {

        private final org.jboss.marshalling.Marshaller delegate;

        JBossMarshaller(final String marshallerType) throws IOException {
            final MarshallingConfiguration marshallingConfiguration = new MarshallingConfiguration();
            marshallingConfiguration.setClassTable(new ProtocolV1ClassTable());
            marshallingConfiguration.setVersion(2);
            org.jboss.marshalling.MarshallerFactory factory = Marshalling.getProvidedMarshallerFactory(marshallerType);
            this.delegate = factory.createMarshaller(marshallingConfiguration);
        }
View Full Code Here

Examples of org.jboss.marshalling.MarshallingConfiguration

            this.marshallerType = marshallerType;
        }

        @Override
        public void start(final DataInput input, final ClassLoaderProvider classLoaderProvider) throws IOException {
            final MarshallingConfiguration marshallingConfiguration = new MarshallingConfiguration();
            marshallingConfiguration.setVersion(2);
            marshallingConfiguration.setClassTable(new ProtocolV1ClassTable());
            marshallingConfiguration.setClassResolver(new LazyClassLoaderClassResolver(classLoaderProvider));
            org.jboss.marshalling.MarshallerFactory factory = Marshalling.getProvidedMarshallerFactory(marshallerType);
            this.delegate = factory.createUnmarshaller(marshallingConfiguration);
            final InputStream is = new InputStream() {
                @Override
                public int read() throws IOException {
View Full Code Here

Examples of org.jboss.marshalling.MarshallingConfiguration

        final Unmarshaller unmarshaller;
        final ByteInput byteInput;
        final AsyncFuture<ServiceContainer> containerFuture;
        try {
            Module.registerURLStreamHandlerFactoryModule(Module.getBootModuleLoader().loadModule(ModuleIdentifier.create("org.jboss.vfs")));
            final MarshallingConfiguration configuration = new MarshallingConfiguration();
            configuration.setVersion(2);
            configuration.setClassResolver(new SimpleClassResolver(DomainServerMain.class.getClassLoader()));
            unmarshaller = factory.createUnmarshaller(configuration);
            byteInput = Marshalling.createByteInput(initialInput);
            unmarshaller.start(byteInput);
            final ServerTask task = unmarshaller.readObject(ServerTask.class);
            unmarshaller.finish();
View Full Code Here

Examples of org.jboss.marshalling.MarshallingConfiguration

      classTable = createMagicNumberClassTable();
      objectTable = createCustomObjectTable();
      externalizerFactoryAndObjectTable = createCustomExternalizerFactory(rpcManager, objectTable);

      configuration = new MarshallingConfiguration();
      configuration.setCreator(new SunReflectiveCreator());
      configuration.setClassTable(classTable);
      configuration.setClassExternalizerFactory(externalizerFactoryAndObjectTable);
      configuration.setObjectTable(objectTable);
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.