Convenience methods for key factory.