org.apache.ignite.internal.managers.communication

## Class GridIoMessageFactory

- java.lang.Object
- - org.apache.ignite.internal.managers.communication.GridIoMessageFactory

All Implemented Interfaces:
  Extension, MessageFactory

    public class GridIoMessageFactory
    extends Object
    implements MessageFactory

Message factory implementation.

### Constructor Summary

Constructors
Constructor and Description
`GridIoMessageFactory(MessageFactory[] ext)`

### Method Summary

Methods
`Message` `create(byte type)` Creates new message instance of provided type.
`static void` `registerCustom(byte type, IgniteOutClosure<Message> c)` Registers factory for custom message.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### GridIoMessageFactory

    public GridIoMessageFactory(MessageFactory[] ext)

Parameters:
  `ext` - Extensions.

### Method Detail

#### create

    public Message create(byte type)

Creates new message instance of provided type.

This method should return `null` if provided message type is unknown to this factory.

Specified by:
  `create` in interface `MessageFactory`
Parameters:
  `type` - Message type.
Returns:
  Message instance.

#### registerCustom

    public static void registerCustom(byte type,
                      IgniteOutClosure<Message> c)

Registers factory for custom message. Used for test purposes.

Parameters:
  `type` - Message type.
  `c` - Message producer.

2015 Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Fabric | : ver. 1.2.0-incubating
Release Date | : June 16 2015