Sha256: aec7d06eab5a91196561f5366696ea35fb6b87f585159a4e41e93d9c0fbb9e19

Contents?: true

Size: 337 Bytes

Versions: 6

Compression:

Stored size: 337 Bytes

Contents

module RubySL
  module Socket
    module Foreign
      class Iovec < Rubinius::FFI::Struct
        config('rbx.platform.iovec', :iov_base, :iov_len)

        def self.with_buffer(buffer)
          vec = new

          vec[:iov_base] = buffer
          vec[:iov_len]  = buffer.total

          vec
        end
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
rubysl-socket-2.2.1 lib/rubysl/socket/foreign/iovec.rb
rubysl-socket-2.2 lib/rubysl/socket/foreign/iovec.rb
rubysl-socket-2.1.3 lib/rubysl/socket/foreign/iovec.rb
rubysl-socket-2.1.2 lib/rubysl/socket/foreign/iovec.rb
rubysl-socket-2.1.1 lib/rubysl/socket/foreign/iovec.rb
rubysl-socket-2.1.0 lib/rubysl/socket/foreign/iovec.rb