rack-amf 1.0.0 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -6,7 +6,7 @@ require 'spec/rake/spectask'
6
6
 
7
7
  spec = Gem::Specification.new do |s|
8
8
  s.name = 'rack-amf'
9
- s.version = '1.0.0'
9
+ s.version = '2.0.0'
10
10
  s.summary = 'AMF gateway packaged as a rack middleware'
11
11
  s.authors = ['Stephen Augenstein']
12
12
  s.email = 'perl.programmer@gmail.com'
@@ -18,7 +18,7 @@ spec = Gem::Specification.new do |s|
18
18
  s.files = FileList['README.rdoc', 'Rakefile', 'lib/**/*.rb', 'spec/**/*.{rb,opts}']
19
19
  s.test_files = Dir[*['spec/**/*_spec.rb']]
20
20
 
21
- s.add_dependency('RocketAMF')
21
+ s.add_dependency 'RocketAMF', '>= 0.2.0'
22
22
  end
23
23
 
24
24
  desc 'Default: Run the specs'
@@ -36,4 +36,11 @@ end
36
36
 
37
37
  Spec::Rake::SpecTask.new do |t|
38
38
  t.spec_opts = ['--options', 'spec/spec.opts']
39
+ end
40
+
41
+ desc 'Generate a gemspec file'
42
+ task :gemspec do
43
+ File.open("#{spec.name}.gemspec", 'w') do |f|
44
+ f.write spec.to_ruby
45
+ end
39
46
  end
@@ -46,16 +46,4 @@ module Rack::AMF
46
46
  raise "Invalide mode: #{options[:mode]}"
47
47
  end
48
48
  end
49
- end
50
-
51
- # For compatibility
52
- module AMF #:nodoc:
53
- def self.const_missing const
54
- if const == :ClassMapper
55
- $stderr.puts("DEPRECATION WARNING: Please use RocketAMF::ClassMapper instead of AMF::ClassMapper")
56
- AMF.const_set(:ClassMapper, RocketAMF::ClassMapper)
57
- else
58
- super(const)
59
- end
60
- end
61
49
  end
@@ -1,6 +1,3 @@
1
- require 'rack/amf/request'
2
- require 'rack/amf/response'
3
-
4
1
  module Rack::AMF
5
2
  # Provide some helper items that can be included in the various middleware
6
3
  # being offered.
@@ -15,8 +12,8 @@ module Rack::AMF
15
12
 
16
13
  # Wrap request and response
17
14
  env['rack.input'].rewind
18
- env['rack-amf.request'] = Request.new.populate_from_stream(env['rack.input'].read)
19
- env['rack-amf.response'] = Response.new(env['rack-amf.request'])
15
+ env['rack-amf.request'] = RocketAMF::Envelope.new.populate_from_stream(env['rack.input'].read)
16
+ env['rack-amf.response'] = RocketAMF::Envelope.new
20
17
 
21
18
  # Call handle on "inheriting" class
22
19
  handle env
metadata CHANGED
@@ -1,7 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rack-amf
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ hash: 15
5
+ prerelease: false
6
+ segments:
7
+ - 2
8
+ - 0
9
+ - 0
10
+ version: 2.0.0
5
11
  platform: ruby
6
12
  authors:
7
13
  - Stephen Augenstein
@@ -9,19 +15,25 @@ autorequire:
9
15
  bindir: bin
10
16
  cert_chain: []
11
17
 
12
- date: 2010-03-20 00:00:00 -04:00
18
+ date: 2010-07-29 00:00:00 -04:00
13
19
  default_executable:
14
20
  dependencies:
15
21
  - !ruby/object:Gem::Dependency
16
22
  name: RocketAMF
17
- type: :runtime
18
- version_requirement:
19
- version_requirements: !ruby/object:Gem::Requirement
23
+ prerelease: false
24
+ requirement: &id001 !ruby/object:Gem::Requirement
25
+ none: false
20
26
  requirements:
21
27
  - - ">="
22
28
  - !ruby/object:Gem::Version
23
- version: "0"
24
- version:
29
+ hash: 23
30
+ segments:
31
+ - 0
32
+ - 2
33
+ - 0
34
+ version: 0.2.0
35
+ type: :runtime
36
+ version_requirements: *id001
25
37
  description:
26
38
  email: perl.programmer@gmail.com
27
39
  executables: []
@@ -37,8 +49,6 @@ files:
37
49
  - lib/rack/amf/middleware/pass_through.rb
38
50
  - lib/rack/amf/middleware/service_manager.rb
39
51
  - lib/rack/amf/middleware.rb
40
- - lib/rack/amf/request.rb
41
- - lib/rack/amf/response.rb
42
52
  - lib/rack/amf.rb
43
53
  - spec/service_manager_spec.rb
44
54
  - spec/spec_helper.rb
@@ -56,21 +66,27 @@ rdoc_options:
56
66
  require_paths:
57
67
  - lib
58
68
  required_ruby_version: !ruby/object:Gem::Requirement
69
+ none: false
59
70
  requirements:
60
71
  - - ">="
61
72
  - !ruby/object:Gem::Version
73
+ hash: 3
74
+ segments:
75
+ - 0
62
76
  version: "0"
63
- version:
64
77
  required_rubygems_version: !ruby/object:Gem::Requirement
78
+ none: false
65
79
  requirements:
66
80
  - - ">="
67
81
  - !ruby/object:Gem::Version
82
+ hash: 3
83
+ segments:
84
+ - 0
68
85
  version: "0"
69
- version:
70
86
  requirements: []
71
87
 
72
88
  rubyforge_project:
73
- rubygems_version: 1.3.5
89
+ rubygems_version: 1.3.7
74
90
  signing_key:
75
91
  specification_version: 3
76
92
  summary: AMF gateway packaged as a rack middleware
@@ -1,8 +0,0 @@
1
- module Rack::AMF
2
- class Request < RocketAMF::Request #:nodoc:
3
- def version
4
- $stderr.puts("DEPRECATION WARNING: use amf_version instead of version")
5
- amf_version
6
- end
7
- end
8
- end
@@ -1,19 +0,0 @@
1
- module Rack::AMF
2
- class Response < RocketAMF::Response #:nodoc:
3
- def initialize request
4
- @request = request
5
- super()
6
- end
7
-
8
- # Builds response, iterating over each method call and using the return value
9
- # as the method call's return value
10
- def each_method_call *args, &block
11
- if args.length == 0
12
- $stderr.puts("DEPRECATION WARNING: Use each_method_call request, &block instead of each_method_call &block")
13
- super(@request, &block)
14
- else
15
- super(*args, &block)
16
- end
17
- end
18
- end
19
- end