You don't need to instantiate to use class constants. PlatformInfo.VERSION_UBUNTU_PRECISE does the trick.