org.springframework.cloud.dataflow.rest.resource

## Class TaskDefinitionResource

- java.lang.Object
- - org.springframework.hateoas.RepresentationModel<TaskDefinitionResource>
  - - org.springframework.cloud.dataflow.rest.resource.TaskDefinitionResource

-     public class TaskDefinitionResource
      extends org.springframework.hateoas.RepresentationModel<TaskDefinitionResource>

  A HATEOAS representation of a `TaskDefinition`.
  Author:
    Michael Minella, Glenn Renfro, Gunnar Hillert

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `TaskDefinitionResource.Page`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `TaskDefinitionResource()` Default constructor to be used by Jackson.
    `` | `TaskDefinitionResource(String name, String dslText, String description)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `getDescription()`
    `String` | `getDslText()`
    `TaskExecutionResource` | `getLastTaskExecution()`
    `String` | `getName()`
    `String` | `getStatus()` Return the status of this task.
    `boolean` | `isComposed()` Return if this task is a composed task
    `boolean` | `isComposedTaskElement()`
    `void` | `setComposed(boolean composed)` Set if this task is a composed task
    `void` | `setComposedTaskElement(boolean composedTaskElement)`
    `void` | `setLastTaskExecution(TaskExecutionResource lastTaskExecution)`

    - ### Methods inherited from class org.springframework.hateoas.RepresentationModel

      `add, add, add, addAllIf, addIf, equals, getLink, getLink, getLinks, getLinks, getLinks, getRequiredLink, getRequiredLink, hashCode, hasLink, hasLink, hasLinks, of, of, removeLinks, toString`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### TaskDefinitionResource

          protected TaskDefinitionResource()

      Default constructor to be used by Jackson.

    - #### TaskDefinitionResource

          public TaskDefinitionResource(String name,
                                        String dslText,
                                        String description)

  - ### Method Detail

    - #### getName

          public String getName()

    - #### getDslText

          public String getDslText()

    - #### getDescription

          public String getDescription()

    - #### isComposed

          public boolean isComposed()

      Return if this task is a composed task
      Returns:
        composed

    - #### setComposed

          public void setComposed(boolean composed)

      Set if this task is a composed task
      Parameters:
        `composed` - is task a composed task

    - #### isComposedTaskElement

          public boolean isComposedTaskElement()

    - #### setComposedTaskElement

          public void setComposedTaskElement(boolean composedTaskElement)

    - #### getStatus

          public String getStatus()

      Return the status of this task. Returns the value of `Enum.toString()`.
      Returns:
        task status

    - #### getLastTaskExecution

          public TaskExecutionResource getLastTaskExecution()

      Returns:
        Last `TaskExecution` if available, null otherwise

    - #### setLastTaskExecution

          public void setLastTaskExecution(TaskExecutionResource lastTaskExecution)

      Parameters:
        `lastTaskExecution` - the last Task Execution

Copyright © 2021 Pivotal Software, Inc.. All rights reserved.