added is_connected? method