Big refactorization, now the GMT_Resource types take care of their own IO registration.  Unfortunately, they need the handle of the GMT session for this, but I think it is more maintainable this way.