struct MessagePack::Copy

Overview

Fast copy msgpack objects from IO to IO, without full parse, without create temp objects this is usefull for streaming apis MessagePack::Copy.new(io1, io2).copy_objects(1) This is from 40% to 700% faster than MessagePack::IOUnpacker.new(io1).read.to_msgpack(io2)

Defined in:

message_pack/copy.cr

Constructors

Instance Method Summary

Instance methods inherited from class Object

===(other : MessagePack::Any) ===, to_msgpack(io : IO)
to_msgpack(packer : MessagePack::Packer)
to_msgpack
to_msgpack

Class methods inherited from class Object

from_msgpack(string_or_io, zero_copy = false) from_msgpack

Constructor Detail

def self.new(io_src : IO, io_dst : IO) #

[View source]

Instance Method Detail

def copy_object #

[View source]
def copy_objects(n) #

[View source]
def io_dst : IO #

[View source]
def io_src : IO #

[View source]