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 classImmutableCloseTracking.BuilderBuilds instances of typeImmutableCloseTracking.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImmutableCloseTracking.Builderbuilder()Creates a builder forImmutableCloseTracking.Optional<GitHubInstant>closedAt()Closed date.static ImmutableCloseTrackingcopyOf(CloseTracking instance)Creates an immutable copy of aCloseTrackingvalue.GitHubInstantcreatedAt()Created datebooleanequals(Object another)This instance is equal to all instances ofImmutableCloseTrackingthat have equal attribute values.inthashCode()Computes a hash code from attributes:createdAt,updatedAt,closedAt.StringtoString()Prints the immutable valueCloseTrackingwith attribute values.GitHubInstantupdatedAt()Updated dateImmutableCloseTrackingwithClosedAt(GitHubInstant value)Copy the current immutable object by setting a present value for the optionalclosedAtattribute.ImmutableCloseTrackingwithClosedAt(Optional<? extends GitHubInstant> optional)Copy the current immutable object by setting an optional value for theclosedAtattribute.ImmutableCloseTrackingwithCreatedAt(GitHubInstant value)Copy the current immutable object by setting a value for thecreatedAtattribute.ImmutableCloseTrackingwithUpdatedAt(GitHubInstant value)Copy the current immutable object by setting a value for theupdatedAtattribute.
-
-
-
Method Detail
-
createdAt
@Nullable public GitHubInstant createdAt()
Created date- Specified by:
createdAtin interfaceUpdateTracking- Returns:
- The date when the issue was created
-
updatedAt
@Nullable public GitHubInstant updatedAt()
Updated date- Specified by:
updatedAtin interfaceUpdateTracking- Returns:
- The date when the issue was updated
-
closedAt
public Optional<GitHubInstant> closedAt()
Closed date.- Specified by:
closedAtin 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 thecreatedAtattribute. 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
thisobject
-
withUpdatedAt
public final ImmutableCloseTracking withUpdatedAt(@Nullable GitHubInstant value)
Copy the current immutable object by setting a value for theupdatedAtattribute. 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
thisobject
-
withClosedAt
public final ImmutableCloseTracking withClosedAt(GitHubInstant value)
Copy the current immutable object by setting a present value for the optionalclosedAtattribute.- Parameters:
value- The value for closedAt- Returns:
- A modified copy of
thisobject
-
withClosedAt
public final ImmutableCloseTracking withClosedAt(Optional<? extends GitHubInstant> optional)
Copy the current immutable object by setting an optional value for theclosedAtattribute. 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
thisobject
-
equals
public boolean equals(@Nullable Object another)This instance is equal to all instances ofImmutableCloseTrackingthat have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:createdAt,updatedAt,closedAt.
-
toString
public String toString()
Prints the immutable valueCloseTrackingwith attribute values.
-
copyOf
public static ImmutableCloseTracking copyOf(CloseTracking instance)
Creates an immutable copy of aCloseTrackingvalue. 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) // nullablecreatedAt.updatedAt(com.spotify.github.GitHubInstant | null) // nullableupdatedAt.closedAt(com.spotify.github.GitHubInstant) // optionalclosedAt.build();- Returns:
- A new ImmutableCloseTracking builder
-
-