I wrote a dynamic class to allow the generation of dynamic classes in Ruby programming language.
I wonder if this is secure. PHP did not allow that, I think.
But Ruby seems to allow it.
Here is the link:
I wrote a dynamic class to allow the generation of dynamic classes in Ruby programming language.
I wonder if this is secure. PHP did not allow that, I think.
But Ruby seems to allow it.
Here is the link:
This is reasonably secure - at least, provided you aren't including user-provided data in your class definition - but it's also fairly pointless. Ruby is a highly dynamic and flexible language that allows you to define classes dynamically without writing them to separate files at all.
Skip creating new files - if you want a new class, you can just call
Class.new
, like this:Of course, in reality you'd do something more useful with dynamically-generated classes, but this basic approach will work.
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
Hehe. I think your approach is much better than mine.
:)
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit