Revised coredata to support UIManagedDocument