Skip to content

Instantly share code, notes, and snippets.

@akwiatkowski
Last active October 13, 2015 15:00
Show Gist options
  • Save akwiatkowski/c1e32837f46695fb52d6 to your computer and use it in GitHub Desktop.
Save akwiatkowski/c1e32837f46695fb52d6 to your computer and use it in GitHub Desktop.
crystal attribute declaration problem
require "yaml"
require "logger"
class WebcamDownloader::Downloader
def initialize
@logger = Logger.new(STDOUT)
@webcam_array = WebcamArray.new
end
def setup
@webcam_array.logger = @logger
@webcam_array.setup
end
end
class WebcamDownloader::WebcamArray
property :logger
def initialize
end
def setup
logger.debug "#{self.class} setup"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment