class RecordMessageEncoder implements ResponseMessageEncoder<RecordMessage> {

    @Override
    public void encode( Neo4jPack.Packer packer, RecordMessage message ) throws IOException
    {
        AnyValue[] fields = message.fields();
        packer.packStructHeader( 1, message.signature() );
        packer.packListHeader( fields.length );
        for ( AnyValue field : fields )
        {
            packer.pack( field );
        }
    }

}