private static void runBuiltinFilterCommand(Repository repo, CheckoutMetadata checkoutMetadata, ObjectLoader ol, OutputStream channel) throws MissingObjectException, IOException { boolean isMandatory = repo.getConfig().getBoolean( ConfigConstants.CONFIG_FILTER_SECTION, ConfigConstants.CONFIG_SECTION_LFS, ConfigConstants.CONFIG_KEY_REQUIRED, false); FilterCommand command = null; try { command = FilterCommandRegistry.createFilterCommand( checkoutMetadata.smudgeFilterCommand, repo, ol.openStream(), channel); } catch (IOException e) { LOG.error(JGitText.get().failedToDetermineFilterDefinition, e); if (!isMandatory) { // In case an IOException occurred during creating of the // command then proceed as if there would not have been a // builtin filter (only if the filter is not mandatory). ol.copyTo(channel); } else { throw e; } } if (command != null) { while (command.run() != -1) { // loop as long as command.run() tells there is work to do } } }
.createFilterCommand(filterCommand, repository, in, buffer); while (command.run() != -1) {
private static void runBuiltinFilterCommand(Repository repo, CheckoutMetadata checkoutMetadata, ObjectLoader ol, OutputStream channel) throws MissingObjectException, IOException { boolean isMandatory = repo.getConfig().getBoolean( ConfigConstants.CONFIG_FILTER_SECTION, ConfigConstants.CONFIG_SECTION_LFS, ConfigConstants.CONFIG_KEY_REQUIRED, false); FilterCommand command = null; try { command = FilterCommandRegistry.createFilterCommand( checkoutMetadata.smudgeFilterCommand, repo, ol.openStream(), channel); } catch (IOException e) { LOG.error(JGitText.get().failedToDetermineFilterDefinition, e); if (!isMandatory) { // In case an IOException occurred during creating of the // command then proceed as if there would not have been a // builtin filter (only if the filter is not mandatory). ol.copyTo(channel); } else { throw e; } } if (command != null) { while (command.run() != -1) { // loop as long as command.run() tells there is work to do } } }
.createFilterCommand(filterCommand, repository, in, buffer); while (command.run() != -1) {