Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NoMethodError: undefined method `to_class_builder' for "xsd:anyType":String #19

Open
dmolesUC opened this issue Apr 17, 2015 · 0 comments

Comments

@dmolesUC
Copy link

I get the error above under Ruby 1.9.3-p551 when I try to follow the README example with the ResourceSync schema. My script:

#! /usr/bin/env ruby
require 'rxsd'
xsd_uri = 'http://www.openarchives.org/rs/0.9.1/resourcesync.xsd'
schema = RXSD::Parser.parse_xsd :uri => xsd_uri
classes = schema.to :ruby_classes

Result:

/Users/dmoles/.rvm/gems/ruby-1.9.3-p551/gems/rxsd-0.5.2/lib/rxsd/xsd/restriction.rb:110:in `to_class_builder': undefined method `to_class_builder' for "xsd:anyType":String (NoMethodError)
    from /Users/dmoles/.rvm/gems/ruby-1.9.3-p551/gems/rxsd-0.5.2/lib/rxsd/xsd/complex_content.rb:67:in `to_class_builder'
    from /Users/dmoles/.rvm/gems/ruby-1.9.3-p551/gems/rxsd-0.5.2/lib/rxsd/xsd/complex_type.rb:83:in `to_class_builder'
    from /Users/dmoles/.rvm/gems/ruby-1.9.3-p551/gems/rxsd-0.5.2/lib/rxsd/xsd/element.rb:135:in `to_class_builder'
    from /Users/dmoles/.rvm/gems/ruby-1.9.3-p551/gems/rxsd-0.5.2/lib/rxsd/xsd/schema.rb:105:in `block in to_class_builders'
    from /Users/dmoles/.rvm/gems/ruby-1.9.3-p551/gems/rxsd-0.5.2/lib/rxsd/xsd/schema.rb:104:in `each'
    from /Users/dmoles/.rvm/gems/ruby-1.9.3-p551/gems/rxsd-0.5.2/lib/rxsd/xsd/schema.rb:104:in `to_class_builders'
    from /Users/dmoles/.rvm/gems/ruby-1.9.3-p551/gems/rxsd-0.5.2/lib/rxsd/translator.rb:44:in `all_class_builders'
    from /Users/dmoles/.rvm/gems/ruby-1.9.3-p551/gems/rxsd-0.5.2/lib/rxsd/translator.rb:54:in `to'
    from ./schema.rb:9:in `<main>'

Possibly related to #6?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant