Added support to load/save environments to strings

Got rid of the Environment constructor with a filename. Replaced it
with an istream constructor. Added two static methods to construct
an object from a filename or file contents.

Got rid of a load of unnecessary calls to close()

Added a save metamethod to the envdef object and allowed a string to
be passed to newEnvDefinition which is the same format as returned
by save
Merge branch 'feature-envsaveload-20140520' into develop

Brought in the ability to load/save environment definitions as strings