Capture the pattern method name to use in the replacement text.