/** * Sets {@link BinaryContext}. * <p/> * @param ctx Binary context. */ private void setBinaryContext(BinaryContext ctx, IgniteConfiguration cfg) { ctx.configure(this, cfg); impl = new GridBinaryMarshaller(ctx); }
binaryMarsh = new GridBinaryMarshaller(binaryCtx);
/** * Create binary marshaller. * * @return Marshaller. */ public static GridBinaryMarshaller marshaller() { BinaryContext ctx = new BinaryContext(BinaryNoopMetadataHandler.instance(), new IgniteConfiguration(), new NullLogger()); BinaryMarshaller marsh = new BinaryMarshaller(); marsh.setContext(new MarshallerContextImpl(null, null)); ctx.configure(marsh, new IgniteConfiguration()); return new GridBinaryMarshaller(ctx); }
/** Create new marshaller implementation. */ private GridBinaryMarshaller createImpl(BinaryConfiguration binCfg) { IgniteConfiguration igniteCfg = new IgniteConfiguration(); if (binCfg == null) { binCfg = new BinaryConfiguration(); binCfg.setCompactFooter(false); } igniteCfg.setBinaryConfiguration(binCfg); BinaryContext ctx = new BinaryContext(metaHnd, igniteCfg, new NullLogger()); BinaryMarshaller marsh = new BinaryMarshaller(); marsh.setContext(marshCtx); ctx.configure(marsh, igniteCfg); ctx.registerUserTypesSchema(); return new GridBinaryMarshaller(ctx); } }
/** * Sets {@link BinaryContext}. * <p/> * @param ctx Binary context. */ @SuppressWarnings("UnusedDeclaration") private void setBinaryContext(BinaryContext ctx, IgniteConfiguration cfg) { ctx.configure(this, cfg); impl = new GridBinaryMarshaller(ctx); }
binaryMarsh = new GridBinaryMarshaller(binaryCtx);
/** * Create binary marshaller. * * @return Marshaller. */ @SuppressWarnings("deprecation") public static GridBinaryMarshaller marshaller() { BinaryContext ctx = new BinaryContext(BinaryNoopMetadataHandler.instance(), new IgniteConfiguration(), new NullLogger()); BinaryMarshaller marsh = new BinaryMarshaller(); marsh.setContext(new MarshallerContextImpl(null, null)); ctx.configure(marsh, new IgniteConfiguration()); return new GridBinaryMarshaller(ctx); }
/** Create new marshaller implementation. */ private GridBinaryMarshaller createImpl(BinaryConfiguration binCfg) { IgniteConfiguration igniteCfg = new IgniteConfiguration(); if (binCfg == null) { binCfg = new BinaryConfiguration(); binCfg.setCompactFooter(false); } igniteCfg.setBinaryConfiguration(binCfg); BinaryContext ctx = new BinaryContext(metaHnd, igniteCfg, new NullLogger()); BinaryMarshaller marsh = new BinaryMarshaller(); marsh.setContext(marshCtx); ctx.configure(marsh, igniteCfg); ctx.registerUserTypesSchema(); return new GridBinaryMarshaller(ctx); } }