angus-remote 0.0.14 → 0.0.15
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/lib/angus/remote/response/builder.rb +13 -13
- data/lib/angus/remote/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
YWMwMTViZThkMmM0ODg4YjJiYTM5M2M0NjlmNjUzNjFiYTRjMGJmNA==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
MTFjZjRhZmM0OTVlMWYyYzQyMTE1YzEzOTJjM2MzYjVlZDQ0NmQ5ZA==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
ODY3Yzc3MjkxMWY4MGQ5MzcyNmJjNjk5NzA1NGFmNDBmOTJhYzQ4YzBjNTNl
|
10
|
+
MDZlOWI3MzRmMzZlMzBiY2Y2Njg5OWViNGYwY2RiNDUwN2ExZTRmMDI0Yjc3
|
11
|
+
YzQxZjAxZGE3MDE1ZjM5YzNmYTMyMjNhMmUyMjI2NmNiYTg5Y2U=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
NjRiMTM4OTlkNTdmMWZiZjk1MzU5YWI1ZTQwMDE3NjZjZTQxNjBiOGNkYWU0
|
14
|
+
NTRkODUxYjQzNDg2NDIzYjA1NDQzZWRjYTA1NDZiMDNlZWJlMWNkNzNhODZm
|
15
|
+
OWQ0ZTllZDUyM2IxYTc1MmI5ZWUyOTliNTRmNWM2ODEwOTJhMjc=
|
@@ -25,29 +25,29 @@ module Angus
|
|
25
25
|
# specified in the operation response metadata
|
26
26
|
#
|
27
27
|
# @param [Integer] status_code HTTP status_code
|
28
|
-
# @param
|
29
|
-
# @param
|
30
|
-
# @param
|
31
|
-
# @param
|
32
|
-
# @param
|
28
|
+
# @param [String] body HTTP body
|
29
|
+
# @param [String] service_code_name Name of the service that the response belongs to
|
30
|
+
# @param [String] service_version Version of the service that the response belongs to
|
31
|
+
# @param [String] operation_namespace Namespace of the operation that the response belongs to
|
32
|
+
# @param [String] operation_name Name of the operation that the response belongs to
|
33
33
|
#
|
34
34
|
# @return A Response object that responds to the methods:
|
35
35
|
# - status
|
36
36
|
# - messages
|
37
37
|
#
|
38
38
|
# Also, provides one method for each value / object / array returned
|
39
|
-
def self.build(status_code, body, service_code_name,
|
39
|
+
def self.build(status_code, body, service_code_name, service_version, operation_namespace,
|
40
40
|
operation_code_name)
|
41
41
|
service_definition = Angus::Remote::ServiceDirectory.service_definition(
|
42
|
-
service_code_name,
|
42
|
+
service_code_name, service_version
|
43
43
|
)
|
44
44
|
|
45
|
-
self.build_from_definition(status_code, body,
|
46
|
-
operation_code_name)
|
45
|
+
self.build_from_definition(status_code, body, service_code_name, service_version,
|
46
|
+
service_definition, operation_namespace, operation_code_name)
|
47
47
|
end
|
48
48
|
|
49
|
-
def self.build_from_definition(status_code, body,
|
50
|
-
operation_code_name)
|
49
|
+
def self.build_from_definition(status_code, body, service_code_name, service_version,
|
50
|
+
service_definition, operation_namespace, operation_code_name)
|
51
51
|
representations = service_definition.representations
|
52
52
|
glossary = service_definition.glossary
|
53
53
|
|
@@ -63,8 +63,8 @@ module Angus
|
|
63
63
|
# TODO use constants
|
64
64
|
response[:status_code] = status_code
|
65
65
|
response[:body] = body
|
66
|
-
response[:service_code_name] =
|
67
|
-
response[:service_version] =
|
66
|
+
response[:service_code_name] = service_code_name
|
67
|
+
response[:service_version] = service_version
|
68
68
|
response[:operation_namespace] = operation_namespace
|
69
69
|
response[:operation_code_name] = operation_code_name
|
70
70
|
|
data/lib/angus/remote/version.rb
CHANGED