write file role to entity and file JSON files

Previously file role only came from that part of the filename.
This created problems with files with mis-capitalized filenames.
With this change, when the File object is created the role is
read from the filename; later when data is loaded from JSON
the role in the data overrides the role from the filename.
Role is written to File and Entity JSON when either is saved.
added a bunch of documentation to DDRLocalCollection