rjb 1.0.1-mswin32 → 1.0.2-mswin32
Sign up to get free protection for your applications and to get access to all the features.
- data/ChangeLog +11 -0
- data/ext/jniwrap.h +1 -1
- data/ext/load.c +5 -1
- data/ext/riconv.c +1 -1
- data/ext/riconv.h +1 -1
- data/ext/rjb.c +8 -4
- data/ext/rjb.h +1 -1
- data/ext/rjbexception.c +1 -1
- data/lib/rjbcore.so +0 -0
- data/test/jp/co/infoseek/hp/arton/rjb/Test.class +0 -0
- data/test/test.rb +7 -1
- metadata +2 -3
- data/test/jp/co/infoseek/hp/arton/rjb/JTest.class +0 -0
data/ChangeLog
CHANGED
@@ -1,3 +1,14 @@
|
|
1
|
+
Sun Oct 08 arton (on behalf of richard apodaca)
|
2
|
+
*load.c
|
3
|
+
support AMD64
|
4
|
+
|
5
|
+
Mon Sep 11 arton
|
6
|
+
*test.rb
|
7
|
+
add a test of arguments types are various array.
|
8
|
+
*Test.java
|
9
|
+
add a test of arguments types are various array.
|
10
|
+
*rjb.c
|
11
|
+
accept nil for array parameter.
|
1
12
|
Sun Sep 10 arton
|
2
13
|
*test.rb
|
3
14
|
add a test of return type is an object wrapped an array
|
data/ext/jniwrap.h
CHANGED
data/ext/load.c
CHANGED
@@ -12,7 +12,7 @@
|
|
12
12
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
13
13
|
* Lesser General Public License for more details.
|
14
14
|
*
|
15
|
-
* $Id: load.c
|
15
|
+
* $Id: load.c 5 2006-10-07 19:51:57Z arton $
|
16
16
|
*/
|
17
17
|
|
18
18
|
#include <stdlib.h>
|
@@ -45,6 +45,10 @@
|
|
45
45
|
#define ARCH "sparcv9"
|
46
46
|
#elif defined(__sparc__)
|
47
47
|
#define ARCH "sparc"
|
48
|
+
#elif defined(__amd64__)
|
49
|
+
#define ARCH "amd64"
|
50
|
+
#undef JVM_TYPE
|
51
|
+
#define JVM_TYPE "server"
|
48
52
|
#elif defined(i586) || defined(__i386__)
|
49
53
|
#define ARCH "i386"
|
50
54
|
#endif
|
data/ext/riconv.c
CHANGED
data/ext/riconv.h
CHANGED
@@ -12,7 +12,7 @@
|
|
12
12
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
13
13
|
* Lesser General Public License for more details.
|
14
14
|
*
|
15
|
-
* $Id: riconv.h
|
15
|
+
* $Id: riconv.h 4 2006-09-11 15:21:38Z arton $
|
16
16
|
*/
|
17
17
|
#ifndef _RICONV_H
|
18
18
|
#define _RICONV_H
|
data/ext/rjb.c
CHANGED
@@ -12,10 +12,10 @@
|
|
12
12
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
13
13
|
* Lesser General Public License for more details.
|
14
14
|
*
|
15
|
-
* $Id: rjb.c
|
15
|
+
* $Id: rjb.c 4 2006-09-11 15:21:38Z arton $
|
16
16
|
*/
|
17
17
|
|
18
|
-
#define RJB_VERSION "1.0.
|
18
|
+
#define RJB_VERSION "1.0.2"
|
19
19
|
|
20
20
|
#include "ruby.h"
|
21
21
|
#include "st.h"
|
@@ -1033,7 +1033,11 @@ static void rv2jarray(JNIEnv* jenv, VALUE val, jvalue* jv, const char* psig, int
|
|
1033
1033
|
{
|
1034
1034
|
int i;
|
1035
1035
|
jarray ja = NULL;
|
1036
|
-
|
1036
|
+
if (NIL_P(val))
|
1037
|
+
{
|
1038
|
+
// no-op, null for an array
|
1039
|
+
}
|
1040
|
+
else if (*(psig + 1) == '[')
|
1037
1041
|
{
|
1038
1042
|
if (TYPE(val) != T_ARRAY) {
|
1039
1043
|
rb_raise(rb_eRuntimeError, "array's rank unmatch");
|
@@ -1864,7 +1868,7 @@ static int check_rtype(JNIEnv* jenv, VALUE v, char* p)
|
|
1864
1868
|
case T_OBJECT:
|
1865
1869
|
// fall down to the next case
|
1866
1870
|
default:
|
1867
|
-
if (pcls)
|
1871
|
+
if (pcls || *p == '[')
|
1868
1872
|
{
|
1869
1873
|
return 1;
|
1870
1874
|
}
|
data/ext/rjb.h
CHANGED
@@ -12,7 +12,7 @@
|
|
12
12
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
13
13
|
* Lesser General Public License for more details.
|
14
14
|
*
|
15
|
-
* $Id: rjb.h
|
15
|
+
* $Id: rjb.h 4 2006-09-11 15:21:38Z arton $
|
16
16
|
* $Log: rjb.h,v $
|
17
17
|
* Revision 1.1 2005/01/16 17:36:10 arton
|
18
18
|
* Initial revision
|
data/ext/rjbexception.c
CHANGED
@@ -12,7 +12,7 @@
|
|
12
12
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
13
13
|
* Lesser General Public License for more details.
|
14
14
|
*
|
15
|
-
* $Id: rjbexception.c
|
15
|
+
* $Id: rjbexception.c 4 2006-09-11 15:21:38Z arton $
|
16
16
|
*/
|
17
17
|
|
18
18
|
#include "ruby.h"
|
data/lib/rjbcore.so
CHANGED
Binary file
|
Binary file
|
data/test/test.rb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/local/env ruby
|
2
|
-
# $Id
|
2
|
+
# $Id: test.rb 4 2006-09-11 15:21:38Z arton $
|
3
3
|
|
4
4
|
require 'test/unit'
|
5
5
|
require 'rjb'
|
@@ -405,5 +405,11 @@ class TestRjb < Test::Unit::TestCase
|
|
405
405
|
assert_equal(2, a[1][0].intValue)
|
406
406
|
assert_equal('Hello World !!', a[1][1].toString)
|
407
407
|
end
|
408
|
+
|
409
|
+
def test_CallByNullForArraies()
|
410
|
+
test = import('jp.co.infoseek.hp.arton.rjb.Test').new
|
411
|
+
assert_equal(nil, test.callWithArraies(nil, nil, nil, nil, nil, nil,
|
412
|
+
nil, nil))
|
413
|
+
end
|
408
414
|
end
|
409
415
|
|
metadata
CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.9.0
|
|
3
3
|
specification_version: 1
|
4
4
|
name: rjb
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 1.0.
|
7
|
-
date: 2006-
|
6
|
+
version: 1.0.2
|
7
|
+
date: 2006-10-08 00:00:00 +09:00
|
8
8
|
summary: Ruby Java bridge
|
9
9
|
require_paths:
|
10
10
|
- lib
|
@@ -47,7 +47,6 @@ files:
|
|
47
47
|
- test/jp/co/infoseek/hp/arton/rjb/Base.class
|
48
48
|
- test/jp/co/infoseek/hp/arton/rjb/ExtBase.class
|
49
49
|
- test/jp/co/infoseek/hp/arton/rjb/IBase.class
|
50
|
-
- test/jp/co/infoseek/hp/arton/rjb/JTest.class
|
51
50
|
- test/jp/co/infoseek/hp/arton/rjb/Test.class
|
52
51
|
- COPYING
|
53
52
|
- ChangeLog
|
Binary file
|