Overview

Packages

  • None
  • Yaga

Classes

  • ActedModel
  • ActionController
  • ActionModel
  • AwardCombo
  • BadgeAwardModel
  • BadgeController
  • BadgeModel
  • BadgesController
  • BadgesModule
  • BestController
  • BestFilterModule
  • CakeDayPost
  • CommentCount
  • CommentMarathon
  • DiscussionBodyLength
  • DiscussionCategory
  • DiscussionCount
  • DiscussionPageCount
  • HasMentioned
  • HolidayVisit
  • LeaderBoardModule
  • LengthOfService
  • ManualAward
  • NecroPost
  • NewbieComment
  • PhotoExists
  • PostCount
  • PostReactions
  • QnAAnserCount
  • RankController
  • RankModel
  • ReactController
  • ReactionCount
  • ReactionModel
  • ReflexComment
  • RulesController
  • SocialConnection
  • Yaga
  • YagaController
  • YagaHooks

Interfaces

  • YagaRule
  • Overview
  • Package
  • Class
  • Tree
  • Todo
  • Download

Class RulesController

Manages the building of a rules cache and is provides admin functions for managing badges in the dashboard.

Gdn_Controller
Extended by RulesController
Package: Yaga
Since: 1.0
Located at controllers/class.rulescontroller.php
Methods summary
public
# Initialize( )

May be used in the future.

May be used in the future.

Since

1.0
public static array
# GetRules( )

This checks the cache for current rule set and expires once a day. It loads all php files in the rules folder and selects only those that implement the 'YagaRule' interface.

This checks the cache for current rule set and expires once a day. It loads all php files in the rules folder and selects only those that implement the 'YagaRule' interface.

Returns

array
Rules that are currently available to use. The class names are keys and the friendly names are values.
public static array
# GetInteractionRules( )

This checks the cache for current rule set that can be triggered for a user by another user. It loads all rules and selects only those that return true on its Interacts() method.

This checks the cache for current rule set that can be triggered for a user by another user. It loads all rules and selects only those that return true on its Interacts() method.

Returns

array
Rules that are currently available to use that are interactive.
public
# GetCriteriaForm( string $RuleClass )

This creates a new rule object in a safe way and renders its criteria form.

This creates a new rule object in a safe way and renders its criteria form.

Parameters

$RuleClass
string
$RuleClass
Yaga API documentation generated by ApiGen 2.8.0