예제 #1
0
 def server_to_defend(ip):
     if APP_DEBUG:
         Log.info('CALLED: Add.server_to_defend(' + str(ip) + ')')
     if not validators.is_ip(ip):
         Log.error(str(ip) + ' is not a valid ip address')
         return False
     return Add.__add__(keys.SERVER_TO_DEFEND, ip)
예제 #2
0
 def game_server(ip):
     if APP_DEBUG:
         Log.info('CALLED: Set.game_server(' + str(ip) + ')')
     if not validators.is_ip(ip):
         Log.error(str(ip) + ' is not a valid ip address')
         return False
     return Set.__set__(keys.GAME_SERVER, ip)
예제 #3
0
 def my_ip(ip):
     if APP_DEBUG:
         Log.info('CALLED: Set.my_ip(' + str(ip) + ')')
     if not validators.is_ip(ip):
         Log.error(str(ip) + ' is not a valid ip address')
         return False
     return Set.__set__(keys.MY_IP, ip)
예제 #4
0
 def team_player(ip='*'):
     if APP_DEBUG:
         Log.info('CALLED: Remove.team_player(' + str(ip) + ')')
     if ip != '*' and not validators.is_ip(ip):
         Log.error(str(ip) + ' is not a valid ip address')
         return False
     return Remove.__remove__(keys.TEAM_PLAYER, ip)
예제 #5
0
 def server_to_defend(ip='*'):
     if APP_DEBUG:
         Log.info('CALLED: Remove.server_to_defend(' + str(ip) + ')')
     if ip != '*' and not validators.is_ip(ip):
         Log.error(str(ip) + ' is not a valid ip address')
         return False
     return Remove.__remove__(keys.SERVER_TO_DEFEND, ip)
예제 #6
0
 def team_player(ip):
     if APP_DEBUG:
         Log.info('CALLED: Add.team_player(' + str(ip) + ')')
     if not validators.is_ip(ip):
         Log.error(str(ip) + ' is not a valid ip address')
         return False
     return Add.__add__(keys.TEAM_PLAYER, ip)