reprise 0.1.2-x64-mingw-ucrt → 0.1.3-x64-mingw-ucrt
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Cargo.lock +1 -1
- data/README.md +1 -3
- data/lib/reprise/3.1/reprise.so +0 -0
- data/lib/reprise/3.2/reprise.so +0 -0
- data/lib/reprise/3.3/reprise.so +0 -0
- data/lib/reprise/schedule.rb +27 -7
- data/lib/reprise/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ce911aec52544af3b3c5940ab437f506fef94efe9a2130703b2be9c37c5826b5
|
4
|
+
data.tar.gz: bd44bc05d06e2a81b5a338dc5dc28618b2b65e4a979a3accfd8020df23bcc275
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 353d72834f4aa5df21e85ca21f2d4c8d1221616efab806229e30024ee68d430c6da4ca9eb94956a44d737da46146c6a208bcb4eeedb1e1066f691e76aea5c63c
|
7
|
+
data.tar.gz: 58f3f6bb632e1b3c3e223536a145fa95231a6ab90310e50a4dbc0efeacaf5323e69493023e39bc1dfc0f00b6fcf4eb18b8dd7951fe62e94d72bedc585a4bae2e
|
data/Cargo.lock
CHANGED
data/README.md
CHANGED
@@ -229,7 +229,7 @@ you would probably be much better served by choosing one of those two gems inste
|
|
229
229
|
the influence of Rust leaks into its Ruby API. Alternative gems offer much more flexible APIs that support a variety
|
230
230
|
of more idiomatic calling conventions: they have better, more forgiving ergonomics. Reprise may invest more efforts
|
231
231
|
here in the future, but not until we have landed on a feature-complete, performant core - our primary design goal.
|
232
|
-
Until then,
|
232
|
+
Until then, our API will remain sparse but sufficient.
|
233
233
|
- **Stability.** Reprise is still experimental; we do not yet have a `1.0.0` release or a public roadmap. Breaking changes
|
234
234
|
may be frequent across releases. If you do not want to pin Reprise to a specific version and want a library that you can
|
235
235
|
upgrade without reviewing the changelog, you may want to consider an alternative for now.
|
@@ -317,8 +317,6 @@ How do you filter out recurring series occurrences that conflict with other sche
|
|
317
317
|
in your application?
|
318
318
|
|
319
319
|
At time of writing, alternative gems' solutions to this problem are somewhat wanting:
|
320
|
-
- **None**: It is entirely the responsibility of the client application to handle occurrence exclusions,
|
321
|
-
despite this logic being core to the domain of recurring schedule management.
|
322
320
|
- **Date-based exclusion**: Client applications can pass specific dates when occurrences should be excluded.
|
323
321
|
This is not sufficient except for in the most simple of circumstances. Again, consider our hypothetical
|
324
322
|
Monday @ 12:30 PM recurring series: being able to exclude a specific _date_ from your recurrence rule still
|
data/lib/reprise/3.1/reprise.so
CHANGED
Binary file
|
data/lib/reprise/3.2/reprise.so
CHANGED
Binary file
|
data/lib/reprise/3.3/reprise.so
CHANGED
Binary file
|
data/lib/reprise/schedule.rb
CHANGED
@@ -85,6 +85,12 @@ module Reprise
|
|
85
85
|
# influences occurrence queries, and whether any added exclusions conflict with any of the schedule's
|
86
86
|
# occurrences.
|
87
87
|
|
88
|
+
# @!macro [new] count
|
89
|
+
# @param count [Integer, nil] An optional count limit to apply to the occurrences
|
90
|
+
# of a series; once the schedule has generated the requested number of occurrences,
|
91
|
+
# it will halt further expansion of that specific series. The count takes precedence
|
92
|
+
# over the optional +ends_at+ param.
|
93
|
+
|
88
94
|
# @!macro [new] label
|
89
95
|
# @param label [String, nil] An optional label to apply to all of the occurrences
|
90
96
|
# that are generated from the series. See {Reprise::Core::Occurrence#label}.
|
@@ -93,15 +99,17 @@ module Reprise
|
|
93
99
|
# @!macro duration_in_seconds
|
94
100
|
# @!macro interval
|
95
101
|
# @!macro recurring_series_start_and_end_times
|
102
|
+
# @!macro count
|
96
103
|
# @!macro label
|
97
104
|
# @return [void]
|
98
|
-
def repeat_minutely(time_of_day: nil, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, label: nil)
|
105
|
+
def repeat_minutely(time_of_day: nil, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, count: nil, label: nil)
|
99
106
|
internal_schedule.repeat_minutely(
|
100
107
|
time_of_day: TimeOfDay.new(time_of_day || self.starts_at).to_h,
|
101
108
|
duration_in_seconds:,
|
102
109
|
interval:,
|
103
110
|
starts_at_unix_timestamp: starts_at.presence&.to_i,
|
104
111
|
ends_at_unix_timestamp: ends_at.presence&.to_i,
|
112
|
+
count:,
|
105
113
|
label:
|
106
114
|
)
|
107
115
|
end
|
@@ -110,15 +118,17 @@ module Reprise
|
|
110
118
|
# @!macro duration_in_seconds
|
111
119
|
# @!macro interval
|
112
120
|
# @!macro recurring_series_start_and_end_times
|
121
|
+
# @!macro count
|
113
122
|
# @!macro label
|
114
123
|
# @return [void]
|
115
|
-
def repeat_hourly(time_of_day: nil, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, label: nil)
|
124
|
+
def repeat_hourly(time_of_day: nil, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, count: nil, label: nil)
|
116
125
|
internal_schedule.repeat_hourly(
|
117
126
|
time_of_day: TimeOfDay.new(time_of_day || self.starts_at).to_h,
|
118
127
|
duration_in_seconds:,
|
119
128
|
interval:,
|
120
129
|
starts_at_unix_timestamp: starts_at.presence&.to_i,
|
121
130
|
ends_at_unix_timestamp: ends_at.presence&.to_i,
|
131
|
+
count:,
|
122
132
|
label:
|
123
133
|
)
|
124
134
|
end
|
@@ -127,15 +137,17 @@ module Reprise
|
|
127
137
|
# @!macro duration_in_seconds
|
128
138
|
# @!macro interval
|
129
139
|
# @!macro recurring_series_start_and_end_times
|
140
|
+
# @!macro count
|
130
141
|
# @!macro label
|
131
142
|
# @return [void]
|
132
|
-
def repeat_daily(time_of_day: nil, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, label: nil)
|
143
|
+
def repeat_daily(time_of_day: nil, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, count: nil, label: nil)
|
133
144
|
internal_schedule.repeat_daily(
|
134
145
|
time_of_day: TimeOfDay.new(time_of_day || self.starts_at).to_h,
|
135
146
|
duration_in_seconds:,
|
136
147
|
interval:,
|
137
148
|
starts_at_unix_timestamp: starts_at.presence&.to_i,
|
138
149
|
ends_at_unix_timestamp: ends_at.presence&.to_i,
|
150
|
+
count:,
|
139
151
|
label:
|
140
152
|
)
|
141
153
|
end
|
@@ -145,6 +157,7 @@ module Reprise
|
|
145
157
|
# @!macro duration_in_seconds
|
146
158
|
# @!macro interval
|
147
159
|
# @!macro recurring_series_start_and_end_times
|
160
|
+
# @!macro count
|
148
161
|
# @!macro label
|
149
162
|
# @return [void]
|
150
163
|
# @example with a +time_of_day+ hash
|
@@ -152,7 +165,7 @@ module Reprise
|
|
152
165
|
# @example with a local time for +time_of_day+
|
153
166
|
# local_time = Time.current.in_time_zone(my_current_time_zone)
|
154
167
|
# schedule.repeat_weekly(:monday, time_of_day: local_time, duration_in_seconds: 30)
|
155
|
-
def repeat_weekly(weekday, time_of_day: nil, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, label: nil)
|
168
|
+
def repeat_weekly(weekday, time_of_day: nil, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, count: nil, label: nil)
|
156
169
|
internal_schedule.repeat_weekly(
|
157
170
|
weekday,
|
158
171
|
time_of_day: TimeOfDay.new(time_of_day || self.starts_at).to_h,
|
@@ -160,6 +173,7 @@ module Reprise
|
|
160
173
|
interval:,
|
161
174
|
starts_at_unix_timestamp: starts_at.presence&.to_i,
|
162
175
|
ends_at_unix_timestamp: ends_at.presence&.to_i,
|
176
|
+
count:,
|
163
177
|
label:
|
164
178
|
)
|
165
179
|
end
|
@@ -169,11 +183,12 @@ module Reprise
|
|
169
183
|
# @!macro duration_in_seconds
|
170
184
|
# @!macro interval
|
171
185
|
# @!macro recurring_series_start_and_end_times
|
186
|
+
# @!macro count
|
172
187
|
# @!macro label
|
173
188
|
# @return [void]
|
174
189
|
# @example
|
175
190
|
# schedule.repeat_monthly_by_day(15, time_of_day: { hour: 9 }, duration_in_seconds: 30)
|
176
|
-
def repeat_monthly_by_day(day_number, time_of_day:, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, label: nil)
|
191
|
+
def repeat_monthly_by_day(day_number, time_of_day:, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, count: nil, label: nil)
|
177
192
|
internal_schedule.repeat_monthly_by_day(
|
178
193
|
day_number,
|
179
194
|
time_of_day: TimeOfDay.new(time_of_day || self.starts_at).to_h,
|
@@ -181,6 +196,7 @@ module Reprise
|
|
181
196
|
interval:,
|
182
197
|
starts_at_unix_timestamp: starts_at.presence&.to_i,
|
183
198
|
ends_at_unix_timestamp: ends_at.presence&.to_i,
|
199
|
+
count:,
|
184
200
|
label:
|
185
201
|
)
|
186
202
|
end
|
@@ -191,9 +207,10 @@ module Reprise
|
|
191
207
|
# @!macro duration_in_seconds
|
192
208
|
# @!macro interval
|
193
209
|
# @!macro recurring_series_start_and_end_times
|
210
|
+
# @!macro count
|
194
211
|
# @!macro label
|
195
212
|
# @return [void]
|
196
|
-
def repeat_monthly_by_nth_weekday(weekday, nth_day, time_of_day:, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, label: nil)
|
213
|
+
def repeat_monthly_by_nth_weekday(weekday, nth_day, time_of_day:, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, count: nil, label: nil)
|
197
214
|
internal_schedule.repeat_monthly_by_nth_weekday(
|
198
215
|
weekday,
|
199
216
|
nth_day,
|
@@ -202,6 +219,7 @@ module Reprise
|
|
202
219
|
interval:,
|
203
220
|
starts_at_unix_timestamp: starts_at.presence&.to_i,
|
204
221
|
ends_at_unix_timestamp: ends_at.presence&.to_i,
|
222
|
+
count:,
|
205
223
|
label:
|
206
224
|
)
|
207
225
|
end
|
@@ -211,11 +229,12 @@ module Reprise
|
|
211
229
|
# @!macro duration_in_seconds
|
212
230
|
# @!macro interval
|
213
231
|
# @!macro recurring_series_start_and_end_times
|
232
|
+
# @!macro count
|
214
233
|
# @!macro label
|
215
234
|
# @return [void]
|
216
235
|
# @example
|
217
236
|
# schedule.repeat_annually_by_day(200, duration_in_seconds: 30)
|
218
|
-
def repeat_annually_by_day(day_number, time_of_day:, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, label: nil)
|
237
|
+
def repeat_annually_by_day(day_number, time_of_day:, duration_in_seconds:, interval: 1, starts_at: nil, ends_at: nil, count: nil, label: nil)
|
219
238
|
internal_schedule.repeat_annually_by_day(
|
220
239
|
day_number,
|
221
240
|
time_of_day: TimeOfDay.new(time_of_day || self.starts_at).to_h,
|
@@ -223,6 +242,7 @@ module Reprise
|
|
223
242
|
interval:,
|
224
243
|
starts_at_unix_timestamp: starts_at.presence&.to_i,
|
225
244
|
ends_at_unix_timestamp: ends_at.presence&.to_i,
|
245
|
+
count:,
|
226
246
|
label:
|
227
247
|
)
|
228
248
|
end
|
data/lib/reprise/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: reprise
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: x64-mingw-ucrt
|
6
6
|
authors:
|
7
7
|
- Jordan Hiltunen
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-07-
|
11
|
+
date: 2024-07-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: benchmark-ips
|