Last active
August 22, 2016 06:31
-
-
Save imarban/7afbc1898cf2af52aeda72432f8791a9 to your computer and use it in GitHub Desktop.
This file contains 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 WirelessPrinter: | |
def __init__(ip): | |
self.ip = ip | |
def print_now(report): | |
open_connection() | |
report.prepare_for_print() | |
# Code required to print to an actual printer | |
close_connection() | |
printer = WirelessPrinter("192.168.1.13") | |
report = SalesReport() | |
printer.print_now(report) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment