Class: ProcessorTemplate

Inherits:
Processor show all
Defined in:
lib/Processors/ProcessorTemplate.rb

Overview

Add to config.yml:

processors:

- ProcessorTemplate:
    class: "ProcessorTemplate"
    parameter1: "value"
    parameter2: "value"
    parameter3: "value"
    ...

Instance Attribute Summary

Attributes inherited from Processor

#baseExecutePath, #config, #configFilePath

Instance Method Summary collapse

Constructor Details

#initialize(config, configFilePath, baseExecutePath) ⇒ ProcessorTemplate

Returns a new instance of ProcessorTemplate.



21
22
23
24
25
26
# File 'lib/Processors/ProcessorTemplate.rb', line 21

def initialize(config, configFilePath, baseExecutePath)
    # init Processor
    # get paraemter from config e.g. config["parameter1"]
    # configFilePath: file path of config file (apple.yml/android.yml)
    # baseExecutePath: user excute path
end

Instance Method Details

#processReviews(reviews, platform) ⇒ Object



28
29
30
31
32
33
34
35
36
37
# File 'lib/Processors/ProcessorTemplate.rb', line 28

def processReviews(reviews, platform)
    if reviews.length < 1
        return reviews
    end

    ## do what your want to do with reviews...
    
    ## return result reviews
    return reviews
end