win32-nio 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/CHANGES +4 -0
- data/README +2 -2
- data/lib/win32/nio.rb +1 -1
- data/lib/win32/windows/functions.rb +16 -12
- data/test/test_win32_nio_read.rb +1 -1
- data/win32-nio.gemspec +2 -2
- metadata +3 -3
data/CHANGES
CHANGED
data/README
CHANGED
@@ -49,7 +49,7 @@
|
|
49
49
|
|
50
50
|
= Known Bugs
|
51
51
|
None that I know of. Please log any other bug reports on the RubyForge
|
52
|
-
project page at
|
52
|
+
project page at https://github.com/djberg96/win32-nio.
|
53
53
|
|
54
54
|
= Future Plans
|
55
55
|
The pure Ruby code is really only meant for prototyping. The eventual
|
@@ -60,7 +60,7 @@
|
|
60
60
|
Artistic 2.0
|
61
61
|
|
62
62
|
= Copyright
|
63
|
-
(C) 2008-
|
63
|
+
(C) 2008-2013 Daniel J. Berger, All Rights Reserved
|
64
64
|
|
65
65
|
= Warranty
|
66
66
|
This package is provided "as is" and without any express or
|
data/lib/win32/nio.rb
CHANGED
@@ -3,21 +3,25 @@ require 'ffi'
|
|
3
3
|
module Windows
|
4
4
|
module Functions
|
5
5
|
extend FFI::Library
|
6
|
+
typedef :ulong, :dword
|
7
|
+
typedef :uintptr_t, :handle
|
8
|
+
typedef :pointer, :ptr
|
9
|
+
|
6
10
|
ffi_lib :kernel32
|
7
11
|
ffi_convention :stdcall
|
8
12
|
|
9
|
-
attach_function :CloseHandle, [:
|
10
|
-
attach_function :CreateFileA, [:string, :
|
11
|
-
attach_function :CreateFileW, [:buffer_in, :
|
12
|
-
attach_function :GetOverlappedResult, [:
|
13
|
-
attach_function :GetSystemInfo, [:
|
14
|
-
attach_function :ReadFile, [:
|
15
|
-
attach_function :ReadFileScatter, [:
|
16
|
-
attach_function :SleepEx, [:
|
17
|
-
attach_function :VirtualAlloc, [:
|
18
|
-
attach_function :VirtualFree, [:
|
13
|
+
attach_function :CloseHandle, [:handle], :bool
|
14
|
+
attach_function :CreateFileA, [:string, :dword, :dword, :ptr, :dword, :dword, :handle], :handle
|
15
|
+
attach_function :CreateFileW, [:buffer_in, :dword, :dword, :ptr, :dword, :dword, :handle], :handle
|
16
|
+
attach_function :GetOverlappedResult, [:handle, :ptr, :ptr, :bool], :bool
|
17
|
+
attach_function :GetSystemInfo, [:ptr], :void
|
18
|
+
attach_function :ReadFile, [:handle, :buffer_out, :dword, :ptr, :ptr], :bool
|
19
|
+
attach_function :ReadFileScatter, [:handle, :ptr, :dword, :ptr, :ptr], :bool
|
20
|
+
attach_function :SleepEx, [:dword, :bool], :dword
|
21
|
+
attach_function :VirtualAlloc, [:ptr, :size_t, :dword, :dword], :dword
|
22
|
+
attach_function :VirtualFree, [:dword, :size_t, :dword], :bool
|
19
23
|
|
20
|
-
callback :completion_function, [:
|
21
|
-
attach_function :ReadFileEx, [:
|
24
|
+
callback :completion_function, [:dword, :dword, :ptr], :void
|
25
|
+
attach_function :ReadFileEx, [:handle, :buffer_out, :dword, :ptr, :completion_function], :bool
|
22
26
|
end
|
23
27
|
end
|
data/test/test_win32_nio_read.rb
CHANGED
data/win32-nio.gemspec
CHANGED
@@ -2,11 +2,11 @@ require 'rubygems'
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |spec|
|
4
4
|
spec.name = 'win32-nio'
|
5
|
-
spec.version = '0.1.
|
5
|
+
spec.version = '0.1.1'
|
6
6
|
spec.author = 'Daniel J. Berger'
|
7
7
|
spec.license = 'Artistic 2.0'
|
8
8
|
spec.email = 'djberg96@gmail.com'
|
9
|
-
spec.homepage = '
|
9
|
+
spec.homepage = 'https://github.com/djberg96/win32-nio'
|
10
10
|
spec.summary = 'Native IO for MS Windows'
|
11
11
|
spec.files = Dir['**/*'].reject{ |f| f.include?('git') }
|
12
12
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: win32-nio
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2013-04-10 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: ffi
|
@@ -84,7 +84,7 @@ files:
|
|
84
84
|
- test/test_win32_nio_read.rb
|
85
85
|
- test/test_win32_nio_readlines.rb
|
86
86
|
- win32-nio.gemspec
|
87
|
-
homepage:
|
87
|
+
homepage: https://github.com/djberg96/win32-nio
|
88
88
|
licenses:
|
89
89
|
- Artistic 2.0
|
90
90
|
post_install_message:
|