fdk 0.0.5 → 0.0.6
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/README.md +7 -9
- data/lib/fdk/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0a04c6a05decf6440ece064c24827dd505eebb86
|
4
|
+
data.tar.gz: 2cbbdc2ba37f8c25e2dc067bd42090c4f4409a15
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 936660907b2484d6b9f1082c80d078f156da12e14f014c4252f1d9ddb66f2196480ca1d6d17d051d51e181e9e6f25825a99394f33286222b14c48a66e966cfaa
|
7
|
+
data.tar.gz: e5d8d24886cf711db36422ea9e434fe430bd288320baf5177c4dbe41aa65042aa9da35801294e29277c2a473ab217da937a1141a51e61a8cde8c11358ae8a832
|
data/README.md
CHANGED
@@ -31,21 +31,19 @@ Then simply pass that function to the FDK:
|
|
31
31
|
FDK.call(myfunc)
|
32
32
|
```
|
33
33
|
|
34
|
-
## Example
|
34
|
+
## Full Example
|
35
35
|
|
36
36
|
```ruby
|
37
37
|
require 'fdk'
|
38
38
|
|
39
|
-
def
|
40
|
-
|
39
|
+
def myhandler(context, input)
|
40
|
+
STDERR.puts "request_url: " + context.protocol['request_url']
|
41
|
+
STDERR.puts "call_id: " + context.call_id
|
42
|
+
STDERR.puts "input: " + input.to_s
|
43
|
+
return {message: "Hello " + input['name'].to_s + "!"}
|
41
44
|
end
|
42
45
|
|
43
|
-
FDK.handle(:
|
44
|
-
|
45
|
-
def call(context, input)
|
46
|
-
# Do some work here
|
47
|
-
return "Hello " + input + "!"
|
48
|
-
end
|
46
|
+
FDK.handle(:myhandler)
|
49
47
|
```
|
50
48
|
|
51
49
|
## Running the example that is in the root directory of this repo
|
data/lib/fdk/version.rb
CHANGED