""" All constants for core module go here. """

TIME_UNIT_MINUTE = 'minute' 
TIME_UNIT_HOUR = 'hour'
TIME_UNIT_DAY = 'day'
TIME_UNIT_WEEK = 'week'
TIME_UNIT_MONTH = 'month'
TIME_UNIT_YEAR = 'year'
TIME_UNIT_LIFE = 'life'
COUNTER_TIME_UNITS = (TIME_UNIT_HOUR, TIME_UNIT_DAY, TIME_UNIT_WEEK, TIME_UNIT_MONTH, TIME_UNIT_YEAR, TIME_UNIT_LIFE)

MIGRATION_INITIAL = 0
MIGRATION_EXECUTING = 1
MIGRATION_FINISHED = 2

FOLLOW_RULE_STATE_INIT = 0
FOLLOW_RULE_STATE_ACTIVATED = 1
FOLLOW_RULE_STATE_EXPIRED = 2
FOLLOW_RULE_STATE_ERROR = 3
FOLLOW_RULE_STATE_EXECUTING = 4
FOLLOW_RULE_STATE_PROTECTED = 5
FOLLOW_RULE_STATE_SUSPEND = 6

FOLLOW_STATS_INACTIVATED = 0
FOLLOW_STATS_ACTIVATED = 1
FOLLOW_STATS_PROTECTED = 2
FOLLOW_STATS_SUSPENDED = 3

FOLLOW_RULE_TO_STATS_MAP = {FOLLOW_RULE_STATE_INIT:FOLLOW_STATS_INACTIVATED,
                            FOLLOW_RULE_STATE_EXPIRED:FOLLOW_STATS_INACTIVATED,
                            FOLLOW_RULE_STATE_ERROR:FOLLOW_STATS_INACTIVATED,
                            FOLLOW_RULE_STATE_SUSPEND:FOLLOW_STATS_SUSPENDED,
                            FOLLOW_RULE_STATE_ACTIVATED:FOLLOW_STATS_ACTIVATED,
                            FOLLOW_RULE_STATE_EXECUTING:FOLLOW_STATS_ACTIVATED,
                            FOLLOW_RULE_STATE_PROTECTED:FOLLOW_STATS_PROTECTED
                            }

FOLLOW_STATS_MAP = {FOLLOW_STATS_INACTIVATED:'Inactivated',
                    FOLLOW_STATS_ACTIVATED:'Activated',
                    FOLLOW_STATS_PROTECTED:'Protected',
                    FOLLOW_STATS_SUSPENDED:'Suspended',
                    }


