quickbooks_web_connector 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (66) hide show
  1. data/MIT-LICENSE +20 -0
  2. data/README.md +109 -0
  3. data/Rakefile +28 -0
  4. data/app/assets/javascripts/quickbooks_web_connector/application.js +15 -0
  5. data/app/assets/stylesheets/quickbooks_web_connector/application.css +13 -0
  6. data/app/controllers/quickbooks_web_connector/application_controller.rb +5 -0
  7. data/app/controllers/quickbooks_web_connector/qwc_controller.rb +12 -0
  8. data/app/controllers/quickbooks_web_connector/soap_controller.rb +10 -0
  9. data/app/helpers/quickbooks_web_connector/application_helper.rb +4 -0
  10. data/app/views/layouts/quickbooks_web_connector/application.html.erb +14 -0
  11. data/app/views/quickbooks_web_connector/qwc/qwc.xml.builder +12 -0
  12. data/config/routes.rb +6 -0
  13. data/lib/quickbooks_web_connector/config.rb +35 -0
  14. data/lib/quickbooks_web_connector/engine.rb +5 -0
  15. data/lib/quickbooks_web_connector/job.rb +61 -0
  16. data/lib/quickbooks_web_connector/json_coder.rb +23 -0
  17. data/lib/quickbooks_web_connector/soap_wrapper/QBWebConnectorSvc.rb +72 -0
  18. data/lib/quickbooks_web_connector/soap_wrapper/default.rb +204 -0
  19. data/lib/quickbooks_web_connector/soap_wrapper/defaultMappingRegistry.rb +166 -0
  20. data/lib/quickbooks_web_connector/soap_wrapper/defaultServant.rb +140 -0
  21. data/lib/quickbooks_web_connector/soap_wrapper.rb +30 -0
  22. data/lib/quickbooks_web_connector/version.rb +3 -0
  23. data/lib/quickbooks_web_connector.rb +127 -0
  24. data/lib/tasks/quickbooks_web_connector_tasks.rake +4 -0
  25. data/spec/config/config_spec.rb +83 -0
  26. data/spec/controllers/quickbooks_web_connector/qwc_controller_spec.rb +29 -0
  27. data/spec/controllers/quickbooks_web_connector/soap_controller_spec.rb +306 -0
  28. data/spec/dummy/README.rdoc +261 -0
  29. data/spec/dummy/Rakefile +7 -0
  30. data/spec/dummy/app/assets/javascripts/application.js +15 -0
  31. data/spec/dummy/app/assets/stylesheets/application.css +13 -0
  32. data/spec/dummy/app/controllers/application_controller.rb +3 -0
  33. data/spec/dummy/app/helpers/application_helper.rb +2 -0
  34. data/spec/dummy/app/views/layouts/application.html.erb +14 -0
  35. data/spec/dummy/config/application.rb +59 -0
  36. data/spec/dummy/config/boot.rb +10 -0
  37. data/spec/dummy/config/database.yml +25 -0
  38. data/spec/dummy/config/environment.rb +5 -0
  39. data/spec/dummy/config/environments/development.rb +37 -0
  40. data/spec/dummy/config/environments/production.rb +67 -0
  41. data/spec/dummy/config/environments/test.rb +37 -0
  42. data/spec/dummy/config/initializers/backtrace_silencers.rb +7 -0
  43. data/spec/dummy/config/initializers/inflections.rb +15 -0
  44. data/spec/dummy/config/initializers/mime_types.rb +5 -0
  45. data/spec/dummy/config/initializers/secret_token.rb +7 -0
  46. data/spec/dummy/config/initializers/session_store.rb +8 -0
  47. data/spec/dummy/config/initializers/wrap_parameters.rb +14 -0
  48. data/spec/dummy/config/locales/en.yml +5 -0
  49. data/spec/dummy/config/routes.rb +6 -0
  50. data/spec/dummy/config.ru +4 -0
  51. data/spec/dummy/db/test.sqlite3 +0 -0
  52. data/spec/dummy/log/development.log +0 -0
  53. data/spec/dummy/log/test.log +26009 -0
  54. data/spec/dummy/public/404.html +26 -0
  55. data/spec/dummy/public/422.html +26 -0
  56. data/spec/dummy/public/500.html +25 -0
  57. data/spec/dummy/public/favicon.ico +0 -0
  58. data/spec/dummy/script/rails +6 -0
  59. data/spec/quickbooks_web_connector/soap_wrapper/defaultServant_spec.rb +150 -0
  60. data/spec/quickbooks_web_connector_spec.rb +47 -0
  61. data/spec/routing/quickbooks_web_connector_spec.rb +17 -0
  62. data/spec/spec_helper.rb +50 -0
  63. data/spec/support/redis/dump.rdb +1 -0
  64. data/spec/support/redis/redis-test.conf +115 -0
  65. data/spec/views/quickbooks_web_connector/qwc/qwc.xml.builder_spec.rb +56 -0
  66. metadata +232 -0
