crv_api_client 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +26 -0
- data/.rspec +2 -0
- data/Gemfile +4 -0
- data/Guardfile +10 -0
- data/LICENSE.txt +22 -0
- data/README.md +47 -0
- data/Rakefile +7 -0
- data/crv_api_client.gemspec +30 -0
- data/lib/crv_api_client/animals.rb +84 -0
- data/lib/crv_api_client/api/animals/animals.rb +1734 -0
- data/lib/crv_api_client/api/animals/animals_driver.rb +113 -0
- data/lib/crv_api_client/api/animals/animals_mapping_registry.rb +2082 -0
- data/lib/crv_api_client/api/animals/rs_animal_service_client.rb +122 -0
- data/lib/crv_api_client/api/animals.rb +9 -0
- data/lib/crv_api_client/api/reproduction/esb_rs_reproduction_service_client.rb +158 -0
- data/lib/crv_api_client/api/reproduction/reproduction.rb +8810 -0
- data/lib/crv_api_client/api/reproduction/reproduction_driver.rb +136 -0
- data/lib/crv_api_client/api/reproduction/reproduction_mapping_registry.rb +5244 -0
- data/lib/crv_api_client/api/reproduction.rb +9 -0
- data/lib/crv_api_client/api.rb +6 -0
- data/lib/crv_api_client/errors.rb +57 -0
- data/lib/crv_api_client/helpers/attributes.rb +34 -0
- data/lib/crv_api_client/helpers/crv.rb +89 -0
- data/lib/crv_api_client/helpers/endpoint.rb +46 -0
- data/lib/crv_api_client/helpers.rb +7 -0
- data/lib/crv_api_client/reproduction.rb +87 -0
- data/lib/crv_api_client/utils/configuration.rb +40 -0
- data/lib/crv_api_client/utils.rb +5 -0
- data/lib/crv_api_client/version.rb +3 -0
- data/lib/crv_api_client.rb +26 -0
- data/spec/lib/crv/animals_spec.rb +95 -0
- data/spec/lib/crv/api/animals/animals_driver_spec.rb +39 -0
- data/spec/lib/crv/api/reproduction/reproduction_driver_spec.rb +39 -0
- data/spec/lib/crv/helpers/attributes_spec.rb +52 -0
- data/spec/lib/crv/helpers/crv_spec.rb +146 -0
- data/spec/lib/crv/helpers/endpoint_spec.rb +54 -0
- data/spec/lib/crv/reproduction_spec.rb +137 -0
- data/spec/lib/crv_spec.rb +22 -0
- data/spec/spec_helper.rb +91 -0
- metadata +204 -0
@@ -0,0 +1,113 @@
|
|
1
|
+
module CrvApiClient::Api::Animals
|
2
|
+
|
3
|
+
class RsAnimalPortType < ::SOAP::RPC::Driver
|
4
|
+
|
5
|
+
DefaultEndpointUrl = "https://acceptatie.cr-delta.nl/event/animal/rsAnimal"
|
6
|
+
|
7
|
+
Methods = [
|
8
|
+
["modifyAnimalManagement",
|
9
|
+
"modifyAnimalManagement",
|
10
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "modifyAnimalManagementRequest"]],
|
11
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "modifyAnimalManagementResponse"]]],
|
12
|
+
{:request_style => :document, :request_use => :literal,
|
13
|
+
:response_style => :document, :response_use => :literal,
|
14
|
+
:faults => {}}
|
15
|
+
],
|
16
|
+
["addPlannedDeparture",
|
17
|
+
"addPlannedDeparture",
|
18
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "addPlannedDepartureRequest"]],
|
19
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "addPlannedDepartureResponse"]]],
|
20
|
+
{:request_style => :document, :request_use => :literal,
|
21
|
+
:response_style => :document, :response_use => :literal,
|
22
|
+
:faults => {}}
|
23
|
+
],
|
24
|
+
["deletePlannedDeparture",
|
25
|
+
"deletePlannedDeparture",
|
26
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "deletePlannedDepartureRequest"]],
|
27
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "deletePlannedDepartureResponse"]]],
|
28
|
+
{:request_style => :document, :request_use => :literal,
|
29
|
+
:response_style => :document, :response_use => :literal,
|
30
|
+
:faults => {}}
|
31
|
+
],
|
32
|
+
["listPlannedDeparture",
|
33
|
+
"listPlannedDeparture",
|
34
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "listPlannedDepartureRequest"]],
|
35
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "listPlannedDepartureResponse"]]],
|
36
|
+
{:request_style => :document, :request_use => :literal,
|
37
|
+
:response_style => :document, :response_use => :literal,
|
38
|
+
:faults => {}}
|
39
|
+
],
|
40
|
+
["listFoodChainInformation",
|
41
|
+
"listFoodChainInformation",
|
42
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "listFoodChainInformationRequest"]],
|
43
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "listFoodChainInformationResponse"]]],
|
44
|
+
{:request_style => :document, :request_use => :literal,
|
45
|
+
:response_style => :document, :response_use => :literal,
|
46
|
+
:faults => {}}
|
47
|
+
],
|
48
|
+
["listPlannedArrival",
|
49
|
+
"listPlannedArrival",
|
50
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "listPlannedArrivalRequest"]],
|
51
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "listPlannedArrivalResponse"]]],
|
52
|
+
{:request_style => :document, :request_use => :literal,
|
53
|
+
:response_style => :document, :response_use => :literal,
|
54
|
+
:faults => {}}
|
55
|
+
],
|
56
|
+
["modifyPlannedArrival",
|
57
|
+
"modifyPlannedArrival",
|
58
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "modifyPlannedArrivalRequest"]],
|
59
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "modifyPlannedArrivalResponse"]]],
|
60
|
+
{:request_style => :document, :request_use => :literal,
|
61
|
+
:response_style => :document, :response_use => :literal,
|
62
|
+
:faults => {}}
|
63
|
+
],
|
64
|
+
["getAverageHerdWeight",
|
65
|
+
"getAverageHerdWeight",
|
66
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "getAverageHerdWeightRequest"]],
|
67
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "getAverageHerdWeightResponse"]]],
|
68
|
+
{:request_style => :document, :request_use => :literal,
|
69
|
+
:response_style => :document, :response_use => :literal,
|
70
|
+
:faults => {}}
|
71
|
+
],
|
72
|
+
["listHerdPedigree",
|
73
|
+
"listHerdPedigree",
|
74
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "listHerdPedigreeRequest"]],
|
75
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/animalMessages/", "listHerdPedigreeResponse"]]],
|
76
|
+
{:request_style => :document, :request_use => :literal,
|
77
|
+
:response_style => :document, :response_use => :literal,
|
78
|
+
:faults => {}}
|
79
|
+
]
|
80
|
+
]
|
81
|
+
|
82
|
+
def initialize(endpoint_url = CrvApiClient.configuration.endpoint_animals)
|
83
|
+
endpoint_url ||= DefaultEndpointUrl
|
84
|
+
super(endpoint_url, nil)
|
85
|
+
self.mapping_registry = ::CrvApiClient::Api::Animals::RsAnimalMappingRegistry::EncodedRegistry
|
86
|
+
self.literal_mapping_registry = ::CrvApiClient::Api::Animals::RsAnimalMappingRegistry::LiteralRegistry
|
87
|
+
init_methods
|
88
|
+
end
|
89
|
+
|
90
|
+
private
|
91
|
+
|
92
|
+
def init_methods
|
93
|
+
Methods.each do |definitions|
|
94
|
+
opt = definitions.last
|
95
|
+
if opt[:request_style] == :document
|
96
|
+
add_document_operation(*definitions)
|
97
|
+
else
|
98
|
+
add_rpc_operation(*definitions)
|
99
|
+
qname = definitions[0]
|
100
|
+
name = definitions[2]
|
101
|
+
if qname.name != name and qname.name.capitalize == name.capitalize
|
102
|
+
::SOAP::Mapping.define_singleton_method(self, qname.name) do |*arg|
|
103
|
+
__send__(name, *arg)
|
104
|
+
end
|
105
|
+
end
|
106
|
+
end
|
107
|
+
end
|
108
|
+
end
|
109
|
+
end
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
end
|