About.com offers expert, quality information that helps people find solutions to daily needs.
Displaying 1 - 10 of 641

Articles related to ruby module

Modules: Containment and Composition - Ruby - About.com
Underneath it all, classes are just collections of methods. Ruby implements them using Module, which also have other uses including composition and ...
Using the Enumerable Module - Ruby - About.com
By using the Enumerable module, you can make any of your classes act like Ruby standard collections. All you need to do is implement the 'each' method.
Mixin Modules - Ruby - About.com
Mixins are one of Ruby's defining features, but often one of the most difficult to understand for those new to Ruby. They're not difficult to understand, but they're ...
Variables Declared in the Global Scope - Ruby - About.com
Ruby does not compute variable scope in quite the same way. ... usr/bin/env ruby module DataPrinter @data = { :key => 'value' } def self.print_data puts @data ...
Modules - Ruby - About.com
... would be used. It's not uncommon to see C programs with names like mylibrary_some_function. However, Ruby has a more powerful solution: modules .
NameError: uninitialized constant Object ... - Ruby - About.com
Solution: You've most likely referred to a class or module that doesn't exist. Most likely, you've forgotten to require a gem or library needed for the code to work, ...
A Quick Peek at Ruby: 'Include' vs. 'Require' - About.com
Oct 23, 2008 ... What's the difference between "include" and "require" in Ruby? ... The include method takes all the methods from another module and includes ...
Is the "Require" Method Overlooked in Ruby? - About.com
The 'require' method is the reusable code mechanism in Ruby. ... avoid name clashes, you can enclose everything in your library inside of a module statement.
Ruby Best Practices--Making Quick Exceptions - About.com
On the Ruby Best Practices blog, Gregory Brown wrote an interesting article on a quick way for ... It's implemented by defining a method of the class Module.
Constants in Ruby - About.com
Like just about every programming language every conceived, Ruby ... Another semi-useful feature of constants is that every module keeps a list of its constants.
1  |  2  |  3  |  4  |  5  |  6  |  7  |  8  |  9  |  10      Next >

©2014 About.com. All rights reserved.