major restructure of classes. added filtering/security.