Created
September 10, 2009 07:15
-
-
Save RobertDober/184393 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 << Factory | |
alias_method :__build__, :build | |
def build *args, &blk | |
__log__( *args ) | |
__build__( *args, &blk ) | |
end | |
private | |
def __log__ *args | |
@__logfile__ ||= File::new( "xxx", "w" ) | |
@__logfile__.puts( caller[2].to_s + args.inspect ) | |
end | |
end | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment