move public API classes to sos-env, make Direction and ReturnPath top-level classes