encommon 0.16.0__tar.gz → 0.17.0__tar.gz

Sign up to get free protection for your applications and to get access to all the features.
Files changed (92) hide show
  1. {encommon-0.16.0/encommon.egg-info → encommon-0.17.0}/PKG-INFO +1 -1
  2. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/test_timer.py +5 -0
  3. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/test_timers.py +4 -0
  4. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/timer.py +14 -0
  5. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/timers.py +17 -0
  6. encommon-0.17.0/encommon/version.txt +1 -0
  7. {encommon-0.16.0 → encommon-0.17.0/encommon.egg-info}/PKG-INFO +1 -1
  8. encommon-0.16.0/encommon/version.txt +0 -1
  9. {encommon-0.16.0 → encommon-0.17.0}/LICENSE +0 -0
  10. {encommon-0.16.0 → encommon-0.17.0}/MANIFEST.in +0 -0
  11. {encommon-0.16.0 → encommon-0.17.0}/README.md +0 -0
  12. {encommon-0.16.0 → encommon-0.17.0}/encommon/__init__.py +0 -0
  13. {encommon-0.16.0 → encommon-0.17.0}/encommon/colors/__init__.py +0 -0
  14. {encommon-0.16.0 → encommon-0.17.0}/encommon/colors/color.py +0 -0
  15. {encommon-0.16.0 → encommon-0.17.0}/encommon/colors/test/__init__.py +0 -0
  16. {encommon-0.16.0 → encommon-0.17.0}/encommon/colors/test/test_color.py +0 -0
  17. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/__init__.py +0 -0
  18. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/config.py +0 -0
  19. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/files.py +0 -0
  20. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/logger.py +0 -0
  21. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/params.py +0 -0
  22. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/paths.py +0 -0
  23. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/test/__init__.py +0 -0
  24. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/test/test_config.py +0 -0
  25. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/test/test_files.py +0 -0
  26. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/test/test_logger.py +0 -0
  27. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/test/test_paths.py +0 -0
  28. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/test/test_utils.py +0 -0
  29. {encommon-0.16.0 → encommon-0.17.0}/encommon/config/utils.py +0 -0
  30. {encommon-0.16.0 → encommon-0.17.0}/encommon/conftest.py +0 -0
  31. {encommon-0.16.0 → encommon-0.17.0}/encommon/crypts/__init__.py +0 -0
  32. {encommon-0.16.0 → encommon-0.17.0}/encommon/crypts/crypts.py +0 -0
  33. {encommon-0.16.0 → encommon-0.17.0}/encommon/crypts/hashes.py +0 -0
  34. {encommon-0.16.0 → encommon-0.17.0}/encommon/crypts/params.py +0 -0
  35. {encommon-0.16.0 → encommon-0.17.0}/encommon/crypts/test/__init__.py +0 -0
  36. {encommon-0.16.0 → encommon-0.17.0}/encommon/crypts/test/test_crypts.py +0 -0
  37. {encommon-0.16.0 → encommon-0.17.0}/encommon/crypts/test/test_hashes.py +0 -0
  38. {encommon-0.16.0 → encommon-0.17.0}/encommon/py.typed +0 -0
  39. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/__init__.py +0 -0
  40. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/common.py +0 -0
  41. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/duration.py +0 -0
  42. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/params.py +0 -0
  43. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/parse.py +0 -0
  44. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/__init__.py +0 -0
  45. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/test_duration.py +0 -0
  46. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/test_params.py +0 -0
  47. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/test_parse.py +0 -0
  48. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/test_time.py +0 -0
  49. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/test_unitime.py +0 -0
  50. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/test_utils.py +0 -0
  51. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/test_window.py +0 -0
  52. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/test/test_windows.py +0 -0
  53. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/time.py +0 -0
  54. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/unitime.py +0 -0
  55. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/utils.py +0 -0
  56. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/window.py +0 -0
  57. {encommon-0.16.0 → encommon-0.17.0}/encommon/times/windows.py +0 -0
  58. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/__init__.py +0 -0
  59. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/classes.py +0 -0
  60. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/dicts.py +0 -0
  61. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/empty.py +0 -0
  62. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/lists.py +0 -0
  63. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/notate.py +0 -0
  64. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/strings.py +0 -0
  65. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/test/__init__.py +0 -0
  66. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/test/test_classes.py +0 -0
  67. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/test/test_dicts.py +0 -0
  68. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/test/test_empty.py +0 -0
  69. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/test/test_lists.py +0 -0
  70. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/test/test_notate.py +0 -0
  71. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/test/test_strings.py +0 -0
  72. {encommon-0.16.0 → encommon-0.17.0}/encommon/types/types.py +0 -0
  73. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/__init__.py +0 -0
  74. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/common.py +0 -0
  75. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/files.py +0 -0
  76. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/match.py +0 -0
  77. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/paths.py +0 -0
  78. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/sample.py +0 -0
  79. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/stdout.py +0 -0
  80. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/test/__init__.py +0 -0
  81. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/test/test_files.py +0 -0
  82. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/test/test_match.py +0 -0
  83. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/test/test_paths.py +0 -0
  84. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/test/test_sample.py +0 -0
  85. {encommon-0.16.0 → encommon-0.17.0}/encommon/utils/test/test_stdout.py +0 -0
  86. {encommon-0.16.0 → encommon-0.17.0}/encommon.egg-info/SOURCES.txt +0 -0
  87. {encommon-0.16.0 → encommon-0.17.0}/encommon.egg-info/dependency_links.txt +0 -0
  88. {encommon-0.16.0 → encommon-0.17.0}/encommon.egg-info/requires.txt +0 -0
  89. {encommon-0.16.0 → encommon-0.17.0}/encommon.egg-info/top_level.txt +0 -0
  90. {encommon-0.16.0 → encommon-0.17.0}/pyproject.toml +0 -0
  91. {encommon-0.16.0 → encommon-0.17.0}/reqs-install.txt +0 -0
  92. {encommon-0.16.0 → encommon-0.17.0}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: encommon