data/MIT-LICENSE ADDED
@@ -0,0 +1,20 @@
1
+ Copyright 2012 YOURNAME
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,109 @@
1
+ QuickbooksWebConnector
2
+ ======================
3
+
4
+ QuickbooksWebConnector is a Redis-backed library for queueing up requests for the Quickbooks Web Connector software to fetch and perform. Responses from the Quickbooks Web Connector can also be handled if you need to take some action with the result.
5
+
6
+ QuickbooksWebConnector is heavily inspired by [QBWC](https://github.com/skryl/qbwc) and [Resque](https://github.com/defunkt/resque), so many thanks to the great people behind those gems.
7
+
8
+ Requirements
9
+ ------------
10
+
11
+ QuickbooksWebConnector has only been tested on Rails 3.2.9
12
+
13
+ Overview
14
+ --------
15
+
16
+ QuickbooksWebConnector allows you to create requests and place them on the queue for the Quickbooks Web Connector to fetch, with a response handler to handle the Quickbooks response.
17
+
18
+ A response handler is a Ruby class than responds to the `perform` method that receives the response XML as a string and any additional arguments you specified when enqueueing the request. Here's an example:
19
+
20
+ ```ruby
21
+ require 'rexml/document'
22
+
23
+ class AddCustomerHandler
24
+
25
+ def self.perform(response_xml, customer_id)
26
+ customer = Customer.find(customer_id)
27
+ customer.quickbooks_list_id = REXML::Document.new(response_xml).root.text('QBXMLMsgsRs/CustomerAddRs/CustomerRet/ListID')
28
+ customer.save!
29
+ end
30
+
31
+ end
32
+ ```
33
+
34
+ To enqueue a request, you might add this to your model as an `after_create` callback, or maybe your controller's create action:
35
+
36
+ ```ruby
37
+ class Customer
38
+
39
+ after_create :add_to_quickbooks
40
+
41
+ def add_to_quickbooks
42
+ request_xml = <<-EOT
43
+ <?xml version="1.0" encoding="UTF-8"?>
44
+ <?qbxml version="6.0"?>
45
+ <QBXML>
46
+ <QBXMLMsgsRq onError="stopOnError">
47
+ <CustomerAddRq>
48
+ <CustomerAdd>
49
+ <Name>FooBar Inc</Name>
50
+ </CustomerAdd>
51
+ </CustomerAddRq>
52
+ </QBXMLMsgsRq>
53
+ </QBXML>
54
+ EOT
55
+
56
+ QuickbooksWebConnector.enqueue request_xml, AddCustomerHandler, id
57
+ end
58
+
59
+ end
60
+ ```
61
+
62
+ Once Quickbooks Web Connector received your request and processed it, it would return a response, and your handler will get called like:
63
+
64
+ ```ruby
65
+ AddCustomerHandler.perform response_xml, 1
66
+ ```
67
+
68
+ Installing QuickbooksWebConnector
69
+ =================================
70
+
71
+ First include it in your Gemfile:
72
+
73
+ ```
74
+ $ cat Gemfile
75
+ ...
76
+ gem 'quickbooks_web_connector'
77
+ ...
78
+ ```
79
+
80
+ Next install it with Bundler:
81
+
82
+ ```
83
+ $ bundle install
84
+ ```
85
+
86
+ Mount the engine in your routes.rb
87
+
88
+ ```
89
+ mount QuickbooksWebConnector::Engine => "/quickbooks_web_connector"
90
+ ```
91
+
92
+ TODO: Add note about config in initializer
93
+
94
+ Now start your application:
95
+
96
+ ```
97
+ $ rails server
98
+ ```
99
+
100
+ Contributing
101
+ ============
102
+
103
+ Once you've made your great commits:
104
+
105
+ 1. [Fork](https://help.github.com/forking/) QuickbooksWebConnector
106
+ 2. Create a topic branch: `git checkout -b my_feature`
107
+ 3. Push to your branch: `git push origin my_feature`
108
+ 4. Create a [Pull Request](https://help.github.com/pull-requests/) from your branch
109
+ 5. That's it!
data/Rakefile ADDED
@@ -0,0 +1,28 @@
1
+ #!/usr/bin/env rake
2
+ begin
3
+ require 'bundler/setup'
4
+ rescue LoadError
5
+ puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
6
+ end
7
+ begin
8
+ require 'rdoc/task'
9
+ rescue LoadError
10
+ require 'rdoc/rdoc'
11
+ require 'rake/rdoctask'
12
+ RDoc::Task = Rake::RDocTask
13
+ end
14
+
15
+ RDoc::Task.new(:rdoc) do |rdoc|
16
+ rdoc.rdoc_dir = 'rdoc'
17
+ rdoc.title = 'QuickbooksWebConnector'
18
+ rdoc.options << '--line-numbers'
19
+ rdoc.rdoc_files.include('README.rdoc')
20
+ rdoc.rdoc_files.include('lib/**/*.rb')
21
+ end
22
+
23
+ APP_RAKEFILE = File.expand_path("../spec/dummy/Rakefile", __FILE__)
24
+ load 'rails/tasks/engine.rake'
25
+
26
+
27
+
28
+ Bundler::GemHelper.install_tasks
@@ -0,0 +1,15 @@
1
+ // This is a manifest file that'll be compiled into application.js, which will include all the files
2
+ // listed below.
3
+ //
4
+ // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
5
+ // or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.
6
+ //
7
+ // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
8
+ // the compiled file.
9
+ //
10
+ // WARNING: THE FIRST BLANK LINE MARKS THE END OF WHAT'S TO BE PROCESSED, ANY BLANK LINE SHOULD
11
+ // GO AFTER THE REQUIRES BELOW.
12
+ //
13
+ //= require jquery
14
+ //= require jquery_ujs
15
+ //= require_tree .
@@ -0,0 +1,13 @@
1
+ /*
2
+ * This is a manifest file that'll be compiled into application.css, which will include all the files
3
+ * listed below.
4
+ *
5
+ * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
6
+ * or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.
7
+ *
8
+ * You're free to add application-wide styles to this file and they'll appear at the top of the
9
+ * compiled file, but it's generally better to create a new file per style scope.
10
+ *
11
+ *= require_self
12
+ *= require_tree .
13
+ */
@@ -0,0 +1,5 @@
1
+ module QuickbooksWebConnector
2
+ class ApplicationController < ActionController::Base
3
+ skip_before_filter :verify_authenticity_token
4
+ end
5
+ end
@@ -0,0 +1,12 @@
1
+ module QuickbooksWebConnector
2
+ class QwcController < ApplicationController
3
+
4
+ def download
5
+ send_data render_to_string(:qwc),
6
+ disposition: 'attachment',
7
+ filename: 'qbwc.qwc',
8
+ type: :xml
9
+ end
10
+
11
+ end
12
+ end
@@ -0,0 +1,10 @@
1
+ module QuickbooksWebConnector
2
+ class SoapController < ApplicationController
3
+
4
+ def endpoint
5
+ response = SoapWrapper.route(request)
6
+ render xml: response, content_type: 'text/xml'
7
+ end
8
+
9
+ end
10
+ end
@@ -0,0 +1,4 @@
1
+ module QuickbooksWebConnector
2
+ module ApplicationHelper
3
+ end
4
+ end
@@ -0,0 +1,14 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>QuickbooksWebConnector</title>
5
+ <%= stylesheet_link_tag "quickbooks_web_connector/application", :media => "all" %>
6
+ <%= javascript_include_tag "quickbooks_web_connector/application" %>
7
+ <%= csrf_meta_tags %>
8
+ </head>
9
+ <body>
10
+
11
+ <%= yield %>
12
+
13
+ </body>
14
+ </html>
@@ -0,0 +1,12 @@
1
+ xml.instruct!
2
+ xml.QBWCXML do
3
+ xml.AppName 'My QBWC App'
4
+ xml.AppID
5
+ xml.AppURL quickbooks_web_connector.soap_url
6
+ xml.AppDescription 'My QBWC App Description'
7
+ xml.AppSupport main_app.root_url
8
+ xml.UserName QuickbooksWebConnector.config.username
9
+ xml.OwnerID '{d69682e6-4436-44bc-bd19-d6bfbd11778d}'
10
+ xml.FileID '{916222f3-c574-4c70-8c9d-e3cec2634e49}'
11
+ xml.QBType 'QBFS'
12
+ end
data/config/routes.rb ADDED
@@ -0,0 +1,6 @@
1
+ QuickbooksWebConnector::Engine.routes.draw do
2
+
3
+ get 'qwc' => 'qwc#download', defaults: { format: :xml }
4
+ post 'soap' => 'soap#endpoint'
5
+
6
+ end
@@ -0,0 +1,35 @@
1
+ require 'active_support/configurable'
2
+
3
+ module QuickbooksWebConnector
4
+ # Configure global settings for QuickbooksWebConnector
5
+ # QuickbooksWebConnector.configure do |config|
6
+ # config.server_version
7
+ # end
8
+ def self.configure(&block)
9
+ yield @config ||= QuickbooksWebConnector::Configuration.new
10
+ end
11
+
12
+ # Global settings for QuickbooksWebConnector
13
+ def self.config
14
+ @config
15
+ end
16
+
17
+ class Configuration
18
+ include ActiveSupport::Configurable
19
+
20
+ config_accessor :server_version
21
+ config_accessor :minimum_web_connector_client_version
22
+ config_accessor :username
23
+ config_accessor :password
24
+ config_accessor :company_file_path
25
+ end
26
+
27
+ configure do |config|
28
+ config.server_version = '1.0.0'
29
+ config.minimum_web_connector_client_version = nil
30
+ config.username = 'web_connector'
31
+ config.password = 'secret'
32
+ config.company_file_path = ''
33
+ end
34
+
35
+ end
@@ -0,0 +1,5 @@
1
+ module QuickbooksWebConnector
2
+ class Engine < ::Rails::Engine
3
+ isolate_namespace QuickbooksWebConnector
4
+ end
5
+ end
@@ -0,0 +1,61 @@
1
+ module QuickbooksWebConnector
2
+ class Job
3
+
4
+ attr_accessor :response_xml
5
+
6
+ def initialize(payload)
7
+ @payload = payload
8
+ end
9
+
10
+ # Creates a job by placing it on the queue. Expects XML as a string,
11
+ # a string class name, and an optional array of arguments to
12
+ # pass to the class' `perform` method.
13
+ #
14
+ # Raises an exception if no class is given.
15
+ def self.create(request_xml, klass, *args)
16
+ QuickbooksWebConnector.push('request_xml' => request_xml, 'class' => klass.to_s, 'args' => args)
17
+ end
18
+
19
+ # Returns an instance of QuickbooksWebConnector::Job
20
+ # if any jobs are available. If not, returns nil.
21
+ def self.reserve
22
+ return unless payload = QuickbooksWebConnector.pop
23
+ new(payload)
24
+ end
25
+
26
+ # Return an instance of QuickbooksWebConnector::job if any jobs are
27
+ # available, without removing the job from the queue
28
+ def self.peek
29
+ return unless payload = QuickbooksWebConnector.peek
30
+ new(payload)
31
+ end
32
+
33
+ # Attempts to perform the work represented by this job instance.
34
+ # Calls #perform on the class given in the payload with the
35
+ # Quickbooks response and the arguments given in the payload..
36
+ def perform
37
+ job = payload_class
38
+ job_args = args || []
39
+ job_args.prepend response_xml
40
+
41
+ # Execute the job.
42
+ job.perform(*job_args)
43
+ end
44
+
45
+ # Returns the request XML from the payload.
46
+ def request_xml
47
+ @payload['request_xml']
48
+ end
49
+
50
+ # Returns the actual class constant represented in this job's payload.
51
+ def payload_class
52
+ @payload_class ||= @payload['class'].constantize
53
+ end
54
+
55
+ # Returns an array of args represented in this job's payload.
56
+ def args
57
+ @payload['args']
58
+ end
59
+
60
+ end
61
+ end
@@ -0,0 +1,23 @@
1
+ module QuickbooksWebConnector
2
+ class EncodeException < StandardError; end
3
+ class DecodeException < StandardError; end
4
+
5
+ class JsonCoder
6
+ # Given a Ruby object, returns a string suitable for storage in the
7
+ # queue.
8
+ def encode(object)
9
+ JSON.dump object
10
+ end
11
+
12
+ # Given a string, returns a Ruby object.
13
+ def decode(object)
14
+ return unless object
15
+
16
+ begin
17
+ JSON.load object
18
+ rescue JSON::ParserError => e
19
+ raise DecodeException, e.message, e.backtrace
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,72 @@
1
+ module QuickbooksWebConnector
2
+ module SoapWrapper
3
+ class QBWebConnectorSvcSoap
4
+ Methods = [
5
+ [ "http://developer.intuit.com/serverVersion",
6
+ "serverVersion",
7
+ [ [:in, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "serverVersion"]],
8
+ [:out, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "serverVersionResponse"]] ],
9
+ { :request_style => :document, :request_use => :literal,
10
+ :response_style => :document, :response_use => :literal,
11
+ :faults => {} }
12
+ ],
13
+ [ "http://developer.intuit.com/clientVersion",
14
+ "clientVersion",
15
+ [ [:in, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "clientVersion"]],
16
+ [:out, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "clientVersionResponse"]] ],
17
+ { :request_style => :document, :request_use => :literal,
18
+ :response_style => :document, :response_use => :literal,
19
+ :faults => {} }
20
+ ],
21
+ [ "http://developer.intuit.com/authenticate",
22
+ "authenticate",
23
+ [ [:in, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "authenticate"]],
24
+ [:out, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "authenticateResponse"]] ],
25
+ { :request_style => :document, :request_use => :literal,
26
+ :response_style => :document, :response_use => :literal,
27
+ :faults => {} }
28
+ ],
29
+ [ "http://developer.intuit.com/sendRequestXML",
30
+ "sendRequestXML",
31
+ [ [:in, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "sendRequestXML"]],
32
+ [:out, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "sendRequestXMLResponse"]] ],
33
+ { :request_style => :document, :request_use => :literal,
34
+ :response_style => :document, :response_use => :literal,
35
+ :faults => {} }
36
+ ],
37
+ [ "http://developer.intuit.com/receiveResponseXML",
38
+ "receiveResponseXML",
39
+ [ [:in, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "receiveResponseXML"]],
40
+ [:out, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "receiveResponseXMLResponse"]] ],
41
+ { :request_style => :document, :request_use => :literal,
42
+ :response_style => :document, :response_use => :literal,
43
+ :faults => {} }
44
+ ],
45
+ [ "http://developer.intuit.com/connectionError",
46
+ "connectionError",
47
+ [ [:in, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "connectionError"]],
48
+ [:out, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "connectionErrorResponse"]] ],
49
+ { :request_style => :document, :request_use => :literal,
50
+ :response_style => :document, :response_use => :literal,
51
+ :faults => {} }
52
+ ],
53
+ [ "http://developer.intuit.com/getLastError",
54
+ "getLastError",
55
+ [ [:in, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "getLastError"]],
56
+ [:out, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "getLastErrorResponse"]] ],
57
+ { :request_style => :document, :request_use => :literal,
58
+ :response_style => :document, :response_use => :literal,
59
+ :faults => {} }
60
+ ],
61
+ [ "http://developer.intuit.com/closeConnection",
62
+ "closeConnection",
63
+ [ [:in, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "closeConnection"]],
64
+ [:out, "parameters", ["::SOAP::SOAPElement", "http://developer.intuit.com/", "closeConnectionResponse"]] ],
65
+ { :request_style => :document, :request_use => :literal,
66
+ :response_style => :document, :response_use => :literal,
67
+ :faults => {} }
68
+ ]
69
+ ]
70
+ end
71
+ end
72
+ end
@@ -0,0 +1,204 @@
1
+ require 'xsd/qname'
2
+
3
+ # {http://developer.intuit.com/}ArrayOfString
4
+ class ArrayOfString < ::Array
5
+ end
6
+
7
+ module QuickbooksWebConnector
8
+ module SoapWrapper
9
+
10
+ # {http://developer.intuit.com/}authenticate
11
+ # strUserName - SOAP::SOAPString
12
+ # strPassword - SOAP::SOAPString
13
+ class Authenticate
14
+ attr_accessor :strUserName
15
+ attr_accessor :strPassword
16
+
17
+ def initialize(strUserName = nil, strPassword = nil)
18
+ @strUserName = strUserName
19
+ @strPassword = strPassword
20
+ end
21
+ end
22
+
23
+ # {http://developer.intuit.com/}authenticateResponse
24
+ # authenticateResult - ArrayOfString
25
+ class AuthenticateResponse
26
+ attr_accessor :authenticateResult
27
+
28
+ def initialize(authenticateResult = nil)
29
+ @authenticateResult = authenticateResult
30
+ end
31
+ end
32
+
33
+ # {http://developer.intuit.com/}serverVersion
34
+ # strVersion - SOAP::SOAPString
35
+ class ServerVersion
36
+ attr_accessor :strVersion
37
+
38
+ def initialize(strVersion = nil)
39
+ @strVersion = strVersion
40
+ end
41
+ end
42
+
43
+ # {http://developer.intuit.com/}serverVersionResponse
44
+ # serverVersionResult - SOAP::SOAPString
45
+ class ServerVersionResponse
46
+ attr_accessor :serverVersionResult
47
+
48
+ def initialize(serverVersionResult = nil)
49
+ @serverVersionResult = serverVersionResult
50
+ end
51
+ end
52
+
53
+ # {http://developer.intuit.com/}clientVersion
54
+ # strVersion - SOAP::SOAPString
55
+ class ClientVersion
56
+ attr_accessor :strVersion
57
+
58
+ def initialize(strVersion = nil)
59
+ @strVersion = strVersion
60
+ end
61
+ end
62
+
63
+ # {http://developer.intuit.com/}clientVersionResponse
64
+ # clientVersionResult - SOAP::SOAPString
65
+ class ClientVersionResponse
66
+ attr_accessor :clientVersionResult
67
+
68
+ def initialize(clientVersionResult = nil)
69
+ @clientVersionResult = clientVersionResult
70
+ end
71
+ end
72
+
73
+ # {http://developer.intuit.com/}sendRequestXML
74
+ # ticket - SOAP::SOAPString
75
+ # strHCPResponse - SOAP::SOAPString
76
+ # strCompanyFileName - SOAP::SOAPString
77
+ # qbXMLCountry - SOAP::SOAPString
78
+ # qbXMLMajorVers - SOAP::SOAPInt
79
+ # qbXMLMinorVers - SOAP::SOAPInt
80
+ class SendRequestXML
81
+ attr_accessor :ticket
82
+ attr_accessor :strHCPResponse
83
+ attr_accessor :strCompanyFileName
84
+ attr_accessor :qbXMLCountry
85
+ attr_accessor :qbXMLMajorVers
86
+ attr_accessor :qbXMLMinorVers
87
+
88
+ def initialize(ticket = nil, strHCPResponse = nil, strCompanyFileName = nil, qbXMLCountry = nil, qbXMLMajorVers = nil, qbXMLMinorVers = nil)
89
+ @ticket = ticket
90
+ @strHCPResponse = strHCPResponse
91
+ @strCompanyFileName = strCompanyFileName
92
+ @qbXMLCountry = qbXMLCountry
93
+ @qbXMLMajorVers = qbXMLMajorVers
94
+ @qbXMLMinorVers = qbXMLMinorVers
95
+ end
96
+ end
97
+
98
+ # {http://developer.intuit.com/}sendRequestXMLResponse
99
+ # sendRequestXMLResult - SOAP::SOAPString
100
+ class SendRequestXMLResponse
101
+ attr_accessor :sendRequestXMLResult
102
+
103
+ def initialize(sendRequestXMLResult = nil)
104
+ @sendRequestXMLResult = sendRequestXMLResult
105
+ end
106
+ end
107
+
108
+ # {http://developer.intuit.com/}receiveResponseXML
109
+ # ticket - SOAP::SOAPString
110
+ # response - SOAP::SOAPString
111
+ # hresult - SOAP::SOAPString
112
+ # message - SOAP::SOAPString
113
+ class ReceiveResponseXML
114
+ attr_accessor :ticket
115
+ attr_accessor :response
116
+ attr_accessor :hresult
117
+ attr_accessor :message
118
+
119
+ def initialize(ticket = nil, response = nil, hresult = nil, message = nil)
120
+ @ticket = ticket
121
+ @response = response
122
+ @hresult = hresult
123
+ @message = message
124
+ end
125
+ end
126
+
127
+ # {http://developer.intuit.com/}receiveResponseXMLResponse
128
+ # receiveResponseXMLResult - SOAP::SOAPInt
129
+ class ReceiveResponseXMLResponse
130
+ attr_accessor :receiveResponseXMLResult
131
+
132
+ def initialize(receiveResponseXMLResult = nil)
133
+ @receiveResponseXMLResult = receiveResponseXMLResult
134
+ end
135
+ end
136
+
137
+ # {http://developer.intuit.com/}connectionError
138
+ # ticket - SOAP::SOAPString
139
+ # hresult - SOAP::SOAPString
140
+ # message - SOAP::SOAPString
141
+ class ConnectionError
142
+ attr_accessor :ticket
143
+ attr_accessor :hresult
144
+ attr_accessor :message
145
+
146
+ def initialize(ticket = nil, hresult = nil, message = nil)
147
+ @ticket = ticket
148
+ @hresult = hresult
149
+ @message = message
150
+ end
151
+ end
152
+
153
+ # {http://developer.intuit.com/}connectionErrorResponse
154
+ # connectionErrorResult - SOAP::SOAPString
155
+ class ConnectionErrorResponse
156
+ attr_accessor :connectionErrorResult
157
+
158
+ def initialize(connectionErrorResult = nil)
159
+ @connectionErrorResult = connectionErrorResult
160
+ end
161
+ end
162
+
163
+ # {http://developer.intuit.com/}getLastError
164
+ # ticket - SOAP::SOAPString
165
+ class GetLastError
166
+ attr_accessor :ticket
167
+
168
+ def initialize(ticket = nil)
169
+ @ticket = ticket
170
+ end
171
+ end
172
+
173
+ # {http://developer.intuit.com/}getLastErrorResponse
174
+ # getLastErrorResult - SOAP::SOAPString
175
+ class GetLastErrorResponse
176
+ attr_accessor :getLastErrorResult
177
+
178
+ def initialize(getLastErrorResult = nil)
179
+ @getLastErrorResult = getLastErrorResult
180
+ end
181
+ end
182
+
183
+ # {http://developer.intuit.com/}closeConnection
184
+ # ticket - SOAP::SOAPString
185
+ class CloseConnection
186
+ attr_accessor :ticket
187
+
188
+ def initialize(ticket = nil)
189
+ @ticket = ticket
190
+ end
191
+ end
192
+
193
+ # {http://developer.intuit.com/}closeConnectionResponse
194
+ # closeConnectionResult - SOAP::SOAPString
195
+ class CloseConnectionResponse
196
+ attr_accessor :closeConnectionResult
197
+
198
+ def initialize(closeConnectionResult = nil)
199
+ @closeConnectionResult = closeConnectionResult
200
+ end
201
+ end
202
+
203
+ end
204
+ end