Is there a latch / flip-flop with this behaviour?
If this device has a clock, it's a D Flip-Flop with Enable.

If there is no clock, it's known as a "Gated" D-Latch. (https://en.wikipedia.org/wiki/Flip-flop_(electronics)#Gated_D_latch)