Record Class InstructionSet.Defaults
java.lang.Object
java.lang.Record
org.applecommander.disassembler.api.InstructionSet.Defaults
- Record Components:
startAddress- Common starting address for an application. Could be somewhat arbitrary.libraryLabels- A default set of library labels. Commonly is "All" or "None".bytesPerInstruction- Number of bytes commonly used in an expression. The disassembler does wrap after, so nothing is lost.includeDescription- Some instruction sets (p-code in particular) include instruction descriptions that may be useful.
- Enclosing interface:
InstructionSet
public static record InstructionSet.Defaults(int startAddress, List<String> libraryLabels, int bytesPerInstruction, boolean includeDescription)
extends Record
Provides default values that are valid for the InstructionSet.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Initiate construction of a Defaults object.intReturns the value of thebytesPerInstructionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanReturns the value of theincludeDescriptionrecord component.Returns the value of thelibraryLabelsrecord component.intReturns the value of thestartAddressrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Defaults
public Defaults(int startAddress, List<String> libraryLabels, int bytesPerInstruction, boolean includeDescription) Creates an instance of aDefaultsrecord class.- Parameters:
startAddress- the value for thestartAddressrecord componentlibraryLabels- the value for thelibraryLabelsrecord componentbytesPerInstruction- the value for thebytesPerInstructionrecord componentincludeDescription- the value for theincludeDescriptionrecord component
-
-
Method Details
-
builder
Initiate construction of a Defaults object. For example:return Defaults.builder() .startAddress(0x300) .libraryLabels("All") .bytesPerInstruction(3) .get(); -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
startAddress
public int startAddress()Returns the value of thestartAddressrecord component.- Returns:
- the value of the
startAddressrecord component
-
libraryLabels
Returns the value of thelibraryLabelsrecord component.- Returns:
- the value of the
libraryLabelsrecord component
-
bytesPerInstruction
public int bytesPerInstruction()Returns the value of thebytesPerInstructionrecord component.- Returns:
- the value of the
bytesPerInstructionrecord component
-
includeDescription
public boolean includeDescription()Returns the value of theincludeDescriptionrecord component.- Returns:
- the value of the
includeDescriptionrecord component
-