another example of the new api generators.
using generator for Objects.
trying to reflect changes to AddObject.