naether 0.5.2-java → 0.5.3-java
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/VERSION +1 -1
- data/lib/naether.rb +8 -3
- data/lib/naether/java.rb +23 -0
- data/{naether-0.5.2.jar → naether-0.5.3.jar} +0 -0
- data/pom.xml +1 -1
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.5.
|
1
|
+
0.5.3
|
data/lib/naether.rb
CHANGED
@@ -12,7 +12,7 @@ class Naether
|
|
12
12
|
|
13
13
|
# Naether jar path will default to packaged in the gem
|
14
14
|
JAR_LIB = "#{File.dirname(__FILE__)}/.."
|
15
|
-
JAR_PATH = "#{JAR_LIB}/naether-0.5.
|
15
|
+
JAR_PATH = "#{JAR_LIB}/naether-0.5.3.jar" #XXX: hardcoded, should be based on VERSION file
|
16
16
|
|
17
17
|
class << self
|
18
18
|
|
@@ -159,14 +159,19 @@ class Naether
|
|
159
159
|
end
|
160
160
|
|
161
161
|
# Get array of dependencies
|
162
|
-
def dependencies
|
162
|
+
def dependencies
|
163
163
|
Naether::Java.convert_to_ruby_array( @resolver.getDependencies() )
|
164
164
|
end
|
165
165
|
|
166
166
|
# Get array of dependencies as notation
|
167
|
-
def
|
167
|
+
def dependencies_notation
|
168
168
|
Naether::Java.convert_to_ruby_array(@resolver.getDependenciesNotation(), true)
|
169
169
|
end
|
170
|
+
alias_method :dependenciesNotation, :dependencies_notation # some javaism snuck in
|
171
|
+
|
172
|
+
def dependencies_path
|
173
|
+
Naether::Java.convert_to_ruby_hash( @resolver.getDependenciesPath(), true )
|
174
|
+
end
|
170
175
|
|
171
176
|
def dependencies_classpath()
|
172
177
|
@resolver.getResolvedClassPath()
|
data/lib/naether/java.rb
CHANGED
@@ -69,6 +69,29 @@ class Naether
|
|
69
69
|
end
|
70
70
|
end
|
71
71
|
|
72
|
+
def self.convert_to_ruby_hash( java_hash, to_string = false )
|
73
|
+
if Naether.platform == 'java'
|
74
|
+
return java_hash
|
75
|
+
else
|
76
|
+
hash = {}
|
77
|
+
keys = java_hash.keySet()
|
78
|
+
iterator = keys.iterator()
|
79
|
+
if to_string
|
80
|
+
while iterator.hasNext()
|
81
|
+
key = iterator.next().toString()
|
82
|
+
hash[key] = java_hash.get( key ).toString()
|
83
|
+
end
|
84
|
+
else
|
85
|
+
while iterator.hasNext()
|
86
|
+
key = iterator.next()
|
87
|
+
hash[key] = java_hash.get( key )
|
88
|
+
end
|
89
|
+
end
|
90
|
+
|
91
|
+
return hash
|
92
|
+
end
|
93
|
+
end
|
94
|
+
|
72
95
|
#
|
73
96
|
# Handle loading jars for JRuby
|
74
97
|
#
|
Binary file
|
data/pom.xml
CHANGED
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: naether
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.5.
|
5
|
+
version: 0.5.3
|
6
6
|
platform: java
|
7
7
|
authors:
|
8
8
|
- Michael Guymon
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
12
|
|
13
|
-
date: 2011-12-
|
13
|
+
date: 2011-12-14 00:00:00 -05:00
|
14
14
|
default_executable:
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
@@ -74,7 +74,7 @@ files:
|
|
74
74
|
- lib/naether.rb
|
75
75
|
- lib/naether/bootstrap.rb
|
76
76
|
- lib/naether/java.rb
|
77
|
-
- naether-0.5.
|
77
|
+
- naether-0.5.3.jar
|
78
78
|
- pom.xml
|
79
79
|
has_rdoc: true
|
80
80
|
homepage: http://github.com/mguymon/naether
|