The rewrite of this function is perfect example of how using protocols will simplify things.  You can go through a list of items and call the same create function and it will dispatch to the correct place (line 68-69).