Package com.spotify.github
Class ImmutableCloseTracking
- java.lang.Object
-
- com.spotify.github.ImmutableCloseTracking
-
- All Implemented Interfaces:
CloseTracking
,UpdateTracking
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutableCloseTracking extends Object implements CloseTracking
Immutable implementation ofCloseTracking
.Use the builder to create immutable instances:
ImmutableCloseTracking.builder()
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ImmutableCloseTracking.Builder
Builds instances of typeImmutableCloseTracking
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImmutableCloseTracking.Builder
builder()
Creates a builder forImmutableCloseTracking
.Optional<GitHubInstant>
closedAt()
Closed date.static ImmutableCloseTracking
copyOf(CloseTracking instance)
Creates an immutable copy of aCloseTracking
value.GitHubInstant
createdAt()
Created dateboolean
equals(Object another)
This instance is equal to all instances ofImmutableCloseTracking
that have equal attribute values.int
hashCode()
Computes a hash code from attributes:createdAt
,updatedAt
,closedAt
.String
toString()
Prints the immutable valueCloseTracking
with attribute values.GitHubInstant
updatedAt()
Updated dateImmutableCloseTracking
withClosedAt(GitHubInstant value)
Copy the current immutable object by setting a present value for the optionalclosedAt
attribute.ImmutableCloseTracking
withClosedAt(Optional<? extends GitHubInstant> optional)
Copy the current immutable object by setting an optional value for theclosedAt
attribute.ImmutableCloseTracking
withCreatedAt(GitHubInstant value)
Copy the current immutable object by setting a value for thecreatedAt
attribute.ImmutableCloseTracking
withUpdatedAt(GitHubInstant value)
Copy the current immutable object by setting a value for theupdatedAt
attribute.
-
-
-
Method Detail
-
createdAt
@Nullable public GitHubInstant createdAt()
Created date- Specified by:
createdAt
in interfaceUpdateTracking
- Returns:
- The date when the issue was created
-
updatedAt
@Nullable public GitHubInstant updatedAt()
Updated date- Specified by:
updatedAt
in interfaceUpdateTracking
- Returns:
- The date when the issue was updated
-
closedAt
public Optional<GitHubInstant> closedAt()
Closed date.- Specified by:
closedAt
in interfaceCloseTracking
- Returns:
- The date when the issue was closed
-
withCreatedAt
public final ImmutableCloseTracking withCreatedAt(@Nullable GitHubInstant value)
Copy the current immutable object by setting a value for thecreatedAt
attribute. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for createdAt (can benull
)- Returns:
- A modified copy of the
this
object
-
withUpdatedAt
public final ImmutableCloseTracking withUpdatedAt(@Nullable GitHubInstant value)
Copy the current immutable object by setting a value for theupdatedAt
attribute. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for updatedAt (can benull
)- Returns:
- A modified copy of the
this
object
-
withClosedAt
public final ImmutableCloseTracking withClosedAt(GitHubInstant value)
Copy the current immutable object by setting a present value for the optionalclosedAt
attribute.- Parameters:
value
- The value for closedAt- Returns:
- A modified copy of
this
object
-
withClosedAt
public final ImmutableCloseTracking withClosedAt(Optional<? extends GitHubInstant> optional)
Copy the current immutable object by setting an optional value for theclosedAt
attribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for closedAt- Returns:
- A modified copy of
this
object
-
equals
public boolean equals(@Nullable Object another)
This instance is equal to all instances ofImmutableCloseTracking
that have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:createdAt
,updatedAt
,closedAt
.
-
toString
public String toString()
Prints the immutable valueCloseTracking
with attribute values.
-
copyOf
public static ImmutableCloseTracking copyOf(CloseTracking instance)
Creates an immutable copy of aCloseTracking
value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance
- The instance to copy- Returns:
- A copied immutable CloseTracking instance
-
builder
public static ImmutableCloseTracking.Builder builder()
Creates a builder forImmutableCloseTracking
.ImmutableCloseTracking.builder() .createdAt(com.spotify.github.GitHubInstant | null) // nullable
createdAt
.updatedAt(com.spotify.github.GitHubInstant | null) // nullableupdatedAt
.closedAt(com.spotify.github.GitHubInstant) // optionalclosedAt
.build();- Returns:
- A new ImmutableCloseTracking builder
-
-