Sha256: 71e25cddf8cbd243236d5f0b16c0b1f233bdf1e372a63d72a4a8129055975d9a

Contents?: true

Size: 1.3 KB

Versions: 3

Compression:

Stored size: 1.3 KB

Contents

require 'ffi'

module Apple
  module System
    module LoggerFunctions
      extend FFI::Library
      ffi_lib FFI::Library::LIBC

      attach_function(:asl_add_log_file, [:pointer, :int], :int)
      attach_function(:asl_close, [:pointer], :void)
      attach_function(:asl_free, [:pointer], :void)
      attach_function(:asl_get, [:pointer, :string], :string)
      attach_function(:asl_key, [:pointer, :uint32], :string)
      attach_function(:asl_log, [:pointer, :pointer, :int, :string, :varargs], :int)
      attach_function(:asl_new, [:uint32], :pointer)
      attach_function(:asl_open, [:string, :string, :uint32], :pointer)
      attach_function(:asl_remove_log_file, [:pointer, :int], :int)
      attach_function(:asl_search, [:pointer, :pointer], :pointer)
      attach_function(:asl_send, [:pointer, :pointer], :int)
      attach_function(:asl_set, [:pointer, :string, :string], :int)
      attach_function(:asl_set_filter, [:pointer, :int], :int)
      attach_function(:asl_set_query, [:pointer, :string, :string, :uint32], :int)
      attach_function(:asl_unset, [:pointer, :string], :int)
      attach_function(:asl_vlog, [:pointer, :pointer, :int, :string, :pointer], :int)
      attach_function(:aslresponse_free, [:pointer], :void)
      attach_function(:aslresponse_next, [:pointer], :pointer)
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
apple-system-logger-0.1.2 lib/apple/system/logger/functions.rb
apple-system-logger-0.1.1 lib/apple/system/logger/functions.rb
apple-system-logger-0.1.0 lib/apple/system/logger/functions.rb