Class DefaultTaskSuccessResult
- java.lang.Object
-
- org.gradle.tooling.events.internal.DefaultOperationSuccessResult
-
- org.gradle.tooling.events.task.internal.DefaultTaskSuccessResult
-
- All Implemented Interfaces:
OperationResult,SuccessResult,TaskExecutionResult,TaskOperationResult,TaskSuccessResult
- Direct Known Subclasses:
DefaultJavaCompileTaskSuccessResult
public class DefaultTaskSuccessResult extends DefaultOperationSuccessResult implements TaskSuccessResult
Implementation of theTaskSuccessResultinterface.
-
-
Constructor Summary
Constructors Constructor Description DefaultTaskSuccessResult(long startTime, long endTime, boolean upToDate, boolean fromCache, TaskExecutionDetails taskExecutionDetails)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<java.lang.String>getExecutionReasons()Returns the reasons why this task was executed.booleanisFromCache()Returns whether the output for this task was pulled from a build cache when using task output caching.booleanisIncremental()Returns whether this task was executed incrementally.booleanisUpToDate()Returns whether this task was up-to-date.-
Methods inherited from class org.gradle.tooling.events.internal.DefaultOperationSuccessResult
getEndTime, getStartTime
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.gradle.tooling.events.OperationResult
getEndTime, getStartTime
-
-
-
-
Constructor Detail
-
DefaultTaskSuccessResult
public DefaultTaskSuccessResult(long startTime, long endTime, boolean upToDate, boolean fromCache, TaskExecutionDetails taskExecutionDetails)
-
-
Method Detail
-
isUpToDate
public boolean isUpToDate()
Description copied from interface:TaskSuccessResultReturns whether this task was up-to-date.- Specified by:
isUpToDatein interfaceTaskSuccessResult- Returns:
trueif this task was up-to-date
-
isFromCache
public boolean isFromCache()
Description copied from interface:TaskSuccessResultReturns whether the output for this task was pulled from a build cache when using task output caching.NOTE: This will always be false if the Gradle version does not support task output caching.
- Specified by:
isFromCachein interfaceTaskSuccessResult- Returns:
trueif the output for this task was from a build cache
-
isIncremental
public boolean isIncremental()
Description copied from interface:TaskExecutionResultReturns whether this task was executed incrementally.- Specified by:
isIncrementalin interfaceTaskExecutionResult- Returns:
trueif this task was executed incrementally
-
getExecutionReasons
@Nullable public java.util.List<java.lang.String> getExecutionReasons()
Description copied from interface:TaskExecutionResultReturns the reasons why this task was executed.- Specified by:
getExecutionReasonsin interfaceTaskExecutionResult- Returns:
- the reasons why this task was executed; an empty list indicates the task was up-to-date;
nullthat it failed before up-to-date checks had been performed.
-
-