Class TargetImpl
java.lang.Object
pw.chew.clickup4j.internal.entities.TargetImpl
- All Implemented Interfaces:
Target
-
Constructor Summary
ConstructorDescriptionTargetImpl
(@NotNull org.json.JSONObject data, @NotNull ClickUp4j api, @NotNull Goal goal) -
Method Summary
Modifier and TypeMethodDescription@NotNull ClickUp4j
Returns thisClickUp4j
instance.@NotNull String
Returns the ID of theUser
who created the target.int
Returns the current number of steps.@NotNull OffsetDateTime
Returns the date and time when the target was created.@NotNull Goal
getGoal()
TheGoal
this target belongs to.@NotNull UUID
getId()
The unique identifier of the target.@NotNull TimelineEntry
Returns the most recentaction
that was performed on the target.@NotNull String
getName()
Returns the name of the target.@Nullable User
getOwner()
Returns the owner of the target.float
Returns the current percentage of completion.int
The number of steps to complete.int
The number of steps to start with.@NotNull String
getType()
Returns the type of the target.@NotNull String
getUnit()
Returns the unit of measurement for a step.boolean
Returns if this target is completed.
-
Constructor Details
-
TargetImpl
-
-
Method Details
-
getId
Description copied from interface:Target
The unique identifier of the target. -
getGoal
Description copied from interface:Target
TheGoal
this target belongs to. -
getName
Description copied from interface:Target
Returns the name of the target. -
getCreatorId
Description copied from interface:Target
Returns the ID of theUser
who created the target.- Specified by:
getCreatorId
in interfaceTarget
- Returns:
- never-null ID of the
User
who created the target
-
getOwner
Description copied from interface:Target
Returns the owner of the target. -
getType
Description copied from interface:Target
Returns the type of the target. -
getDateCreated
Description copied from interface:Target
Returns the date and time when the target was created.- Specified by:
getDateCreated
in interfaceTarget
- Returns:
- never-null date and time when the target was created
-
getStepsStart
public int getStepsStart()Description copied from interface:Target
The number of steps to start with.- Specified by:
getStepsStart
in interfaceTarget
- Returns:
- number of steps to start with
-
getStepsEnd
public int getStepsEnd()Description copied from interface:Target
The number of steps to complete.- Specified by:
getStepsEnd
in interfaceTarget
- Returns:
- number of steps to complete
-
getCurrentStep
public int getCurrentStep()Description copied from interface:Target
Returns the current number of steps.- Specified by:
getCurrentStep
in interfaceTarget
- Returns:
- current number of steps
-
getUnit
Description copied from interface:Target
Returns the unit of measurement for a step. -
getPercentCompleted
public float getPercentCompleted()Description copied from interface:Target
Returns the current percentage of completion.- Specified by:
getPercentCompleted
in interfaceTarget
- Returns:
- current percentage of completion
-
isCompleted
public boolean isCompleted()Description copied from interface:Target
Returns if this target is completed.- Specified by:
isCompleted
in interfaceTarget
- Returns:
- true if this target is completed, false otherwise
-
getLastAction
Description copied from interface:Target
Returns the most recentaction
that was performed on the target.- Specified by:
getLastAction
in interfaceTarget
- Returns:
- never-null
TimelineEntry
most recent action performed on the target
-
getClickUp4j
Description copied from interface:Target
Returns thisClickUp4j
instance.- Specified by:
getClickUp4j
in interfaceTarget
- Returns:
- never-null ClickUp4j instance.
-