Class AssemblyResolutionResults
- java.lang.Object
-
- org.apache.commons.collections4.collection.AbstractCollectionDecorator<E>
-
- org.apache.commons.collections4.set.AbstractSetDecorator<AssemblyResolution>
-
- ghidra.app.plugin.assembler.sleigh.sem.AssemblyResolutionResults
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Iterable<AssemblyResolution>
,java.util.Collection<AssemblyResolution>
,java.util.Set<AssemblyResolution>
public class AssemblyResolutionResults extends org.apache.commons.collections4.set.AbstractSetDecorator<AssemblyResolution>
A set of possible assembly resolutions for a single SLEIGH constructor Since the assembler works from the leaves up, it unclear in what context a given token appears. Thus, every possible encoding is collected and passed upward. As resolution continues, many of the possible encodings are pruned out. When the resolver reaches the root, we end up with every possible encoding (less some prefixes) of an instruction. This object stores the possible encodings, including error records describing the pruned intermediate results.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.Set<AssemblyResolution>
resolutions
-
Constructor Summary
Constructors Constructor Description AssemblyResolutionResults()
Construct a new (mutable) empty set of resolutions
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
absorb(AssemblyResolutionResults that)
A synonym foraddAll(Collection)
that accepts only another resolution setboolean
add(AssemblyResolution ar)
boolean
addAll(java.util.Collection<? extends AssemblyResolution> c)
protected java.util.Set<AssemblyResolution>
decorated()
java.util.Set<AssemblyResolution>
getResolutions()
Get an unmodifiable reference to this setboolean
remove(AssemblyResolution ar)
static AssemblyResolutionResults
singleton(AssemblyResolvedConstructor rc)
Construct an immutable single-entry set consisting of the one given resolution-
Methods inherited from class org.apache.commons.collections4.set.AbstractSetDecorator
equals, hashCode
-
Methods inherited from class org.apache.commons.collections4.collection.AbstractCollectionDecorator
clear, contains, containsAll, isEmpty, iterator, remove, removeAll, retainAll, setCollection, size, toArray, toArray, toString
-
-
-
-
Field Detail
-
resolutions
protected final java.util.Set<AssemblyResolution> resolutions
-
-
Method Detail
-
singleton
public static AssemblyResolutionResults singleton(AssemblyResolvedConstructor rc)
Construct an immutable single-entry set consisting of the one given resolution- Parameters:
rc
- the single resolution entry- Returns:
- the new resolution set
-
add
public boolean add(AssemblyResolution ar)
- Specified by:
add
in interfacejava.util.Collection<AssemblyResolution>
- Specified by:
add
in interfacejava.util.Set<AssemblyResolution>
- Overrides:
add
in classorg.apache.commons.collections4.collection.AbstractCollectionDecorator<AssemblyResolution>
-
absorb
public void absorb(AssemblyResolutionResults that)
A synonym foraddAll(Collection)
that accepts only another resolution set- Parameters:
that
- the other set
-
addAll
public boolean addAll(java.util.Collection<? extends AssemblyResolution> c)
- Specified by:
addAll
in interfacejava.util.Collection<AssemblyResolution>
- Specified by:
addAll
in interfacejava.util.Set<AssemblyResolution>
- Overrides:
addAll
in classorg.apache.commons.collections4.collection.AbstractCollectionDecorator<AssemblyResolution>
-
getResolutions
public java.util.Set<AssemblyResolution> getResolutions()
Get an unmodifiable reference to this set- Returns:
- the set
-
decorated
protected java.util.Set<AssemblyResolution> decorated()
- Overrides:
decorated
in classorg.apache.commons.collections4.set.AbstractSetDecorator<AssemblyResolution>
-
remove
public boolean remove(AssemblyResolution ar)
-
-