Regular Expressions 101

Community Patterns

Start of Java Functions

1

Regular Expression
PCRE2 (PHP >=7.3)

/
(\(\)\n[[:space:]]{1,}\{)|(\(\)[[:space:]]{1,}\{)
/
gm

Description

I wrote this regex to find all of the function headers in java.

Submitted by anonymous - 7 months ago