Python script to create a generic singleton in Objective-C