Sha256: 2c1af26fb29bd2b2fca8057cb777b7dbc9a282f20a3a113cdf37b431eab95830

Contents?: true

Size: 618 Bytes

Versions: 30

Compression:

Stored size: 618 Bytes

Contents

module RubyPitaya

  class ServiceBase

    def connect
      raise "Service connect method not implemented"
    end

    def disconnect
      raise "Service disconnect method not implemented"
    end

    def client
      raise "Service client method not implemented"
    end

    def clear_all_data
      environment_name = ENV.fetch('RUBYPITAYA_SERVER_ENVIRONMENT', 'development')
      is_test_environment = environment_name == 'test'

      on_clear_all_data if is_test_environment
    end

    protected

    def on_clear_all_data
      raise "Service on_clear_all_data method not implemented"
    end
  end
end

Version data entries

30 entries across 26 versions & 1 rubygems

Version Path
rubypitaya-3.19.6 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.19.5 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.19.4 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.19.3 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.19.2 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.19.1 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.19.0 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.18.0 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.17.2 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.17.1 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.17.0 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.16.0 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.15.3 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.15.2 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.15.1 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.15.0 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.14.0 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.13.1 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.13.0 ./lib/rubypitaya/core/service_base.rb
rubypitaya-3.12.5 ./lib/rubypitaya/core/service_base.rb