IO functions refactored.