Skip to content

Instantly share code, notes, and snippets.

@vcolavin
Last active July 21, 2016 18:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vcolavin/fc0c00bc0dc47614f286abb44cf8299b to your computer and use it in GitHub Desktop.
Save vcolavin/fc0c00bc0dc47614f286abb44cf8299b to your computer and use it in GitHub Desktop.
class Wolf < AR::Base
module Movable
include GeneralMovingMethods
# here would be specifics about wolves moving
end
end
class Rabbit < AR::Base
module Movable
include GeneralMovingMethods
# here would be specifics about rabbits moving
end
end
module GeneralMovingMethods
def whatever
# some general stuff
end
end
Rabbit.new.Movable.move
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment