Sha256: 1428ef241f3e91fe8110ac9c7c09949bc1c8d8a9f99535530d75402e27e88813

Contents?: true

Size: 764 Bytes

Versions: 3

Compression:

Stored size: 764 Bytes

Contents

# frozen_string_literal: true

# Программа "Зодиакальный гороскоп" (на сегодня, на завтра, на неделю, на месяц, на год)
require_relative 'main'

BASE_URL = 'https://orakul.com/'

module AstrologicalForecast
  def self.predict(date = nil, type = nil, period = nil)
    determinant = AstrologicalForecast::DefinitionSign.new(date: date)

    characteristic = AstrologicalForecast::Type.new(type: type, period: period)

    params = {
      definition: determinant.definition,
      signs: determinant.signs,
      user_type: characteristic.user_type,
      user_period: characteristic.user_period
    }

    forecast = AstrologicalForecast::Forecast.new(params)

    forecast.data_forecast
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
astrological_forecast-1.3.5 lib/astrological_forecast.rb
astrological_forecast-1.3.4 lib/astrological_forecast.rb
astrological_forecast-1.3.3 lib/astrological_forecast.rb