Sha256: 4f5631064211cf148e09604a32505e9f251dea20fe0fdc4e145857f4f7e99de2

Contents?: true

Size: 375 Bytes

Versions: 6

Compression:

Stored size: 375 Bytes

Contents

module RubySL
  module Socket
    module Foreign
      class Sockaddr < Rubinius::FFI::Struct
        config("rbx.platform.sockaddr", :sa_data, :sa_family)

        def data
          self[:sa_data]
        end

        def family
          self[:sa_family]
        end

        def to_s
          pointer.read_string(self.class.size)
        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/sockaddr.rb
rubysl-socket-2.2 lib/rubysl/socket/foreign/sockaddr.rb
rubysl-socket-2.1.3 lib/rubysl/socket/foreign/sockaddr.rb
rubysl-socket-2.1.2 lib/rubysl/socket/foreign/sockaddr.rb
rubysl-socket-2.1.1 lib/rubysl/socket/foreign/sockaddr.rb
rubysl-socket-2.1.0 lib/rubysl/socket/foreign/sockaddr.rb