Last active
August 29, 2015 14:17
-
-
Save RhysStansfield/5a1a099ac39a335f0a0d to your computer and use it in GitHub Desktop.
Trainification
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
r@rhyss-mbp:~/git_repos/trainz$ rbenv local 2.2.0 | |
r@rhyss-mbp:~/git_repos/trainz$ ruby -v | |
ruby 2.2.0p0 (2014-12-25 revision 49005) [x86_64-darwin14] | |
r@rhyss-mbp:~/git_repos/trainz$ ruby trainz.rb | |
HERE#<App::TrainStatus:0x007fbfda84e5d0> | |
r@rhyss-mbp:~/git_repos/trainz$ rbenv local 2.2.1 | |
r@rhyss-mbp:~/git_repos/trainz$ ruby -v | |
ruby 2.2.1p85 (2015-02-26 revision 49769) [x86_64-darwin14] | |
r@rhyss-mbp:~/git_repos/trainz$ ruby trainz.rb | |
HERE#<App::TrainStatus:0x007fc00b127bb8> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class App | |
class TrainStatus | |
def initialize | |
print 'HERE' | |
end | |
end | |
class TrainFactory | |
def self.parse_message(msg) | |
App::TrainStatus.new | |
end | |
end | |
end | |
puts App::TrainFactory.parse_message('derp') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment