Skip to content

Instantly share code, notes, and snippets.

@erubboli
Created August 25, 2010 11:08
Show Gist options
  • Save erubboli/549295 to your computer and use it in GitHub Desktop.
Save erubboli/549295 to your computer and use it in GitHub Desktop.
class Poker
def evaluate_cards
primitive_operation1
primitive_operation2
end
def primitive_operation1
raise "template method called!"
end
def primitive_operation2
raise "template method called!"
end
end
class TexasHoldEmPoker <Poker
def primitive_operation1
#...
end
def primitive_operation2
#...
end
end
class OmahaPoker <Poker
def primitive_operation1
#...
end
def primitive_operation2
#...
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment