public boolean install ( ) { if ( tempFile == null ) return true ; // already installed // Move temp file to correct location in blob store: String destPath = store . getRawPathForKey ( blobKey ) ; File destPathFile = new File ( destPath ) ; if ( tempFile . renameTo ( destPathFile ) ) // If the move fails, assume it means a file with the same name already exists; in that // case it must have the identical contents, so we're still OK. tempFile = null ; else cancel ( ) ; return true ; }
Installs a finished blob into the store .