Class ImmutableExploreResult
- java.lang.Object
-
- com.chutneytesting.agent.domain.explore.ImmutableExploreResult
-
- All Implemented Interfaces:
ExploreResult
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutableExploreResult extends Object implements ExploreResult
Immutable implementation ofExploreResult.Use the builder to create immutable instances:
ImmutableExploreResult.builder(). Use the static factory method to create immutable instances:ImmutableExploreResult.of().
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutableExploreResult.BuilderBuilds instances of typeImmutableExploreResult.static classImmutableExploreResult.Link<SOURCE,DESTINATION>Immutable implementation ofExploreResult.Link.static classImmutableExploreResult.Links<SOURCE,DESTINATION>Immutable implementation ofExploreResult.Links.
-
Field Summary
-
Fields inherited from interface com.chutneytesting.agent.domain.explore.ExploreResult
EMPTY
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ExploreResult.Links<AgentId,AgentId>agentLinks()static ImmutableExploreResult.Builderbuilder()Creates a builder forImmutableExploreResult.static ImmutableExploreResultcopyOf(ExploreResult instance)Creates an immutable copy of aExploreResultvalue.booleanequals(Object another)This instance is equal to all instances ofImmutableExploreResultthat have equal attribute values.inthashCode()Computes a hash code from attributes:agentLinks,targetLinks.static ImmutableExploreResultof(ExploreResult.Links<AgentId,AgentId> agentLinks, ExploreResult.Links<AgentId,TargetId> targetLinks)Construct a new immutableExploreResultinstance.ExploreResult.Links<AgentId,TargetId>targetLinks()StringtoString()Prints the immutable valueExploreResultwith attribute values.ImmutableExploreResultwithAgentLinks(ExploreResult.Links<AgentId,AgentId> value)Copy the current immutable object by setting a value for theagentLinksattribute.ImmutableExploreResultwithTargetLinks(ExploreResult.Links<AgentId,TargetId> value)Copy the current immutable object by setting a value for thetargetLinksattribute.
-
-
-
Method Detail
-
agentLinks
public ExploreResult.Links<AgentId,AgentId> agentLinks()
- Specified by:
agentLinksin interfaceExploreResult- Returns:
- The value of the
agentLinksattribute
-
targetLinks
public ExploreResult.Links<AgentId,TargetId> targetLinks()
- Specified by:
targetLinksin interfaceExploreResult- Returns:
- The value of the
targetLinksattribute
-
withAgentLinks
public final ImmutableExploreResult withAgentLinks(ExploreResult.Links<AgentId,AgentId> value)
Copy the current immutable object by setting a value for theagentLinksattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for agentLinks- Returns:
- A modified copy of the
thisobject
-
withTargetLinks
public final ImmutableExploreResult withTargetLinks(ExploreResult.Links<AgentId,TargetId> value)
Copy the current immutable object by setting a value for thetargetLinksattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for targetLinks- Returns:
- A modified copy of the
thisobject
-
equals
public boolean equals(@Nullable Object another)This instance is equal to all instances ofImmutableExploreResultthat have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:agentLinks,targetLinks.
-
toString
public String toString()
Prints the immutable valueExploreResultwith attribute values.
-
of
public static ImmutableExploreResult of(ExploreResult.Links<AgentId,AgentId> agentLinks, ExploreResult.Links<AgentId,TargetId> targetLinks)
Construct a new immutableExploreResultinstance.- Parameters:
agentLinks- The value for theagentLinksattributetargetLinks- The value for thetargetLinksattribute- Returns:
- An immutable ExploreResult instance
-
copyOf
public static ImmutableExploreResult copyOf(ExploreResult instance)
Creates an immutable copy of aExploreResultvalue. 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 ExploreResult instance
-
builder
public static ImmutableExploreResult.Builder builder()
Creates a builder forImmutableExploreResult.ImmutableExploreResult.builder() .agentLinks(com.chutneytesting.agent.domain.explore.ExploreResult.Links<com.chutneytesting.agent.domain.explore.AgentId, com.chutneytesting.agent.domain.explore.AgentId>) // requiredagentLinks.targetLinks(com.chutneytesting.agent.domain.explore.ExploreResult.Links<com.chutneytesting.agent.domain.explore.AgentId, com.chutneytesting.agent.domain.TargetId>) // requiredtargetLinks.build();- Returns:
- A new ImmutableExploreResult builder
-
-