Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zonuexe/ruby-rboop
https://github.com/zonuexe/ruby-rboop
Last synced: about 5 hours ago
JSON representation
- Host: GitHub
- URL: https://github.com/zonuexe/ruby-rboop
- Owner: zonuexe
- License: other
- Created: 2013-04-01T10:22:26.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2013-04-02T05:29:23.000Z (over 11 years ago)
- Last Synced: 2024-11-06T02:49:14.439Z (about 2 months ago)
- Language: Ruby
- Size: 117 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
rboop - RubyOOP
===============Object-Oriented Programming for Ruby!!!!11
Installation
-------------Add this line to your application's Gemfile:
gem 'ruby-oop'
And then execute:
$ bundle
Or install it yourself as:
$ gem install ruby-oop
Usage
-----### Define your class
It's *mijisso*.
```ruby
require 'rboop'Animal = Klass[:new,
name: 'Animal',
methods: {
sounds: ->(this){
"#{this[:voice] * 2}!!"
},
}
]Dog = Animal[:new,
name: 'Dog',
voice: "BowWow",
]
```## Contributing
1. Fork it
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create new Pull Request