wildcard - Regular Expression for String *.java -



wildcard - Regular Expression for String *.java -

i writing programme finding number of occurences of java classes in log file.

i want count number of distinct times java class called. search should of form "*.java"

can help me regular look this?

a sufficient regular look [a-za-z_][a-za-z_0-9]*\\.java . regular look requires string start letter (or underscore), , go on number of letters or numbers (or underscores), follows java class name conventions. period double escaped \\ -- 1 escaping java escape \ in string, , sec regex matcher escape period (otherwise period special character meaning "any character").

this regular look fit task little improve asked precisely: .*\\.java (which .java preceded anything), because match entirety of line before ".java", leaving 'class names' "printing file myclass.java" instead of "myclass.java".

i seek look out (and seek out changes it) on online tool rubular.

wildcard

Comments

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -