Add java file which performs the matching task