question: public static String detectImdbId ( String text ) { String imdb = "" ; if ( text != null && ! text . isEmpty ( ) ) { imdb = StrgUtils . substr ( text , ".*(tt\\d{7}).*" ) ; if ( imdb . isEmpty ( ) ) { imdb = StrgUtils . substr ( text , ".*imdb\\.com\\/Title\\?(\\d{7}).*" ) ; if ( ! imdb . isEmpty ( ) ) { imdb = "tt" + imdb ; } } } return imdb ; }
target:  gets IMDB id out of filename