private File fileExists ( final String path , final long checksum ) throws FrameworkException { final PropertyKey < Long > checksumKey = StructrApp . key ( File . class , "checksum" ) ; final PropertyKey < String > pathKey = StructrApp . key ( File . class , "path" ) ; return app . nodeQuery ( File . class ) . and ( pathKey , path ) . and ( checksumKey , checksum ) . getFirst ( ) ; }
Check whether a file with given path and checksum already exists