these functions should be part of the Applicatoin - that way we can have debug messages, etc.