sof-cycle 0.1.1 → 0.1.2
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/CHANGELOG.md +6 -6
- data/checksums/sof-cycle-0.1.2.gem.sha512 +1 -0
- data/lib/sof/cycle/version.rb +1 -1
- data/lib/sof/cycle.rb +4 -3
- data/lib/sof/cycles/calendar.rb +2 -0
- data/lib/sof/cycles/dormant.rb +2 -0
- data/lib/sof/cycles/end_of.rb +2 -0
- data/lib/sof/cycles/lookback.rb +2 -0
- data/lib/sof/cycles/volume_only.rb +2 -0
- data/lib/sof/cycles/within.rb +2 -0
- metadata +2 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: ea1c2c9a48bba72114b7681278cd467c57ee147f6f8b1ff176b4508de355920b
|
|
4
|
+
data.tar.gz: 93a7560799df4730a5eaf2d14708b9a24199c0a95d2b01f1487ddc587b0846da
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: baf569f5fb7e0500b8a28915c8f19b86dc97ebee380301787182216d162fd02e659645345d369440959ebde737b59bb8ddd4372dae0bf014a9e3b448e8455e03
|
|
7
|
+
data.tar.gz: 84756e0428c56a7f6dd72e5dc7aa545a587bbffd49479a436e4f8bee2d60ec3496e128f713a36b0169799ff908e0690e4518b147e750eaa0fb662681f0e036a0
|
data/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [0.1.2] - 2024-08-09
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
|
|
12
|
+
- `Cycle#recurring?` to reveal if a given Cycle is one-and-done or must be repeated.
|
|
13
|
+
|
|
8
14
|
## [0.1.1] - 2024-08-09
|
|
9
15
|
|
|
10
16
|
### Added
|
|
@@ -14,9 +20,3 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
14
20
|
subsequent period
|
|
15
21
|
- Add predicate methods for each `Cycle` subclass. E.g. `#dormant?`, `#within?`, etc
|
|
16
22
|
- Refactor into namespaces
|
|
17
|
-
|
|
18
|
-
## [0.1.0] - 2024-07-09
|
|
19
|
-
|
|
20
|
-
### Added
|
|
21
|
-
|
|
22
|
-
- Initial extraction
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
78a488a4cea134800aeca3e3e06461a413c564b111d96b25a74c4ae44b5afa66a04d4c59be33cc455bab0c9b1d80cfdd3af1b980859ae3955cb1fd7350fe1459
|
data/lib/sof/cycle/version.rb
CHANGED
data/lib/sof/cycle.rb
CHANGED
|
@@ -25,7 +25,7 @@ module SOF
|
|
|
25
25
|
|
|
26
26
|
delegate [:activated_notation, :volume, :from, :from_date, :time_span, :period,
|
|
27
27
|
:humanized_period, :period_key, :active?] => :@parser
|
|
28
|
-
delegate [:kind, :volume_only?, :valid_periods] => "self.class"
|
|
28
|
+
delegate [:kind, :recurring?, :volume_only?, :valid_periods] => "self.class"
|
|
29
29
|
delegate [:period_count, :duration] => :time_span
|
|
30
30
|
delegate [:calendar?, :dormant?, :end_of?, :lookback?, :volume_only?,
|
|
31
31
|
:within?] => :kind_inquiry
|
|
@@ -130,10 +130,11 @@ module SOF
|
|
|
130
130
|
@kind = nil
|
|
131
131
|
@valid_periods = []
|
|
132
132
|
|
|
133
|
-
def self.volume_only? = @volume_only
|
|
134
|
-
|
|
135
133
|
class << self
|
|
136
134
|
attr_reader :notation_id, :kind, :valid_periods
|
|
135
|
+
def volume_only? = @volume_only
|
|
136
|
+
|
|
137
|
+
def recurring? = raise "#{name} must implement #{__method__}"
|
|
137
138
|
end
|
|
138
139
|
|
|
139
140
|
# Raises an error if the given period isn't in the list of valid periods.
|
data/lib/sof/cycles/calendar.rb
CHANGED
data/lib/sof/cycles/dormant.rb
CHANGED
data/lib/sof/cycles/end_of.rb
CHANGED
data/lib/sof/cycles/lookback.rb
CHANGED
data/lib/sof/cycles/within.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: sof-cycle
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Jim Gay
|
|
@@ -52,6 +52,7 @@ files:
|
|
|
52
52
|
- Rakefile
|
|
53
53
|
- checksums/sof-cycle-0.1.0.gem.sha512
|
|
54
54
|
- checksums/sof-cycle-0.1.1.gem.sha512
|
|
55
|
+
- checksums/sof-cycle-0.1.2.gem.sha512
|
|
55
56
|
- lib/sof-cycle.rb
|
|
56
57
|
- lib/sof/cycle.rb
|
|
57
58
|
- lib/sof/cycle/version.rb
|