bsflow 2.3.0 → 2.4.0
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/Gemfile.lock +1 -1
- data/README.md +37 -0
- data/lib/bsflow/drop_args.rb +11 -0
- data/lib/bsflow/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fe2809ea660acc40e779db1641232e9b4ecc1872641821e874c65a4de3912b8f
|
4
|
+
data.tar.gz: 47cf8932707f68d673d9f9e7e23aa4b964e4c948de0334a5a55fc850542caeba
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 67ae1fd6e8898bdee8fc669796f43f2fa7b93ae2f593e124ff9273d44f2d470a498a122d47bec67eafea863216ebd98c8a9eaf4266c78956370ddfdaad16c9cd
|
7
|
+
data.tar.gz: e3f2421c36acc78ccd81230f97d68a6eca84cdc748ccde4394dd103888516b6859bf2a997ab90a10ee1aa8d49d717857a7afb37d2c70be26d4d462beffb7b4ef
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -378,6 +378,43 @@ Paramaters:
|
|
378
378
|
|
379
379
|
- **_proc_** - an objects responding on `.call` message with one argument.
|
380
380
|
|
381
|
+
### Class BSFlow::DropArgs
|
382
|
+
|
383
|
+
It calls a proc and returns its output. All arguments are ignored.
|
384
|
+
|
385
|
+
Source code:
|
386
|
+
|
387
|
+
```ruby
|
388
|
+
module BSFlow
|
389
|
+
class DropArgs
|
390
|
+
def initialize(proc:)
|
391
|
+
@proc = proc
|
392
|
+
end
|
393
|
+
|
394
|
+
def call(*args)
|
395
|
+
@proc.call
|
396
|
+
end
|
397
|
+
end
|
398
|
+
end
|
399
|
+
```
|
400
|
+
|
401
|
+
#### Require
|
402
|
+
|
403
|
+
```ruby
|
404
|
+
require "bsflow/drop_args"
|
405
|
+
```
|
406
|
+
|
407
|
+
#### Constructor
|
408
|
+
|
409
|
+
```ruby
|
410
|
+
BSFlow:DropArgs.new(proc: proc) # => new_args_dropper
|
411
|
+
```
|
412
|
+
|
413
|
+
Paramaters:
|
414
|
+
|
415
|
+
- **_proc_** - an objects responding on `.call` message without arguments.
|
416
|
+
|
417
|
+
|
381
418
|
### Class BSFlow::Combine
|
382
419
|
|
383
420
|
It passes its `.call` arguments to each injected sub_proc, then it passes their outputs to injected combine_proc and returns the output.
|
data/lib/bsflow/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bsflow
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bartłomiej Sielski
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-11-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -72,6 +72,7 @@ files:
|
|
72
72
|
- bsflow.gemspec
|
73
73
|
- lib/bsflow.rb
|
74
74
|
- lib/bsflow/combine.rb
|
75
|
+
- lib/bsflow/drop_args.rb
|
75
76
|
- lib/bsflow/false.rb
|
76
77
|
- lib/bsflow/first_arg.rb
|
77
78
|
- lib/bsflow/last_arg.rb
|