callable_tree 0.3.7 → 0.3.9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (37) hide show
  1. checksums.yaml +4 -4
  2. data/.github/dependabot.yml +7 -0
  3. data/.github/workflows/build.yml +3 -5
  4. data/.github/workflows/codeql-analysis.yml +4 -4
  5. data/.rubocop.yml +6 -0
  6. data/.ruby-version +1 -1
  7. data/CHANGELOG.md +12 -0
  8. data/Gemfile.lock +3 -3
  9. data/README.md +460 -276
  10. data/callable_tree.gemspec +1 -0
  11. data/examples/builder/external-verbosify.rb +87 -0
  12. data/examples/builder/hooks.rb +67 -0
  13. data/examples/builder/identity.rb +91 -0
  14. data/examples/builder/internal-broadcastable.rb +11 -11
  15. data/examples/builder/internal-composable.rb +11 -11
  16. data/examples/builder/internal-seekable.rb +9 -15
  17. data/examples/builder/logging.rb +36 -39
  18. data/examples/{external-verbosify.rb → class/external-verbosify.rb} +3 -5
  19. data/examples/class/hooks.rb +70 -0
  20. data/examples/{identity.rb → class/identity.rb} +3 -5
  21. data/examples/{internal-broadcastable.rb → class/internal-broadcastable.rb} +0 -0
  22. data/examples/{internal-composable.rb → class/internal-composable.rb} +0 -0
  23. data/examples/{internal-seekable.rb → class/internal-seekable.rb} +3 -5
  24. data/examples/{logging.rb → class/logging.rb} +47 -47
  25. data/lib/callable_tree/node/builder.rb +13 -0
  26. data/lib/callable_tree/node/hooks/terminator.rb +99 -0
  27. data/lib/callable_tree/node/internal/strategy/broadcast.rb +19 -2
  28. data/lib/callable_tree/node/internal/strategy/compose.rb +15 -3
  29. data/lib/callable_tree/node/internal/strategy/seek.rb +11 -1
  30. data/lib/callable_tree/node/internal/strategy.rb +10 -2
  31. data/lib/callable_tree/node/internal.rb +22 -28
  32. data/lib/callable_tree/node/root.rb +1 -0
  33. data/lib/callable_tree/version.rb +1 -1
  34. data/lib/callable_tree.rb +1 -0
  35. metadata +17 -11
  36. data/examples/builder/hooks-caller.rb +0 -38
  37. data/examples/hooks-caller.rb +0 -39
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0ebaae495d65a776fa0eea8c4aa5e23a1dca39245f05531b1d79bb7384c27228
4
- data.tar.gz: af843950714bc7302b3fab17fc23a775e5f436f97923aad80783998794d110ab
3
+ metadata.gz: 1f81f9d9f97c638d350599e56656dd0430765f8ab79e572b3906963ffc94d32b
4
+ data.tar.gz: 7fb4ad3eb420568d51cb3c3969969fa5c14bf82d99b6f2fb2035ce081e641d64
5
5
  SHA512:
6
- metadata.gz: 5311c4a2ad2436815362a8349e278b73c8c568a4bf4721c990d7a5b5c8c74d876267dc5729c67f0e6e9a4c540e99cffa3d9ece8b9046acf057ca2f48e20a97ab
7
- data.tar.gz: baa36b79d0ad3ba777fcad27c8b04c7ff1b1da7d665c1f74dbadf49e6d36828ed0fc3d0eaa1cc45c54107e24806a8ec66e4b719095e055260fec8a3ec16669c2
6
+ metadata.gz: cdf78b08f6d7b6ea112b510ac564724b7c15842bc44ccf4e603bc17083f0a0999705656e37277729006f8f955340f21e0191af720b474492d97e74b6cd6c2a51
7
+ data.tar.gz: c0fd6fed3b3ec188b51375558a202543d72ee70aaffe25489dd1cf99c6f8882377e61868e32dc07eed43947cb85248c419c35ebbc89f2ca326f829a0bdb533cd
@@ -0,0 +1,7 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: "github-actions"
4
+ directory: "/"
5
+ schedule:
6
+ interval: "weekly"
7
+ target-branch: "develop"
@@ -5,19 +5,17 @@ jobs:
5
5
  runs-on: ubuntu-latest
6
6
  strategy:
7
7
  matrix:
