delete class locally