org.apache.ignite.internal.portable.api

## Interface PortableSerializer

    public interface PortableSerializer

Interface that allows to implement custom serialization logic for portable objects. Can be used instead of `PortableMarshalAware` in case if the class cannot be changed directly.

Portable serializer can be configured for all portable objects via `PortableMarshaller.getSerializer()` method, or for a specific portable type via `PortableTypeConfiguration.getSerializer()` method.

### Method Summary

Methods
`void` `readPortable(Object obj, PortableReader reader)` Reads fields from provided reader.
`void` `writePortable(Object obj, PortableWriter writer)` Writes fields to provided writer.

### Method Detail

#### writePortable

    void writePortable(Object obj,
                     PortableWriter writer)
                       throws PortableException

Writes fields to provided writer.

Parameters:
  `obj` - Empty object.
  `writer` - Portable object writer.
Throws:
  `PortableException` - In case of error.

#### readPortable

    void readPortable(Object obj,
                    PortableReader reader)
                      throws PortableException

Reads fields from provided reader.

Parameters:
  `obj` - Empty object
  `reader` - Portable object reader.
Throws:
  `PortableException` - In case of error.

2015 Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Fabric | : ver. 1.4.0
Release Date | : September 24 2015