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,136 @@
|
|
1
|
+
module CrvApiClient::Api::Reproduction
|
2
|
+
|
3
|
+
class RsReproductionPortType < ::SOAP::RPC::Driver
|
4
|
+
DefaultEndpointUrl = "https://acceptatie.cr-delta.nl/event/reproduction/rsReproduction"
|
5
|
+
|
6
|
+
Methods = [
|
7
|
+
["listTopGestationCalving",
|
8
|
+
"listTopGestationCalving",
|
9
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listTopGestationCalvingRequest"]],
|
10
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listTopGestationCalvingResponse"]]],
|
11
|
+
{:request_style => :document, :request_use => :literal,
|
12
|
+
:response_style => :document, :response_use => :literal,
|
13
|
+
:faults => {}}
|
14
|
+
],
|
15
|
+
["listFertilization",
|
16
|
+
"listFertilization",
|
17
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listFertilizationRequest"]],
|
18
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listFertilizationResponse"]]],
|
19
|
+
{:request_style => :document, :request_use => :literal,
|
20
|
+
:response_style => :document, :response_use => :literal,
|
21
|
+
:faults => {}}
|
22
|
+
],
|
23
|
+
["addAnimalReproductionIndication",
|
24
|
+
"addAnimalReproductionIndication",
|
25
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "addAnimalReproductionIndicationRequest"]],
|
26
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "addAnimalReproductionIndicationResponse"]]],
|
27
|
+
{:request_style => :document, :request_use => :literal,
|
28
|
+
:response_style => :document, :response_use => :literal,
|
29
|
+
:faults => {}}
|
30
|
+
],
|
31
|
+
["listAnimalReproduction",
|
32
|
+
"listAnimalReproduction",
|
33
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listAnimalReproductionRequest"]],
|
34
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listAnimalReproductionResponse"]]],
|
35
|
+
{:request_style => :document, :request_use => :literal,
|
36
|
+
:response_style => :document, :response_use => :literal,
|
37
|
+
:faults => {}}
|
38
|
+
],
|
39
|
+
["addAiEtDelivery",
|
40
|
+
"addAiEtDelivery",
|
41
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "addAiEtDeliveryRequest"]],
|
42
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "addAiEtDeliveryResponse"]]],
|
43
|
+
{:request_style => :document, :request_use => :literal,
|
44
|
+
:response_style => :document, :response_use => :literal,
|
45
|
+
:faults => {}}
|
46
|
+
],
|
47
|
+
["addPreferredBull",
|
48
|
+
"addPreferredBull",
|
49
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "addPreferredBullRequest"]],
|
50
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "addPreferredBullResponse"]]],
|
51
|
+
{:request_style => :document, :request_use => :literal,
|
52
|
+
:response_style => :document, :response_use => :literal,
|
53
|
+
:faults => {}}
|
54
|
+
],
|
55
|
+
["deletePreferredBull",
|
56
|
+
"deletePreferredBull",
|
57
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "deletePreferredBullRequest"]],
|
58
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "deletePreferredBullResponse"]]],
|
59
|
+
{:request_style => :document, :request_use => :literal,
|
60
|
+
:response_style => :document, :response_use => :literal,
|
61
|
+
:faults => {}}
|
62
|
+
],
|
63
|
+
["listPreferredBull",
|
64
|
+
"listPreferredBull",
|
65
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listPreferredBullRequest"]],
|
66
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listPreferredBullResponse"]]],
|
67
|
+
{:request_style => :document, :request_use => :literal,
|
68
|
+
:response_style => :document, :response_use => :literal,
|
69
|
+
:faults => {}}
|
70
|
+
],
|
71
|
+
["listReproductionLastParity",
|
72
|
+
"listReproductionLastParity",
|
73
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listReproductionLastParityRequest"]],
|
74
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listReproductionLastParityResponse"]]],
|
75
|
+
{:request_style => :document, :request_use => :literal,
|
76
|
+
:response_style => :document, :response_use => :literal,
|
77
|
+
:faults => {}}
|
78
|
+
],
|
79
|
+
["listAnimalReproductionIndication",
|
80
|
+
"listAnimalReproductionIndication",
|
81
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listAnimalIndicationRequest"]],
|
82
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "listAnimalIndicationResponse"]]],
|
83
|
+
{:request_style => :document, :request_use => :literal,
|
84
|
+
:response_style => :document, :response_use => :literal,
|
85
|
+
:faults => {}}
|
86
|
+
],
|
87
|
+
["modifyAnimalReproductionIndication",
|
88
|
+
"modifyAnimalReproductionIndication",
|
89
|
+
[[:in, "requestStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "modifyAnimalIndicationRequest"]],
|
90
|
+
[:out, "responseStream", ["::SOAP::SOAPElement", "http://ws.crvholding.com/reproductionMessages/", "modifyAnimalIndicationResponse"]]],
|
91
|
+
{:request_style => :document, :request_use => :literal,
|
92
|
+
:response_style => :document, :response_use => :literal,
|
93
|
+
:faults => {}}
|
94
|
+
],
|
95
|
+
["GetHerdList",
|
96
|
+
"getHerdList",
|
97
|
+
[[:in, "parameters", ["::SOAP::SOAPElement", "ADEType:1", "GetHerdListRequest"]],
|
98
|
+
[:out, "parameters", ["::SOAP::SOAPElement", "ADEType:1", "GetHerdListResponse"]]],
|
99
|
+
{:request_style => :document, :request_use => :literal,
|
100
|
+
:response_style => :document, :response_use => :literal,
|
101
|
+
:faults => {}}
|
102
|
+
]
|
103
|
+
]
|
104
|
+
|
105
|
+
def initialize(endpoint_url = CrvApiClient.configuration.endpoint_reproduction)
|
106
|
+
endpoint_url ||= DefaultEndpointUrl
|
107
|
+
super(endpoint_url, nil)
|
108
|
+
self.mapping_registry = ::CrvApiClient::Api::Reproduction::RsReproductionMappingRegistry::EncodedRegistry
|
109
|
+
self.literal_mapping_registry = ::CrvApiClient::Api::Reproduction::RsReproductionMappingRegistry::LiteralRegistry
|
110
|
+
init_methods
|
111
|
+
end
|
112
|
+
|
113
|
+
private
|
114
|
+
|
115
|
+
def init_methods
|
116
|
+
Methods.each do |definitions|
|
117
|
+
opt = definitions.last
|
118
|
+
if opt[:request_style] == :document
|
119
|
+
add_document_operation(*definitions)
|
120
|
+
else
|
121
|
+
add_rpc_operation(*definitions)
|
122
|
+
qname = definitions[0]
|
123
|
+
name = definitions[2]
|
124
|
+
if qname.name != name and qname.name.capitalize == name.capitalize
|
125
|
+
::SOAP::Mapping.define_singleton_method(self, qname.name) do |*arg|
|
126
|
+
__send__(name, *arg)
|
127
|
+
end
|
128
|
+
end
|
129
|
+
end
|
130
|
+
end
|
131
|
+
end
|
132
|
+
end
|
133
|
+
|
134
|
+
|
135
|
+
end
|
136
|
+
|