8
- ruby: ['2.4', '2.5', '2.6', '2.7', '3.0', '3.1']
8
+ ruby: ['2.4', '2.5', '2.6', '2.7', '3.0', '3.1', '3.2.0-preview1']
9
9
  steps:
10
- - uses: actions/checkout@v2
10
+ - uses: actions/checkout@v3
11
11
  - uses: ruby/setup-ruby@v1
12
12
  with:
13
13
  ruby-version: ${{ matrix.ruby }}
14
14
  - run: gem install bundler:2.3.7
15
- - uses: actions/cache@v2
15
+ - uses: actions/cache@v3
16
16
  with:
17
17
  path: vendor/bundle
18
18
  key: ${{ runner.os }}-ruby-${{ matrix.ruby }}-gems-${{ hashFiles('**/Gemfile.lock') }}
19
- restore-keys: |
20
- ${{ runner.os }}-gems-
21
19
  - name: Run bundle install
22
20
  run: |
23
21
  bundle config path vendor/bundle
@@ -38,11 +38,11 @@ jobs:
38
38
 
39
39
  steps:
40
40
  - name: Checkout repository
41
- uses: actions/checkout@v2
41
+ uses: actions/checkout@v3
42
42
 
43
43
  # Initializes the CodeQL tools for scanning.
44
44
  - name: Initialize CodeQL
45
- uses: github/codeql-action/init@v1
45
+ uses: github/codeql-action/init@v2
46
46
  with:
47
47
  languages: ${{ matrix.language }}
48
48
  # If you wish to specify custom queries, you can do so here or in a config file.
@@ -53,7 +53,7 @@ jobs:
53
53
  # Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
54
54
  # If this step fails, then you should remove it and run the build manually (see below)
55
55
  - name: Autobuild
56
- uses: github/codeql-action/autobuild@v1
56
+ uses: github/codeql-action/autobuild@v2
57
57
 
58
58
  # ℹ️ Command-line programs to run using the OS shell.
59
59
  # 📚 https://git.io/JvXDl
@@ -67,4 +67,4 @@ jobs:
67
67
  # make release
68
68
 
69
69
  - name: Perform CodeQL Analysis
70
- uses: github/codeql-action/analyze@v1
70
+ uses: github/codeql-action/analyze@v2
data/.rubocop.yml ADDED
@@ -0,0 +1,6 @@
1
+ AllCops:
2
+ NewCops: enable
3
+ Style/HashSyntax:
4
+ EnforcedShorthandSyntax: never
5
+ Naming/BlockForwarding:
6
+ EnforcedStyle: explicit
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 3.1.1
1
+ 3.1.2
data/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.3.9] - 2022-11-06
4
+
5
+ - Change `CallableTree::Node::Internal#broadcastable` to take `terminable` keyword parameter as boolean. It defaults to `false`, which is the same behavior as before.
6
+ - Change `CallableTree::Node::Internal#composable` to take `terminable` keyword parameter as boolean. It defaults to `false`, which is the same behavior as before.
7
+ - Change `CallableTree::Node::Internal#seekable` to take `terminable` keyword parameter as boolean. It defaults to `true`, which is the same behavior as before.
8
+
9
+ ## [0.3.8] - 2022-05-05
10
+
11
+ - (Experimental) Add `CallableTree::Node::Internal::Builder#identifier`.
12
+ - (Experimental) Add `CallableTree::Node::External::Builder#identifier`.
13
+ - (Experimental) Add `CallableTree::Node::Hooks::Terminator`.
14
+
3
15
  ## [0.3.7] - 2022-04-09
4
16
 
5
17
  - Add `CallableTree::Node#internal?`
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- callable_tree (0.3.7)
4
+ callable_tree (0.3.9)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -14,13 +14,13 @@ GEM
14
14
  rspec-mocks (~> 3.11.0)
15
15
  rspec-core (3.11.0)
16
16
  rspec-support (~> 3.11.0)
17
- rspec-expectations (3.11.0)
17
+ rspec-expectations (3.11.1)
18
18
  diff-lcs (>= 1.2.0, < 2.0)
19
19
  rspec-support (~> 3.11.0)
20
20
  rspec-mocks (3.11.1)
21
21
  diff-lcs (>= 1.2.0, < 2.0)
22
22
  rspec-support (~> 3.11.0)
23
- rspec-support (3.11.0)
23
+ rspec-support (3.11.1)
24
24
 
25
25
  PLATFORMS
26
26
  x86_64-darwin-21