EXP1(?=EXP2) (?<=EXP2)EXP1 EXP1(?!EXP2)
The string must match EXP1 and EXP2, but only the part of the string that matches EXP1 is returned.
EXP1
EXP2