Extracted more core functionality from PlatformLayer