How to cut segment using closed curve


is it possible to preserve the segment area inside the closed curve , erase the outside part ?