I need a regular expression that will match a substring within a quoted string and will not match it outside of the quoted string. For example, if the substring is my substring
then in the following example it should match the second entry and unmatch the first and last entry:
This entry of my substring is unmatched. "This entry of \"my substring\" is matched." This entry of my substring is unmatched.
Conversely, in the next example, the expression should match the first and last entry and unmatch the second entry:
"This entry of my substring is matched." This entry of my substring is unmatched. "This entry of my substring is matched."
It should also work for the case where the quoted string containing the target substring is surrounded by other quoted strings:
"A quoted string." "This entry of my substring is matched." "A quoted string."