Package ghidra.trace.model.time.schedule
Class AbstractStep
java.lang.Object
ghidra.trace.model.time.schedule.AbstractStep
- All Implemented Interfaces:
Step,Comparable<Step>
-
Nested Class Summary
Nested classes/interfaces inherited from interface ghidra.trace.model.time.schedule.Step
Step.StepType -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidadvance(long steps) Add to the count of this stepabstract AbstractStepclone()longcoalescePatches(Language language, List<Step> steps) compareStep(Step step) Richly compare this step to anotherbooleanlonglonglonginthashCode()booleanisCompatible(Step step) Check if the given step can be combined with this onebooleanisNop()longrewind(long steps) Subtract from the count of this steptoString()toString(TraceSchedule.TimeRadix radix) protected abstract StringReturn the step portion oftoString()Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface ghidra.trace.model.time.schedule.Step
compareStepType, compareTo, execute, execute, getSkipCount, getThread, getType, getTypeOrder, isEventThread, subtract
-
Field Details
-
threadKey
protected final long threadKey -
tickCount
protected long tickCount
-
-
Constructor Details
-
AbstractStep
protected AbstractStep(long threadKey, long tickCount)
-
-
Method Details
-
toStringStepPart
Return the step portion oftoString()- Parameters:
radix- the radix- Returns:
- the string
-
toString
-
toString
-
isNop
public boolean isNop() -
getThreadKey
public long getThreadKey()- Specified by:
getThreadKeyin interfaceStep
-
getTickCount
public long getTickCount()- Specified by:
getTickCountin interfaceStep
-
getPatchCount
public long getPatchCount()- Specified by:
getPatchCountin interfaceStep
-
clone
-
advance
public void advance(long steps) Add to the count of this step- Parameters:
steps- the count to add
-
rewind
public long rewind(long steps) Description copied from interface:StepSubtract from the count of this stepIf this step has a count exceeding that given, then this method simply subtracts the given number from the
tickCountand returns the (negative) difference. If this step has exactly the count given, this method sets the count to 0 and returns 0, indicating this step should be removed from the sequence. If the given count exceeds that of this step, this method sets the count to 0 and returns the (positive) difference, indicating this step should be removed from the sequence, and the remaining steps rewound from the preceding step. -
isCompatible
Description copied from interface:StepCheck if the given step can be combined with this oneTwo steps applied to the same thread can just be summed. If the given step applies to the "last thread" or to the same thread as this step, then it can be combined.
- Specified by:
isCompatiblein interfaceStep- Parameters:
step- the second step- Returns:
- true if combinable, false otherwise.
-
addTo
-
hashCode
public int hashCode() -
equals
-
compareStep
Description copied from interface:StepRichly compare this step to another- Specified by:
compareStepin interfaceStep- Parameters:
step- the object of comparison (this being the subject)- Returns:
- a result describing the relationship from subject to object
-
coalescePatches
- Specified by:
coalescePatchesin interfaceStep
-