mondrian-rest 0.7.1-java → 0.7.2-java

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0226d216ac38421203f90d11844887ffc2070fd3683afa867d8df8204fbc932f
4
- data.tar.gz: 7e802242a410efcb28018191c255d8508635117b3c4472dac452c68b4658d01c
3
+ metadata.gz: ed1a89a7fd34fed09b05bbdc426156e4f6a6b5029e06706400c47bcd33dd96a9
4
+ data.tar.gz: 8e2c135b305e02740276f49f3792fa13ac5c83f58c814910c7e1b6916ebb182e
5
5
  SHA512:
6
- metadata.gz: c8e362c9aab9cd50df5dab2b1ecb808ba94dc60b0c80087d97a0d65be80cfe266f0e311fbe2f5ddbccad877ebf1a78c37d1908c9fae4babed1445a3444dc1f3d
7
- data.tar.gz: 33173f228cc7151a9a4b39dd78a943cbfe36de11e3b5ada4f2f3fbd4a0711d3f4624e1f095ba22164e75b281e40b7ed2d209d2bc61e39a99c25b888d759834f6
6
+ metadata.gz: 3bff20c0e4ee3b619ef4d4bf0e09d66aa5213778b7d9d97f444e914e809d611e2ee802e718210dfa5790020f76573a3c7c4aa9e61fa59b3d37dca8865e28fc6b
7
+ data.tar.gz: 7aba57e8652de450ce8ff897c392c196e5d5deb668f659cd7e56fca8a7d5520f812926a7b2732ac6f0426138dd3bf3d84371284a4230c97760e0eb9dcf16e1c4
data/.travis.yml CHANGED
@@ -1,11 +1,18 @@
1
+ sudo: false
1
2
  language: ruby
3
+ before_install:
4
+ - gem update --system
5
+ - gem install bundler
6
+ - gem install jbundler
2
7
  jdk:
3
8
  - oraclejdk8
4
9
  rvm:
5
- - jruby-9.1.5.0
10
+ - jruby-9.1.13.0
6
11
  env:
7
12
  - JRUBY_OPTS=--debug
8
13
 
14
+ script: rake install_jars && rake
15
+
9
16
  branches:
10
17
  only:
11
18
  - public
@@ -75,8 +75,11 @@ module Mondrian::REST
75
75
  end
76
76
 
77
77
  NEST.map(cprops.map { |cp|
78
- org.olap4j.mdx.IdentifierNode.parseIdentifier(cp).getSegmentList.to_a.map(&:name)
79
- })
78
+ names = org.olap4j.mdx.IdentifierNode.parseIdentifier(cp).getSegmentList.to_a.map(&:name)
79
+ # IF prop in Dim.Hier.Lvl.Prop format, skip names[1]
80
+ names.size == 4 ? [names[0], names[2], names[3]] : names
81
+ })
82
+
80
83
  end
81
84
 
82
85
  ##
@@ -86,7 +89,9 @@ module Mondrian::REST
86
89
  def self.parse_properties(properties, dimensions)
87
90
  properties.map { |p|
88
91
  sl = org.olap4j.mdx.IdentifierNode.parseIdentifier(p).getSegmentList.to_a
89
- if sl.size != 3
92
+ slsize = sl.size
93
+
94
+ if slsize != 3 and slsize != 4
90
95
  raise PropertyError, "Properties must be in the form `Dimension.Level.Property Name`"
91
96
  end
92
97
 
@@ -96,9 +101,11 @@ module Mondrian::REST
96
101
  end
97
102
 
98
103
  sl.map(&:name)
99
- }.group_by(&:first)
100
- .reduce({}) { |h, (k,v)|
101
- h[k] = Hash[v.group_by { |x| x[1] }.map { |k1, v1| [k1, v1.map(&:last)] }]
104
+ }
105
+ .group_by(&:first)
106
+ .reduce({}) { |h, (k,v)|
107
+ h[k] = Hash[v.group_by { |x| x.size == 4 ? x[2] : x[1] }
108
+ .map { |k1, v1| [k1, v1.map(&:last)] }]
102
109
  h
103
110
  }
104
111
  end
@@ -210,7 +210,7 @@ module Mondrian
210
210
  # return the contents of the filter axis
211
211
  # puts self.raw_cell_set.getFilterAxis.inspect
212
212
 
213
- dimensions = self.axis_members.map { |am| am.first.dimension_info }
213
+ dimensions = self.axis_members.map { |am| am.first ? am.first.dimension_info : nil }
214
214
 
215
215
  pprops = unless self.properties.nil?
216
216
  Mondrian::REST::APIHelpers.parse_properties(self.properties,
@@ -1,7 +1,7 @@
1
1
  # coding: utf-8
2
2
  Gem::Specification.new do |s|
3
3
  s.name = "mondrian-rest"
4
- s.version = '0.7.1'
4
+ s.version = '0.7.2'
5
5
  s.authors = ["Manuel Aristarán"]
6
6
  s.email = ["manuel@jazzido.com"]
7
7
  s.homepage = "https://github.com/jazzido/mondrian-rest"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mondrian-rest
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.1
4
+ version: 0.7.2
5
5
  platform: java
6
6
  authors:
7
7
  - Manuel Aristarán
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-09-05 00:00:00.000000000 Z
11
+ date: 2017-09-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  requirement: !ruby/object:Gem::Requirement