3
- Version: 0.16.0
3
+ Version: 0.17.0
4
4
  Summary: Enasis Network Common Library
5
5
  License: MIT
6
6
  Classifier: Programming Language :: Python :: 3
@@ -68,6 +68,7 @@ def test_Timer(
68
68
  assert timer.remains <= 1
69
69
 
70
70
  assert not timer.ready()
71
+ assert timer.pause()
71
72
 
72
73
 
73
74
  sleep(1)
@@ -77,11 +78,15 @@ def test_Timer(
77
78
  assert timer.remains == 0
78
79
 
79
80
  assert timer.ready()
81
+ assert timer.pause()
80
82
 
81
83
  assert not timer.ready()
84
+ assert timer.pause()
82
85
 
83
86
  timer.update('1980-01-01')
84
87
 
85
88
  assert timer.ready()
89
+ assert timer.pause()
86
90
 
87
91
  assert not timer.ready()
92
+ assert timer.pause()
@@ -151,10 +151,12 @@ def test_Timers_cover(
151
151
 
152
152
 
153
153
  assert timers.ready('two')
154
+ assert timers.pause('two')
154
155
 
155
156
  timers.update('two', 'now')
156
157
 
157
158
  assert not timers.ready('two')
159
+ assert timers.pause('two')
158
160
 
159
161
 
160
162
  timers = Timers()
@@ -165,10 +167,12 @@ def test_Timers_cover(
165
167
  timers.create('fur', params)
166
168
 
167
169
  assert not timers.ready('fur')
170
+ assert timers.pause('fur')
168
171
 
169
172
  sleep(1)
170
173
 
171
174
  assert timers.ready('fur')
175
+ assert timers.pause('fur')
172
176
 
173
177
  timers.delete('fur')
174
178
 
@@ -131,6 +131,20 @@ class Timer:
131
131
  return True
132
132
 
133
133
 
134
+ def pause(
135
+ self,
136
+ update: bool = True,
137
+ ) -> bool:
138
+ """
139
+ Determine whether or not the appropriate time has passed.
140
+
141
+ :param update: Determines whether or not time is updated.
142
+ :returns: Boolean indicating whether enough time passed.
143
+ """
144
+
145
+ return not self.ready(update)
146
+
147
+
134
148
  def update(
135
149
  self,
136
150
  value: Optional[PARSABLE] = None,
@@ -365,6 +365,23 @@ class Timers:
365
365
  return ready
366
366
 
367
367
 
368
+ def pause(
369
+ self,
370
+ unique: str,
371
+ update: bool = True,
372
+ ) -> bool:
373
+ """
374
+ Determine whether or not the appropriate time has passed.
375
+
376
+ :param unique: Unique identifier for the related child.
377
+ :param update: Determines whether or not time is updated.
378
+ :returns: Boolean indicating whether enough time passed.
379
+ """
380
+
381
+ return not self.ready(
382
+ unique, update)
383
+
384
+
368
385
  def create(
369
386
  self,
370
387
  unique: str,
@@ -0,0 +1 @@
1
+ 0.17.0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: encommon
3
- Version: 0.16.0
3
+ Version: 0.17.0
4
4
  Summary: Enasis Network Common Library
5
5
  License: MIT
6
6
  Classifier: Programming Language :: Python :: 3
@@ -1 +0,0 @@
1
- 0.16.0
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes