/**
* @package Freemius for EDD Add-On
* @copyright Copyright (c) 2015, Freemius, Inc.
* @license https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License Version 3
* @since 1.0.0
*/
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
class FS_Pricing extends FS_Entity {
#region Properties
/**
* @var number
*/
public $plan_id;
/**
* @var int
*/
public $licenses;
/**
* @var null|float
*/
public $monthly_price;
/**
* @var null|float
*/
public $annual_price;
/**
* @var null|float
*/
public $lifetime_price;
/**
* @author Leo Fajardo (@leorw)
* @since 2.3.1
*
* @var string One of the following: `usd`, `gbp`, `eur`.
*/
public $currency;
#endregion Properties
/**
* @param object|bool $pricing
*/
function __construct( $pricing = false ) {
parent::__construct( $pricing );
}
static function get_type() {
return 'pricing';
}
/**
* @author Vova Feldman (@svovaf)
* @since 1.1.8
*
* @return bool
*/
function has_monthly() {
return ( is_numeric( $this->monthly_price ) && $this->monthly_price > 0 );
}
/**
* @author Vova Feldman (@svovaf)
* @since 1.1.8
*
* @return bool
*/
function has_annual() {
return ( is_numeric( $this->annual_price ) && $this->annual_price > 0 );
}
/**
* @author Vova Feldman (@svovaf)
* @since 1.1.8
*
* @return bool
*/
function has_lifetime() {
return ( is_numeric( $this->lifetime_price ) && $this->lifetime_price > 0 );
}
/**
* Check if unlimited licenses pricing.
*
* @author Vova Feldman (@svovaf)
* @since 1.1.8
*
* @return bool
*/
function is_unlimited() {
return is_null( $this->licenses );
}
/**
* Check if pricing has more than one billing cycle.
*
* @author Vova Feldman (@svovaf)
* @since 1.1.8
*
* @return bool
*/
function is_multi_cycle() {
$cycles = 0;
if ( $this->has_monthly() ) {
$cycles ++;
}
if ( $this->has_annual() ) {
$cycles ++;
}
if ( $this->has_lifetime() ) {
$cycles ++;
}
return $cycles > 1;
}
/**
* Get annual over monthly discount.
*
* @author Vova Feldman (@svovaf)
* @since 1.1.8
*
* @return int
*/
function annual_discount_percentage() {
return floor( $this->annual_savings() / ( $this->monthly_price * 12 * ( $this->is_unlimited() ? 1 : $this->licenses ) ) * 100 );
}
/**
* Get annual over monthly savings.
*
* @author Vova Feldman (@svovaf)
* @since 1.1.8
*
* @return float
*/
function annual_savings() {
return ( $this->monthly_price * 12 - $this->annual_price ) * ( $this->is_unlimited() ? 1 : $this->licenses );
}
/**
* @author Leo Fajardo (@leorw)
* @since 2.3.1
*
* @return bool
*/
function is_usd() {
return ( 'usd' === $this->currency );
}
}
Wealth Projecthttps://validator.w3.org/feed/docs/rss2.htmlHome<description>Dive into the exciting world of Tropical Wins Casino & Sportsbook. Enjoy a vast selection of games, seamless sports betting, and exclusive bonuses.</description>Welcome to Casino RiobetWelcome to the Thrilling World of LandboardingWelcome to Casino Hexabet UK<description>Explore essential tips and strategies to enhance your wellness journey. Learn how to improve your physical and mental health effectively.” </description><description>Dive into the exciting world of Magic Win Casino & Sportsbook, where you can enjoy a variety of games and thrilling sports betting.</description><description>Explore the thrilling world of FatPirate Casino Online Slots, featuring exciting games, big wins, and unique themes that will transport you to a high-seas adventure.</description><description>Explore the thrilling world of Cherry Gold Casino & Sportsbook, where unmatched gaming experiences and exciting sports betting await players. Dive into our comprehensive guide to discover why Cherry Gold should be your go-to gaming destination.</description>Welcome to The Grand Idea Online Casino<description>Explore Pyramid Spins Casino & Sportsbook, where thrilling games and exciting sports betting come together. Enjoy seamless gaming experience today!</description><description>Discover Mad Casino & Sportsbook, your premier destination for online gambling and sports betting. Experience a thrilling gaming adventure today!</description><description>Discover the excitement of Neonix Casino, where thrilling games and massive bonuses await. Join now and experience the best in online gambling.</description><description>Delve into the enchanting world of Casino Kingdom, where games, rewards, and adventures await you in a majestic royal setting.</description>The Graeme Hunter Casino Registration Process: A Comprehensive Guide<description>Explore the thrills of Efbet Online Casino UK with its extensive gaming options, bonuses, and user-friendly platform.</description><description>Explore the excitement of CasinoXO Casino & Sportsbook. Enjoy a wide range of games, sports betting, and fantastic promotions on a secure platform.</description><description>Discover how White Cloud Web Design can elevate your business with stunning web design, branding, and comprehensive digital solutions.</description><description>Dive into the exciting world of Mr West Casino, where thrilling games, incredible bonuses, and top-notch service await you. Discover your next favorite game today!</description><description>Discover the exciting world of online gaming at Playoro Casino. Enjoy a vast selection of games, enticing bonuses, and a secure gaming environment.</description>Sky Hills Casino Online Slots: Your Gateway to Exciting Gaming AdventuresWelcome to Casino Lucky Boys<description>Explore Jettbet, a premier online casino offering a wide range of games, exciting bonuses, and top-notch security. Join the adventure today!</description><description>Discover the enchanting world of Casino Golden Genie, where captivating stories and fortunes await. Learn about the games, bonuses, and the magical experience that sets it apart.</description>The Allure of Disco Themed Casinos<description>Explore Casino Wageon, a premier destination for gaming enthusiasts. Unearth strategies, promotions, and the latest updates in the world of online gambling.</description><description>Explore the thrilling world of Scarlet Casino & Sportsbook, where you can enjoy a wide range of games and sports betting options. Join now for an unforgettable experience!</description><description>Dive into the exciting world of Casino MisterX. Explore games, bonuses, and more!</description><description>Explore the captivating universe of Patrick Spins, a unique approach to mastering the art of spinning in different forms. Discover insights, techniques, and the philosophy behind Patrick Spins.</description>Casino Love: A Romantic Gamble<description>Discover the enchanting world of the Iris flower, its symbolism in various cultures, and its significance in garden design and horticulture.</description><description>Explore the thrilling world of God Odds Casino & Sportsbook, where you can enjoy a wide range of games and sports betting options with great odds.</description>Welcome to WinsMania Casino<description>Explore Cryptorino Online Casino UK for a superior gaming experience. Enjoy a vast array of games, exclusive bonuses, and a secure environment.</description>Bonus_e_funzioni_del_gioco_chicken-road-official_it_per_le_puntate_onlineScommesse_e_moltiplicatori_nel_gioco_chicken-road-official_it_per_utentiScommesse_su_chicken-road-official_it_con_l_app_per_le_giocate_onlineFuncionamiento_del_juego_https_chicken-road-es_com_es_con_rondas_de_azar_2707163Moltiplicatori_e_regole_del_gioco_su_https_chicken-road-official_it_per_ogni_punBonus_su_https_chicken-road-official_it_per_le_sessioni_di_gioco_online<description>Dive into the exciting world of Casino Winbeast, where gaming meets luxury and winning becomes a lifestyle. Discover games, bonuses, and more!</description>Welcome to the Enigmatic World of Vampire BingoVampire Bingo: A Spine-Chilling Gaming Adventure<description>Delve into the vibrant offerings of Spinhub Online Casino UK, where thrilling games, generous bonuses, and exceptional player experiences await.</description><description>Explore the thrilling world of online gaming at Rollino Casino. Discover a variety of exciting games, promotions, and bonuses that make Rollino the perfect destination for casino enthusiasts.</description>Welcome to Rollino Casino: Where Thrills Await<description>Discover the exciting world of Orion Spins Online Casino in the UK. Explore games, promotions, and the unique features that set it apart.</description><description>Discover the thrilling world of Orion Spins Online Casino UK where top-notch games, exciting bonuses, and a stellar gaming experience await you.</description>Marchewka Casino: Where Fun Meets FortuneWelcome to Marchewka Casino & Sportsbook