SafespotResult
Result of a PvP safespot query.
Final classRLPlugins API
public final class SafespotResultMembers
Constructors
- newSafespotResult(SafespotResult.Status, SafespotPlan, String, int, int, int)
Creates a SafespotResult.
Methods
- booleanequals(Object)
Whether this and the other object are the same thing.
- intgetCandidatesEvaluated()
Compatibility alias for older planning terminology.
- intgetNodesVisited()
Compatibility alias for older planning terminology.
- intgetPathNodesVisited()
Number of path nodes visited while choosing the closest reachable safespot.
- SafespotPlangetPlan()
PvP safespot plan, or
nullwhen unavailable. - StringgetReason()
Human-readable result reason.
- intgetSnapshotTick()
Game tick used to build the result.
- SafespotResult.StatusgetStatus()
Query status.
- intgetTilesEvaluated()
Number of candidate tiles evaluated.
- inthashCode()
A number Java uses when this is put in a set or a map.
- booleanhasPlan()
Returns whether the result contains at least one safespot.
- SafespotResultinvalid(String)
Creates an invalid-input result.
- SafespotResultnotRequested()
Result returned before any safespot query has been requested.
SafespotResult(SafespotResult.Status, SafespotPlan, String, int, int, int)
public SafespotResult(SafespotResult.Status status, SafespotPlan plan, String reason, int tilesEvaluated, int pathNodesVisited, int snapshotTick)Creates a SafespotResult.
Parameters
status- Status.
plan- Plan.
reason- Reason.
tilesEvaluated- Tiles evaluated.
pathNodesVisited- Path nodes visited.
snapshotTick- Snapshot tick.
equals(Object)
public boolean equals(Object o)Whether this and the other object are the same thing.
Parameters
o- O.
getCandidatesEvaluated()
public int getCandidatesEvaluated()Compatibility alias for older planning terminology.
Returns
Evaluated tile count.
getNodesVisited()
public int getNodesVisited()Compatibility alias for older planning terminology.
Returns
Visited path nodes.
getPathNodesVisited()
public int getPathNodesVisited()Number of path nodes visited while choosing the closest reachable safespot.
Returns
Visited path nodes.
getPlan()
public SafespotPlan getPlan()PvP safespot plan, or null when unavailable.
Returns
Plan.
getReason()
public String getReason()Human-readable result reason.
Returns
Reason.
getSnapshotTick()
public int getSnapshotTick()Game tick used to build the result.
Returns
Snapshot tick.
getStatus()
public SafespotResult.Status getStatus()Query status.
Returns
Status.
getTilesEvaluated()
public int getTilesEvaluated()Number of candidate tiles evaluated.
Returns
Evaluated tile count.
hashCode()
public int hashCode()A number Java uses when this is put in a set or a map.
hasPlan()
public boolean hasPlan()Returns whether the result contains at least one safespot.
Returns
true when a safespot bucket contains tiles.
invalid(String)static
public static SafespotResult invalid(String reason)Creates an invalid-input result.
Parameters
reason- Human-readable reason.
Returns
Invalid-input result.
notRequested()static
public static SafespotResult notRequested()Result returned before any safespot query has been requested.
Returns
Not-requested result.
Also allowed
Every class has these, as in plain Java.
toString