isolated entity dependancy in entity representation
fixed attach/detach/detachAll bug