/* * Copyright (C) 2009, Alex Blewitt * Copyright (C) 2007, Robin Rosenberg * Copyright (C) 2008, Shawn O. Pearce and others * * This program and the accompanying materials are made available under the * terms of the Eclipse Distribution License v. 1.0 which is available at * https://www.eclipse.org/org/documents/edl-v10.php. * * SPDX-License-Identifier: BSD-3-Clause */ package org.eclipse.jgit.lib; /** * A NullProgressMonitor does not report progress anywhere. */ public class NullProgressMonitor implements ProgressMonitor { /** Immutable instance of a null progress monitor. */ public static final NullProgressMonitor INSTANCE = new NullProgressMonitor(); private NullProgressMonitor() { // Do not let others instantiate } @Override public void start(int totalTasks) { // Do not report. } @Override public void beginTask(String title, int totalWork) { // Do not report. } @Override public void update(int completed) { // Do not report. } @Override public boolean isCancelled() { return false; } @Override public void endTask() { // Do not report. } @Override public void showDuration(boolean enabled) { // don't show } }