Package com.android.repository.api
Class ConsoleProgressIndicator
- java.lang.Object
-
- com.android.repository.api.ProgressIndicatorAdapter
-
- com.android.repository.api.ConsoleProgressIndicator
-
- All Implemented Interfaces:
ProgressIndicator
public class ConsoleProgressIndicator extends ProgressIndicatorAdapter
-
-
Constructor Summary
Constructors Constructor Description ConsoleProgressIndicator()ConsoleProgressIndicator(java.io.PrintStream out, java.io.PrintStream err)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description doublegetFraction()voidlogError(java.lang.String s, java.lang.Throwable e)Logs an error, including a stacktrace.voidlogInfo(java.lang.String s)Logs an info message.voidlogWarning(java.lang.String s, java.lang.Throwable e)Logs a warning, including a stacktrace.voidsetErr(java.io.PrintStream err)voidsetFraction(double progress)Sets how much progress should be shown on the progress bar, between 0 and 1.voidsetOut(java.io.PrintStream out)voidsetSecondaryText(java.lang.String text)Sets the secondary text on the progress indicator.voidsetText(java.lang.String text)Sets the main text shown in the progress indicator.-
Methods inherited from class com.android.repository.api.ProgressIndicatorAdapter
cancel, isCanceled, isCancellable, isIndeterminate, logError, logWarning, setCancellable, setIndeterminate
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.android.repository.api.ProgressIndicator
createSubProgress, logVerbose
-
-
-
-
Method Detail
-
setOut
public void setOut(@NonNull java.io.PrintStream out)
-
setErr
public void setErr(@NonNull java.io.PrintStream err)
-
getFraction
public double getFraction()
- Specified by:
getFractionin interfaceProgressIndicator- Overrides:
getFractionin classProgressIndicatorAdapter- Returns:
- The current amount of progress shown on the progress bar, between 0 and 1.
-
setFraction
public void setFraction(double progress)
Description copied from interface:ProgressIndicatorSets how much progress should be shown on the progress bar, between 0 and 1.- Specified by:
setFractionin interfaceProgressIndicator- Overrides:
setFractionin classProgressIndicatorAdapter
-
logWarning
public void logWarning(@NonNull java.lang.String s, @Nullable java.lang.Throwable e)Description copied from interface:ProgressIndicatorLogs a warning, including a stacktrace.- Specified by:
logWarningin interfaceProgressIndicator- Overrides:
logWarningin classProgressIndicatorAdapter
-
logError
public void logError(@NonNull java.lang.String s, @Nullable java.lang.Throwable e)Description copied from interface:ProgressIndicatorLogs an error, including a stacktrace.- Specified by:
logErrorin interfaceProgressIndicator- Overrides:
logErrorin classProgressIndicatorAdapter
-
logInfo
public void logInfo(@NonNull java.lang.String s)Description copied from interface:ProgressIndicatorLogs an info message.- Specified by:
logInfoin interfaceProgressIndicator- Overrides:
logInfoin classProgressIndicatorAdapter
-
setText
public void setText(@Nullable java.lang.String text)Description copied from interface:ProgressIndicatorSets the main text shown in the progress indicator.- Specified by:
setTextin interfaceProgressIndicator- Overrides:
setTextin classProgressIndicatorAdapter
-
setSecondaryText
public void setSecondaryText(@Nullable java.lang.String text)Description copied from interface:ProgressIndicatorSets the secondary text on the progress indicator.- Specified by:
setSecondaryTextin interfaceProgressIndicator- Overrides:
setSecondaryTextin classProgressIndicatorAdapter
-
-