No commit activity in last 3 years
No release in over 3 years
polyrex-createobject
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

>= 0.5.1, ~> 0.5
 Project Readme

A Polyrex-createobject example

require 'requestor'

eval Requestor.read('http://rorbuilder.info/r/ruby/') {|x| x.require 'polyrex-createobject' }

obj = PolyrexCreateObject.new('a/b[name]/c[name,count]/d[name,age]')
doc = Rexle.new('<a><summary/><records><b><summary><name>123</name></summary><records></records></b></records></a>')
obj.record = doc.root
obj.b(name: 'fun') do |create|
  create.c(name: 'fun5') do |create|
    create.d name: 'fun7', age: 11
  end
end

puts doc.to_s pretty: true
  
  
    
      
        123
      
      
    
    
      
        fun
        [!name]
        polyrex
        b[name]
      
      
        
          
            fun5
            
            [!name] [!count]
            polyrex
            c[name,count]
          
          
            
              
                fun7
                11
                [!name] [!age]
                polyrex
                d[name,age]
              
              
            
          
        
      
    
  

polyrex polyrexcreateobject gem testing