From 9f653408d7feaa2859be69e494cf9353125b9efe Mon Sep 17 00:00:00 2001 From: Stormwind Date: Mon, 23 Feb 2015 22:00:32 +0100 Subject: [PATCH] Use new Storage class The new Storage class is now used. It's atm not used, as it should be, but for the first implementation it's okay. Improvement will follow. --- lib/rubella/output/ascii.rb | 3 ++- lib/rubella/output/image.rb | 3 ++- lib/rubella/weighting/per_value.rb | 3 +-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/lib/rubella/output/ascii.rb b/lib/rubella/output/ascii.rb index f4fe79e..514af0b 100644 --- a/lib/rubella/output/ascii.rb +++ b/lib/rubella/output/ascii.rb @@ -29,7 +29,8 @@ module Rubella @symbols.keys.join(", ") end - def create parsed_list + def create storage + parsed_list = storage.data buckets = parsed_list[0].length columns = parsed_list.length diff --git a/lib/rubella/output/image.rb b/lib/rubella/output/image.rb index cbae72a..a84fcb1 100644 --- a/lib/rubella/output/image.rb +++ b/lib/rubella/output/image.rb @@ -10,7 +10,8 @@ module Rubella @field_size = field_size end - def create parsed_list + def create storage + parsed_list = storage.data buckets = parsed_list[0].length columns = parsed_list.length diff --git a/lib/rubella/weighting/per_value.rb b/lib/rubella/weighting/per_value.rb index a86023c..3da46a0 100644 --- a/lib/rubella/weighting/per_value.rb +++ b/lib/rubella/weighting/per_value.rb @@ -23,7 +23,6 @@ module Rubella # total amount of cores total_amount = data[0].length - # TODO check somewhere, if every dataset has the same amount of cores # prepare data data_list = Array.new() @@ -38,7 +37,7 @@ module Rubella end end - data_list + Rubella::Storage.new data_list end end