META-INF/MANIFEST.MF
Tank1990.iml
Settings.properties
mainclass.txt
registerDatapath.xml
CompileGameJava.sh
Test.class
mars_game.iml
images/Copy22.png
images/StepBack16.png
images/Cut22.gif
images/mars32.ico
images/Find22.png
images/Undo22.png
images/Redo22.png
images/Paste16.png
images/Play16.png
images/Cut24.gif
images/Stop22.png
images/MyBlank16.gif
images/StepForward16.png
images/register.png
images/control.png
images/Pause16.png
images/Reset16.png
images/Open22.png
images/Save22.png
images/Print24.gif
images/ALUcontrol.png
images/SaveAs22.png
images/RedMars16.gif
images/Assemble16.png
images/Help16.png
images/Dump16.png
images/New22.png
images/Print22.gif
images/Pause22.png
images/Previous22.png
images/datapath.png
images/Save16.png
images/RedMars32.GIF
images/Reset22.png
images/Open16.png
images/Help22.png
images/mars.ico
images/Assemble22.png
images/Edit_tab.jpg
images/SaveAs16.png
images/Print16.gif
images/New16.png
images/Dump22.png
images/MarsSurfacePathfinder.jpg
images/Undo16.png
images/Find16.png
images/MyBlank24.gif
images/Cut16.gif
images/StepBack22.png
images/Copy16.png
images/Redo16.png
images/RedMars50.gif
images/MarsThumbnail.gif
images/StepForward22.png
images/Stop16.png
images/Play22.png
images/Paste22.png
images/Next22.png
images/Execute_tab.jpg
Mars.class
CreateNewMarsSourceJar.bat
MARSlicense.txt
controlDatapath.xml
game/bitmap1.bck.txt
game/properties.txt
game/images/lower-monster_12.png
game/images/scorepoint0-20.png
game/images/path1.png
game/images/lower-monster_13.png
game/images/menu.gif
game/images/remoteBombA.png
game/images/lower-monster_11.png
game/images/path2.png
game/images/remoteBombD.png
game/images/lower-monster_14.png
game/images/brick_wall.png
game/images/lower-monster_15.png
game/images/remoteBombE.png
game/images/tankleft.png
game/images/lower-monster_16.png
game/images/blast_edge_3.png
game/images/brick_wall_break3.png
game/images/ninjaShield0.png
game/images/bombman_bomb_3.png
game/images/tankright.png
game/images/lower-monster_5.png
game/images/lower-monster_4.png
game/images/bombman_bomb_2.png
game/images/ninjaShield1.png
game/images/brick_wall_break2.png
game/images/wall1.png
game/images/blast_edge_2.png
game/images/blast_edge_0.png
game/images/mazeGameBackground.png
game/images/scorepoint3-10.png
game/images/bombman_bomb_1.png
game/images/ninjaShield2.png
game/images/wall2.png
game/images/brick_wall_break1.png
game/images/blast_edge_1.png
game/images/scorepoint1-15.png
game/images/brick_wall_break5.png
game/images/bombman_bomb_5.png
game/images/lower-monster_3.png
game/images/lower-monster_2.png
game/images/scorepoint3-15.png
game/images/bombman_bomb_4.png
game/images/subDestroyed.png
game/images/brick_wall_break4.png
game/images/scorepoint1-10.png
game/images/brick_wall_break6.png
game/images/bombman_bomb_6.png
game/images/tankAll.gif
game/images/lower-monster_0.png
game/images/lower-monster_1.png
game/images/tankup.png
game/images/bombman_up_3.png
game/images/blast_middle_2.png
game/images/blast_middle_3.png
game/images/scorepoint1-5.png
game/images/grass.png
game/images/bombman_right_1.png
game/images/bombman_up_2.png
game/images/bombman_right_3.png
game/images/scorepoint3-5.png
game/images/blast_middle_1.png
game/images/blast_middle_0.png
game/images/subDestroyed – Copy.png
game/images/bombman_right_2.png
game/images/bombman_up_1.png
game/images/scorepoint1-20.png
game/images/monster2-1.png
game/images/bombman_left_2.png
game/images/scorepoint3-20.png
game/images/monster0-2.png
game/images/monster2-0.png
game/images/bombman_left_3.png
game/images/ninjaShieldFade2.png
game/images/ninjaShieldFade0.png
game/images/bombman_left_1.png
game/images/monster2-2.png
game/images/monster0-0.png
game/images/monster0-1.png
game/images/ninjaShieldFade1.png
game/images/stone_wall.png
game/images/blast_center_3.png
game/images/scorepoint0-15.png
game/images/ninja2.png
game/images/tankAll – 副本.gif
game/images/blast_center_2.png
game/images/blast_center_0.png
game/images/ninja1.png
game/images/ninja0.png
game/images/scorepoint0-5.png
game/images/tankup_back.png
game/images/blast_center_1.png
game/images/monster1-0.png
game/images/bombman_down_3.png
game/images/bombman_down_2.png
game/images/tankdown.png
game/images/bomb_2.png
game/images/monster1-1.png
game/images/bomb_0.png
game/images/scorepoint0-10.png
game/images/bombman_down_1.png
game/images/bomb_1.png
game/images/monster1-2.png
game/bitmap2.txt
game/bitmap1.txt
game/sounds/move.wav
game/sounds/start.wav
game/sounds/prop.wav
game/sounds/playerCrack.wav
game/sounds/attack.wav
game/sounds/bulletCrack.wav
game/sounds/tankCrack.wav
game/bitmap_tmp.txt
game/quiz.txt
game/route0.txt
game/route1.txt
game/route3.txt
game/route2.txt
docs/constant-values.html
docs/overview-tree.html
docs/index.html
docs/Mars.html
docs/overview-frame.html
docs/allclasses-noframe.html
docs/serialized-form.html
docs/index-all.html
docs/resources/inherit.gif
docs/deprecated-list.html
docs/package-frame.html
docs/stylesheet.css
docs/overview-summary.html
docs/help-doc.html
docs/package-summary.html
docs/allclasses-frame.html
docs/package-list
docs/package-tree.html
docs/mars/tools/IntroToTools.html
docs/mars/tools/DigitalLabSim.html
docs/mars/tools/FloatRepresentation.html
docs/mars/tools/BHTSimulator.html
docs/mars/tools/KeyboardAndDisplaySimulator.html
docs/mars/tools/InstructionStatistics.html
docs/mars/tools/DigitalLabSim.SevenSegmentPanel.html
docs/mars/tools/InstructionCounter.html
docs/mars/tools/MarsBot.html
docs/mars/tools/CacheSimulator.html
docs/mars/tools/DigitalLabSim.HexaKeyboard.EcouteurClick.html
docs/mars/tools/ScreenMagnifier.html
docs/mars/tools/AbstractMarsToolAndApplication.ConnectButton.html
docs/mars/tools/DigitalLabSim.SevenSegmentDisplay.html
docs/mars/tools/MemoryReferenceVisualization.html
docs/mars/tools/MarsTool.html
docs/mars/tools/package-frame.html
docs/mars/tools/BHTSimGUI.html
docs/mars/tools/BHTableModel.html
docs/mars/tools/package-summary.html
docs/mars/tools/AbstractMarsToolAndApplication.html
docs/mars/tools/package-tree.html
docs/mars/tools/ScavengerHunt.html
docs/mars/tools/DigitalLabSim.OneSecondCounter.html
docs/mars/tools/BHTEntry.html
docs/mars/tools/AbstractMarsToolAndApplication.EnterKeyListener.html
docs/mars/tools/BitmapDisplay.html
docs/mars/tools/DigitalLabSim.HexaKeyboard.html
docs/mars/assembler/MacroPool.html
docs/mars/assembler/Directives.html
docs/mars/assembler/SourceLine.html
docs/mars/assembler/SymbolTable.html
docs/mars/assembler/TokenTypes.html
docs/mars/assembler/OperandFormat.html
docs/mars/assembler/TokenList.html
docs/mars/assembler/TranslationCode.html
docs/mars/assembler/package-frame.html
docs/mars/assembler/Assembler.html
docs/mars/assembler/Tokenizer.html
docs/mars/assembler/Symbol.html
docs/mars/assembler/package-summary.html
docs/mars/assembler/Macro.html
docs/mars/assembler/DataTypes.html
docs/mars/assembler/package-tree.html
docs/mars/assembler/Token.html
docs/mars/util/PropertiesFile.html
docs/mars/util/Binary.html
docs/mars/util/FilenameFinder.html
docs/mars/util/package-frame.html
docs/mars/util/EditorFont.html
docs/mars/util/package-summary.html
docs/mars/util/package-tree.html
docs/mars/util/SystemIO.html
docs/mars/util/MemoryDump.html
docs/mars/MarsSplashScreen.html
docs/mars/venus/FileStatus.html
docs/mars/venus/SettingsAssembleAllAction.html
docs/mars/venus/FilePrintAction.html
docs/mars/venus/FileExitAction.html
docs/mars/venus/EditSelectAllAction.html
docs/mars/venus/RunToggleBreakpointsAction.html
docs/mars/venus/HelpAboutAction.html
docs/mars/venus/TextSegmentWindow.html
docs/mars/venus/RunGoAction.html
docs/mars/venus/ToolAction.html
docs/mars/venus/Coprocessor1Window.html
docs/mars/venus/DataSegmentWindow.html
docs/mars/venus/FileNewAction.html
docs/mars/venus/RunAssembleAction.html
docs/mars/venus/EditRedoAction.html
docs/mars/venus/SettingsStartAtMainAction.html
docs/mars/venus/EditTabbedPane.html
docs/mars/venus/HardcopyWriter.html
docs/mars/venus/SettingsEditorAction.html
docs/mars/venus/SettingsMemoryConfigurationAction.html
docs/mars/venus/SettingsAddressDisplayBaseAction.html
docs/mars/venus/RunResetAction.html
docs/mars/venus/EditPasteAction.html
docs/mars/venus/FileOpenAction.html
docs/mars/venus/RunPauseAction.html
docs/mars/venus/editors/package-frame.html
docs/mars/venus/editors/jeditsyntax/TextAreaPainter.html
docs/mars/venus/editors/jeditsyntax/InputHandler.next_line.html
docs/mars/venus/editors/jeditsyntax/InputHandler.overwrite.html
docs/mars/venus/editors/jeditsyntax/SyntaxDocument.html
docs/mars/venus/editors/jeditsyntax/InputHandler.backspace_word.html
docs/mars/venus/editors/jeditsyntax/KeywordMap.html
docs/mars/venus/editors/jeditsyntax/InputHandler.prev_page.html
docs/mars/venus/editors/jeditsyntax/InputHandler.insert_tab.html
docs/mars/venus/editors/jeditsyntax/JEditTextArea.html
docs/mars/venus/editors/jeditsyntax/InputHandler.repeat.html
docs/mars/venus/editors/jeditsyntax/InputHandler.end.html
docs/mars/venus/editors/jeditsyntax/InputHandler.prev_word.html
docs/mars/venus/editors/jeditsyntax/TextAreaPainter.Highlight.html
docs/mars/venus/editors/jeditsyntax/InputHandler.backspace.html
docs/mars/venus/editors/jeditsyntax/JEditBasedTextArea.html
docs/mars/venus/editors/jeditsyntax/PopupHelpItem.html
docs/mars/venus/editors/jeditsyntax/DefaultInputHandler.html
docs/mars/venus/editors/jeditsyntax/tokenmarker/TokenMarker.html
docs/mars/venus/editors/jeditsyntax/tokenmarker/MIPSTokenMarker.html
docs/mars/venus/editors/jeditsyntax/tokenmarker/package-frame.html
docs/mars/venus/editors/jeditsyntax/tokenmarker/package-summary.html
docs/mars/venus/editors/jeditsyntax/tokenmarker/TokenMarker.LineInfo.html
docs/mars/venus/editors/jeditsyntax/tokenmarker/package-tree.html
docs/mars/venus/editors/jeditsyntax/tokenmarker/Token.html
docs/mars/venus/editors/jeditsyntax/InputHandler.NonRepeatable.html
docs/mars/venus/editors/jeditsyntax/InputHandler.next_char.html
docs/mars/venus/editors/jeditsyntax/InputHandler.prev_char.html
docs/mars/venus/editors/jeditsyntax/InputHandler.clip_paste.html
docs/mars/venus/editors/jeditsyntax/InputHandler.html
docs/mars/venus/editors/jeditsyntax/InputHandler.clip_copy.html
docs/mars/venus/editors/jeditsyntax/TextAreaDefaults.html
docs/mars/venus/editors/jeditsyntax/package-frame.html
docs/mars/venus/editors/jeditsyntax/SyntaxStyle.html
docs/mars/venus/editors/jeditsyntax/InputHandler.insert_break.html
docs/mars/venus/editors/jeditsyntax/package-summary.html
docs/mars/venus/editors/jeditsyntax/InputHandler.select_all.html
docs/mars/venus/editors/jeditsyntax/InputHandler.delete_word.html
docs/mars/venus/editors/jeditsyntax/TextUtilities.html
docs/mars/venus/editors/jeditsyntax/InputHandler.next_word.html
docs/mars/venus/editors/jeditsyntax/package-tree.html
docs/mars/venus/editors/jeditsyntax/SyntaxUtilities.html
docs/mars/venus/editors/jeditsyntax/InputHandler.Wrapper.html
docs/mars/venus/editors/jeditsyntax/InputHandler.next_page.html
docs/mars/venus/editors/jeditsyntax/InputHandler.prev_line.html
docs/mars/venus/editors/jeditsyntax/InputHandler.MacroRecorder.html
docs/mars/venus/editors/jeditsyntax/InputHandler.document_home.html
docs/mars/venus/editors/jeditsyntax/InputHandler.delete.html
docs/mars/venus/editors/jeditsyntax/InputHandler.home.html
docs/mars/venus/editors/jeditsyntax/InputHandler.insert_char.html
docs/mars/venus/editors/jeditsyntax/InputHandler.clip_cut.html
docs/mars/venus/editors/jeditsyntax/InputHandler.NonRecordable.html
docs/mars/venus/editors/jeditsyntax/InputHandler.toggle_rect.html
docs/mars/venus/editors/jeditsyntax/InputHandler.document_end.html
docs/mars/venus/editors/package-summary.html
docs/mars/venus/editors/generic/package-frame.html
docs/mars/venus/editors/generic/package-summary.html
docs/mars/venus/editors/generic/package-tree.html
docs/mars/venus/editors/generic/GenericTextArea.html
docs/mars/venus/editors/package-tree.html
docs/mars/venus/editors/MARSTextEditingArea.html
docs/mars/venus/RegistersWindow.html
docs/mars/venus/EditUndoAction.html
docs/mars/venus/FileSaveAction.html
docs/mars/venus/PopupListener.html
docs/mars/venus/SettingsExtendedAction.html
docs/mars/venus/EditFindReplaceAction.html
docs/mars/venus/Editor.html
docs/mars/venus/FileCloseAllAction.html
docs/mars/venus/SettingsLabelAction.html
docs/mars/venus/SettingsDelayedBranchingAction.html
docs/mars/venus/HardcopyWriter.PrintCanceledException.html
docs/mars/venus/ExecutePane.html
docs/mars/venus/RunClearBreakpointsAction.html
docs/mars/venus/Coprocessor0Window.html
docs/mars/venus/RegistersPane.html
docs/mars/venus/package-frame.html
docs/mars/venus/HelpHelpAction.html
docs/mars/venus/EditCutAction.html
docs/mars/venus/FileDumpMemoryAction.html
docs/mars/venus/SettingsSelfModifyingCodeAction.html
docs/mars/venus/package-summary.html
docs/mars/venus/RepeatButton.html
docs/mars/venus/EditCopyAction.html
docs/mars/venus/FileSaveAllAction.html
docs/mars/venus/MessagesPane.html
docs/mars/venus/SettingsWarningsAreErrorsAction.html
docs/mars/venus/NumberDisplayBaseChooser.html
docs/mars/venus/RunStepAction.html
docs/mars/venus/SettingsHighlightingAction.html
docs/mars/venus/EditPane.html
docs/mars/venus/ToolLoader.html
docs/mars/venus/SettingsProgramArgumentsAction.html
docs/mars/venus/package-tree.html
docs/mars/venus/RunSpeedPanel.html
docs/mars/venus/GuiAction.html
docs/mars/venus/FileSaveAsAction.html
docs/mars/venus/VenusUI.html
docs/mars/venus/MainPane.html
docs/mars/venus/RunBackstepAction.html
docs/mars/venus/FileCloseAction.html
docs/mars/venus/SettingsPopupInputAction.html
docs/mars/venus/RunStopAction.html
docs/mars/venus/SettingsAssembleOnOpenAction.html
docs/mars/venus/SettingsExceptionHandlerAction.html
docs/mars/venus/SettingsValueDisplayBaseAction.html
docs/mars/venus/AbstractFontSettingDialog.html
docs/mars/venus/LabelsWindow.html
docs/mars/ProcessingException.html
docs/mars/ErrorList.html
docs/mars/mips/instructions/SimulationCode.html
docs/mars/mips/instructions/ExtendedInstruction.html
docs/mars/mips/instructions/package-frame.html
docs/mars/mips/instructions/BasicInstructionFormat.html
docs/mars/mips/instructions/package-summary.html
docs/mars/mips/instructions/package-tree.html
docs/mars/mips/instructions/Instruction.html
docs/mars/mips/instructions/InstructionSet.html
docs/mars/mips/instructions/syscalls/SyscallPrintString.html
docs/mars/mips/instructions/syscalls/SyscallPrintIntBinary.html
docs/mars/mips/instructions/syscalls/SyscallMidiOut.html
docs/mars/mips/instructions/syscalls/SyscallMessageDialogInt.html
docs/mars/mips/instructions/syscalls/SyscallExit.html
docs/mars/mips/instructions/syscalls/SyscallInputDialogInt.html
docs/mars/mips/instructions/syscalls/SyscallReadFloat.html
docs/mars/mips/instructions/syscalls/SyscallOpen.html
docs/mars/mips/instructions/syscalls/SyscallReadChar.html
docs/mars/mips/instructions/syscalls/SyscallMessageDialog.html
docs/mars/mips/instructions/syscalls/SyscallPrintFloat.html
docs/mars/mips/instructions/syscalls/SyscallSbrk.html
docs/mars/mips/instructions/syscalls/SyscallRandDouble.html
docs/mars/mips/instructions/syscalls/SyscallPrintIntUnsigned.html
docs/mars/mips/instructions/syscalls/SyscallMessageDialogString.html
docs/mars/mips/instructions/syscalls/AbstractSyscall.html
docs/mars/mips/instructions/syscalls/SyscallInputDialogFloat.html
docs/mars/mips/instructions/syscalls/RandomStreams.html
docs/mars/mips/instructions/syscalls/SyscallInputDialogString.html
docs/mars/mips/instructions/syscalls/SyscallReadString.html
docs/mars/mips/instructions/syscalls/SyscallPrintChar.html
docs/mars/mips/instructions/syscalls/SyscallRandIntRange.html
docs/mars/mips/instructions/syscalls/Syscall.html
docs/mars/mips/instructions/syscalls/SyscallTime.html
docs/mars/mips/instructions/syscalls/SyscallRandSeed.html
docs/mars/mips/instructions/syscalls/SyscallPrintIntHex.html
docs/mars/mips/instructions/syscalls/package-frame.html
docs/mars/mips/instructions/syscalls/SyscallPrintInt.html
docs/mars/mips/instructions/syscalls/SyscallMessageDialogDouble.html
docs/mars/mips/instructions/syscalls/SyscallConfirmDialog.html
docs/mars/mips/instructions/syscalls/package-summary.html
docs/mars/mips/instructions/syscalls/SyscallReadInt.html
docs/mars/mips/instructions/syscalls/SyscallExit2.html
docs/mars/mips/instructions/syscalls/SyscallReadDouble.html
docs/mars/mips/instructions/syscalls/SyscallInputDialogDouble.html
docs/mars/mips/instructions/syscalls/SyscallMessageDialogFloat.html
docs/mars/mips/instructions/syscalls/SyscallWrite.html
docs/mars/mips/instructions/syscalls/package-tree.html
docs/mars/mips/instructions/syscalls/SyscallSleep.html
docs/mars/mips/instructions/syscalls/SyscallClose.html
docs/mars/mips/instructions/syscalls/SyscallRandInt.html
docs/mars/mips/instructions/syscalls/SyscallPrintDouble.html
docs/mars/mips/instructions/syscalls/SyscallRead.html
docs/mars/mips/instructions/syscalls/SyscallRandFloat.html
docs/mars/mips/instructions/syscalls/SyscallNumberOverride.html
docs/mars/mips/instructions/syscalls/SyscallMidiOutSync.html
docs/mars/mips/instructions/BasicInstruction.html
docs/mars/mips/hardware/Coprocessor0.html
docs/mars/mips/hardware/Coprocessor1.html
docs/mars/mips/hardware/AccessNotice.html
docs/mars/mips/hardware/MemoryConfiguration.html
docs/mars/mips/hardware/Register.html
docs/mars/mips/hardware/MemoryAccessNotice.html
docs/mars/mips/hardware/MemoryConfigurations.html
docs/mars/mips/hardware/AddressErrorException.html
docs/mars/mips/hardware/package-frame.html
docs/mars/mips/hardware/InvalidRegisterAccessException.html
docs/mars/mips/hardware/package-summary.html
docs/mars/mips/hardware/Memory.html
docs/mars/mips/hardware/RegisterAccessNotice.html
docs/mars/mips/hardware/package-tree.html
docs/mars/mips/hardware/RegisterFile.html
docs/mars/mips/dump/AsciiTextDumpFormat.html
docs/mars/mips/dump/BinaryTextDumpFormat.html
docs/mars/mips/dump/MIFDumpFormat.html
docs/mars/mips/dump/DumpFormat.html
docs/mars/mips/dump/package-frame.html
docs/mars/mips/dump/SegmentWindowDumpFormat.html
docs/mars/mips/dump/DumpFormatLoader.html
docs/mars/mips/dump/package-summary.html
docs/mars/mips/dump/package-tree.html
docs/mars/mips/dump/AbstractDumpFormat.html
docs/mars/mips/dump/BinaryDumpFormat.html
docs/mars/mips/dump/HexTextDumpFormat.html
docs/mars/mips/dump/IntelHexDumpFormat.html
docs/mars/package-frame.html
docs/mars/ErrorMessage.html
docs/mars/simulator/BackStepper.html
docs/mars/simulator/Exceptions.html
docs/mars/simulator/package-frame.html
docs/mars/simulator/Simulator.StopListener.html
docs/mars/simulator/Simulator.html
docs/mars/simulator/SimulatorNotice.html
docs/mars/simulator/package-summary.html
docs/mars/simulator/SwingWorker.html
docs/mars/simulator/ProgramArgumentList.html
docs/mars/simulator/package-tree.html
docs/mars/simulator/DelayedBranch.html
docs/mars/package-summary.html
docs/mars/ProgramStatement.html
docs/mars/MarsLaunch.html
docs/mars/package-tree.html
docs/mars/MIPSprogram.html
docs/mars/Settings.html
docs/mars/Globals.html
ALUcontrolDatapath.xml
CreateNewsMarsJar_200Syscalls.sh
MipsXRayOpcode.xml
Config.properties
Syscall.properties
CreateNewsMarsJar_200Syscalls.bat
CompileGameJava.bat
mars/tools/AbstractMarsToolAndApplication$MessageField.class
mars/tools/MemoryReferenceVisualization$8.class
mars/tools/KeyboardAndDisplaySimulator$4.class
mars/tools/CacheSimulator$5.class
mars/tools/MemoryReferenceVisualization$ColorChooserControls$1.class
mars/tools/AbstractMarsToolAndApplication$CreateAssembleRunMIPSprogram.class
mars/tools/MipsXray$1.class
mars/tools/BitmapDisplay$4.class
mars/tools/FloatRepresentation$InstructionsPane.class
mars/tools/AbstractMarsToolAndApplication$1.class
mars/tools/AbstractMarsToolAndApplication$3.class
mars/tools/BitmapDisplay$6.class
mars/tools/MipsXray$Vertex.class
mars/tools/FloatRepresentation$1.class
mars/tools/ScavengerHunt$ScavengerHuntDisplay.class
mars/tools/SettingsDialog2.class
mars/tools/AbstractMarsToolAndApplication$MessageField$MessageWriter.class
mars/tools/KeyboardAndDisplaySimulator.class
mars/tools/AbstractMarsToolAndApplication.class
mars/tools/MarsBot$BotRunnable.class
mars/tools/AbstractMarsToolAndApplication$EnterKeyListener.class
mars/tools/CacheSimulator$3.class
mars/tools/KeyboardAndDisplaySimulator$2.class
mars/tools/ScribblerSettings.class
mars/tools/CacheSimulator.class
mars/tools/BitmapDisplay$2.class
mars/tools/AbstractMarsToolAndApplication$7.class
mars/tools/CacheSimulator$CacheAccessResult.class
mars/tools/ScavengerHunt$1.class
mars/tools/ScavengerHunt$PlayerData.class
mars/tools/KeyboardAndDisplaySimulator$DisplayResizeAdapter.class
mars/tools/AbstractMarsToolAndApplication$5.class
mars/tools/CacheSimulator$AbstractCache.class
mars/tools/CacheSimulator$Animation.class
mars/tools/MipsXray.class
mars/tools/CacheSimulator$1.class
mars/tools/CacheSimulator$AnyCache.class
mars/tools/FloatRepresentation$HexToBinaryGraphicPanel.class
mars/tools/MagnifierImage$Scribbler.class
mars/tools/KeyboardAndDisplaySimulator$FontChanger.class
mars/tools/AbstractMarsToolAndApplication$2.class
mars/tools/BitmapDisplay.class
mars/tools/AbstractMarsToolAndApplication$10.class
mars/tools/ScribblerSettings2.class
mars/tools/AbstractMarsToolAndApplication$GUIUpdater.class
mars/tools/CacheSimulator$CacheBlock.class
mars/tools/FunctionUnitVisualization.class
mars/tools/CacheSimulator$4.class
mars/tools/IntroToTools.class
mars/tools/UnitAnimation.class
mars/tools/FloatRepresentation$BinaryFractionDisplayTextField.class
mars/tools/KeyboardAndDisplaySimulator$TransmitterDelayTechnique.class
mars/tools/BitmapDisplay$5.class
mars/tools/MarsTool.class
mars/tools/AbstractMarsToolAndApplication$4.class
mars/tools/BitmapDisplay$1.class
mars/tools/CaptureDisplayAlignmentStrategy.class
mars/tools/InstructionStatistics.class
mars/tools/FloatRepresentation$DecimalDisplayKeystokeListenter.class
mars/tools/DigitalLabSim$SevenSegmentPanel.class
mars/tools/KeyboardAndDisplaySimulator$1.class
mars/tools/FloatRepresentation$BinaryDisplayKeystrokeListener.class
mars/tools/KeyboardAndDisplaySimulator$NormallyDistributedDelay.class
mars/tools/KeyboardAndDisplaySimulator$DelayLengthPanel$DelayLengthListener.class
mars/tools/SettingsDialog.class
mars/tools/ScreenMagnifier$1.class
mars/tools/CacheSimulator$2.class
mars/tools/KeyboardAndDisplaySimulator$3.class
mars/tools/KeyboardAndDisplaySimulator$FontSettingDialog.class
mars/tools/ScavengerHunt.class
mars/tools/KeyboardAndDisplaySimulator$UniformlyDistributedDelay.class
mars/tools/ScavengerHunt$ScavengerHuntRunnable.class
mars/tools/BitmapDisplay$3.class
mars/tools/AbstractMarsToolAndApplication$6.class
mars/tools/MemoryReferenceVisualization$GraphicsPanel.class
mars/tools/MarsBot.class
mars/tools/SettingsDialog2$1.class
mars/tools/ScreenMagnifier.class
mars/tools/MemoryReferenceVisualization$3.class
mars/tools/Magnifier.class
mars/tools/BitmapDisplay$Grid.class
mars/tools/KeyboardAndDisplaySimulator$FontSettingDialog$3.class
mars/tools/ScavengerHunt$ScavengerHuntRunnable$1.class
mars/tools/Magnifier$4.class
mars/tools/CaptureMagnifierRectangle.class
mars/tools/BHTSimGUI$1.class
mars/tools/KeyboardAndDisplaySimulator$FontSettingDialog$1.class
mars/tools/MemoryReferenceVisualization$1.class
mars/tools/SettingsDialog$2.class
mars/tools/BHTSimGUI.class
mars/tools/CaptureDisplayCentered.class
mars/tools/AbstractMarsToolAndApplication$8.class
mars/tools/InstructionCounter.class
mars/tools/SettingsDialog2$3.class
mars/tools/MarsBot$MarsBotDisplay.class
mars/tools/KeyboardAndDisplaySimulator$KeyboardKeyListener.class
mars/tools/DigitalLabSim.class
mars/tools/MemoryReferenceVisualization$ColorChooserControls$ColorChooserListener.class
mars/tools/Magnifier$2.class
mars/tools/CaptureModel.class
mars/tools/BHTSimulator.class
mars/tools/MemoryReferenceVisualization$5.class
mars/tools/UnitAnimation$Vertex.class
mars/tools/BHTEntry.class
mars/tools/MemoryReferenceVisualization$7.class
mars/tools/BitmapDisplay$GraphicsPanel.class
mars/tools/MarsBot$BotRunnable$2.class
mars/tools/DigitalLabSim$SevenSegmentDisplay.class
mars/tools/AbstractMarsToolAndApplication$ConnectButton.class
mars/tools/KeyboardAndDisplaySimulator$1$1.class
mars/tools/MagnifierImage$1.class
mars/tools/DigitalLabSim$1.class
mars/tools/MemoryReferenceVisualization$Grid.class
mars/tools/DigitalLabSim$HexaKeyboard.class
mars/tools/SettingsDialog$3.class
mars/tools/DigitalLabSim$HexaKeyboard$EcouteurClick.class
mars/tools/ScavengerHunt$ScavengerHuntRunnable$2.class
mars/tools/DigitalLabSim$OneSecondCounter.class
mars/tools/AbstractMarsToolAndApplication$9.class
mars/tools/SettingsDialog2$2.class
mars/tools/FloatRepresentation$BinaryToDecimalFormulaGraphic.class
mars/tools/BHTableModel.class
mars/tools/Magnifier$5.class
mars/tools/CaptureRectangleStrategy.class
mars/tools/SettingsDialog$1.class
mars/tools/MemoryReferenceVisualization$2.class
mars/tools/KeyboardAndDisplaySimulator$FontSettingDialog$2.class
mars/tools/KeyboardAndDisplaySimulator$DelayLengthPanel.class
mars/tools/FloatRepresentation$FlavorsOfFloat.class
mars/tools/MagnifierImage.class
mars/tools/Magnifier$1.class
mars/tools/MemoryReferenceVisualization$ColorChooserControls.class
mars/tools/MemoryReferenceVisualization$6.class
mars/tools/MipsXray$DatapathAnimation.class
mars/tools/CaptureScaledRectangle.class
mars/tools/CaptureDisplayUpperleft.class
mars/tools/MemoryReferenceVisualization$CounterColorScale.class
mars/tools/KeyboardAndDisplaySimulator$FixedLengthDelay.class
mars/tools/MemoryReferenceVisualization.class
mars/tools/MagnifierImage$2.class
mars/tools/MemoryReferenceVisualization$CounterColor.class
mars/tools/MemoryReferenceVisualization$4.class
mars/tools/FloatRepresentation$HexDisplayKeystrokeListener.class
mars/tools/MarsBot$BotRunnable$1.class
mars/tools/ScavengerHunt$Location.class
mars/tools/FloatRepresentation.class
mars/tools/Magnifier$3.class
mars/assembler/TokenList.class
mars/assembler/Directives.class
mars/assembler/TokenTypes.class
mars/assembler/TranslationCode.class
mars/assembler/Tokenizer.class
mars/assembler/MacroPool.class
mars/assembler/Macro.class
mars/assembler/Assembler$DataSegmentForwardReferences.class
mars/assembler/SourceLine.class
mars/assembler/Assembler$ProgramStatementComparator.class
mars/assembler/SymbolTable.class
mars/assembler/DataTypes.class
mars/assembler/Token.class
mars/assembler/Assembler$UserKernelAddressSpace.class
mars/assembler/Assembler$1.class
mars/assembler/Assembler.class
mars/assembler/OperandFormat.class
mars/assembler/Symbol.class
mars/assembler/Assembler$DataSegmentForwardReferences$DataSegmentForwardReference.class
mars/util/PropertiesFile.class
mars/util/EditorFont.class
mars/util/FilenameFinder$1.class
mars/util/MemoryDump.class
mars/util/Binary.class
mars/util/SystemIO.class
mars/util/SystemIO$FileIOData.class
mars/util/FilenameFinder.class
mars/util/FilenameFinder$MarsFileFilter.class
mars/MarsSplashScreen.class
mars/venus/SettingsMemoryConfigurationAction$MemoryConfigurationDialog.class
mars/venus/HelpHelpAction$1.class
mars/venus/DataSegmentWindow$10.class
mars/venus/EditFindReplaceAction$FindReplaceDialog$2.class
mars/venus/SettingsHighlightingAction$BackgroundChanger.class
mars/venus/MessagesPane$Asker$1$1.class
mars/venus/SettingsHighlightingAction$2.class
mars/venus/EditPane$2.class
mars/venus/TextSegmentWindow$1.class
mars/venus/SettingsEditorAction$EditorFontDialog$8.class
mars/venus/SettingsWarningsAreErrorsAction.class
mars/venus/MessagesPane$Asker.class
mars/venus/MonoRightCellRenderer.class
mars/venus/GuiAction.class
mars/venus/FileExitAction.class
mars/venus/SettingsAssembleAllAction.class
mars/venus/Coprocessor1Window$MyTippedJTable$1.class
mars/venus/FileDumpMemoryAction$DumpFormatComboBoxRenderer.class
mars/venus/FileStatus.class
mars/venus/SettingsHighlightingAction$ForegroundChanger.class
mars/venus/NumberDisplayBaseChooser.class
mars/venus/EditFindReplaceAction.class
mars/venus/DataSegmentWindow$NextButton.class
mars/venus/SettingsAssembleOnOpenAction.class
mars/venus/SettingsHighlightingAction$6.class
mars/venus/SettingsHighlightingAction$DefaultChanger.class
mars/venus/Coprocessor1Window$MyTippedJTable.class
mars/venus/EditFindReplaceAction$FindReplaceDialog$4.class
mars/venus/FileCloseAction.class
mars/venus/AbstractFontSettingDialog$ComboBoxRenderer.class
mars/venus/SettingsEditorAction$EditorFontDialog$ForegroundChanger.class
mars/venus/RunStepAction.class
mars/venus/SettingsEditorAction$EditorFontDialog$BoldItalicChanger.class
mars/venus/VenusUI$2.class
mars/venus/SettingsHighlightingAction$4.class
mars/venus/PopupListener.class
mars/venus/DataSegmentWindow$8.class
mars/venus/EditPasteAction.class
mars/venus/FilePrintAction.class
mars/venus/SettingsEditorAction.class
mars/venus/EditFindReplaceAction$FindReplaceDialog$1.class
mars/venus/LabelsWindow$LabelsForSymbolTable.class
mars/venus/TextSegmentWindow$MyTableColumnMovingListener.class
mars/venus/ToolLoader.class
mars/venus/SettingsEditorAction$EditorFontDialog$9.class
mars/venus/SettingsHighlightingAction$3.class
mars/venus/LabelsWindow$LabelDisplayMouseListener.class
mars/venus/DataSegmentWindow$MyTippedJTable$1.class
mars/venus/RunStopAction.class
mars/venus/LabelsWindow$1.class
mars/venus/HelpHelpAction$2.class
mars/venus/Coprocessor0Window$RegisterCellRenderer.class
mars/venus/RunAssembleAction.class
mars/venus/EditCopyAction.class
mars/venus/Coprocessor0Window$MyTippedJTable.class
mars/venus/RunToggleBreakpointsAction.class
mars/venus/LabelsWindow$LabelItemListener.class
mars/venus/SettingsProgramArgumentsAction.class
mars/venus/ColorSelectButton.class
mars/venus/FileNewAction.class
mars/venus/EditCutAction.class
mars/venus/editors/jeditsyntax/InputHandler$insert_tab.class
mars/venus/editors/jeditsyntax/KeywordMap.class
mars/venus/editors/jeditsyntax/InputHandler$backspace_word.class
mars/venus/editors/jeditsyntax/InputHandler$MacroRecorder.class
mars/venus/editors/jeditsyntax/InputHandler.class
mars/venus/editors/jeditsyntax/InputHandler$repeat.class
mars/venus/editors/jeditsyntax/InputHandler$delete_word.class
mars/venus/editors/jeditsyntax/InputHandler$insert_break.class
mars/venus/editors/jeditsyntax/InputHandler$prev_word.class
mars/venus/editors/jeditsyntax/InputHandler$backspace.class
mars/venus/editors/jeditsyntax/InputHandler$insert_char.class
mars/venus/editors/jeditsyntax/PopupHelpItem.class
mars/venus/editors/jeditsyntax/JEditTextArea$AdjustHandler.class
mars/venus/editors/jeditsyntax/JEditTextArea$ScrollLayout.class
mars/venus/editors/jeditsyntax/SyntaxUtilities.class
mars/venus/editors/jeditsyntax/InputHandler$clip_copy.class
mars/venus/editors/jeditsyntax/InputHandler$NonRepeatable.class
mars/venus/editors/jeditsyntax/InputHandler$end.class
mars/venus/editors/jeditsyntax/InputHandler$prev_page.class
mars/venus/editors/jeditsyntax/JEditTextArea.class
mars/venus/editors/jeditsyntax/SyntaxDocument.class
mars/venus/editors/jeditsyntax/InputHandler$home.class
mars/venus/editors/jeditsyntax/KeywordMap$Keyword.class
mars/venus/editors/jeditsyntax/JEditTextArea$FocusHandler.class
mars/venus/editors/jeditsyntax/InputHandler$next_char.class
mars/venus/editors/jeditsyntax/InputHandler$clip_cut.class
mars/venus/editors/jeditsyntax/InputHandler$Wrapper.class
mars/venus/editors/jeditsyntax/tokenmarker/MIPSTokenMarker.class
mars/venus/editors/jeditsyntax/tokenmarker/TokenMarker.class
mars/venus/editors/jeditsyntax/tokenmarker/Token.class
mars/venus/editors/jeditsyntax/tokenmarker/TokenMarker$LineInfo.class
mars/venus/editors/jeditsyntax/InputHandler$prev_line.class
mars/venus/editors/jeditsyntax/SyntaxStyle.class
mars/venus/editors/jeditsyntax/InputHandler$overwrite.class
mars/venus/editors/jeditsyntax/InputHandler$select_all.class
mars/venus/editors/jeditsyntax/JEditTextArea$2.class
mars/venus/editors/jeditsyntax/InputHandler$document_end.class
mars/venus/editors/jeditsyntax/TextAreaDefaults.class
mars/venus/editors/jeditsyntax/JEditTextArea$PopupHelpActionListener.class
mars/venus/editors/jeditsyntax/TextAreaPainter.class
mars/venus/editors/jeditsyntax/InputHandler$next_word.class
mars/venus/editors/jeditsyntax/JEditBasedTextArea$1.class
mars/venus/editors/jeditsyntax/JEditBasedTextArea.class
mars/venus/editors/jeditsyntax/JEditTextArea$MouseHandler.class
mars/venus/editors/jeditsyntax/InputHandler$next_page.class
mars/venus/editors/jeditsyntax/JEditTextArea$CaretBlinker.class
mars/venus/editors/jeditsyntax/JEditTextArea$ComponentHandler.class
mars/venus/editors/jeditsyntax/JEditTextArea$MutableCaretEvent.class
mars/venus/editors/jeditsyntax/InputHandler$document_home.class
mars/venus/editors/jeditsyntax/JEditTextArea$CaretUndo.class
mars/venus/editors/jeditsyntax/JEditTextArea$1.class
mars/venus/editors/jeditsyntax/TextAreaPainter$Highlight.class
mars/venus/editors/jeditsyntax/InputHandler$prev_char.class
mars/venus/editors/jeditsyntax/JEditTextArea$AdjustHandler$1.class
mars/venus/editors/jeditsyntax/TextUtilities.class
mars/venus/editors/jeditsyntax/InputHandler$clip_paste.class
mars/venus/editors/jeditsyntax/DefaultInputHandler.class
mars/venus/editors/jeditsyntax/JEditTextArea$DragHandler.class
mars/venus/editors/jeditsyntax/InputHandler$NonRecordable.class
mars/venus/editors/jeditsyntax/InputHandler$next_line.class
mars/venus/editors/jeditsyntax/InputHandler$toggle_rect.class
mars/venus/editors/jeditsyntax/JEditTextArea$MouseWheelHandler.class
mars/venus/editors/jeditsyntax/InstructionMouseEvent.class
mars/venus/editors/jeditsyntax/JEditTextArea$DocumentHandler.class
mars/venus/editors/jeditsyntax/InputHandler$delete.class
mars/venus/editors/generic/GenericTextArea$1.class
mars/venus/editors/generic/GenericTextArea.class
mars/venus/editors/generic/GenericTextArea$2.class
mars/venus/editors/MARSTextEditingArea.class
mars/venus/EditPane$1.class
mars/venus/SettingsHighlightingAction$1.class
mars/venus/SettingsValueDisplayBaseAction.class
mars/venus/MessagesPane$Asker$1$2.class
mars/venus/LabelsWindow$MyTippedJTable.class
mars/venus/SettingsPopupInputAction.class
mars/venus/EditSelectAllAction.class
mars/venus/EditFindReplaceAction$FindReplaceDialog$3.class
mars/venus/DataSegmentWindow$PrevButton.class
mars/venus/VenusUI.class
mars/venus/Coprocessor1Window$RegTableModel.class
mars/venus/DataSegmentWindow$9.class
mars/venus/SettingsStartAtMainAction.class
mars/venus/FileDumpMemoryAction.class
mars/venus/SettingsHighlightingAction$5.class
mars/venus/Coprocessor0Window.class
mars/venus/RepeatButton.class
mars/venus/SettingsLabelAction.class
mars/venus/LabelsWindow$MyTippedJTable$SymbolTableHeader$SymbolTableHeaderMouseListener.class
mars/venus/RegistersPane.class
mars/venus/SettingsHighlightingAction.class
mars/venus/TextSegmentWindow$CheckBoxTableCellRenderer.class
mars/venus/EditTabbedPane.class
mars/venus/HelpHelpAction$MyCellRenderer.class
mars/venus/EditFindReplaceAction$FindReplaceDialog$5.class
mars/venus/HelpHelpAction.class
mars/venus/EditUndoAction.class
mars/venus/SettingsExceptionHandlerAction$ExceptionHandlerSettingAction.class
mars/venus/FileSaveAllAction.class
mars/venus/SettingsHighlightingAction$7.class
mars/venus/ExecutePane.class
mars/venus/VenusUI$1.class
mars/venus/DataSegmentWindow$7.class
mars/venus/TextSegmentWindow$MachineCodeCellRenderer.class
mars/venus/AbstractFontSettingDialog.class
mars/venus/SettingsEditorAction$EditorFontDialog$1.class
mars/venus/RegistersWindow$RegTableModel.class
mars/venus/MessagesPane$Asker$3.class
mars/venus/DataSegmentWindow$DataTableModel.class
mars/venus/LabelsWindow.class
mars/venus/LabelsWindow$MyTippedJTable$SymbolTableHeader.class
mars/venus/TextSegmentWindow$CodeCellRenderer.class
mars/venus/MainPane$1.class
mars/venus/SettingsHighlightingAction$FontSettingDialog$2.class
mars/venus/TextSegmentWindow$MyTippedJTable.class
mars/venus/EditFindReplaceAction$FindReplaceDialog.class
mars/venus/HardcopyWriter.class
mars/venus/NumberDisplayBaseChooser$1.class
mars/venus/MessagesPane$4.class
mars/venus/SettingsExceptionHandlerAction.class
mars/venus/SettingsAddressDisplayBaseAction.class
mars/venus/DataSegmentWindow$AddressCellRenderer.class
mars/venus/DataSegmentWindow$MyTippedJTable.class
mars/venus/SettingsMemoryConfigurationAction$MemoryConfigurationDialog$4.class
mars/venus/AbstractFontSettingDialog$2.class
mars/venus/SettingsExceptionHandlerAction$2.class
mars/venus/SettingsEditorAction$EditorFontDialog$3.class
mars/venus/Coprocessor0Window$RegTableModel.class
mars/venus/MessagesPane$Asker$1.class
mars/venus/RunClearBreakpointsAction.class
mars/venus/DataSegmentWindow$5.class
mars/venus/SettingsSelfModifyingCodeAction.class
mars/venus/HelpHelpAction$HelpHyperlinkListener$2.class
mars/venus/SettingsEditorAction$EditorFontDialog$7.class
mars/venus/FileOpenAction.class
mars/venus/RegistersWindow$RegisterCellRenderer.class
mars/venus/SettingsHighlightingAction$FontSettingDialog.class
mars/venus/DataSegmentWindow$1.class
mars/venus/FileDumpMemoryAction$1.class
mars/venus/SettingsMemoryConfigurationAction.class
mars/venus/SettingsDelayedBranchingAction.class
mars/venus/MessagesPane.class
mars/venus/SettingsEditorAction$EditorFontDialog$DefaultChanger.class
mars/venus/RunBackstepAction.class
mars/venus/EditTabbedPane$FileOpener.class
mars/venus/RunSpeedPanel$RunSpeedListener.class
mars/venus/TextSegmentWindow.class
mars/venus/SettingsMemoryConfigurationAction$MemoryConfigurationDialog$2.class
mars/venus/AbstractFontSettingDialog$4.class
mars/venus/LabelsWindow$LabelAddressAscendingComparator.class
mars/venus/FileDumpMemoryAction$3.class
mars/venus/MessagesPane$2.class
mars/venus/RegistersWindow$MyTippedJTable.class
mars/venus/SettingsEditorAction$EditorFontDialog.class
mars/venus/LabelsWindow$LabelNameAscendingComparator.class
mars/venus/RunSpeedPanel.class
mars/venus/DataSegmentWindow$3.class
mars/venus/RunGoAction.class
mars/venus/EditTabbedPane$1.class
mars/venus/SettingsEditorAction$EditorFontDialog$5.class
mars/venus/TextSegmentWindow$MyTippedJTable$TextTableHeader.class
mars/venus/SettingsExtendedAction.class
mars/venus/HelpAboutAction.class
mars/venus/SettingsMemoryConfigurationAction$MemoryConfigurationDialog$5.class
mars/venus/AbstractFontSettingDialog$3.class
mars/venus/SettingsExceptionHandlerAction$3.class
mars/venus/TextSegmentWindow$TextTableModel.class
mars/venus/LabelsWindow$LabelTableModel.class
mars/venus/FileDumpMemoryAction$4.class
mars/venus/RegistersWindow$MyTippedJTable$1.class
mars/venus/RunSpeedPanel$1.class
mars/venus/SettingsHighlightingAction$FontSettingDialog$1.class
mars/venus/SettingsHighlightingAction$8.class
mars/venus/MainPane.class
mars/venus/DataSegmentWindow$4.class
mars/venus/RegistersWindow.class
mars/venus/SettingsEditorAction$EditorFontDialog$2.class
mars/venus/HelpHelpAction$HelpHyperlinkListener.class
mars/venus/DataSegmentWindow.class
mars/venus/MessagesPane$Asker$2.class
mars/venus/AbstractFontSettingDialog$BlockComboListener.class
mars/venus/Editor.class
mars/venus/DataSegmentWindow$6.class
mars/venus/LabelsWindow$DescendingComparator.class
mars/venus/FileSaveAction.class
mars/venus/SettingsHighlightingAction$FontSettingDialog$3.class
mars/venus/ToolAction.class
mars/venus/TextSegmentWindow$MyTippedJTable$TextTableHeader$TextTableHeaderMouseListener.class
mars/venus/AbstractFontSettingDialog$1.class
mars/venus/SettingsExceptionHandlerAction$1.class
mars/venus/Coprocessor1Window.class
mars/venus/SettingsHighlightingAction$FontChanger.class
mars/venus/TextSegmentWindow$ModifiedCode.class
mars/venus/MessagesPane$3.class
mars/venus/SettingsExceptionHandlerAction$ExceptionHandlerSelectionAction.class
mars/venus/EditTabbedPane$FileOpener$ChoosableFileFilterChangeListener.class
mars/venus/DataSegmentWindow$CustomComboBoxModel.class
mars/venus/FileDumpMemoryAction$2.class
mars/venus/SettingsMemoryConfigurationAction$MemoryConfigurationDialog$3.class
mars/venus/FileSaveAsAction.class
mars/venus/FileCloseAllAction.class
mars/venus/SettingsEditorAction$EditorFontDialog$4.class
mars/venus/HelpHelpAction$HelpHyperlinkListener$1.class
mars/venus/SettingsMemoryConfigurationAction$ConfigurationButton.class
mars/venus/DataSegmentWindow$2.class
mars/venus/RunPauseAction.class
mars/venus/Coprocessor0Window$MyTippedJTable$1.class
mars/venus/EditPane.class
mars/venus/SettingsEditorAction$EditorFontDialog$6.class
mars/venus/MessagesPane$Asker$4.class
mars/venus/SettingsMemoryConfigurationAction$MemoryConfigurationDialog$1.class
mars/venus/RunResetAction.class
mars/venus/EditRedoAction.class
mars/venus/HardcopyWriter$PrintCanceledException.class
mars/venus/ToolLoader$MarsToolClassAndInstance.class
mars/venus/MessagesPane$1.class
mars/venus/Coprocessor1Window$RegisterCellRenderer.class
mars/ext/game/SoundPlayer.class
mars/ext/game/util/Sprite.class
mars/ext/game/util/Progress.class
mars/ext/game/MMIOThread.class
mars/ext/game/ActiveElementInterface.class
mars/ext/game/GameBombObject.class
mars/ext/game/GameScreen$1.class
mars/ext/game/GameScreen$ScreenPanel.class
mars/ext/game/GameObject.class
mars/ext/game/GameBulletObject.class
mars/ext/game/GameRemoteBombObject.class
mars/ext/game/MMIOInput.class
mars/ext/game/GamePlayerObject.class
mars/ext/game/GameImage.class
mars/ext/game/GameTextObject.class
mars/ext/game/GameScreen.class
mars/ext/game/GameException.class
mars/ext/game/GameConfigFile.class
mars/ext/game/MazeGameObject.class
mars/ProgramStatement$BasicStatementList$ListElement.class
mars/ErrorList.class
mars/mips/instructions/InstructionSet$62.class
mars/mips/instructions/InstructionSet$27.class
mars/mips/instructions/InstructionSet$143.class
mars/mips/instructions/InstructionSet$106.class
mars/mips/instructions/InstructionSet$46.class
mars/mips/instructions/InstructionSet$122.class
mars/mips/instructions/InstructionSet$86.class
mars/mips/instructions/InstructionSet$84.class
mars/mips/instructions/InstructionSet$79.class
mars/mips/instructions/InstructionSet$44.class
mars/mips/instructions/InstructionSet$120.class
mars/mips/instructions/InstructionSet$60.class
mars/mips/instructions/InstructionSet$25.class
mars/mips/instructions/InstructionSet$141.class
mars/mips/instructions/InstructionSet$104.class
mars/mips/instructions/InstructionSet$139.class
mars/mips/instructions/InstructionSet$18.class
mars/mips/instructions/InstructionSet$145.class
mars/mips/instructions/InstructionSet$100.class
mars/mips/instructions/InstructionSet$64.class
mars/mips/instructions/InstructionSet$21.class
mars/mips/instructions/InstructionSet$99.class
mars/mips/instructions/InstructionSet$59.class
mars/mips/instructions/InstructionSet$38.class
mars/mips/instructions/InstructionSet$80.class
mars/mips/instructions/InstructionSet$119.class
mars/mips/instructions/InstructionSet$124.class
mars/mips/instructions/InstructionSet$40.class
mars/mips/instructions/SyscallLoader.class
mars/mips/instructions/ExtendedInstruction.class
mars/mips/instructions/InstructionSet$126.class
mars/mips/instructions/InstructionSet$42.class
mars/mips/instructions/InstructionSet$82.class
mars/mips/instructions/InstructionSet$147.class
mars/mips/instructions/InstructionSet$102.class
mars/mips/instructions/BasicInstructionFormat.class
mars/mips/instructions/InstructionSet$9.class
mars/mips/instructions/InstructionSet$66.class
mars/mips/instructions/InstructionSet$23.class
mars/mips/instructions/InstructionSet$121.class
mars/mips/instructions/InstructionSet$45.class
mars/mips/instructions/InstructionSet$85.class
mars/mips/instructions/InstructionSet$78.class
mars/mips/instructions/InstructionSet$19.class
mars/mips/instructions/InstructionSet$138.class
mars/mips/instructions/InstructionSet$105.class
mars/mips/instructions/InstructionSet$140.class
mars/mips/instructions/InstructionSet$24.class
mars/mips/instructions/InstructionSet$61.class
mars/mips/instructions/InstructionSet$107.class
mars/mips/instructions/InstructionSet$142.class
mars/mips/instructions/InstructionSet$26.class
mars/mips/instructions/InstructionSet$63.class
mars/mips/instructions/InstructionSet$87.class
mars/mips/instructions/SimulationCode.class
mars/mips/instructions/InstructionSet$123.class
mars/mips/instructions/InstructionSet$47.class
mars/mips/instructions/InstructionSet$83.class
mars/mips/instructions/InstructionSet$43.class
mars/mips/instructions/InstructionSet$127.class
mars/mips/instructions/InstructionSet$22.class
mars/mips/instructions/InstructionSet$67.class
mars/mips/instructions/InstructionSet$103.class
mars/mips/instructions/InstructionSet$146.class
mars/mips/instructions/InstructionSet$8.class
mars/mips/instructions/BasicInstruction.class
mars/mips/instructions/InstructionSet$58.class
mars/mips/instructions/Instruction.class
mars/mips/instructions/InstructionSet$20.class
mars/mips/instructions/InstructionSet$65.class
mars/mips/instructions/InstructionSet$98.class
mars/mips/instructions/InstructionSet$101.class
mars/mips/instructions/InstructionSet$144.class
mars/mips/instructions/InstructionSet$41.class
mars/mips/instructions/InstructionSet$125.class
mars/mips/instructions/InstructionSet$118.class
mars/mips/instructions/InstructionSet$39.class
mars/mips/instructions/InstructionSet$81.class
mars/mips/instructions/InstructionSet$151.class
mars/mips/instructions/InstructionSet$114.class
mars/mips/instructions/InstructionSet$70.class
mars/mips/instructions/InstructionSet$35.class
mars/mips/instructions/InstructionSet$129.class
mars/mips/instructions/InstructionSet$69.class
mars/mips/instructions/InstructionSet$94.class
mars/mips/instructions/InstructionSet$6.class
mars/mips/instructions/InstructionSet$148.class
mars/mips/instructions/InstructionSet$130.class
mars/mips/instructions/InstructionSet$54.class
mars/mips/instructions/InstructionSet$11.class
mars/mips/instructions/InstructionSet$132.class
mars/mips/instructions/InstructionSet$56.class
mars/mips/instructions/InstructionSet$13.class
mars/mips/instructions/InstructionSet$96.class
mars/mips/instructions/InstructionSet$4.class
mars/mips/instructions/InstructionSet$153.class
mars/mips/instructions/InstructionSet$116.class
mars/mips/instructions/InstructionSet$72.class
mars/mips/instructions/InstructionSet$37.class
mars/mips/instructions/InstructionSet$MatchMap.class
mars/mips/instructions/InstructionSet$76.class
mars/mips/instructions/InstructionSet$33.class
mars/mips/instructions/InstructionSet$112.class
mars/mips/instructions/InstructionSet$52.class
mars/mips/instructions/InstructionSet$17.class
mars/mips/instructions/InstructionSet$136.class
mars/mips/instructions/InstructionSet$92.class
mars/mips/instructions/InstructionSet$109.class
mars/mips/instructions/InstructionSet$2.class
mars/mips/instructions/InstructionSet$90.class
mars/mips/instructions/InstructionSet$28.class
mars/mips/instructions/InstructionSet$50.class
mars/mips/instructions/InstructionSet$15.class
mars/mips/instructions/InstructionSet$134.class
mars/mips/instructions/InstructionSet.class
mars/mips/instructions/InstructionSet$89.class
mars/mips/instructions/InstructionSet$74.class
mars/mips/instructions/InstructionSet$31.class
mars/mips/instructions/InstructionSet$155.class
mars/mips/instructions/InstructionSet$110.class
mars/mips/instructions/InstructionSet$49.class
mars/mips/instructions/InstructionSet$5.class
mars/mips/instructions/InstructionSet$97.class
mars/mips/instructions/InstructionSet$12.class
mars/mips/instructions/InstructionSet$57.class
mars/mips/instructions/InstructionSet$133.class
mars/mips/instructions/InstructionSet$36.class
mars/mips/instructions/InstructionSet$73.class
mars/mips/instructions/InstructionSet$117.class
mars/mips/instructions/InstructionSet$152.class
mars/mips/instructions/InstructionSet$128.class
mars/mips/instructions/InstructionSet$34.class
mars/mips/instructions/InstructionSet$71.class
mars/mips/instructions/InstructionSet$115.class
mars/mips/instructions/InstructionSet$150.class
mars/mips/instructions/InstructionSet$10.class
mars/mips/instructions/InstructionSet$55.class
mars/mips/instructions/InstructionSet$131.class
mars/mips/instructions/InstructionSet$7.class
mars/mips/instructions/InstructionSet$149.class
mars/mips/instructions/InstructionSet$68.class
mars/mips/instructions/InstructionSet$95.class
mars/mips/instructions/InstructionSet$135.class
mars/mips/instructions/InstructionSet$14.class
mars/mips/instructions/InstructionSet$51.class
mars/mips/instructions/InstructionSet$91.class
mars/mips/instructions/InstructionSet$29.class
mars/mips/instructions/InstructionSet$108.class
mars/mips/instructions/InstructionSet$3.class
mars/mips/instructions/InstructionSet$48.class
mars/mips/instructions/InstructionSet$111.class
mars/mips/instructions/InstructionSet$154.class
mars/mips/instructions/InstructionSet$88.class
mars/mips/instructions/InstructionSet$30.class
mars/mips/instructions/InstructionSet$75.class
mars/mips/instructions/InstructionSet$113.class
mars/mips/instructions/InstructionSet$32.class
mars/mips/instructions/InstructionSet$77.class
mars/mips/instructions/syscalls/SyscallInputDialogDouble.class
mars/mips/instructions/syscalls/SyscallClose.class
mars/mips/instructions/syscalls/SyscallRandInt.class
mars/mips/instructions/syscalls/Syscall101GameRefreshScreen.class
mars/mips/instructions/syscalls/SyscallMidiOutSync.class
mars/mips/instructions/syscalls/SyscallReadInt.class
mars/mips/instructions/syscalls/SyscallSbrk.class
mars/mips/instructions/syscalls/SyscallPrintString.class
mars/mips/instructions/syscalls/Syscall.class
mars/mips/instructions/syscalls/SyscallMessageDialogString.class
mars/mips/instructions/syscalls/SyscallWrite.class
mars/mips/instructions/syscalls/SyscallConfirmDialog.class
mars/mips/instructions/syscalls/Syscall100CreateGame.class
mars/mips/instructions/syscalls/Syscall107ChangeObjectDirection.class
mars/mips/instructions/syscalls/SyscallMidiOut.class
mars/mips/instructions/syscalls/SyscallTime.class
mars/mips/instructions/syscalls/SyscallReadString.class
mars/mips/instructions/syscalls/Syscall106GameGetObjLocation.class
mars/mips/instructions/syscalls/AbstractSyscall.class
mars/mips/instructions/syscalls/SyscallRandFloat.class
mars/mips/instructions/syscalls/SyscallReadChar.class
mars/mips/instructions/syscalls/Syscall105CreateGameText.class
mars/mips/instructions/syscalls/EndOfTrackListener.class
mars/mips/instructions/syscalls/Tone.class
mars/mips/instructions/syscalls/SyscallPrintChar.class
mars/mips/instructions/syscalls/Syscall103CreateGameObject.class
mars/mips/instructions/syscalls/SyscallReadDouble.class
mars/mips/instructions/syscalls/SyscallMessageDialog.class
mars/mips/instructions/syscalls/SyscallInputDialogString.class
mars/mips/instructions/syscalls/SyscallRandIntRange.class
mars/mips/instructions/syscalls/SyscallSleep.class
mars/mips/instructions/syscalls/SyscallPrintIntUnsigned.class
mars/mips/instructions/syscalls/SyscallPrintDouble.class
mars/mips/instructions/syscalls/Syscall102GamePlaySound.class
mars/mips/instructions/syscalls/SyscallPrintInt.class
mars/mips/instructions/syscalls/SyscallRandSeed.class
mars/mips/instructions/syscalls/SyscallGameHelper.class
mars/mips/instructions/syscalls/SyscallMessageDialogDouble.class
mars/mips/instructions/syscalls/Syscall112EnemyShoot.class
mars/mips/instructions/syscalls/Syscall111HitEnemy.class
mars/mips/instructions/syscalls/SyscallPrintFloat.class
mars/mips/instructions/syscalls/ToneGenerator.class
mars/mips/instructions/syscalls/RandomStreams.class
mars/mips/instructions/syscalls/SyscallExit.class
mars/mips/instructions/syscalls/Syscall108CreateEnemies.class
mars/mips/instructions/syscalls/SyscallExit2.class
mars/mips/instructions/syscalls/SyscallPrintIntHex.class
mars/mips/instructions/syscalls/Syscall104GameSetObjLocation.class
mars/mips/instructions/syscalls/SyscallMessageDialogInt.class
mars/mips/instructions/syscalls/SyscallRandDouble.class
mars/mips/instructions/syscalls/Syscall110HitBrick.class
mars/mips/instructions/syscalls/SyscallOpen.class
mars/mips/instructions/syscalls/SyscallMessageDialogFloat.class
mars/mips/instructions/syscalls/SyscallPrintIntBinary.class
mars/mips/instructions/syscalls/SyscallReadFloat.class
mars/mips/instructions/syscalls/SyscallInputDialogInt.class
mars/mips/instructions/syscalls/SyscallInputDialogFloat.class
mars/mips/instructions/syscalls/SyscallRead.class
mars/mips/instructions/syscalls/SyscallNumberOverride.class
mars/mips/instructions/syscalls/Syscall109EnemyMove.class
mars/mips/instructions/InstructionSet$93.class
mars/mips/instructions/InstructionSet$1.class
mars/mips/instructions/InstructionSet$137.class
mars/mips/instructions/InstructionSet$16.class
mars/mips/instructions/InstructionSet$53.class
mars/mips/hardware/AccessNotice.class
mars/mips/hardware/MemoryAccessNotice.class
mars/mips/hardware/Coprocessor0.class
mars/mips/hardware/RegisterFile.class
mars/mips/hardware/Register.class
mars/mips/hardware/MemoryConfigurations.class
mars/mips/hardware/Coprocessor1.class
mars/mips/hardware/InvalidRegisterAccessException.class
mars/mips/hardware/MemoryConfiguration.class
mars/mips/hardware/Memory.class
mars/mips/hardware/Memory$MemoryObservable.class
mars/mips/hardware/AddressErrorException.class
mars/mips/hardware/RegisterAccessNotice.class
mars/mips/dump/BinaryDumpFormat.class
mars/mips/dump/AbstractDumpFormat.class
mars/mips/dump/SegmentWindowDumpFormat.class
mars/mips/dump/AsciiTextDumpFormat.class
mars/mips/dump/HexTextDumpFormat.class
mars/mips/dump/DumpFormat.class
mars/mips/dump/BinaryTextDumpFormat.class
mars/mips/dump/DumpFormatLoader.class
mars/mips/dump/MIFDumpFormat.class
mars/mips/dump/IntelHexDumpFormat.class
mars/Globals.class
mars/MarsSplashScreen$ImageBackgroundPanel.class
mars/MIPSprogram.class
mars/simulator/BackStepper.class
mars/simulator/Simulator.class
mars/simulator/Simulator$SimThread.class
mars/simulator/Simulator$StopListener.class
mars/simulator/Simulator$1.class
mars/simulator/SwingWorker$2.class
mars/simulator/Exceptions.class
mars/simulator/DelayedBranch.class
mars/simulator/BackStepper$BackstepStack.class
mars/simulator/BackStepper$1.class
mars/simulator/SwingWorker$ThreadVar.class
mars/simulator/SwingWorker$1.class
mars/simulator/BackStepper$BackStep.class
mars/simulator/ProgramArgumentList.class
mars/simulator/SwingWorker.class
mars/simulator/Simulator$UpdateGUI.class
mars/simulator/SimulatorNotice.class
mars/ErrorMessage.class
mars/ProcessingException.class
mars/Settings.class
mars/MarsLaunch$2.class
mars/ProgramStatement.class
mars/ProgramStatement$BasicStatementList.class
mars/MarsLaunch.class
mars/MarsLaunch$1.class
help/SyscallMessageDialogQuestion.gif
help/MacrosHelp.html
help/SyscallMessageDialogInformation.gif
help/MarsHelpLimits.html
help/MarsHelpSettings.html
help/ExceptionsHelp.html
help/SyscallMessageDialogError.gif
help/MarsHelpIDE.html
help/MarsHelpIntro.html
help/MarsHelpDebugging.html
help/BugReportingHelp.html
help/MarsHelpCommand.html
help/MarsHelpTools.html
help/MarsHelpHistory.html
help/MIPSInstructionSetSong.html
help/SyscallMessageDialogWarning.gif
help/HTML_of_links_for_posting_to_MARS_website.html
help/mipsref.pdf
help/SyscallHelp.html
help/Acknowledgements.html
CreateNewMarsSourceJar.sh
.idea/artifacts/Tank1990_jar.xml
.idea/encodings.xml
.idea/vcs.xml
.idea/workspace.xml
.idea/modules.xml
.idea/misc.xml
PseudoOps.txt
Manifest-Version: 1.0
Main-Class: Mars
# NOTE: These are defaults only. The values of these keys are maintained by Java Preferences
# objects, which store key-value pairs in a system-dependent way (Windows uses Registry).
AssembleAll = false
AssembleOnOpen = false
BareMachine = false
DataSegmentHighlighting = true
DelayedBranching = false
DisplayAddressesInHex = true
DisplayValuesInHex = true
EditorCurrentLineHighlighting = true
EditorLineNumbersDisplayed = true
ExtendedAssembler = true
LabelWindowVisibility = false
LoadExceptionHandler = false
ProgramArguments = false
RegistersHighlighting = true
StartAtMain = false
WarningsAreErrors = false
PopupInstructionGuidance = true
EditorPopupPrefixLength = 2
EvenRowBackground = 0x00e0e0e0
EvenRowForeground = 0
OddRowBackground = 0x00ffffff
OddRowForeground = 0
TextSegmentHighlightBackground = 0x00ffff99
TextSegmentHighlightForeground = 0
TextSegmentDelaySlotHighlightBackground = 0x33ff00
TextSegmentDelaySlotHighlightForeground = 0
DataSegmentHighlightBackground = 0x0099ccff
DataSegmentHighlightForeground = 0
RegisterHighlightBackground = 0x0099cc55
RegisterHighlightForeground = 0
Main-Class: Mars
Class-Path: .
00000
$zero
00001
at
00010
$v0
00011
$v1
00100
$a0
00101
$a1
00110
$a2
00111
$a3
01000
$t0
01001
$t1
01010
$t2
01011
$t3
01100
$t4
01101
$t5
01110
$t6
01111
$t7
10000
$s0
10001
$s1
10010
$s2
10011
$s3
10100
$s4
10101
$s5
11000
$s6
10111
$s7
11000
$t8
11001
$t9
11010
$k0
11011
$k1
11100
$gp
11101
$sp
11110
$fp
11111
$ra
0
init
1
2
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
50
true
1#2#38#39#40#41#42
false
1
registerAdd1
1
700
0#205#0
0#205#0
100#100#100
0#205#0
0#205#0
0#205#0
68
true
58
false
2
registerAdd2
1
700
0#0#255
0#0#255
100#100#100
0#0#255
0#0#255
0#0#255
275
true
59
false
3
registerWrite
1
163
0#0#255
0#255#255
100#100#100
0#0#255
100#100#100
100#100#100
346
true
5
false
4
registerData
1
270
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100
427
true
6
false
5
registerWrite
346
245
0#0#255
0#255#255
100#100#100
0#0#255
100#100#100
100#100#100
163
false
28#29#30#31#32
false
6
registerData
427
252
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100
272
false
7#8
false
7
registerData
252
223
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100
272
false
9#10
false
8
inputReg32
272
375
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100
250
true
38
false
9
registerData
212
195
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100
272
false
11#13
false
10
inputReg31
278
375
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100
220
true
39
false
11
registerData
183
162
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100
272
false
12#14
false
12
inputReg2
278
375
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100
158
true
41
false
13
inputRegIND
278
375
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100
188
true
40
false
14
registerData
152
126
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100
272
false
15
false
15
inputReg1
274
375
16#78#139
16#78#139
100#100#100
00#255#255
100#100#100
100#100#100S
126
true
42
false
16
writeControl
0
52
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
392
false
17
false
17
writeControl
392
257
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
52
true
18
false
18
writeControl
52
110
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
257
false
19#20
false
19
writeControl
121
141
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
257
false
21#22
false
20
and1
262
313
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
116
true
0
false
21
and2
262
313
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
147
true
0
false
22
writeControl
152
175
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
257
false
23#24
false
23
and3
262
313
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
180
true
0
false
24
writeControl
185
205
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
257
false
25#26
false
25
writeControl
216
240
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
257
false
27
false
26
and4
262
313
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
211
true
36
false
27
and5
258
313
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
241
true
37
false
28
and1a
233
313
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
102
true
33
false
29
and2a
233
313
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
137
true
34
false
30
and3a
233
313
0#0#255
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
169
true
35
false
31
and4a
233
313
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
197
true
0
false
32
and5a
233
313
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
228
true
0
false
33
regData1
340
375
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
110
true
0
false
34
regData2
340
375
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
140
true
0
false
35
regData3
340
375
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
172
true
0
false
36
regData4
340
375
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
202
true
0
false
37
regData5
340
375
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
234
true
0
false
38
regOutput32
520
543
010#010#150
010#010#150
100#100#100
010#010#150
010#010#150
100#100#100
242
true
43#44
false
39
regOutput31
520
566
254#254#0
254#254#0
100#100#100
254#254#0
254#254#0
254#254#0
210
true
46#47
false
40
regOutputIND
520
588
010#250#150
010#250#150
100#100#100
010#250#150
010#250#150
100#100#100
182
true
49#50
false
41
regOutput2
520
610
0#255#255
0#255#255
100#100#100
0#255#255
0#255#255
0#255#255
151
true
52#53
false
42
regOutput1
520
633
123#123#0
123#123#0
100#100#100
123#123#0
123#123#0
100#100#100
120
true
55#56
false
43
mux1Reg32
552
665
010#010#150
010#010#150
100#100#100
010#010#150
010#010#150
100#100#100
242
true
0
false
44
mux2Reg32
247
435
010#010#150
010#010#150
100#100#100
010#010#150
010#010#150
100#100#100
547
false
45
false
45
mux2Reg32
548
665
010#010#150
010#010#150
100#100#100
010#010#150
010#010#150
100#100#100
434
true
0
false
46
muxReg31
575
663
254#254#0
254#254#0
100#100#100
254#254#0
254#254#0
100#100#100
210
true
0
false
47
mux2Reg31
217
407
254#254#0
254#254#0
100#100#100
254#254#0
254#254#0
100#100#100
570
false
48
false
48
mux2Reg31
570
665
254#254#0
254#254#0
100#100#100
254#254#0
254#254#0
100#100#100
407
true
0
false
49
muxRegInd
597
665
010#250#150
010#250#150
100#100#100
010#250#150
010#250#150
100#100#100
182
true
0
false
50
muxRegInd
186
379
010#250#150
010#250#150
100#100#100
010#250#150
010#250#150
100#100#100
594
false
51
false
51
muxRegInd
594
665
010#250#150
010#250#150
100#100#100
010#250#150
010#250#150
100#100#100
379
true
0
false
52
muxReg2
155
353
0#255#255
0#255#255
100#100#100
0#255#255
0#255#255
100#100#100
616
false
54
false
53
muxReg2
623
665
0#255#255
0#255#255
100#100#100
0#255#255
0#255#255
100#100#100
150
true
0
false
54
muxReg2
615
665
0#255#255
0#255#255
100#100#100
0#255#255
0#255#255
100#100#100
353
true
0
false
55
mux2reg1
642
665
123#123#0
123#123#0
100#100#100
123#123#0
123#123#0
100#100#100
120
true
0
false
56
mux1reg1
125
335
123#123#0
123#123#0
100#100#100
123#123#0
123#123#0
100#100#100
639
false
57
false
57
mux2reg1
639
665
123#123#0
123#123#0
100#100#100
123#123#0
123#123#0
100#100#100
335
true
0
false
58
registerAdd1
68
95
0#205#0
0#205#0
100#100#100
0#205#0
0#205#0
0#205#0
700
false
61
false
59
registerAdd2
275
290
0#0#255
0#0#255
100#100#100
0#0#255
0#0#255
0#0#255
700
false
60
false
60
mux2output
738
800
254#254#0
254#254#0
100#100#100
254#254#0
254#254#0
100#100#100
346
true
0
false
61
mux2output
737
800
010#250#150
010#250#150
100#100#100
010#250#150
010#250#150
100#100#100
145
true
3#4#16
false
del mars\ext\game\*.class
del mars\mips\instructions\syscalls\*.class
javac -source 1.5 -target 1.5 mars\ext\game\*.java
javac -source 1.5 -target 1.5 mars\mips\instructions\syscalls\*.java
pause
Test
public synchronized class Test {
public void Test();
public static void main(String[]);
}
Mars
public synchronized class Mars {
public void Mars();
public static void main(String[]);
}
jar cmf mainclass.txt NewMars_source.jar PseudoOps.txt Config.properties Syscall.properties Settings.properties MARSlicense.txt mainclass.txt MipsXRayOpcode.xml registerDatapath.xml controlDatapath.xml ALUcontrolDatapath.xml CreateNewsMarsJar_200Syscalls.bat CreateNewMarsSourceJar.bat Mars.java Mars.class docs help images mars CompileGameJava.bat game
Copyright (c) 2003-2013, Pete Sanderson and Kenneth Vollmar
Developed by Pete Sanderson (psanderson@otterbein.edu)
and Kenneth Vollmar (kenvollmar@missouristate.edu)
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
“Software”), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject
to the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
(MIT license, http://www.opensource.org/licenses/mit-license.html)
00000
$zero
00001
at
00010
$v0
00011
$v1
00100
$a0
00101
$a1
00110
$a2
00111
$a3
01000
$t0
01001
$t1
01010
$t2
01011
$t3
01100
$t4
01101
$t5
01110
$t6
01111
$t7
10000
$s0
10001
$s1
10010
$s2
10011
$s3
10100
$s4
10101
$s5
11000
$s6
10111
$s7
11000
$t8
11001
$t9
11010
$k0
11011
$k1
11100
$gp
11101
$sp
11110
$fp
11111
$ra
0
init
1
2
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
28
true
1#2#3#4#5#6
false
1
bit5_1and1
3
207
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
28
true
7#8
false
2
bit4_1and1
3
217
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
52
true
9#10
false
3
bit3_1and1
3
228
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
76
true
11#12
false
4
bit2_1and1
3
238
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100
true
13#14
false
5
bit1_1and1
3
247
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
124
true
15#16
false
6
bit0_1and1
3
255
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
145
true
17#18
false
7
bit5_2and1
217
312
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
28
true
19#20
false
8
bit5_3and1
37
160
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
211
false
55
false
9
bit4_2and1
228
320
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
52
true
21#22
false
10
bit4_3and1
60
160
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
222
false
0
false
11
bit3_2and1
238
330
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
76
true
23#24
false
12
bit3_3and1
82
160
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
231
false
0
false
13
bit2_2and1
247
342
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100
true
25#26
false
14
bit2_3and1
105
160
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
242
false
0
false
15
bit1_2and1
258
352
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
124
true
27#28
false
16
bit1_3and1
130
160
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
252
false
0
false
17
bit0_2and1
267
360
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
145
true
29#30
false
18
bit0_3and1
150
160
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
262
false
0
false
19
bit5_2and2
320
408
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
28
true
31#32
false
20
bit5_3and2
37
167
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
316
false
56
false
21
bit4_2and2
332
417
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
52
true
33#34
false
22
bit4_3and2
60
160
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
325
false
0
false
23
bit3_2and2
342
427
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
76
true
35#36
false
24
bit3_3and2
82
160
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
336
false
0
false
25
bit2_2and2
352
437
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100
true
37#38
false
26
bit2_3and2
105
160
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
346
false
0
false
27
bit1_2and2
362
446
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
124
true
39#40
false
28
bit1_3and2
130
168
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
357
false
0
false
29
bit0_2and2
372
457
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
145
true
41#42
false
30
bit0_3and2
152
167
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
367
false
0
false
31
bit5_2and3
418
502
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
28
true
43#44
false
32
bit5_3and3
37
167
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
412
false
57
false
33
bit4_2and3
426
511
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
52
true
45#46
false
34
bit4_3and3
60
160
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
422
false
0
false
35
bit3_2and3
436
521
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
76
true
47#48
false
36
bit3_3and3
82
165
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
432
false
0
false
37
bit2_2and3
446
531
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100
true
49#50
false
38
bit2_3and3
105
160
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
442
false
0
false
39
bit1_2and3
456
540
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
124
true
51#52
false
40
bit1_3and3
130
168
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
452
false
0
false
41
bit0_2and3
466
551
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
145
true
53#54
false
42
bit0_3and3
152
167
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
461
false
0
false
43
bit5_2and4
515
660
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
28
true
0
false
44
bit5_3and4
37
160
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
507
false
58
false
45
bit4_2and4
524
660
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
52
true
0
false
46
bit4_3and4
60
160
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
517
false
0
false
47
bit3_2and4
534
660
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
76
true
0
false
48
bit3_3and4
82
160
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
527
false
0
false
49
bit2_2and4
544
660
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100
true
0
false
50
bit2_3and4
105
167
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
537
false
0
false
51
bit1_2and4
554
660
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
124
true
0
false
52
bit1_3and4
130
158
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
547
false
0
false
53
bit0_2and4
564
660
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
145
true
0
false
54
bit0_3and4
152
158
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
557
false
0
false
55
and1_out
225
233
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
236
false
59#60
false
56
and2_out
225
249
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
341
false
63#64
false
57
and3_out
225
277
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
435
false
71#72
false
58
and4_out
225
418
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
532
false
75#76
false
59
and1_out2
245
332
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
236
false
61#62
false
60
regDst
242
795
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
239
true
0
false
61
and1_out3
340
443
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
236
false
69#78
false
62
regDst
244
577
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
336
true
0
false
63
and2_out2
261
302
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
341
false
65#69
false
64
or1_in1
345
574
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
255
true
0
false
65
and2_out3
312
355
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
341
false
66#68
false
66
and2_out4
365
377
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
341
false
67#70
false
67
and2_out5
390
470
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
341
false
0
false
68
or2_in2
345
574
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
360
true
80
false
69
memToReg
345
795
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
308
true
0
false
70
readMem
345
795
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
384
true
0
false
71
and3_out2
287
397
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
435
false
73#74
false
72
or1_in2
440
575
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
283
true
79
false
73
and3_out3
410
480
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
435
false
0
false
74
writeMem
440
795
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
403
true
0
false
75
branch
537
795
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
425
true
0
false
76
and4_out2
430
465
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
532
false
77
false
77
opALU0
537
795
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
470
true
0
false
78
OpAlu1
242
795
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
448
true
0
false
79
or1_out
640
795
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
266
true
0
false
80
writeReg
648
795
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
345
true
0
false
0 0 0 0 1 1 0 0 0 0 1 1 0 0 0 0 0 0 1 1 0 0 0 0 0 0
0 0 0 0 1 1 0 0 0 0 1 1 0 0 1 1 0 0 1 1 0 0 0 0 0 0
-1 -1 1 1 1 1 1 1 0 0 1 1 0 0 0 0 0 0 1 1 1 0 0 0 0 0
-1 -1 1 1 1 1 1 1 0 0 1 1 0 0 2 2 0 0 1 1 1 0 0 0 0 0
-1 -1 -1 -1 -1 -1 0 0 0 0 1 1 0 0 1 1 0 0 1 1 0 0 0 1 1 0
-1 -1 -1 -1 -1 -1 0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 1 1 0
-1 -1 4 4 4 4 1 1 1 1 1 1 1 1 4 4 4 4 1 1 1 1 0 0 4 4
-1 -1 4 4 4 4 1 1 1 1 1 1 1 1 4 4 4 4 1 1 1 1 0 0 4 4
0 0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 1 1 0 0 0 0 0 0 0 0 1 1 1 1 0 0 0 0 0 0 0 0 0 0
0 0 0 0 1 1 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2
0 0 0 0 1 1 0 0 0 0 0 1 1 1 1 1 0 0 1 1 0 0 0 0 0 0
1 1 1 1 0 0 1 1 0 0 0 1 1 1 1 1 -1 -1 1 1 0 0 0 0 1 1
1 1 1 1 0 0 1 1 0 0 0 1 1 1 1 1 -1 -1 1 1 2 2 2 2 1 1
0 0 0 0 0 0 2 2 0 0 0 0 0 0 -1 -1 -1 -1 -1 -1 -1 -1 0 0 0 0
0 0 0 0 0 0 2 2 0 0 2 2 0 0 -1 -1 -1 -1 -1 -1 -1 -1 0 0 0 0
4 4 4 4 0 0 4 4 4 4 4 4 4 4 4 4 0 0 1 1 1 1 4 4 4 4
4 4 4 4 0 0 4 4 4 4 4 4 4 4 4 4 0 0 1 1 1 1 4 4 4 4
-1 -1 -1 -1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
-1 -1 -1 -1 0 0 0 1 0 0 0 0 1 1 1 1 0 0 0 0 0 0 0 0 0 0
-1 -1 -1 -1 1 1 0 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0 1 1 0 0
-1 -1 -1 -1 1 1 0 0 1 0 0 0 0 0 0 1 0 0 2 2 1 1 1 1 0 0
-1 -1 0 0 1 1 0 0 1 0 0 0 0 0 0 0 0 0 1 1 0 0 1 1 0 0
-1 -1 2 2 1 1 0 0 1 0 0 1 1 1 1 0 0 0 0 0 0 0 1 1 0 0
0 0 0 0 0 0 0 0 0 0 0 1 9 8 1 0 0 0 0 0 0 0 1 1 0 0
0 0 0 0 0 0 0 0 0 0 0 1 8 8 1 0 0 0 1 1 0 0 0 0 0 0
title = BattleCity Game
width = 512
height = 448
mazeWidth = 416
mazeHeight = 416
bitmapColumn = 26
bitmapRow = 26
object1Size = 32
object2Size = 32
object3Size = 6
object4Size = 6
object5Size = 32
object6Size = 32
object7Size = 32
obj7width=64
type1=tank
type2=enemy
type3=bullet
type4=enemyBullet
ImageAll=/game/images/tankAll.gif
// using mazeBitmap
mazeBitmap2 = /game/bitmap1.txt
mazeBitmap = /game/bitmap1.bck.txt
grass = /game/images/grass.png
stone_wall = /game/images/stone_wall.png
brick_wall = /game/images/brick_wall.png
brick_wall_break1 = /game/images/brick_wall_break1.png
brick_wall_break2 = /game/images/brick_wall_break2.png
brick_wall_break3 = /game/images/brick_wall_break3.png
brick_wall_break4 = /game/images/brick_wall_break4.png
brick_wall_break5 = /game/images/brick_wall_break5.png
brick_wall_break6 = /game/images/brick_wall_break6.png
tile0 = /game/images/path1.png
tile1 = /game/images/wall1.png
// music has some error
soundCount = 7
sound0 = /game/sounds/start.wav
sound1 = /game/sounds/move.wav
sound2 = /game/sounds/playerCrack.wav
sound3 = /game/sounds/prop.wav
sound4 = /game/sounds/tankCrack.wav
sound5 = /game/sounds/attack.wav
sound6 = /game/sounds/bulletCrack.wav
seekDistance = 210
routeFile0 = /game/route0.txt
// routeFile1 = /game/route1.txt
// routeFile2 = /game/route2.txt
// routeFile3 = /game/route3.txt
// Type Info
// type 0 for bomb
// type 1 for bombman
// type 2 for monster
object*3 + string*2 = 5
objectTypeCount = 10
topObjectType = 4
Bomb
object0ImagePackCount = 1
object0Pack0Image0 = /game/images/bomb_0.png
object0Pack0Image1 = /game/images/bomb_1.png
object0Pack0Image2 = /game/images/bomb_2.png
blastCenterImage0 = /game/images/blast_center_0.png
blastCenterImage1 = /game/images/blast_center_1.png
blastCenterImage2 = /game/images/blast_center_2.png
blastCenterImage3 = /game/images/blast_center_3.png
blastMiddileImage0 = /game/images/blast_middle_0.png
blastMiddileImage1 = /game/images/blast_middle_1.png
blastMiddileImage2 = /game/images/blast_middle_2.png
blastMiddileImage3 = /game/images/blast_middle_3.png
blastEdgeImage0 = /game/images/blast_edge_0.png
blastEdgeImage1 = /game/images/blast_edge_1.png
blastEdgeImage2 = /game/images/blast_edge_2.png
blastEdgeImage3 = /game/images/blast_edge_3.png
//bullet
object3ImagePackCount = 1
object3Pack0Image0 = /game/images/bomb_0.png
object3Pack0Image1 = /game/images/bomb_1.png
object3Pack0Image2 = /game/images/bomb_2.png
object3Pack0Image3 = /game/images/bomb_2.png
//enemy bullet
object4ImagePackCount = 1
object4Pack0Image0 = /game/images/bomb_0.png
object4Pack0Image1 = /game/images/bomb_1.png
object4Pack0Image2 = /game/images/bomb_2.png
object4Pack0Image3 = /game/images/bomb_2.png
//Bombman, tank
one pack -> one gif
object1ImagePackCount = 1
object1Pack0Image0 = /game/images/tankup.png
object1Pack0Image2 = /game/images/tankdown.png
object1Pack0Image1 = /game/images/tankleft.png
object1Pack0Image3 = /game/images/tankright.png
//oject1Pack0Image3 = /game/images/bombman_left_1.png
//oject1Pack0Image4 = /game/images/bombman_left_2.png
//oject1Pack0Image5 = /game/images/bombman_left_3.png
//oject1Pack0Image6 = /game/images/bombman_right_1.png
//oject1Pack0Image7 = /game/images/bombman_right_2.png
//oject1Pack0Image8 = /game/images/bombman_right_3.png
//oject1Pack0Image9 = /game/images/bombman_up_1.png
//oject1Pack0Image10 = /game/images/bombman_up_2.png
//oject1Pack0Image11 = /game/images/bombman_up_3.png
// monster
object2Speed = 2
x1=0
y1=0
x2=384
y2=0
// how many packs
object2ImagePackCount = 1
one pack -> one gif
object2Pack0Image0 = /game/images/lower-monster_0.png
object2Pack0Image1 = /game/images/lower-monster_1.png
object2Pack0Image2 = /game/images/lower-monster_2.png
object2Pack0Image3 = /game/images/lower-monster_3.png
object2Pack0Image4 = /game/images/lower-monster_4.png
object2Pack0Image5 = /game/images/lower-monster_5.png
object2Pack1Image0 = /game/images/lower-monster_11.png
object2Pack1Image1 = /game/images/lower-monster_12.png
object2Pack1Image2 = /game/images/lower-monster_13.png
object2Pack1Image0 = /game/images/lower-monster_14.png
object2Pack1Image1 = /game/images/lower-monster_15.png
object2Pack1Image2 = /game/images/lower-monster_16.png
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
1 2 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 2 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 2 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 2 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 1 1 0 1 1 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 0 0 1 0 1 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 1 1 0 1 1 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 1 0 1 0 1 0 1 0 1
1 0 1 0 1 0 1 0 1 0 1 0 1 1 1 0 1 1 1 0 1 0 1 0 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
1 0 1 1 1 1 0 1 1 0 1 1 0 1 1 1 1 1 1 0 1 1 1 0 1
1 0 1 0 1 0 0 1 0 0 0 1 0 1 1 1 1 1 1 0 0 0 1 0 1
1 0 1 0 1 1 0 1 0 1 0 1 0 1 0 1 1 0 1 0 1 0 1 0 1
1 0 1 0 1 1 0 0 0 1 0 0 0 1 0 1 1 0 1 0 1 1 1 0 1
1 0 0 0 1 1 0 1 0 1 0 1 0 1 0 1 1 0 1 0 1 0 0 0 1
1 1 1 0 1 1 0 1 0 1 0 1 0 1 0 1 1 0 1 0 1 0 1 1 1
1 0 1 0 1 1 0 1 1 1 1 1 0 1 0 1 1 0 1 0 1 1 1 1 1
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
1 1 1 1 0 1 0 1 1 1 1 0 1 1 1 0 1 1 1 0 1 1 0 1 1
1 0 0 0 0 1 0 1 1 1 1 0 1 1 1 0 1 1 1 0 1 1 0 0 1
1 1 1 1 0 1 0 1 0 0 0 0 0 1 1 0 0 1 1 0 0 1 1 0 1
1 0 0 0 0 1 0 1 1 1 1 1 0 1 1 1 0 1 1 1 0 0 0 0 1
1 0 1 1 1 1 0 1 0 0 0 1 0 1 1 1 0 1 1 1 0 1 0 1 1
1 0 1 0 0 0 0 1 0 1 0 1 0 1 1 1 0 1 1 1 0 0 0 1 1
1 0 1 0 1 1 0 0 0 0 0 1 0 1 1 1 0 0 0 0 0 1 1 1 1
1 0 1 1 1 1 0 1 1 1 1 1 0 1 1 1 0 1 1 1 0 0 0 0 1
1 0 0 1 1 0 0 0 0 0 0 1 0 0 0 0 0 1 1 1 0 1 1 0 1
1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
Approximately how many bytes are one Megabyte?
One million
Ten thousands
One thousand
One hundred
How much information can a CD (Compact Disc) usually store?
650MB
10MB
1.4MB
150MB
DOS in computer terms stands for:
Disk Operating System
Dual Organized System
Dual Operating System
Disk Organized System
Which part is the “brain” of the computer?
CPU
ROM
RAM
Monitor
Which of the following is not an input device?
Monitor
Keyboard
Microphone
Joystick
Which of the following is the capital of the US?
Washington DC
Tokyo
Beijing
Madrid
The capacity of your hard drive is measured in:
Gigabytes
52X
MHz
Mbps
Which of the following is not an output device?
Keyboard
Speakers
Monitor
Printer
Physical components that make up your computer are known as:
Hardware
Software
Web Browsers
Operating Systems
What does RAM in computer terms stand for?
Random Access Memory
Readily Accessed Mailer
Random Authorization Mechanism
Remote Authorization Mechanism
Which of the following is the largest planet in the solar system?
Jupiter
Neptune
Earth
Mars
What does a light-year measure?
Distance
Time
Brightness
Weight
What date is the National Day of Hong Kong?
October 1st
June 1st
March 1st
April 1st
I _____ tennis every Sunday morning.
play
playing
am playing
am play
Babies _____ when they are hungry.
cry
cries
cried
are crying
You can’t borrow my pencil. I _____ it myself.
am using
was using
use
using
Who plays Lara Croft in the Tomb Raider series of films?
Angelina Jolie
Tom Cruise
Madonna
Jennifer Aniston
How many sides does a pentagon have?
5
3
4
8
What is the fifth letter of the english alphabet?
E
J
K
D
In general, which of the following animals runs the fastest?
Tiger
Dog
Mice
Elephant
What is the maximum limit of loading money into an octopus card?
$500
$200
$1,000
An infinite amount
How many eggs are used in “gai daan jai” (little chicken egg) waffle?
30
24
16
10
What make and model of car is a standard Hong Kong taxi?
Toyota Crown Comfort
Honda Civic
Mitsubishi Canter
Lexus IS
A Hong Kong government vehicle uses a license plate with two letters:
AM
AA
BM
BQ
How many islands are in Hong Kong?
More than 200
Around seven
Around 30
Around 100
On which weekday do the government museums offer free admission?
Wednesday
Tuesday
Monday
Friday
According to the Hong Kong government, a standard egg tart has:
310 calories
250 calories
180 calories
460 calories
How did dai pai dongs get their name?
From their large-sized restaurant licenses
From their laminated, single-sheet menus
From their oversized woks
From their signature dishes
On RTHK Radio 3, the program “All the Way with Ray” begins at:
10pm
1am
10am
11pm
In which district is Central Plaza located?
Wan Chai
Central
Kwun Tong
Sheung Wan
A zong (sticky rice dumpling) is traditionally wrapped using:
Bamboo leaves
Banana leaves
Pandanus leaves
Eucalyptus leaves
In a cold warning on TVB’s weather report, Freddy (the weatherman):
turns into a block of ice
wears earmuffs and a scarf
gets crushed under the word “COLD”
coughs and sneezes
What song does the Mister Softee truck play?
“The Blue Danube”
“Pop Goes the Weasel”
“The Teddy Bear’s Picnic”
“ABC”
What is the full address of Chungking Mansions?
36-44 Nathan Road
100-120 Chungking Road
65 Haiphong Road
1 Clear Water Bay Road
Where did actor Chow Yun-fat spend his childhood?
Lamma Island
Vancouver
Sham Shui Po
Sai Kung
r
r
r
r
r
r
d 30 60
d 180 30
d 180 150
d 180 270
d 30 120
o
d 570 270
d 600 540
o
r
r
o
Constant Field Values
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Constant Field Values
Contents mars.*
mars.*
mars.ErrorList
public static final String ERROR_MESSAGE_PREFIX “Error”
public static final String FILENAME_PREFIX ” in ”
public static final String LINE_PREFIX ” line ”
public static final String MESSAGE_SEPARATOR “: ”
public static final String POSITION_PREFIX ” column ”
public static final String WARNING_MESSAGE_PREFIX “Warning”
mars.ErrorMessage
public static final boolean ERROR false
public static final boolean WARNING true
mars.Globals
public static final String helpPath “/help/”
public static final String imagesPath “/images/”
public static final String version “4.4”
mars.Settings
public static final int ASSEMBLE_ALL_ENABLED 3
public static final int ASSEMBLE_ON_OPEN_ENABLED 2
public static final int AUTO_INDENT 19
public static final int BARE_MACHINE_ENABLED 1
public static final int CARET_BLINK_RATE 4
public static final int DATA_SEGMENT_HIGHLIGHTING 12
public static final int DATASEGMENT_HIGHLIGHT_BACKGROUND 8
public static final int DATASEGMENT_HIGHLIGHT_FONT 5
public static final int DATASEGMENT_HIGHLIGHT_FOREGROUND 9
public static final int DELAYED_BRANCHING_ENABLED 8
public static final int DISPLAY_ADDRESSES_IN_HEX 5
public static final int DISPLAY_VALUES_IN_HEX 6
public static final int EDITOR_CURRENT_LINE_HIGHLIGHTING 15
public static final int EDITOR_FONT 0
public static final int EDITOR_LINE_NUMBERS_DISPLAYED 9
public static final int EDITOR_POPUP_PREFIX_LENGTH 6
public static final int EDITOR_TAB_SIZE 5
public static final int EVEN_ROW_BACKGROUND 0
public static final int EVEN_ROW_FONT 1
public static final int EVEN_ROW_FOREGROUND 1
public static final int EXCEPTION_HANDLER 0
public static final int EXCEPTION_HANDLER_ENABLED 7
public static final int EXTENDED_ASSEMBLER_ENABLED 0
public static final int GENERIC_TEXT_EDITOR 18
public static final int LABEL_SORT_STATE 2
public static final int LABEL_WINDOW_VISIBILITY 4
public static final int MEMORY_CONFIGURATION 3
public static final int ODD_ROW_BACKGROUND 2
public static final int ODD_ROW_FONT 2
public static final int ODD_ROW_FOREGROUND 3
public static final int POPUP_INSTRUCTION_GUIDANCE 16
public static final int POPUP_SYSCALL_INPUT 17
public static final int PROGRAM_ARGUMENTS 11
public static final int REGISTER_HIGHLIGHT_BACKGROUND 10
public static final int REGISTER_HIGHLIGHT_FONT 6
public static final int REGISTER_HIGHLIGHT_FOREGROUND 11
public static final int REGISTERS_HIGHLIGHTING 13
public static final int SELF_MODIFYING_CODE_ENABLED 20
public static final int START_AT_MAIN 14
public static final int TEXT_COLUMN_ORDER 1
public static final int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_BACKGROUND 6
public static final int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FONT 4
public static final int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FOREGROUND 7
public static final int TEXTSEGMENT_HIGHLIGHT_BACKGROUND 4
public static final int TEXTSEGMENT_HIGHLIGHT_FONT 3
public static final int TEXTSEGMENT_HIGHLIGHT_FOREGROUND 5
public static final int WARNINGS_ARE_ERRORS 10
mars.assembler.*
mars.assembler.DataTypes
public static final int BYTE_SIZE 1
public static final int CHAR_SIZE 1
public static final int DOUBLE_SIZE 8
public static final int FLOAT_SIZE 4
public static final int HALF_SIZE 2
public static final double LOW_DOUBLE_VALUE -1.7976931348623157E308
public static final double LOW_FLOAT_VALUE -3.4028234663852886E38
public static final int MAX_BYTE_VALUE 127
public static final double MAX_DOUBLE_VALUE 1.7976931348623157E308
public static final double MAX_FLOAT_VALUE 3.4028234663852886E38
public static final int MAX_HALF_VALUE 32767
public static final int MAX_UHALF_VALUE 65535
public static final int MAX_WORD_VALUE 2147483647
public static final int MIN_BYTE_VALUE -128
public static final int MIN_HALF_VALUE -32768
public static final int MIN_UHALF_VALUE 0
public static final int MIN_WORD_VALUE -2147483648
public static final int WORD_SIZE 4
mars.assembler.Symbol
public static final boolean DATA_SYMBOL true
public static final boolean TEXT_SYMBOL false
mars.assembler.SymbolTable
public static final int NOT_FOUND -1
mars.assembler.TokenTypes
public static final String TOKEN_DELIMITERS “\t ,()”
mars.mips.*
mars.mips.hardware.AccessNotice
public static final int READ 0
public static final int WRITE 1
mars.mips.hardware.Coprocessor0
public static final int CAUSE 13
public static final int DEFAULT_STATUS_VALUE 65297
public static final int EPC 14
public static final int EXCEPTION_LEVEL 1
public static final int STATUS 12
public static final int VADDR 8
mars.mips.hardware.Memory
public static final boolean BIG_ENDIAN false
public static final boolean LITTLE_ENDIAN true
public static final int WORD_LENGTH_BYTES 4
mars.mips.hardware.RegisterFile
public static final int GLOBAL_POINTER_REGISTER 28
public static final int STACK_POINTER_REGISTER 29
mars.mips.instructions.Instruction
public static final int INSTRUCTION_LENGTH 4
public static final int INSTRUCTION_LENGTH_BITS 32
mars.simulator.*
mars.simulator.Exceptions
public static final int ADDRESS_EXCEPTION_LOAD 4
public static final int ADDRESS_EXCEPTION_STORE 5
public static final int ARITHMETIC_OVERFLOW_EXCEPTION 12
public static final int BREAKPOINT_EXCEPTION 9
public static final int DIVIDE_BY_ZERO_EXCEPTION 15
public static final int EXTERNAL_INTERRUPT_DISPLAY 128
public static final int EXTERNAL_INTERRUPT_KEYBOARD 64
public static final int FLOATING_POINT_OVERFLOW 16
public static final int FLOATING_POINT_UNDERFLOW 17
public static final int RESERVED_INSTRUCTION_EXCEPTION 10
public static final int SYSCALL_EXCEPTION 8
public static final int TRAP_EXCEPTION 13
mars.simulator.Simulator
public static final int BREAKPOINT 1
public static final int CLIFF_TERMINATION 5
public static final int EXCEPTION 2
public static final int MAX_STEPS 3
public static final int NO_DEVICE 0
public static final int NORMAL_TERMINATION 4
public static final int PAUSE_OR_STOP 6
mars.simulator.SimulatorNotice
public static final int SIMULATOR_START 0
public static final int SIMULATOR_STOP 1
mars.tools.*
mars.tools.BHTSimGUI
public static final String BHT_DO_NOT_TAKE_BRANCH “NOT TAKE”
public static final String BHT_TAKE_BRANCH “TAKE”
mars.tools.BHTSimulator
public static final int BHT_DEFAULT_HISTORY 1
public static final boolean BHT_DEFAULT_INITVAL false
public static final int BHT_DEFAULT_SIZE 16
public static final String BHT_HEADING “Branch History Table Simulator”
public static final String BHT_NAME “BHT Simulator”
public static final String BHT_VERSION “Version 1.0 (Ingo Kofler)”
mars.tools.DigitalLabSim
public static final int EXTERNAL_INTERRUPT_HEXA_KEYBOARD 512
public static final int EXTERNAL_INTERRUPT_TIMER 256
mars.util.*
mars.util.EditorFont
public static final int DEFAULT_SIZE 12
public static final int MAX_SIZE 72
public static final int MIN_SIZE 6
mars.util.SystemIO
public static final int SYSCALL_BUFSIZE 128
public static final int SYSCALL_MAXFILES 32
mars.venus.*
mars.venus.Editor
public static final int MAX_BLINK_RATE 1000
public static final int MAX_TAB_SIZE 32
public static final int MIN_BLINK_RATE 0
public static final int MIN_TAB_SIZE 1
mars.venus.FileStatus
public static final int EDITED 4
public static final int NEW_EDITED 2
public static final int NEW_NOT_EDITED 1
public static final int NO_FILE 0
public static final int NOT_EDITED 3
public static final int OPENING 8
public static final int RUNNABLE 5
public static final int RUNNING 6
public static final int TERMINATED 7
mars.venus.HelpHelpAction
public static final String descriptionDetailSeparator “:”
mars.venus.NumberDisplayBaseChooser
public static final int ASCII 0
public static final int DECIMAL 10
public static final int HEXADECIMAL 16
mars.venus.RunSpeedPanel
public static final double UNLIMITED_SPEED 40.0
mars.venus.SettingsHighlightingAction
public static final String APPLY_TOOL_TIP_TEXT “Apply current settings now and leave dialog open”
public static final String CANCEL_TOOL_TIP_TEXT “Close dialog without applying current settings”
public static final String CLOSE_TOOL_TIP_TEXT “Apply current settings and close dialog”
public static final String RESET_TOOL_TIP_TEXT “Reset to initial settings without applying”
mars.venus.editors.MARSTextEditingArea
public static final int TEXT_FOUND 1
public static final int TEXT_NOT_FOUND 0
public static final int TEXT_REPLACED_FOUND_NEXT 2
public static final int TEXT_REPLACED_NOT_FOUND_NEXT 3
mars.venus.editors.jeditsyntax.InputHandler
public static final String SMART_HOME_END_PROPERTY “InputHandler.homeEnd”
mars.venus.editors.jeditsyntax.tokenmarker.Token
public static final byte COMMENT1 1
public static final byte COMMENT2 2
public static final byte END 127
public static final byte ID_COUNT 12
public static final byte INTERNAL_FIRST 100
public static final byte INTERNAL_LAST 126
public static final byte INVALID 10
public static final byte KEYWORD1 6
public static final byte KEYWORD2 7
public static final byte KEYWORD3 8
public static final byte LABEL 5
public static final byte LITERAL1 3
public static final byte LITERAL2 4
public static final byte MACRO_ARG 11
public static final byte NULL 0
public static final byte OPERATOR 9
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For All Packages
Package Hierarchies:
mars, mars.assembler, mars.mips.dump, mars.mips.hardware, mars.mips.instructions, mars.mips.instructions.syscalls, mars.simulator, mars.tools, mars.util, mars.venus, mars.venus.editors, mars.venus.editors.generic, mars.venus.editors.jeditsyntax, mars.venus.editors.jeditsyntax.tokenmarker
Class Hierarchy
java.lang.Object javax.swing.AbstractAction (implements javax.swing.Action, java.lang.Cloneable, java.io.Serializable)
mars.venus.GuiAction mars.venus.EditCopyAction
mars.venus.EditCutAction
mars.venus.EditFindReplaceAction
mars.venus.EditPasteAction
mars.venus.EditRedoAction
mars.venus.EditSelectAllAction
mars.venus.EditUndoAction
mars.venus.FileCloseAction
mars.venus.FileCloseAllAction
mars.venus.FileDumpMemoryAction
mars.venus.FileExitAction
mars.venus.FileNewAction
mars.venus.FileOpenAction
mars.venus.FilePrintAction
mars.venus.FileSaveAction
mars.venus.FileSaveAllAction
mars.venus.FileSaveAsAction
mars.venus.HelpAboutAction
mars.venus.HelpHelpAction
mars.venus.RunAssembleAction
mars.venus.RunBackstepAction
mars.venus.RunClearBreakpointsAction (implements javax.swing.event.TableModelListener)
mars.venus.RunGoAction
mars.venus.RunPauseAction
mars.venus.RunResetAction
mars.venus.RunStepAction
mars.venus.RunStopAction
mars.venus.RunToggleBreakpointsAction
mars.venus.SettingsAddressDisplayBaseAction
mars.venus.SettingsAssembleAllAction
mars.venus.SettingsAssembleOnOpenAction
mars.venus.SettingsDelayedBranchingAction
mars.venus.SettingsEditorAction
mars.venus.SettingsExceptionHandlerAction
mars.venus.SettingsExtendedAction
mars.venus.SettingsHighlightingAction
mars.venus.SettingsLabelAction
mars.venus.SettingsMemoryConfigurationAction
mars.venus.SettingsPopupInputAction
mars.venus.SettingsProgramArgumentsAction
mars.venus.SettingsSelfModifyingCodeAction
mars.venus.SettingsStartAtMainAction
mars.venus.SettingsValueDisplayBaseAction
mars.venus.SettingsWarningsAreErrorsAction
mars.venus.ToolAction
javax.swing.text.AbstractDocument (implements javax.swing.text.Document, java.io.Serializable)
javax.swing.text.PlainDocument mars.venus.editors.jeditsyntax.SyntaxDocument
mars.mips.dump.AbstractDumpFormat (implements mars.mips.dump.DumpFormat)
mars.mips.dump.AsciiTextDumpFormat
mars.mips.dump.BinaryDumpFormat
mars.mips.dump.BinaryTextDumpFormat
mars.mips.dump.HexTextDumpFormat
mars.mips.dump.IntelHexDumpFormat
mars.mips.dump.SegmentWindowDumpFormat
mars.mips.instructions.syscalls.AbstractSyscall (implements mars.mips.instructions.syscalls.Syscall)
mars.mips.instructions.syscalls.SyscallClose
mars.mips.instructions.syscalls.SyscallConfirmDialog
mars.mips.instructions.syscalls.SyscallExit
mars.mips.instructions.syscalls.SyscallExit2
mars.mips.instructions.syscalls.SyscallInputDialogDouble
mars.mips.instructions.syscalls.SyscallInputDialogFloat
mars.mips.instructions.syscalls.SyscallInputDialogInt
mars.mips.instructions.syscalls.SyscallInputDialogString
mars.mips.instructions.syscalls.SyscallMessageDialog
mars.mips.instructions.syscalls.SyscallMessageDialogDouble
mars.mips.instructions.syscalls.SyscallMessageDialogFloat
mars.mips.instructions.syscalls.SyscallMessageDialogInt
mars.mips.instructions.syscalls.SyscallMessageDialogString
mars.mips.instructions.syscalls.SyscallMidiOut
mars.mips.instructions.syscalls.SyscallMidiOutSync
mars.mips.instructions.syscalls.SyscallOpen
mars.mips.instructions.syscalls.SyscallPrintChar
mars.mips.instructions.syscalls.SyscallPrintDouble
mars.mips.instructions.syscalls.SyscallPrintFloat
mars.mips.instructions.syscalls.SyscallPrintInt
mars.mips.instructions.syscalls.SyscallPrintIntBinary
mars.mips.instructions.syscalls.SyscallPrintIntHex
mars.mips.instructions.syscalls.SyscallPrintIntUnsigned
mars.mips.instructions.syscalls.SyscallPrintString
mars.mips.instructions.syscalls.SyscallRandDouble
mars.mips.instructions.syscalls.SyscallRandFloat
mars.mips.instructions.syscalls.SyscallRandInt
mars.mips.instructions.syscalls.SyscallRandIntRange
mars.mips.instructions.syscalls.SyscallRandSeed
mars.mips.instructions.syscalls.SyscallRead
mars.mips.instructions.syscalls.SyscallReadChar
mars.mips.instructions.syscalls.SyscallReadDouble
mars.mips.instructions.syscalls.SyscallReadFloat
mars.mips.instructions.syscalls.SyscallReadInt
mars.mips.instructions.syscalls.SyscallReadString
mars.mips.instructions.syscalls.SyscallSbrk
mars.mips.instructions.syscalls.SyscallSleep
mars.mips.instructions.syscalls.SyscallTime
mars.mips.instructions.syscalls.SyscallWrite
javax.swing.table.AbstractTableModel (implements java.io.Serializable, javax.swing.table.TableModel)
mars.tools.BHTableModel
mars.mips.hardware.AccessNotice mars.mips.hardware.MemoryAccessNotice
mars.mips.hardware.RegisterAccessNotice
mars.assembler.Assembler
mars.simulator.BackStepper
mars.mips.instructions.BasicInstructionFormat
mars.tools.BHTEntry
mars.util.Binary
java.awt.Component (implements java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable)
java.awt.Container javax.swing.JComponent (implements java.io.Serializable)
javax.swing.AbstractButton (implements java.awt.ItemSelectable, javax.swing.SwingConstants)
javax.swing.JButton (implements javax.accessibility.Accessible)
mars.tools.AbstractMarsToolAndApplication.ConnectButton
mars.venus.RepeatButton (implements java.awt.event.ActionListener, java.awt.event.MouseListener)
javax.swing.JToggleButton (implements javax.accessibility.Accessible)
javax.swing.JCheckBox (implements javax.accessibility.Accessible)
mars.venus.NumberDisplayBaseChooser
mars.tools.DigitalLabSim.SevenSegmentDisplay
mars.venus.editors.jeditsyntax.JEditTextArea mars.venus.editors.jeditsyntax.JEditBasedTextArea (implements javax.swing.event.CaretListener, mars.venus.editors.MARSTextEditingArea)
javax.swing.JInternalFrame (implements javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants)
mars.venus.DataSegmentWindow (implements java.util.Observer)
mars.venus.LabelsWindow
mars.venus.TextSegmentWindow (implements java.util.Observer)
javax.swing.JLayeredPane (implements javax.accessibility.Accessible)
javax.swing.JDesktopPane (implements javax.accessibility.Accessible)
mars.venus.ExecutePane
javax.swing.JPanel (implements javax.accessibility.Accessible)
mars.tools.BHTSimGUI
mars.venus.Coprocessor0Window (implements java.util.Observer)
mars.venus.Coprocessor1Window (implements java.awt.event.ActionListener, java.util.Observer)
mars.tools.DigitalLabSim.HexaKeyboard
mars.tools.DigitalLabSim.SevenSegmentPanel
mars.venus.EditPane (implements java.util.Observer)
mars.venus.RegistersWindow (implements java.util.Observer)
mars.venus.RunSpeedPanel
javax.swing.JTabbedPane (implements javax.accessibility.Accessible, java.io.Serializable, javax.swing.SwingConstants)
mars.venus.EditTabbedPane
mars.venus.MainPane
mars.venus.MessagesPane
mars.venus.RegistersPane
javax.swing.text.JTextComponent (implements javax.accessibility.Accessible, javax.swing.Scrollable)
javax.swing.JTextArea mars.venus.editors.generic.GenericTextArea (implements mars.venus.editors.MARSTextEditingArea)
mars.venus.editors.jeditsyntax.TextAreaPainter (implements javax.swing.text.TabExpander)
java.awt.Window (implements javax.accessibility.Accessible)
java.awt.Dialog javax.swing.JDialog (implements javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants)
mars.venus.AbstractFontSettingDialog
java.awt.Frame (implements java.awt.MenuContainer)
javax.swing.JFrame (implements javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants)
mars.tools.AbstractMarsToolAndApplication (implements mars.tools.MarsTool, java.util.Observer)
mars.tools.BHTSimulator (implements java.awt.event.ActionListener)
mars.tools.BitmapDisplay
mars.tools.CacheSimulator
mars.tools.DigitalLabSim
mars.tools.FloatRepresentation
mars.tools.InstructionCounter
mars.tools.InstructionStatistics
mars.tools.IntroToTools
mars.tools.KeyboardAndDisplaySimulator
mars.tools.MemoryReferenceVisualization
mars.venus.VenusUI
javax.swing.JWindow (implements javax.accessibility.Accessible, javax.swing.RootPaneContainer)
mars.MarsSplashScreen
mars.mips.hardware.Coprocessor0
mars.mips.hardware.Coprocessor1
mars.assembler.DataTypes
mars.simulator.DelayedBranch
mars.tools.DigitalLabSim.HexaKeyboard.EcouteurClick (implements java.awt.event.MouseListener)
mars.tools.DigitalLabSim.OneSecondCounter
mars.assembler.Directives
mars.mips.dump.DumpFormatLoader
mars.venus.Editor
mars.util.EditorFont
mars.ErrorList
mars.ErrorMessage
mars.simulator.Exceptions
mars.util.FilenameFinder
mars.venus.FileStatus
mars.Globals
mars.venus.editors.jeditsyntax.InputHandler.backspace (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.backspace_word (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.clip_copy (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.clip_cut (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.clip_paste (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.delete (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.delete_word (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.document_end (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.document_home (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.end (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.home (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.insert_break (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.insert_char (implements java.awt.event.ActionListener, mars.venus.editors.jeditsyntax.InputHandler.NonRepeatable)
mars.venus.editors.jeditsyntax.InputHandler.insert_tab (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.next_char (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.next_line (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.next_page (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.next_word (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.overwrite (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.prev_char (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.prev_line (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.prev_page (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.prev_word (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.repeat (implements java.awt.event.ActionListener, mars.venus.editors.jeditsyntax.InputHandler.NonRecordable)
mars.venus.editors.jeditsyntax.InputHandler.select_all (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.toggle_rect (implements java.awt.event.ActionListener)
mars.mips.instructions.Instruction mars.mips.instructions.BasicInstruction
mars.mips.instructions.ExtendedInstruction
mars.mips.instructions.InstructionSet
java.awt.event.KeyAdapter (implements java.awt.event.KeyListener)
mars.tools.AbstractMarsToolAndApplication.EnterKeyListener
mars.venus.editors.jeditsyntax.InputHandler mars.venus.editors.jeditsyntax.DefaultInputHandler
mars.venus.editors.jeditsyntax.KeywordMap
mars.assembler.Macro
mars.assembler.MacroPool
Mars
mars.tools.MarsBot (implements mars.tools.MarsTool, java.util.Observer)
mars.MarsLaunch
mars.mips.hardware.MemoryConfiguration
mars.mips.hardware.MemoryConfigurations
mars.util.MemoryDump
mars.mips.dump.MIFDumpFormat
mars.MIPSprogram
java.awt.event.MouseAdapter (implements java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.awt.event.MouseWheelListener)
mars.venus.PopupListener
java.util.Observable mars.mips.hardware.Memory
mars.mips.hardware.Register
mars.Settings
mars.simulator.Simulator
mars.assembler.OperandFormat
mars.venus.editors.jeditsyntax.PopupHelpItem
mars.simulator.ProgramArgumentList
mars.ProgramStatement
mars.util.PropertiesFile
mars.mips.instructions.syscalls.RandomStreams
mars.mips.hardware.RegisterFile
mars.tools.ScavengerHunt (implements mars.tools.MarsTool, java.util.Observer)
mars.tools.ScreenMagnifier (implements mars.tools.MarsTool)
mars.simulator.SimulatorNotice
mars.assembler.SourceLine
mars.simulator.SwingWorker
mars.assembler.Symbol
mars.assembler.SymbolTable
mars.venus.editors.jeditsyntax.SyntaxStyle
mars.venus.editors.jeditsyntax.SyntaxUtilities
mars.mips.instructions.syscalls.SyscallNumberOverride
mars.util.SystemIO
mars.venus.editors.jeditsyntax.TextAreaDefaults
mars.venus.editors.jeditsyntax.TextUtilities
java.lang.Throwable (implements java.io.Serializable)
java.lang.Exception mars.mips.hardware.AddressErrorException
mars.venus.HardcopyWriter.PrintCanceledException
mars.mips.hardware.InvalidRegisterAccessException
mars.ProcessingException
mars.venus.editors.jeditsyntax.tokenmarker.Token
mars.assembler.Token
mars.assembler.Tokenizer
mars.assembler.TokenList (implements java.lang.Cloneable)
mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker.LineInfo
mars.assembler.TokenTypes
mars.venus.ToolLoader
java.io.Writer (implements java.lang.Appendable, java.io.Closeable, java.io.Flushable)
mars.venus.HardcopyWriter
Interface Hierarchy
mars.mips.dump.DumpFormat
mars.venus.editors.jeditsyntax.InputHandler.MacroRecorder
mars.venus.editors.jeditsyntax.InputHandler.NonRecordable
mars.venus.editors.jeditsyntax.InputHandler.NonRepeatable
mars.venus.editors.jeditsyntax.InputHandler.Wrapper
mars.venus.editors.MARSTextEditingArea
mars.tools.MarsTool
mars.mips.instructions.SimulationCode
mars.simulator.Simulator.StopListener
mars.mips.instructions.syscalls.Syscall
mars.venus.editors.jeditsyntax.TextAreaPainter.Highlight
mars.assembler.TranslationCode
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Generated Documentation (Untitled)
Frame Alert
This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client.
Link toNon-frame version.
Mars
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Class Mars
java.lang.Object
Mars
public class Mars
extends Object
Portal to Mars
Author:
Pete Sanderson
Constructor Summary
Mars()
Method Summary
static void main(String[] args)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
Mars
public Mars()
Method Detail
main
public static void main(String[] args)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Overview List
All Classes
Packages
mars
mars.assembler
mars.mips.dump
mars.mips.hardware
mars.mips.instructions
mars.mips.instructions.syscalls
mars.simulator
mars.tools
mars.util
mars.venus
mars.venus.editors
mars.venus.editors.generic
mars.venus.editors.jeditsyntax
mars.venus.editors.jeditsyntax.tokenmarker
All Classes
All Classes
AbstractDumpFormat
AbstractFontSettingDialog
AbstractMarsToolAndApplication
AbstractSyscall
AccessNotice
AddressErrorException
AsciiTextDumpFormat
Assembler
BackStepper
BasicInstruction
BasicInstructionFormat
BHTableModel
BHTEntry
BHTSimGUI
BHTSimulator
Binary
BinaryDumpFormat
BinaryTextDumpFormat
BitmapDisplay
CacheSimulator
Coprocessor0
Coprocessor0Window
Coprocessor1
Coprocessor1Window
DataSegmentWindow
DataTypes
DefaultInputHandler
DelayedBranch
DigitalLabSim
Directives
DumpFormat
DumpFormatLoader
EditCopyAction
EditCutAction
EditFindReplaceAction
Editor
EditorFont
EditPane
EditPasteAction
EditRedoAction
EditSelectAllAction
EditTabbedPane
EditUndoAction
ErrorList
ErrorMessage
Exceptions
ExecutePane
ExtendedInstruction
FileCloseAction
FileCloseAllAction
FileDumpMemoryAction
FileExitAction
FilenameFinder
FileNewAction
FileOpenAction
FilePrintAction
FileSaveAction
FileSaveAllAction
FileSaveAsAction
FileStatus
FloatRepresentation
GenericTextArea
Globals
GuiAction
HardcopyWriter
HardcopyWriter.PrintCanceledException
HelpAboutAction
HelpHelpAction
HexTextDumpFormat
InputHandler
InputHandler.backspace
InputHandler.backspace_word
InputHandler.clip_copy
InputHandler.clip_cut
InputHandler.clip_paste
InputHandler.delete
InputHandler.delete_word
InputHandler.document_end
InputHandler.document_home
InputHandler.end
InputHandler.home
InputHandler.insert_break
InputHandler.insert_char
InputHandler.insert_tab
InputHandler.MacroRecorder
InputHandler.next_char
InputHandler.next_line
InputHandler.next_page
InputHandler.next_word
InputHandler.NonRecordable
InputHandler.NonRepeatable
InputHandler.overwrite
InputHandler.prev_char
InputHandler.prev_line
InputHandler.prev_page
InputHandler.prev_word
InputHandler.repeat
InputHandler.select_all
InputHandler.toggle_rect
InputHandler.Wrapper
Instruction
InstructionCounter
InstructionSet
InstructionStatistics
IntelHexDumpFormat
IntroToTools
InvalidRegisterAccessException
JEditBasedTextArea
JEditTextArea
KeyboardAndDisplaySimulator
KeywordMap
LabelsWindow
Macro
MacroPool
MainPane
Mars
MarsBot
MarsLaunch
MarsSplashScreen
MARSTextEditingArea
MarsTool
Memory
MemoryAccessNotice
MemoryConfiguration
MemoryConfigurations
MemoryDump
MemoryReferenceVisualization
MessagesPane
MIFDumpFormat
MIPSprogram
MIPSTokenMarker
NumberDisplayBaseChooser
OperandFormat
PopupHelpItem
PopupListener
ProcessingException
ProgramArgumentList
ProgramStatement
PropertiesFile
RandomStreams
Register
RegisterAccessNotice
RegisterFile
RegistersPane
RegistersWindow
RepeatButton
RunAssembleAction
RunBackstepAction
RunClearBreakpointsAction
RunGoAction
RunPauseAction
RunResetAction
RunSpeedPanel
RunStepAction
RunStopAction
RunToggleBreakpointsAction
ScavengerHunt
ScreenMagnifier
SegmentWindowDumpFormat
Settings
SettingsAddressDisplayBaseAction
SettingsAssembleAllAction
SettingsAssembleOnOpenAction
SettingsDelayedBranchingAction
SettingsEditorAction
SettingsExceptionHandlerAction
SettingsExtendedAction
SettingsHighlightingAction
SettingsLabelAction
SettingsMemoryConfigurationAction
SettingsPopupInputAction
SettingsProgramArgumentsAction
SettingsSelfModifyingCodeAction
SettingsStartAtMainAction
SettingsValueDisplayBaseAction
SettingsWarningsAreErrorsAction
SimulationCode
Simulator
Simulator.StopListener
SimulatorNotice
SourceLine
SwingWorker
Symbol
SymbolTable
SyntaxDocument
SyntaxStyle
SyntaxUtilities
Syscall
SyscallClose
SyscallConfirmDialog
SyscallExit
SyscallExit2
SyscallInputDialogDouble
SyscallInputDialogFloat
SyscallInputDialogInt
SyscallInputDialogString
SyscallMessageDialog
SyscallMessageDialogDouble
SyscallMessageDialogFloat
SyscallMessageDialogInt
SyscallMessageDialogString
SyscallMidiOut
SyscallMidiOutSync
SyscallNumberOverride
SyscallOpen
SyscallPrintChar
SyscallPrintDouble
SyscallPrintFloat
SyscallPrintInt
SyscallPrintIntBinary
SyscallPrintIntHex
SyscallPrintIntUnsigned
SyscallPrintString
SyscallRandDouble
SyscallRandFloat
SyscallRandInt
SyscallRandIntRange
SyscallRandSeed
SyscallRead
SyscallReadChar
SyscallReadDouble
SyscallReadFloat
SyscallReadInt
SyscallReadString
SyscallSbrk
SyscallSleep
SyscallTime
SyscallWrite
SystemIO
TextAreaDefaults
TextAreaPainter
TextAreaPainter.Highlight
TextSegmentWindow
TextUtilities
Token
Token
Tokenizer
TokenList
TokenMarker
TokenTypes
ToolAction
ToolLoader
TranslationCode
VenusUI
Serialized Form
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Serialized Form
Package mars
Class mars.MarsSplashScreen extends JWindow implements Serializable
Serialized Fields
duration
int duration
Class mars.ProcessingException extends Exception implements Serializable
Serialized Fields
errs
ErrorList errs
Package mars.mips.hardware
Class mars.mips.hardware.AddressErrorException extends Exception implements Serializable
Serialized Fields
address
int address
type
int type
Class mars.mips.hardware.InvalidRegisterAccessException extends Exception implements Serializable
Serialized Fields
errs
ErrorList errs
Package mars.tools
Class mars.tools.AbstractMarsToolAndApplication extends JFrame implements Serializable
Serialized Fields
isBeingUsedAsAMarsTool
boolean isBeingUsedAsAMarsTool
thisMarsApp
AbstractMarsToolAndApplication thisMarsApp
dialog
JDialog dialog
theWindow
Window theWindow
headingLabel
JLabel headingLabel
title
String title
heading
String heading
emptyBorder
EmptyBorder emptyBorder
backgroundColor
Color backgroundColor
lowMemoryAddress
int lowMemoryAddress
highMemoryAddress
int highMemoryAddress
observing
boolean observing
mostRecentlyOpenedFile
File mostRecentlyOpenedFile
interactiveGUIUpdater
Runnable interactiveGUIUpdater
operationStatusMessages
mars.tools.AbstractMarsToolAndApplication.MessageField operationStatusMessages
openFileButton
JButton openFileButton
assembleRunButton
JButton assembleRunButton
stopButton
JButton stopButton
multiFileAssemble
boolean multiFileAssemble
connectButton
AbstractMarsToolAndApplication.ConnectButton connectButton
Class mars.tools.AbstractMarsToolAndApplication.ConnectButton extends JButton implements Serializable
Class mars.tools.BHTableModel extends AbstractTableModel implements Serializable
Serialized Fields
m_entries
Vector
vector holding the entries of the BHT
m_entryCnt
int m_entryCnt
number of entries in the BHT
m_historySize
int m_historySize
number of past branch events to remember
m_columnNames
String[] m_columnNames
name of the table columns
m_columnClasses
Class
type of the table columns
Class mars.tools.BHTSimGUI extends JPanel implements Serializable
Serialized Fields
m_tfInstruction
JTextField m_tfInstruction
text field presenting the most recent branch instruction
m_tfAddress
JTextField m_tfAddress
text field representing the address of the most recent branch instruction
m_tfIndex
JTextField m_tfIndex
text field representing the resulting BHT index of the branch instruction
m_cbBHTentries
JComboBox m_cbBHTentries
combo box for selecting the number of BHT entries
m_cbBHThistory
JComboBox m_cbBHThistory
combo box for selecting the history size
m_cbBHTinitVal
JComboBox m_cbBHTinitVal
combo box for selecting the initial value
m_tabBHT
JTable m_tabBHT
the table representing the BHT
m_taLog
JTextArea m_taLog
text field for log output
Class mars.tools.BHTSimulator extends AbstractMarsToolAndApplication implements Serializable
Serialized Fields
m_gui
BHTSimGUI m_gui
the GUI of the BHT simulator
m_bhtModel
BHTableModel m_bhtModel
the model of the BHT
m_pendingBranchInstAddress
int m_pendingBranchInstAddress
state variable that indicates that the last instruction was a branch instruction (if address != 0) or not (address == 0)
m_lastBranchTaken
boolean m_lastBranchTaken
state variable that signals if the last branch was taken
Class mars.tools.BitmapDisplay extends AbstractMarsToolAndApplication implements Serializable
Serialized Fields
visualizationUnitPixelWidthSelector
JComboBox visualizationUnitPixelWidthSelector
visualizationUnitPixelHeightSelector
JComboBox visualizationUnitPixelHeightSelector
visualizationPixelWidthSelector
JComboBox visualizationPixelWidthSelector
visualizationPixelHeightSelector
JComboBox visualizationPixelHeightSelector
displayBaseAddressSelector
JComboBox displayBaseAddressSelector
drawingArea
Graphics drawingArea
canvas
JPanel canvas
results
JPanel results
emptyBorder
EmptyBorder emptyBorder
countFonts
Font countFonts
backgroundColor
Color backgroundColor
visualizationUnitPixelWidthChoices
String[] visualizationUnitPixelWidthChoices
defaultVisualizationUnitPixelWidthIndex
int defaultVisualizationUnitPixelWidthIndex
visualizationUnitPixelHeightChoices
String[] visualizationUnitPixelHeightChoices
defaultVisualizationUnitPixelHeightIndex
int defaultVisualizationUnitPixelHeightIndex
displayAreaPixelWidthChoices
String[] displayAreaPixelWidthChoices
defaultDisplayWidthIndex
int defaultDisplayWidthIndex
displayAreaPixelHeightChoices
String[] displayAreaPixelHeightChoices
defaultDisplayHeightIndex
int defaultDisplayHeightIndex
unitPixelWidth
int unitPixelWidth
unitPixelHeight
int unitPixelHeight
displayAreaWidthInPixels
int displayAreaWidthInPixels
displayAreaHeightInPixels
int displayAreaHeightInPixels
displayBaseAddressChoices
String[] displayBaseAddressChoices
displayBaseAddresses
int[] displayBaseAddresses
defaultBaseAddressIndex
int defaultBaseAddressIndex
baseAddress
int baseAddress
theGrid
mars.tools.BitmapDisplay.Grid theGrid
Class mars.tools.CacheSimulator extends AbstractMarsToolAndApplication implements Serializable
Serialized Fields
cacheBlockSizeSelector
JComboBox cacheBlockSizeSelector
cacheBlockCountSelector
JComboBox cacheBlockCountSelector
cachePlacementSelector
JComboBox cachePlacementSelector
cacheReplacementSelector
JComboBox cacheReplacementSelector
cacheSetSizeSelector
JComboBox cacheSetSizeSelector
memoryAccessCountDisplay
JTextField memoryAccessCountDisplay
cacheHitCountDisplay
JTextField cacheHitCountDisplay
cacheMissCountDisplay
JTextField cacheMissCountDisplay
replacementPolicyDisplay
JTextField replacementPolicyDisplay
cachableAddressesDisplay
JTextField cachableAddressesDisplay
cacheSizeDisplay
JTextField cacheSizeDisplay
cacheHitRateDisplay
JProgressBar cacheHitRateDisplay
animations
mars.tools.CacheSimulator.Animation animations
logPanel
JPanel logPanel
logScroll
JScrollPane logScroll
logText
JTextArea logText
logShow
JCheckBox logShow
emptyBorder
EmptyBorder emptyBorder
countFonts
Font countFonts
backgroundColor
Color backgroundColor
cacheBlockSizeChoicesInt
int[] cacheBlockSizeChoicesInt
cacheBlockCountChoicesInt
int[] cacheBlockCountChoicesInt
cacheBlockSizeChoices
String[] cacheBlockSizeChoices
cacheBlockCountChoices
String[] cacheBlockCountChoices
placementPolicyChoices
String[] placementPolicyChoices
DIRECT
int DIRECT
FULL
int FULL
SET
int SET
replacementPolicyChoices
String[] replacementPolicyChoices
LRU
int LRU
RANDOM
int RANDOM
cacheSetSizeChoices
String[] cacheSetSizeChoices
defaultCacheBlockSizeIndex
int defaultCacheBlockSizeIndex
defaultCacheBlockCountIndex
int defaultCacheBlockCountIndex
defaultPlacementPolicyIndex
int defaultPlacementPolicyIndex
defaultReplacementPolicyIndex
int defaultReplacementPolicyIndex
defaultCacheSetSizeIndex
int defaultCacheSetSizeIndex
theCache
mars.tools.CacheSimulator.AbstractCache theCache
memoryAccessCount
int memoryAccessCount
cacheHitCount
int cacheHitCount
cacheMissCount
int cacheMissCount
cacheHitRate
double cacheHitRate
randu
Random randu
Class mars.tools.DigitalLabSim extends AbstractMarsToolAndApplication implements Serializable
Serialized Fields
sevenSegPanel
DigitalLabSim.SevenSegmentPanel sevenSegPanel
hexaKeyPanel
DigitalLabSim.HexaKeyboard hexaKeyPanel
Class mars.tools.DigitalLabSim.HexaKeyboard extends JPanel implements Serializable
Serialized Fields
button
JButton[] button
Class mars.tools.DigitalLabSim.SevenSegmentDisplay extends JComponent implements Serializable
Serialized Fields
aff
char aff
Class mars.tools.DigitalLabSim.SevenSegmentPanel extends JPanel implements Serializable
Serialized Fields
display
DigitalLabSim.SevenSegmentDisplay[] display
Class mars.tools.FloatRepresentation extends AbstractMarsToolAndApplication implements Serializable
Serialized Fields
attachedRegister
Register attachedRegister
fpRegisters
Register[] fpRegisters
thisFloatTool
FloatRepresentation thisFloatTool
binarySignDecoratedDisplay
JPanel binarySignDecoratedDisplay
binaryExponentDecoratedDisplay
JPanel binaryExponentDecoratedDisplay
binaryFractionDecoratedDisplay
JPanel binaryFractionDecoratedDisplay
hexDisplay
JTextField hexDisplay
decimalDisplay
JTextField decimalDisplay
binarySignDisplay
JTextField binarySignDisplay
binaryExponentDisplay
JTextField binaryExponentDisplay
binaryFractionDisplay
JTextField binaryFractionDisplay
expansionDisplay
JLabel expansionDisplay
significandLabel
JLabel significandLabel
binaryToDecimalFormulaGraphic
mars.tools.FloatRepresentation.BinaryToDecimalFormulaGraphic binaryToDecimalFormulaGraphic
instructions
mars.tools.FloatRepresentation.InstructionsPane instructions
defaultInstructions
String defaultInstructions
Class mars.tools.InstructionCounter extends AbstractMarsToolAndApplication implements Serializable
Serialized Fields
counter
int counter
Number of instructions executed until now.
counterField
JTextField counterField
counterR
int counterR
Number of instructions of type R.
counterRField
JTextField counterRField
progressbarR
JProgressBar progressbarR
counterI
int counterI
Number of instructions of type I.
counterIField
JTextField counterIField
progressbarI
JProgressBar progressbarI
counterJ
int counterJ
Number of instructions of type J.
counterJField
JTextField counterJField
progressbarJ
JProgressBar progressbarJ
lastAddress
int lastAddress
The last address we saw. We ignore it because the only way for a
program to execute twice the same instruction is to enter an infinite
loop, which is not insteresting in the POV of counting instructions.
Class mars.tools.InstructionStatistics extends AbstractMarsToolAndApplication implements Serializable
Serialized Fields
m_tfTotalCounter
JTextField m_tfTotalCounter
text field for visualizing the total number of instructions processed
m_tfCounters
JTextField[] m_tfCounters
array of text field – one for each instruction category
m_pbCounters
JProgressBar[] m_pbCounters
array of progress pars – one for each instruction category
m_totalCounter
int m_totalCounter
counter for the total number of instructions processed
m_counters
int[] m_counters
array of counter variables – one for each instruction category
m_categoryLabels
String[] m_categoryLabels
names of the instruction categories as array
lastAddress
int lastAddress
The last address we saw. We ignore it because the only way for a
program to execute twice the same instruction is to enter an infinite
loop, which is not insteresting in the POV of counting instructions.
Class mars.tools.IntroToTools extends AbstractMarsToolAndApplication implements Serializable
Class mars.tools.KeyboardAndDisplaySimulator extends AbstractMarsToolAndApplication implements Serializable
Serialized Fields
delayTechniques
mars.tools.KeyboardAndDisplaySimulator.TransmitterDelayTechnique[] delayTechniques
countingInstructions
boolean countingInstructions
instructionCount
int instructionCount
transmitDelayInstructionCountLimit
int transmitDelayInstructionCountLimit
currentDelayInstructionLimit
int currentDelayInstructionLimit
characterToDisplay
char characterToDisplay
displayAfterDelay
boolean displayAfterDelay
keyboardAndDisplay
JPanel keyboardAndDisplay
displayScrollPane
JScrollPane displayScrollPane
display
JTextArea display
displayPanel
JPanel displayPanel
displayOptions
JPanel displayOptions
delayTechniqueChooser
JComboBox delayTechniqueChooser
delayLengthPanel
mars.tools.KeyboardAndDisplaySimulator.DelayLengthPanel delayLengthPanel
delayLengthSlider
JSlider delayLengthSlider
displayAfterDelayCheckBox
JCheckBox displayAfterDelayCheckBox
keyboardPanel
JPanel keyboardPanel
keyAccepterScrollPane
JScrollPane keyAccepterScrollPane
keyEventAccepter
JTextArea keyEventAccepter
fontButton
JButton fontButton
defaultFont
Font defaultFont
Class mars.tools.MemoryReferenceVisualization extends AbstractMarsToolAndApplication implements Serializable
Serialized Fields
wordsPerUnitSelector
JComboBox wordsPerUnitSelector
visualizationUnitPixelWidthSelector
JComboBox visualizationUnitPixelWidthSelector
visualizationUnitPixelHeightSelector
JComboBox visualizationUnitPixelHeightSelector
visualizationPixelWidthSelector
JComboBox visualizationPixelWidthSelector
visualizationPixelHeightSelector
JComboBox visualizationPixelHeightSelector
displayBaseAddressSelector
JComboBox displayBaseAddressSelector
drawHashMarksSelector
JCheckBox drawHashMarksSelector
drawingArea
Graphics drawingArea
canvas
JPanel canvas
results
JPanel results
emptyBorder
EmptyBorder emptyBorder
countFonts
Font countFonts
backgroundColor
Color backgroundColor
wordsPerUnitChoices
String[] wordsPerUnitChoices
defaultWordsPerUnitIndex
int defaultWordsPerUnitIndex
visualizationUnitPixelWidthChoices
String[] visualizationUnitPixelWidthChoices
defaultVisualizationUnitPixelWidthIndex
int defaultVisualizationUnitPixelWidthIndex
visualizationUnitPixelHeightChoices
String[] visualizationUnitPixelHeightChoices
defaultVisualizationUnitPixelHeightIndex
int defaultVisualizationUnitPixelHeightIndex
displayAreaPixelWidthChoices
String[] displayAreaPixelWidthChoices
defaultDisplayWidthIndex
int defaultDisplayWidthIndex
displayAreaPixelHeightChoices
String[] displayAreaPixelHeightChoices
defaultDisplayHeightIndex
int defaultDisplayHeightIndex
defaultDrawHashMarks
boolean defaultDrawHashMarks
unitPixelWidth
int unitPixelWidth
unitPixelHeight
int unitPixelHeight
wordsPerUnit
int wordsPerUnit
visualizationAreaWidthInPixels
int visualizationAreaWidthInPixels
visualizationAreaHeightInPixels
int visualizationAreaHeightInPixels
defaultCounterColors
mars.tools.MemoryReferenceVisualization.CounterColor[] defaultCounterColors
countTable
int[] countTable
COUNT_INDEX_INIT
int COUNT_INDEX_INIT
displayBaseAddressChoices
String[] displayBaseAddressChoices
displayBaseAddresses
int[] displayBaseAddresses
defaultBaseAddressIndex
int defaultBaseAddressIndex
baseAddress
int baseAddress
theGrid
mars.tools.MemoryReferenceVisualization.Grid theGrid
counterColorScale
mars.tools.MemoryReferenceVisualization.CounterColorScale counterColorScale
Package mars.venus
Class mars.venus.AbstractFontSettingDialog extends JDialog implements Serializable
Serialized Fields
editorDialog
JDialog editorDialog
fontFamilySelector
JComboBox fontFamilySelector
fontStyleSelector
JComboBox fontStyleSelector
fontSizeSelector
JSlider fontSizeSelector
fontSizeSpinSelector
JSpinner fontSizeSpinSelector
fontSample
JLabel fontSample
currentFont
Font currentFont
initialFontFamily
String initialFontFamily
initialFontStyle
String initialFontStyle
initialFontSize
String initialFontSize
Class mars.venus.Coprocessor0Window extends JPanel implements Serializable
Serialized Fields
tableData
Object[][] tableData
highlighting
boolean highlighting
highlightRow
int highlightRow
executePane
ExecutePane executePane
rowGivenRegNumber
int[] rowGivenRegNumber
Class mars.venus.Coprocessor1Window extends JPanel implements Serializable
Serialized Fields
tableData
Object[][] tableData
highlighting
boolean highlighting
highlightRow
int highlightRow
executePane
ExecutePane executePane
conditionFlagCheckBox
JCheckBox[] conditionFlagCheckBox
Class mars.venus.DataSegmentWindow extends JInternalFrame implements Serializable
Serialized Fields
dataTableScroller
JScrollPane dataTableScroller
contentPane
Container contentPane
tablePanel
JPanel tablePanel
dataButton
JButton dataButton
nextButton
JButton nextButton
prevButton
JButton prevButton
stakButton
JButton stakButton
globButton
JButton globButton
heapButton
JButton heapButton
kernButton
JButton kernButton
extnButton
JButton extnButton
mmioButton
JButton mmioButton
textButton
JButton textButton
asciiDisplayCheckBox
JCheckBox asciiDisplayCheckBox
addressHighlighting
boolean addressHighlighting
asciiDisplay
boolean asciiDisplay
addressRow
int addressRow
addressColumn
int addressColumn
addressRowFirstAddress
int addressRowFirstAddress
settings
Settings settings
firstAddress
int firstAddress
homeAddress
int homeAddress
userOrKernelMode
boolean userOrKernelMode
baseAddressSelector
JComboBox baseAddressSelector
displayBaseAddressChoices
String[] displayBaseAddressChoices
displayBaseAddresses
int[] displayBaseAddresses
defaultBaseAddressIndex
int defaultBaseAddressIndex
baseAddressButtons
JButton[] baseAddressButtons
displayBaseAddressArray
int[] displayBaseAddressArray
descriptions
String[] descriptions
Class mars.venus.EditCopyAction extends GuiAction implements Serializable
Class mars.venus.EditCutAction extends GuiAction implements Serializable
Class mars.venus.EditFindReplaceAction extends GuiAction implements Serializable
Serialized Fields
findReplaceDialog
JDialog findReplaceDialog
Class mars.venus.EditPane extends JPanel implements Serializable
Serialized Fields
sourceCode
MARSTextEditingArea sourceCode
mainUI
VenusUI mainUI
currentDirectoryPath
String currentDirectoryPath
caretPositionLabel
JLabel caretPositionLabel
showLineNumbers
JCheckBox showLineNumbers
lineNumbers
JLabel lineNumbers
isCompoundEdit
boolean isCompoundEdit
compoundEdit
CompoundEdit compoundEdit
fileStatus
FileStatus fileStatus
Class mars.venus.EditPasteAction extends GuiAction implements Serializable
Class mars.venus.EditRedoAction extends GuiAction implements Serializable
Class mars.venus.EditSelectAllAction extends GuiAction implements Serializable
Class mars.venus.EditTabbedPane extends JTabbedPane implements Serializable
Serialized Fields
editTab
EditPane editTab
mainPane
MainPane mainPane
mainUI
VenusUI mainUI
editor
Editor editor
fileOpener
mars.venus.EditTabbedPane.FileOpener fileOpener
Class mars.venus.EditUndoAction extends GuiAction implements Serializable
Class mars.venus.ExecutePane extends JDesktopPane implements Serializable
Serialized Fields
registerValues
RegistersWindow registerValues
coprocessor1Values
Coprocessor1Window coprocessor1Values
coprocessor0Values
Coprocessor0Window coprocessor0Values
dataSegment
DataSegmentWindow dataSegment
textSegment
TextSegmentWindow textSegment
labelValues
LabelsWindow labelValues
mainUI
VenusUI mainUI
valueDisplayBase
NumberDisplayBaseChooser valueDisplayBase
addressDisplayBase
NumberDisplayBaseChooser addressDisplayBase
labelWindowVisible
boolean labelWindowVisible
Class mars.venus.FileCloseAction extends GuiAction implements Serializable
Class mars.venus.FileCloseAllAction extends GuiAction implements Serializable
Class mars.venus.FileDumpMemoryAction extends GuiAction implements Serializable
Serialized Fields
dumpDialog
JDialog dumpDialog
segmentArray
String[] segmentArray
baseAddressArray
int[] baseAddressArray
limitAddressArray
int[] limitAddressArray
highAddressArray
int[] highAddressArray
segmentListArray
String[] segmentListArray
segmentListBaseArray
int[] segmentListBaseArray
segmentListHighArray
int[] segmentListHighArray
segmentListSelector
JComboBox segmentListSelector
formatListSelector
JComboBox formatListSelector
Class mars.venus.FileExitAction extends GuiAction implements Serializable
Class mars.venus.FileNewAction extends GuiAction implements Serializable
Class mars.venus.FileOpenAction extends GuiAction implements Serializable
Serialized Fields
mostRecentlyOpenedFile
File mostRecentlyOpenedFile
fileChooser
JFileChooser fileChooser
fileFilterCount
int fileFilterCount
fileFilterList
ArrayList
listenForUserAddedFileFilter
PropertyChangeListener listenForUserAddedFileFilter
Class mars.venus.FilePrintAction extends GuiAction implements Serializable
Class mars.venus.FileSaveAction extends GuiAction implements Serializable
Class mars.venus.FileSaveAllAction extends GuiAction implements Serializable
Class mars.venus.FileSaveAsAction extends GuiAction implements Serializable
Class mars.venus.GuiAction extends AbstractAction implements Serializable
Serialized Fields
mainUI
VenusUI mainUI
Class mars.venus.HardcopyWriter.PrintCanceledException extends Exception implements Serializable
Class mars.venus.HelpAboutAction extends GuiAction implements Serializable
Class mars.venus.HelpHelpAction extends GuiAction implements Serializable
Class mars.venus.LabelsWindow extends JInternalFrame implements Serializable
Serialized Fields
contentPane
Container contentPane
labelPanel
JPanel labelPanel
dataLabels
JCheckBox dataLabels
textLabels
JCheckBox textLabels
listOfLabelsForSymbolTable
ArrayList
labelsWindow
LabelsWindow labelsWindow
tableSortComparator
Comparator
tableSortingComparators
Comparator
sortState
int sortState
Class mars.venus.MainPane extends JTabbedPane implements Serializable
Serialized Fields
editTab
EditPane editTab
executeTab
ExecutePane executeTab
editTabbedPane
EditTabbedPane editTabbedPane
mainUI
VenusUI mainUI
Class mars.venus.MessagesPane extends JTabbedPane implements Serializable
Serialized Fields
assemble
JTextArea assemble
run
JTextArea run
assembleTab
JPanel assembleTab
runTab
JPanel runTab
Class mars.venus.NumberDisplayBaseChooser extends JCheckBox implements Serializable
Serialized Fields
base
int base
settingMenuItem
JCheckBoxMenuItem settingMenuItem
Class mars.venus.RegistersPane extends JTabbedPane implements Serializable
Serialized Fields
regsTab
RegistersWindow regsTab
cop1Tab
Coprocessor1Window cop1Tab
cop0Tab
Coprocessor0Window cop0Tab
mainUI
VenusUI mainUI
Class mars.venus.RegistersWindow extends JPanel implements Serializable
Serialized Fields
tableData
Object[][] tableData
highlighting
boolean highlighting
highlightRow
int highlightRow
executePane
ExecutePane executePane
Class mars.venus.RepeatButton extends JButton implements Serializable
Serialized Fields
pressed
boolean pressed
The pressed state for this button.
repeatEnabled
boolean repeatEnabled
Flag to indicate that the button should fire events when held.
If false, the button is effectively a plain old JButton, but
there may be times when this feature might wish to be disabled.
timer
Timer timer
The hold-down timer for this button.
initialDelay
int initialDelay
The initial delay for this button. Hold-down time before first
timer firing. In milliseconds.
delay
int delay
The delay between timer firings for this button once the delay
period is past. In milliseconds.
modifiers
int modifiers
Holder of the modifiers used when the mouse pressed the button.
This is used for subsequently fired action events. This may change
after mouse pressed if the user moves the mouse out, releases a key
and then moves the mouse back in.
Class mars.venus.RunAssembleAction extends GuiAction implements Serializable
Class mars.venus.RunBackstepAction extends GuiAction implements Serializable
Serialized Fields
name
String name
executePane
ExecutePane executePane
Class mars.venus.RunClearBreakpointsAction extends GuiAction implements Serializable
Class mars.venus.RunGoAction extends GuiAction implements Serializable
Serialized Fields
name
String name
executePane
ExecutePane executePane
Class mars.venus.RunPauseAction extends GuiAction implements Serializable
Class mars.venus.RunResetAction extends GuiAction implements Serializable
Class mars.venus.RunSpeedPanel extends JPanel implements Serializable
Serialized Fields
speedTable
double[] speedTable
sliderLabel
JLabel sliderLabel
runSpeedSlider
JSlider runSpeedSlider
runSpeedIndex
int runSpeedIndex
Class mars.venus.RunStepAction extends GuiAction implements Serializable
Serialized Fields
name
String name
executePane
ExecutePane executePane
Class mars.venus.RunStopAction extends GuiAction implements Serializable
Class mars.venus.RunToggleBreakpointsAction extends GuiAction implements Serializable
Class mars.venus.SettingsAddressDisplayBaseAction extends GuiAction implements Serializable
Class mars.venus.SettingsAssembleAllAction extends GuiAction implements Serializable
Class mars.venus.SettingsAssembleOnOpenAction extends GuiAction implements Serializable
Class mars.venus.SettingsDelayedBranchingAction extends GuiAction implements Serializable
Class mars.venus.SettingsEditorAction extends GuiAction implements Serializable
Serialized Fields
editorDialog
JDialog editorDialog
fontFamilySelector
JComboBox fontFamilySelector
fontStyleSelector
JComboBox fontStyleSelector
tabSizeSelector
JSlider tabSizeSelector
fontSizeDisplay
JTextField fontSizeDisplay
initialFontFamily
String initialFontFamily
initialFontStyle
String initialFontStyle
initialFontSize
String initialFontSize
Class mars.venus.SettingsExceptionHandlerAction extends GuiAction implements Serializable
Serialized Fields
exceptionHandlerDialog
JDialog exceptionHandlerDialog
exceptionHandlerSetting
JCheckBox exceptionHandlerSetting
exceptionHandlerSelectionButton
JButton exceptionHandlerSelectionButton
exceptionHandlerDisplay
JTextField exceptionHandlerDisplay
initialSelected
boolean initialSelected
initialPathname
String initialPathname
Class mars.venus.SettingsExtendedAction extends GuiAction implements Serializable
Class mars.venus.SettingsHighlightingAction extends GuiAction implements Serializable
Serialized Fields
highlightDialog
JDialog highlightDialog
backgroundButtons
JButton[] backgroundButtons
foregroundButtons
JButton[] foregroundButtons
fontButtons
JButton[] fontButtons
defaultCheckBoxes
JCheckBox[] defaultCheckBoxes
samples
JLabel[] samples
currentNondefaultBackground
Color[] currentNondefaultBackground
currentNondefaultForeground
Color[] currentNondefaultForeground
initialSettingsBackground
Color[] initialSettingsBackground
initialSettingsForeground
Color[] initialSettingsForeground
initialFont
Font[] initialFont
currentFont
Font[] currentFont
currentNondefaultFont
Font[] currentNondefaultFont
dataHighlightButton
JButton dataHighlightButton
registerHighlightButton
JButton registerHighlightButton
currentDataHighlightSetting
boolean currentDataHighlightSetting
initialDataHighlightSetting
boolean initialDataHighlightSetting
currentRegisterHighlightSetting
boolean currentRegisterHighlightSetting
initialRegisterHighlightSetting
boolean initialRegisterHighlightSetting
Class mars.venus.SettingsLabelAction extends GuiAction implements Serializable
Class mars.venus.SettingsMemoryConfigurationAction extends GuiAction implements Serializable
Serialized Fields
configDialog
JDialog configDialog
fontFamilySelector
JComboBox fontFamilySelector
fontStyleSelector
JComboBox fontStyleSelector
fontSizeSelector
JSlider fontSizeSelector
fontSizeDisplay
JTextField fontSizeDisplay
thisAction
SettingsMemoryConfigurationAction thisAction
initialFontFamily
String initialFontFamily
initialFontStyle
String initialFontStyle
initialFontSize
String initialFontSize
Class mars.venus.SettingsPopupInputAction extends GuiAction implements Serializable
Class mars.venus.SettingsProgramArgumentsAction extends GuiAction implements Serializable
Class mars.venus.SettingsSelfModifyingCodeAction extends GuiAction implements Serializable
Class mars.venus.SettingsStartAtMainAction extends GuiAction implements Serializable
Class mars.venus.SettingsValueDisplayBaseAction extends GuiAction implements Serializable
Class mars.venus.SettingsWarningsAreErrorsAction extends GuiAction implements Serializable
Class mars.venus.TextSegmentWindow extends JInternalFrame implements Serializable
Serialized Fields
programArgumentsPanel
JPanel programArgumentsPanel
programArgumentsTextField
JTextField programArgumentsTextField
table
JTable table
tableScroller
JScrollPane tableScroller
data
Object[][] data
intAddresses
int[] intAddresses
addressRows
Hashtable
executeMods
Hashtable
contentPane
Container contentPane
tableModel
mars.venus.TextSegmentWindow.TextTableModel tableModel
tableCellFont
Font tableCellFont
codeHighlighting
boolean codeHighlighting
breakpointsEnabled
boolean breakpointsEnabled
highlightAddress
int highlightAddress
tableModelListener
TableModelListener tableModelListener
inDelaySlot
boolean inDelaySlot
Class mars.venus.ToolAction extends AbstractAction implements Serializable
Serialized Fields
toolClass
Class
Class mars.venus.VenusUI extends JFrame implements Serializable
Serialized Fields
mainUI
VenusUI mainUI
menu
JMenuBar menu
toolbar
JToolBar toolbar
mainPane
MainPane mainPane
registersPane
RegistersPane registersPane
registersTab
RegistersWindow registersTab
coprocessor1Tab
Coprocessor1Window coprocessor1Tab
coprocessor0Tab
Coprocessor0Window coprocessor0Tab
messagesPane
MessagesPane messagesPane
splitter
JSplitPane splitter
horizonSplitter
JSplitPane horizonSplitter
north
JPanel north
frameState
int frameState
editor
Editor editor
file
JMenu file
run
JMenu run
window
JMenu window
help
JMenu help
edit
JMenu edit
settings
JMenu settings
fileNew
JMenuItem fileNew
fileOpen
JMenuItem fileOpen
fileClose
JMenuItem fileClose
fileCloseAll
JMenuItem fileCloseAll
fileSave
JMenuItem fileSave
fileSaveAs
JMenuItem fileSaveAs
fileSaveAll
JMenuItem fileSaveAll
fileDumpMemory
JMenuItem fileDumpMemory
filePrint
JMenuItem filePrint
fileExit
JMenuItem fileExit
editUndo
JMenuItem editUndo
editRedo
JMenuItem editRedo
editCut
JMenuItem editCut
editCopy
JMenuItem editCopy
editPaste
JMenuItem editPaste
editFindReplace
JMenuItem editFindReplace
editSelectAll
JMenuItem editSelectAll
runGo
JMenuItem runGo
runStep
JMenuItem runStep
runBackstep
JMenuItem runBackstep
runReset
JMenuItem runReset
runAssemble
JMenuItem runAssemble
runStop
JMenuItem runStop
runPause
JMenuItem runPause
runClearBreakpoints
JMenuItem runClearBreakpoints
runToggleBreakpoints
JMenuItem runToggleBreakpoints
settingsLabel
JCheckBoxMenuItem settingsLabel
settingsPopupInput
JCheckBoxMenuItem settingsPopupInput
settingsValueDisplayBase
JCheckBoxMenuItem settingsValueDisplayBase
settingsAddressDisplayBase
JCheckBoxMenuItem settingsAddressDisplayBase
settingsExtended
JCheckBoxMenuItem settingsExtended
settingsAssembleOnOpen
JCheckBoxMenuItem settingsAssembleOnOpen
settingsAssembleAll
JCheckBoxMenuItem settingsAssembleAll
settingsWarningsAreErrors
JCheckBoxMenuItem settingsWarningsAreErrors
settingsStartAtMain
JCheckBoxMenuItem settingsStartAtMain
settingsDelayedBranching
JCheckBoxMenuItem settingsDelayedBranching
settingsProgramArguments
JCheckBoxMenuItem settingsProgramArguments
settingsSelfModifyingCode
JCheckBoxMenuItem settingsSelfModifyingCode
settingsExceptionHandler
JMenuItem settingsExceptionHandler
settingsEditor
JMenuItem settingsEditor
settingsHighlighting
JMenuItem settingsHighlighting
settingsMemoryConfiguration
JMenuItem settingsMemoryConfiguration
helpHelp
JMenuItem helpHelp
helpAbout
JMenuItem helpAbout
Undo
JButton Undo
Redo
JButton Redo
Cut
JButton Cut
Copy
JButton Copy
Paste
JButton Paste
FindReplace
JButton FindReplace
SelectAll
JButton SelectAll
New
JButton New
Open
JButton Open
Save
JButton Save
SaveAs
JButton SaveAs
SaveAll
JButton SaveAll
DumpMemory
JButton DumpMemory
JButton Print
Run
JButton Run
Assemble
JButton Assemble
Reset
JButton Reset
Step
JButton Step
Backstep
JButton Backstep
Stop
JButton Stop
Pause
JButton Pause
Help
JButton Help
fileNewAction
Action fileNewAction
fileOpenAction
Action fileOpenAction
fileCloseAction
Action fileCloseAction
fileCloseAllAction
Action fileCloseAllAction
fileSaveAction
Action fileSaveAction
fileSaveAsAction
Action fileSaveAsAction
fileSaveAllAction
Action fileSaveAllAction
fileDumpMemoryAction
Action fileDumpMemoryAction
filePrintAction
Action filePrintAction
fileExitAction
Action fileExitAction
editUndoAction
EditUndoAction editUndoAction
editRedoAction
EditRedoAction editRedoAction
editCutAction
Action editCutAction
editCopyAction
Action editCopyAction
editPasteAction
Action editPasteAction
editFindReplaceAction
Action editFindReplaceAction
editSelectAllAction
Action editSelectAllAction
runAssembleAction
Action runAssembleAction
runGoAction
Action runGoAction
runStepAction
Action runStepAction
runBackstepAction
Action runBackstepAction
runResetAction
Action runResetAction
runStopAction
Action runStopAction
runPauseAction
Action runPauseAction
runClearBreakpointsAction
Action runClearBreakpointsAction
runToggleBreakpointsAction
Action runToggleBreakpointsAction
settingsLabelAction
Action settingsLabelAction
settingsPopupInputAction
Action settingsPopupInputAction
settingsValueDisplayBaseAction
Action settingsValueDisplayBaseAction
settingsAddressDisplayBaseAction
Action settingsAddressDisplayBaseAction
settingsExtendedAction
Action settingsExtendedAction
settingsAssembleOnOpenAction
Action settingsAssembleOnOpenAction
settingsAssembleAllAction
Action settingsAssembleAllAction
settingsWarningsAreErrorsAction
Action settingsWarningsAreErrorsAction
settingsStartAtMainAction
Action settingsStartAtMainAction
settingsProgramArgumentsAction
Action settingsProgramArgumentsAction
settingsDelayedBranchingAction
Action settingsDelayedBranchingAction
settingsExceptionHandlerAction
Action settingsExceptionHandlerAction
settingsEditorAction
Action settingsEditorAction
settingsHighlightingAction
Action settingsHighlightingAction
settingsMemoryConfigurationAction
Action settingsMemoryConfigurationAction
settingsSelfModifyingCodeAction
Action settingsSelfModifyingCodeAction
helpHelpAction
Action helpHelpAction
helpAboutAction
Action helpAboutAction
Package mars.venus.editors.generic
Class mars.venus.editors.generic.GenericTextArea extends JTextArea implements Serializable
Serialized Fields
editPane
EditPane editPane
undoManager
UndoManager undoManager
undoableEditListener
UndoableEditListener undoableEditListener
sourceCode
JTextArea sourceCode
editAreaScrollPane
JScrollPane editAreaScrollPane
isCompoundEdit
boolean isCompoundEdit
compoundEdit
CompoundEdit compoundEdit
Package mars.venus.editors.jeditsyntax
Class mars.venus.editors.jeditsyntax.JEditBasedTextArea extends JEditTextArea implements Serializable
Serialized Fields
editPane
EditPane editPane
undoManager
UndoManager undoManager
undoableEditListener
UndoableEditListener undoableEditListener
isCompoundEdit
boolean isCompoundEdit
compoundEdit
CompoundEdit compoundEdit
sourceCode
JEditBasedTextArea sourceCode
Class mars.venus.editors.jeditsyntax.JEditTextArea extends JComponent implements Serializable
Serialized Fields
lineNumbersVertical
JScrollBar lineNumbersVertical
Creates a new JEditTextArea with the specified settings.
popupMenu
JPopupMenu popupMenu
painter
TextAreaPainter painter
popup
JPopupMenu popup
listenerList
EventListenerList listenerList
caretEvent
mars.venus.editors.jeditsyntax.JEditTextArea.MutableCaretEvent caretEvent
caretBlinks
boolean caretBlinks
caretVisible
boolean caretVisible
blink
boolean blink
editable
boolean editable
caretBlinkRate
int caretBlinkRate
firstLine
int firstLine
visibleLines
int visibleLines
electricScroll
int electricScroll
horizontalOffset
int horizontalOffset
vertical
JScrollBar vertical
horizontal
JScrollBar horizontal
scrollBarsInitialized
boolean scrollBarsInitialized
inputHandler
InputHandler inputHandler
document
SyntaxDocument document
documentHandler
mars.venus.editors.jeditsyntax.JEditTextArea.DocumentHandler documentHandler
lineSegment
Segment lineSegment
selectionStart
int selectionStart
selectionStartLine
int selectionStartLine
selectionEnd
int selectionEnd
selectionEndLine
int selectionEndLine
biasLeft
boolean biasLeft
bracketPosition
int bracketPosition
bracketLine
int bracketLine
magicCaret
int magicCaret
overwrite
boolean overwrite
rectSelect
boolean rectSelect
unredoing
boolean unredoing
Class mars.venus.editors.jeditsyntax.SyntaxDocument extends PlainDocument implements Serializable
Serialized Fields
tokenMarker
TokenMarker tokenMarker
Class mars.venus.editors.jeditsyntax.TextAreaPainter extends JComponent implements Serializable
Serialized Fields
currentLineIndex
int currentLineIndex
currentLineTokens
Token currentLineTokens
currentLine
Segment currentLine
textArea
JEditTextArea textArea
styles
SyntaxStyle[] styles
caretColor
Color caretColor
selectionColor
Color selectionColor
lineHighlightColor
Color lineHighlightColor
bracketHighlightColor
Color bracketHighlightColor
eolMarkerColor
Color eolMarkerColor
blockCaret
boolean blockCaret
lineHighlight
boolean lineHighlight
bracketHighlight
boolean bracketHighlight
paintInvalid
boolean paintInvalid
eolMarkers
boolean eolMarkers
cols
int cols
rows
int rows
tabSize
int tabSize
tabSizeChars
int tabSizeChars
fm
FontMetrics fm
highlights
TextAreaPainter.Highlight highlights
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Index
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
A B C D E F G H I J K L M N O P Q R S T U V W X Y _
A
AbstractDumpFormat – Class in mars.mips.dump
Abstract class for memory dump file formats.
AbstractDumpFormat(String, String, String, String) –
Constructor for class mars.mips.dump.AbstractDumpFormat
Typical constructor.
AbstractFontSettingDialog – Class in mars.venus
Abstract class for a font selection dialog.
AbstractFontSettingDialog(Frame, String, boolean, Font) –
Constructor for class mars.venus.AbstractFontSettingDialog
Create a new font chooser.
AbstractMarsToolAndApplication – Class in mars.tools
An abstract class that provides generic components to facilitate implementation of
a MarsTool and/or stand-alone Mars-based application.
AbstractMarsToolAndApplication(String, String) –
Constructor for class mars.tools.AbstractMarsToolAndApplication
Simple constructor
AbstractMarsToolAndApplication.ConnectButton – Class in mars.tools
AbstractMarsToolAndApplication.ConnectButton() –
Constructor for class mars.tools.AbstractMarsToolAndApplication.ConnectButton
AbstractMarsToolAndApplication.EnterKeyListener – Class in mars.tools
AbstractMarsToolAndApplication.EnterKeyListener(AbstractButton) –
Constructor for class mars.tools.AbstractMarsToolAndApplication.EnterKeyListener
AbstractSyscall – Class in mars.mips.instructions.syscalls
Abstract class that a MIPS syscall system service may extend.
AbstractSyscall(int, String) –
Constructor for class mars.mips.instructions.syscalls.AbstractSyscall
Constructor is provided so subclass may initialize instance variables.
accessIsFromGUI() –
Method in class mars.mips.hardware.AccessNotice
Query whether the access originated from MARS GUI (AWT event queue)
accessIsFromMIPS() –
Method in class mars.mips.hardware.AccessNotice
Query whether the access originated from executing MIPS program
AccessNotice – Class in mars.mips.hardware
Object provided to Observers of runtime access to MIPS memory or registers.
AccessNotice(int) –
Constructor for class mars.mips.hardware.AccessNotice
action() –
Method in class mars.tools.AbstractMarsToolAndApplication
Required MarsTool method to carry out Tool functions.
action() –
Method in class mars.tools.MarsBot
action() –
Method in interface mars.tools.MarsTool
Performs tool functions.
action() –
Method in class mars.tools.ScavengerHunt
action() –
Method in class mars.tools.ScreenMagnifier
actionPerformed(ActionEvent) –
Method in class mars.tools.BHTSimulator
Handles the actions when selecting another value in one of the two combo boxes.
actionPerformed(ActionEvent) –
Method in class mars.venus.Coprocessor1Window
Called when user clicks on a condition flag checkbox.
actionPerformed(ActionEvent) –
Method in class mars.venus.EditCopyAction
actionPerformed(ActionEvent) –
Method in class mars.venus.EditCutAction
actionPerformed(ActionEvent) –
Method in class mars.venus.EditFindReplaceAction
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.backspace
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.backspace_word
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.clip_copy
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.clip_cut
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.clip_paste
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.delete
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.delete_word
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.document_end
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.document_home
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.end
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.home
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.insert_break
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.insert_char
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.insert_tab
actionPerformed(ActionListener, String) –
Method in interface mars.venus.editors.jeditsyntax.InputHandler.MacroRecorder
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.next_char
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.next_line
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.next_page
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.next_word
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.overwrite
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.prev_char
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.prev_line
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.prev_page
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.prev_word
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.repeat
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.select_all
actionPerformed(ActionEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler.toggle_rect
actionPerformed(ActionEvent) –
Method in class mars.venus.EditPasteAction
actionPerformed(ActionEvent) –
Method in class mars.venus.EditRedoAction
Adapted from TextComponentDemo.java in the
Java Tutorial “Text Component Features”
actionPerformed(ActionEvent) –
Method in class mars.venus.EditSelectAllAction
actionPerformed(ActionEvent) –
Method in class mars.venus.EditUndoAction
Adapted from TextComponentDemo.java in the
Java Tutorial “Text Component Features”
actionPerformed(ActionEvent) –
Method in class mars.venus.FileCloseAction
actionPerformed(ActionEvent) –
Method in class mars.venus.FileCloseAllAction
actionPerformed(ActionEvent) –
Method in class mars.venus.FileDumpMemoryAction
actionPerformed(ActionEvent) –
Method in class mars.venus.FileExitAction
Exit MARS, unless one or more files have unsaved edits and user cancels.
actionPerformed(ActionEvent) –
Method in class mars.venus.FileNewAction
Code to create a new document.
actionPerformed(ActionEvent) –
Method in class mars.venus.FileOpenAction
Launch a file chooser for name of file to open
actionPerformed(ActionEvent) –
Method in class mars.venus.FilePrintAction
Uses the HardcopyWriter class developed by David Flanagan for the book
“Java Examples in a Nutshell”.
actionPerformed(ActionEvent) –
Method in class mars.venus.FileSaveAction
saves the file, if not alredy saved it will do a saveAs
actionPerformed(ActionEvent) –
Method in class mars.venus.FileSaveAllAction
actionPerformed(ActionEvent) –
Method in class mars.venus.FileSaveAsAction
actionPerformed(ActionEvent) –
Method in class mars.venus.GuiAction
does nothing by default.
actionPerformed(ActionEvent) –
Method in class mars.venus.HelpAboutAction
actionPerformed(ActionEvent) –
Method in class mars.venus.HelpHelpAction
Displays tabs with categories of information
actionPerformed(ActionEvent) –
Method in class mars.venus.RepeatButton
Handle action events.
actionPerformed(ActionEvent) –
Method in class mars.venus.RunAssembleAction
actionPerformed(ActionEvent) –
Method in class mars.venus.RunBackstepAction
perform next simulated instruction step.
actionPerformed(ActionEvent) –
Method in class mars.venus.RunClearBreakpointsAction
When this option is selected, tell text segment window to clear breakpoints in its table model.
actionPerformed(ActionEvent) –
Method in class mars.venus.RunGoAction
Action to take when GO is selected — run the MIPS program!
actionPerformed(ActionEvent) –
Method in class mars.venus.RunPauseAction
actionPerformed(ActionEvent) –
Method in class mars.venus.RunResetAction
reset GUI components and MIPS resources
actionPerformed(ActionEvent) –
Method in class mars.venus.RunStepAction
perform next simulated instruction step.
actionPerformed(ActionEvent) –
Method in class mars.venus.RunStopAction
actionPerformed(ActionEvent) –
Method in class mars.venus.RunToggleBreakpointsAction
When this option is selected, tell text segment window to clear breakpoints in its table model.
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsAddressDisplayBaseAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsAssembleAllAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsAssembleOnOpenAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsDelayedBranchingAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsEditorAction
When this action is triggered, launch a dialog to view and modify
editor settings.
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsExceptionHandlerAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsExtendedAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsHighlightingAction
When this action is triggered, launch a dialog to view and modify
editor settings.
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsLabelAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsMemoryConfigurationAction
When this action is triggered, launch a dialog to view and modify
editor settings.
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsPopupInputAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsProgramArgumentsAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsSelfModifyingCodeAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsStartAtMainAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsValueDisplayBaseAction
actionPerformed(ActionEvent) –
Method in class mars.venus.SettingsWarningsAreErrorsAction
actionPerformed(ActionEvent) –
Method in class mars.venus.ToolAction
Response when tool’s item selected from menu.
add(Token) –
Method in class mars.assembler.TokenList
Adds a Token object to the end of the list.
add(ErrorMessage) –
Method in class mars.ErrorList
Add new error message to end of list.
add(ErrorMessage, int) –
Method in class mars.ErrorList
Add new error message at specified index position.
add(String, byte) –
Method in class mars.venus.editors.jeditsyntax.KeywordMap
Adds a key-value mapping.
addArg(String) –
Method in class mars.assembler.Macro
addAsObserver() –
Method in class mars.tools.AbstractMarsToolAndApplication
Add this app/tool as an Observer of desired MIPS Observables (memory and registers).
addAsObserver(int, int) –
Method in class mars.tools.AbstractMarsToolAndApplication
Add this app/tool as an Observer of the specified subrange of MIPS memory.
addAsObserver(Register) –
Method in class mars.tools.AbstractMarsToolAndApplication
Add this app/tool as an Observer of the specified MIPS register.
addAsObserver() –
Method in class mars.tools.BHTSimulator
Adds BHTSimulator as observer of the text segment.
addAsObserver() –
Method in class mars.tools.BitmapDisplay
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only.
addAsObserver() –
Method in class mars.tools.DigitalLabSim
addAsObserver() –
Method in class mars.tools.FloatRepresentation
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only.
addAsObserver() –
Method in class mars.tools.InstructionCounter
addAsObserver() –
Method in class mars.tools.InstructionStatistics
registers the tool as observer for the text segment of the MIPS program
addAsObserver() –
Method in class mars.tools.KeyboardAndDisplaySimulator
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only.
addAsObserver() –
Method in class mars.tools.MemoryReferenceVisualization
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only.
addCaretListener(CaretListener) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Adds a caret change listener to this text area.
addConditionFlagClear(int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addConditionFlagSet(int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addCoprocessor0Restore(int, int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addCoprocessor1Restore(int, int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addCustomHighlight(TextAreaPainter.Highlight) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Adds a custom highlight painter.
addDefaultKeyBindings() –
Method in class mars.venus.editors.jeditsyntax.DefaultInputHandler
Sets up the default key bindings.
addDefaultKeyBindings() –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Adds the default key bindings to this input handler.
addDoNothing(int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addKeyBinding(String, ActionListener) –
Method in class mars.venus.editors.jeditsyntax.DefaultInputHandler
Adds a key binding to this input handler.
addKeyBinding(String, ActionListener) –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Adds a key binding to this input handler.
addLabel(String) –
Method in class mars.assembler.Macro
addMemoryRestoreByte(int, int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addMemoryRestoreHalf(int, int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addMemoryRestoreRawWord(int, int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addMemoryRestoreWord(int, int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addObserver(Observer) –
Method in class mars.mips.hardware.Memory
Method to accept registration from observer for any memory address.
addObserver(Observer, int) –
Method in class mars.mips.hardware.Memory
Method to accept registration from observer for specific address.
addObserver(Observer, int, int) –
Method in class mars.mips.hardware.Memory
Method to accept registration from observer for specific address range.
addPCRestore(int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addProgramArgumentsPanel() –
Method in class mars.venus.TextSegmentWindow
addRegisterFileRestore(int, int) –
Method in class mars.simulator.BackStepper
Add a new “back step” (the undo action) to the stack.
addRegistersObserver(Observer) –
Static method in class mars.mips.hardware.Coprocessor0
Each individual register is a separate object and Observable.
addRegistersObserver(Observer) –
Static method in class mars.mips.hardware.Coprocessor1
Each individual register is a separate object and Observable.
addRegistersObserver(Observer) –
Static method in class mars.mips.hardware.RegisterFile
Each individual register is a separate object and Observable.
ADDRESS_EXCEPTION_LOAD –
Static variable in class mars.simulator.Exceptions
ADDRESS_EXCEPTION_STORE –
Static variable in class mars.simulator.Exceptions
AddressErrorException – Exception in mars.mips.hardware
Represents MIPS AddressErrorException.
AddressErrorException(String, int, int) –
Constructor for exception mars.mips.hardware.AddressErrorException
Constructor for the AddressErrorException class
addStopListener(Simulator.StopListener) –
Method in class mars.simulator.Simulator
addSymbol(Token, int, boolean, ErrorList) –
Method in class mars.assembler.SymbolTable
Adds a Symbol object into the array of Symbols.
addToken(int, byte) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Adds a token to the token list.
addUndoableEdit(UndoableEdit) –
Method in class mars.venus.editors.jeditsyntax.SyntaxDocument
Adds an undoable edit to this document’s undo list.
aff –
Variable in class mars.tools.DigitalLabSim.SevenSegmentDisplay
ALIGN –
Static variable in class mars.assembler.Directives
alignToWordBoundary(int) –
Static method in class mars.mips.hardware.Memory
Utility method to align given address to next full word boundary, if not already
aligned.
allocateBytesFromHeap(int) –
Method in class mars.mips.hardware.Memory
Returns the next available word-aligned heap address.
apply(Font) –
Method in class mars.venus.AbstractFontSettingDialog
Apply the given font.
APPLY_TOOL_TIP_TEXT –
Static variable in class mars.venus.SettingsHighlightingAction
ARITHMETIC_OVERFLOW_EXCEPTION –
Static variable in class mars.simulator.Exceptions
ASCII –
Static variable in class mars.assembler.Directives
ASCII –
Static variable in class mars.venus.NumberDisplayBaseChooser
ASCII_NON_PRINT –
Static variable in class mars.Globals
Placeholder for non-printable ASCII codes
ASCII_TABLE –
Static variable in class mars.Globals
Array of strings to display for ASCII codes in ASCII display of data segment.
AsciiTextDumpFormat – Class in mars.mips.dump
Class that represents the “ASCII text” memory dump format.
AsciiTextDumpFormat() –
Constructor for class mars.mips.dump.AsciiTextDumpFormat
Constructor.
ASCIIZ –
Static variable in class mars.assembler.Directives
assemble(MIPSprogram, boolean) –
Method in class mars.assembler.Assembler
Parse and generate machine code for the given MIPS program.
assemble(MIPSprogram, boolean, boolean) –
Method in class mars.assembler.Assembler
Parse and generate machine code for the given MIPS program.
assemble(ArrayList, boolean) –
Method in class mars.assembler.Assembler
Parse and generate machine code for the given MIPS program.
assemble(ArrayList, boolean, boolean) –
Method in class mars.assembler.Assembler
Parse and generate machine code for the given MIPS program.
assemble(ArrayList, boolean) –
Method in class mars.MIPSprogram
Assembles the MIPS source program.
assemble(ArrayList, boolean, boolean) –
Method in class mars.MIPSprogram
Assembles the MIPS source program.
ASSEMBLE_ALL_ENABLED –
Static variable in class mars.Settings
Flag to determine whether only the current editor source file (enabled false) or
all files in its directory (enabled true) will be assembled when assembly is selected.
ASSEMBLE_ON_OPEN_ENABLED –
Static variable in class mars.Settings
Flag to determine whether or not a file is immediately and automatically assembled
upon opening.
Assembler – Class in mars.assembler
An Assembler is capable of assembling a MIPS program.
Assembler() –
Constructor for class mars.assembler.Assembler
AUTO_INDENT –
Static variable in class mars.Settings
Flag to control whether or not language-aware editor will use auto-indent feature
B
BACKSPACE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
BACKSPACE_WORD –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
backStep() –
Method in class mars.simulator.BackStepper
Carry out a “back step”, which will undo the latest execution step.
BackStepper – Class in mars.simulator
Used to “step backward” through execution, undoing each instruction.
BackStepper() –
Constructor for class mars.simulator.BackStepper
Create a fresh BackStepper.
backSteppingEnabled() –
Method in class mars.MIPSprogram
Returns status of BackStepper associated with this program.
BARE_MACHINE_ENABLED –
Static variable in class mars.Settings
Flag to determine whether or not program being assembled is limited to
using register numbers instead of names.
BasicInstruction – Class in mars.mips.instructions
Class to represent a basic instruction in the MIPS instruction set.
BasicInstruction(String, String, BasicInstructionFormat, String, SimulationCode) –
Constructor for class mars.mips.instructions.BasicInstruction
BasicInstruction constructor.
BasicInstruction(String, BasicInstructionFormat, String, SimulationCode) –
Constructor for class mars.mips.instructions.BasicInstruction
BasicInstructionFormat – Class in mars.mips.instructions
These are the MIPS-defined formats of basic machine instructions.
beginCompoundEdit() –
Method in class mars.venus.editors.jeditsyntax.SyntaxDocument
Starts a compound edit that can be undone in one operation.
beginMacro(Token) –
Method in class mars.assembler.MacroPool
This method will be called by parser when reached .macro
directive.
Instantiates a new Macro object and stores it in MacroPool.current
.
BHT_DEFAULT_HISTORY –
Static variable in class mars.tools.BHTSimulator
constant for the default history size
BHT_DEFAULT_INITVAL –
Static variable in class mars.tools.BHTSimulator
constant for the default inital value
BHT_DEFAULT_SIZE –
Static variable in class mars.tools.BHTSimulator
constant for the default size of the BHT
BHT_DO_NOT_TAKE_BRANCH –
Static variable in class mars.tools.BHTSimGUI
constant for the String representing “do not take the branch”
BHT_HEADING –
Static variable in class mars.tools.BHTSimulator
the heading of the tool
BHT_NAME –
Static variable in class mars.tools.BHTSimulator
the name of the tool
BHT_TAKE_BRANCH –
Static variable in class mars.tools.BHTSimGUI
constant for the String representing “take the branch”
BHT_VERSION –
Static variable in class mars.tools.BHTSimulator
the version of the tool
BHTableModel – Class in mars.tools
Simulates the actual functionality of a Branch History Table (BHT).
BHTableModel(int, int, boolean) –
Constructor for class mars.tools.BHTableModel
Constructs a new BHT with given number of entries and history size.
BHTEntry – Class in mars.tools
Represents a single entry of the Branch History Table.
BHTEntry(int, boolean) –
Constructor for class mars.tools.BHTEntry
Constructs a BHT entry with a given history size.
BHTSimGUI – Class in mars.tools
Represents the GUI of the BHT Simulator Tool.
BHTSimGUI() –
Constructor for class mars.tools.BHTSimGUI
Creates the GUI components of the BHT Simulator
The GUI is a subclass of JPanel which is integrated in the GUI of the MARS tool
BHTSimulator – Class in mars.tools
A MARS tool for simulating branch prediction with a Branch History Table (BHT)
BHTSimulator() –
Constructor for class mars.tools.BHTSimulator
Creates a BHT Simulator with given name and heading.
biasLeft –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
BIG_ENDIAN –
Static variable in class mars.mips.hardware.Memory
Constant representing byte order of each memory word.
Binary – Class in mars.util
Some utility methods for working with binary representations.
Binary() –
Constructor for class mars.util.Binary
BinaryDumpFormat – Class in mars.mips.dump
Class that represents the “binary” memory dump format.
BinaryDumpFormat() –
Constructor for class mars.mips.dump.BinaryDumpFormat
Constructor.
binaryStringToHexDigit(String) –
Static method in class mars.util.Binary
Translate String consisting of ‘1’s and ‘0’s into char equivalent of the corresponding
hexadecimal digit.
binaryStringToHexString(String) –
Static method in class mars.util.Binary
Translate String consisting of ‘1’s and ‘0’s into String equivalent of the corresponding
hexadecimal value.
binaryStringToInt(String) –
Static method in class mars.util.Binary
Translate String consisting of ‘1’s and ‘0’s into an int value having that binary representation.
binaryStringToLong(String) –
Static method in class mars.util.Binary
Translate String consisting of ‘1’s and ‘0’s into a long value having that binary representation.
BinaryTextDumpFormat – Class in mars.mips.dump
Class that represents the “binary text” memory dump format.
BinaryTextDumpFormat() –
Constructor for class mars.mips.dump.BinaryTextDumpFormat
Constructor.
BitmapDisplay – Class in mars.tools
Bitmapp display simulator.
BitmapDisplay(String, String) –
Constructor for class mars.tools.BitmapDisplay
Simple constructor, likely used to run a stand-alone bitmap display tool.
BitmapDisplay() –
Constructor for class mars.tools.BitmapDisplay
Simple constructor, likely used by the MARS Tools menu mechanism
bitValue(int, int) –
Static method in class mars.util.Binary
Returns the bit value of the given bit position of the given int value.
bitValue(long, int) –
Static method in class mars.util.Binary
Returns the bit value of the given bit position of the given long value.
blink –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
blinkCaret() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Blinks the caret.
blockCaret –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
blockCaret –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
BOTTOM –
Static variable in class mars.venus.editors.jeditsyntax.JEditTextArea
bracketHighlight –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
bracketHighlight –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
bracketHighlightColor –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
bracketHighlightColor –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
bracketLine –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
bracketPosition –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
BREAKPOINT –
Static variable in class mars.simulator.Simulator
various reasons for simulate to end…
BREAKPOINT_EXCEPTION –
Static variable in class mars.simulator.Exceptions
buildBasicStatementFromBasicInstruction(ErrorList) –
Method in class mars.ProgramStatement
Given specification of BasicInstruction for this operator, build the
corresponding assembly statement in basic assembly format (e.g.
buildButtonAreaMarsTool() –
Method in class mars.tools.AbstractMarsToolAndApplication
The MarsTool default set of controls has one row of 3 buttons.
buildButtonAreaStandAlone() –
Method in class mars.tools.AbstractMarsToolAndApplication
The Mars stand-alone app default set of controls has two rows of controls.
buildConfigurationCollection() –
Static method in class mars.mips.hardware.MemoryConfigurations
buildControlPanel() –
Method in class mars.venus.AbstractFontSettingDialog
buildDialogPanel() –
Method in class mars.venus.AbstractFontSettingDialog
buildDisplayArea() –
Method in class mars.tools.FloatRepresentation
buildHeadingArea() –
Method in class mars.tools.AbstractMarsToolAndApplication
Constructs GUI header as label with default positioning and font.
buildMachineStatementFromBasicStatement(ErrorList) –
Method in class mars.ProgramStatement
Given the current statement in Basic Assembly format (see above), build the
32-bit binary machine code statement.
buildMainDisplayArea() –
Method in class mars.tools.AbstractMarsToolAndApplication
Abstract method that must be instantiated by subclass to build the main display area
of the GUI.
buildMainDisplayArea() –
Method in class mars.tools.BHTSimulator
Creates a GUI and initialize the GUI with the default values.
buildMainDisplayArea() –
Method in class mars.tools.BitmapDisplay
Method that constructs the main display area.
buildMainDisplayArea() –
Method in class mars.tools.CacheSimulator
Method that constructs the main cache simulator display area.
buildMainDisplayArea() –
Method in class mars.tools.DigitalLabSim
buildMainDisplayArea() –
Method in class mars.tools.FloatRepresentation
Method that constructs the main display area.
buildMainDisplayArea() –
Method in class mars.tools.InstructionCounter
buildMainDisplayArea() –
Method in class mars.tools.InstructionStatistics
creates the display area for the tool as required by the API
buildMainDisplayArea() –
Method in class mars.tools.IntroToTools
Implementation of the inherited abstract method to build the main
display area of the GUI.
buildMainDisplayArea() –
Method in class mars.tools.KeyboardAndDisplaySimulator
Method that constructs the main display area.
buildMainDisplayArea() –
Method in class mars.tools.MemoryReferenceVisualization
Method that constructs the main display area.
buildToolsMenu() –
Method in class mars.venus.ToolLoader
Called in VenusUI to build its Tools menu.
button –
Variable in class mars.tools.DigitalLabSim.HexaKeyboard
BYTE –
Static variable in class mars.assembler.Directives
BYTE_SIZE –
Static variable in class mars.assembler.DataTypes
Number of bytes occupied by MIPS byte is 1.
C
CacheSimulator – Class in mars.tools
A data cache simulator.
CacheSimulator(String, String) –
Constructor for class mars.tools.CacheSimulator
Simple constructor, likely used to run a stand-alone cache simulator.
CacheSimulator() –
Constructor for class mars.tools.CacheSimulator
Simple constructor, likely used by the MARS Tools menu mechanism
CANCEL_TOOL_TIP_TEXT –
Static variable in class mars.venus.SettingsHighlightingAction
CARET_BLINK_RATE –
Static variable in class mars.Settings
Caret blink rate in milliseconds, 0 means don’t blink.
caretBlinkRate –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
caretBlinkRate –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
caretBlinks –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
caretBlinks –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
caretColor –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
caretColor –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
caretEvent –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
caretTimer –
Static variable in class mars.venus.editors.jeditsyntax.JEditTextArea
caretUpdate(CaretEvent) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Display caret position on the edit pane.
caretVisible –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
caretVisible –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
CAUSE –
Static variable in class mars.mips.hardware.Coprocessor0
CENTER –
Static variable in class mars.venus.editors.jeditsyntax.JEditTextArea
changeResetValue(int) –
Method in class mars.mips.hardware.Register
Change the register’s reset value; the value to which it will be
set when resetValue() is called.
CHAR_SIZE –
Static variable in class mars.assembler.DataTypes
Number of bytes occupied by MIPS character is 1.
charnum –
Variable in class mars.venus.HardcopyWriter
chars_per_line –
Variable in class mars.venus.HardcopyWriter
chars_per_tab –
Variable in class mars.venus.HardcopyWriter
charwidth –
Variable in class mars.venus.HardcopyWriter
clear() –
Method in class mars.assembler.SymbolTable
Creates a fresh arrayList for a new table.
clear() –
Method in class mars.mips.hardware.Memory
Explicitly clear the contents of memory.
clearAllBreakpoints() –
Method in class mars.venus.TextSegmentWindow
Clears all breakpoints that have been set since last assemble, and
updates the display of the breakpoint column.
clearBit(int, int) –
Static method in class mars.util.Binary
Sets the specified bit of the specified value to 0, and returns the result.
clearConditionFlag(int) –
Static method in class mars.mips.hardware.Coprocessor1
Set condition flag to 0 (false).
clearConditionFlags() –
Static method in class mars.mips.hardware.Coprocessor1
Clear all condition flags (0-7).
clearHighlighting() –
Method in class mars.venus.Coprocessor0Window
Clear highlight background color from any row currently highlighted.
clearHighlighting() –
Method in class mars.venus.Coprocessor1Window
Clear highlight background color from any row currently highlighted.
clearHighlighting() –
Method in class mars.venus.DataSegmentWindow
Clear highlight background color from any cell currently highlighted.
clearHighlighting() –
Method in class mars.venus.RegistersWindow
Clear highlight background color from any cell currently highlighted.
clearPane() –
Method in class mars.venus.ExecutePane
Clears out all components of the Execute tab: text segment
display, data segment display, label display and register display.
clearWindow() –
Method in class mars.venus.Coprocessor0Window
Reset and redisplay registers
clearWindow() –
Method in class mars.venus.Coprocessor1Window
Reset and redisplay registers.
clearWindow() –
Method in class mars.venus.DataSegmentWindow
Removes the table from its frame, typically done when a file is closed.
clearWindow() –
Method in class mars.venus.LabelsWindow
Clear the window
clearWindow() –
Method in class mars.venus.RegistersWindow
clear and redisplay registers
clearWindow() –
Method in class mars.venus.TextSegmentWindow
remove all components
CLIFF_TERMINATION –
Static variable in class mars.simulator.Simulator
CLIP_COPY –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
CLIP_CUT –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
CLIP_PASTE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
clone() –
Method in class mars.assembler.TokenList
Makes clone (shallow copy) of this token list object.
close() –
Method in class mars.venus.Editor
Perform “close” operation on current tab’s file.
close() –
Method in class mars.venus.HardcopyWriter
This is the close( ) method that all Writer subclasses must implement.
CLOSE_TOOL_TIP_TEXT –
Static variable in class mars.venus.SettingsHighlightingAction
closeAll() –
Method in class mars.venus.Editor
Close all currently open files.
closeAllFiles() –
Method in class mars.venus.EditTabbedPane
Carries out all necessary operations to implement
the Close All operation from the File menu.
closeCurrentFile() –
Method in class mars.venus.EditTabbedPane
Carries out all necessary operations to implement
the Close operation from the File menu.
closeDialog() –
Method in class mars.venus.AbstractFontSettingDialog
closeFile(int) –
Static method in class mars.util.SystemIO
Close the file with specified file descriptor
COLON –
Static variable in class mars.assembler.TokenTypes
COLOR_PREDICTION_CORRECT –
Static variable in class mars.tools.BHTSimGUI
constant for the color to signal a correct prediction
COLOR_PREDICTION_INCORRECT –
Static variable in class mars.tools.BHTSimGUI
constant for the color to signal a misprediction
COLOR_PREPREDICTION –
Static variable in class mars.tools.BHTSimGUI
constant for the color that highlights the current BHT entry
cols –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
cols –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
COMMENT –
Static variable in class mars.assembler.TokenTypes
COMMENT1 –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Comment 1 token id.
COMMENT2 –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Comment 2 token id.
commitMacro(Token) –
Method in class mars.assembler.MacroPool
This method will be called by parser when reached .end_macro
directive.
connect() –
Method in class mars.tools.AbstractMarsToolAndApplication.ConnectButton
connectButton –
Variable in class mars.tools.AbstractMarsToolAndApplication
construct() –
Method in class mars.simulator.SwingWorker
Compute the value to be returned by the get method.
convertLineColumnToStreamPosition(int, int) –
Method in class mars.venus.EditPane
Given line and column (position in the line) numbers, calculate
its byte stream position in text being edited.
convertStreamPositionToLineColumn(int) –
Method in class mars.venus.EditPane
Coprocessor0 – Class in mars.mips.hardware
Represents Coprocessor 0.
Coprocessor0() –
Constructor for class mars.mips.hardware.Coprocessor0
Coprocessor0Window – Class in mars.venus
Sets up a window to display registers in the UI.
Coprocessor0Window() –
Constructor for class mars.venus.Coprocessor0Window
Constructor which sets up a fresh window with a table that contains the register values.
Coprocessor1 – Class in mars.mips.hardware
Represents Coprocessor 1, the Floating Point Unit (FPU)
Coprocessor1() –
Constructor for class mars.mips.hardware.Coprocessor1
Coprocessor1Window – Class in mars.venus
Sets up a window to display Coprocessor 1 registers in the Registers pane of the UI.
Coprocessor1Window() –
Constructor for class mars.venus.Coprocessor1Window
Constructor which sets up a fresh window with a table that contains the register values.
copy() –
Method in class mars.venus.editors.jeditsyntax.DefaultInputHandler
Returns a copy of this input handler that shares the same
key bindings.
copy() –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Returns a copy of this input handler that shares the same
key bindings.
copy() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Places the selected text into the clipboard.
copy() –
Method in interface mars.venus.editors.MARSTextEditingArea
copyrightHolders –
Static variable in class mars.Globals
MARS copyright holders
copyrightYears –
Static variable in class mars.Globals
MARS copyright years
copyText() –
Method in class mars.venus.EditPane
copy currently-selected text into clipboard
counter –
Variable in class mars.tools.InstructionCounter
Number of instructions executed until now.
counterI –
Variable in class mars.tools.InstructionCounter
Number of instructions of type I.
counterJ –
Variable in class mars.tools.InstructionCounter
Number of instructions of type J.
counterR –
Variable in class mars.tools.InstructionCounter
Number of instructions of type R.
countObservers() –
Method in class mars.mips.hardware.Memory
Return number of observers
createExampleTokenList() –
Method in class mars.mips.instructions.Instruction
Used to build a token list from the example instruction
provided as constructor argument.
createFontFromStringValues(String, String, String) –
Static method in class mars.util.EditorFont
Creates a new Font object based on the given String specifications.
createMacroPool() –
Method in class mars.MIPSprogram
Instantiates a new MacroPool and sends reference of this
MIPSprogram to it
createParsedList() –
Method in class mars.MIPSprogram
Produces new empty list to hold parsed source code statements.
currentFont –
Variable in class mars.venus.AbstractFontSettingDialog
cut() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Deletes the selected text from the text area and places it
into the clipboard.
cut() –
Method in interface mars.venus.editors.MARSTextEditingArea
cutText() –
Method in class mars.venus.EditPane
cut currently-selected text into clipboard
D
DATA –
Static variable in class mars.assembler.Directives
DATA_SEGMENT_HIGHLIGHTING –
Static variable in class mars.Settings
Flag to control whether or not highlighting is applied to data segment window
DATA_SYMBOL –
Static variable in class mars.assembler.Symbol
dataBaseAddress –
Static variable in class mars.mips.hardware.Memory
base address for storage of non-global static data in data segment: 0x10010000 (from SPIM)
DATASEGMENT_HIGHLIGHT_BACKGROUND –
Static variable in class mars.Settings
RGB color for text segment highlighted background
DATASEGMENT_HIGHLIGHT_FONT –
Static variable in class mars.Settings
Font for text segment highlighted background
DATASEGMENT_HIGHLIGHT_FOREGROUND –
Static variable in class mars.Settings
RGB color for text segment highlighted foreground
dataSegmentBaseAddress –
Static variable in class mars.mips.hardware.Memory
base address for (user) data segment: 0x10000000
dataSegmentLimitAddress –
Static variable in class mars.mips.hardware.Memory
DataSegmentWindow – Class in mars.venus
Represents the Data Segment window, which is a type of JInternalFrame.
DataSegmentWindow(NumberDisplayBaseChooser[]) –
Constructor for class mars.venus.DataSegmentWindow
Constructor for the Data Segment window.
DataTypes – Class in mars.assembler
Information about MIPS data types.
DataTypes() –
Constructor for class mars.assembler.DataTypes
debug –
Static variable in class mars.Globals
Flag to determine whether or not to produce internal debugging information.
DECIMAL –
Static variable in class mars.venus.NumberDisplayBaseChooser
DEFAULT_SIZE –
Static variable in class mars.util.EditorFont
DEFAULT_STATUS_VALUE –
Static variable in class mars.mips.hardware.Coprocessor0
DEFAULT_STYLE_INT –
Static variable in class mars.util.EditorFont
DEFAULT_STYLE_STRING –
Static variable in class mars.util.EditorFont
defaultBooleanSettingsValues –
Static variable in class mars.Settings
Last resort default values for boolean settings; will use only if neither
the Preferences nor the properties file work.
DefaultInputHandler – Class in mars.venus.editors.jeditsyntax
The default input handler.
DefaultInputHandler() –
Constructor for class mars.venus.editors.jeditsyntax.DefaultInputHandler
Creates a new input handler with no key bindings defined.
defaultMaxSteps –
Static variable in class mars.venus.RunGoAction
DELAYED_BRANCHING_ENABLED –
Static variable in class mars.Settings
Flag to determine whether or not delayed branching is in effect at MIPS execution.
DelayedBranch – Class in mars.simulator
Represents a (potential) delayed branch.
DelayedBranch() –
Constructor for class mars.simulator.DelayedBranch
DELETE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
DELETE_WORD –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
deleteAsObserver() –
Method in class mars.tools.AbstractMarsToolAndApplication
Delete this app/tool as an Observer of MIPS Observables (memory and registers).
deleteAsObserver(Register) –
Method in class mars.tools.AbstractMarsToolAndApplication
Delete this app/tool as an Observer of the specified MIPS register
deleteAsObserver() –
Method in class mars.tools.FloatRepresentation
Delete this app/tool as an Observer of the attached register.
deleteLines(int, int) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Informs the token marker that line have been deleted from
the document.
deleteObserver(Observer) –
Method in class mars.mips.hardware.Memory
Remove specified memory observers
deleteObservers() –
Method in class mars.mips.hardware.Memory
Remove all memory observers
deleteRegistersObserver(Observer) –
Static method in class mars.mips.hardware.Coprocessor0
Each individual register is a separate object and Observable.
deleteRegistersObserver(Observer) –
Static method in class mars.mips.hardware.Coprocessor1
Each individual register is a separate object and Observable.
deleteRegistersObserver(Observer) –
Static method in class mars.mips.hardware.RegisterFile
Each individual register is a separate object and Observable.
DELIMITER –
Static variable in class mars.assembler.TokenTypes
description –
Variable in class mars.mips.instructions.Instruction
Description of instruction for display to user
descriptionDetailSeparator –
Static variable in class mars.venus.HelpHelpAction
Separates Instruction name descriptor from detailed (operation) description
in help string.
DigitalLabSim – Class in mars.tools
DigitalLabSim(String, String) –
Constructor for class mars.tools.DigitalLabSim
DigitalLabSim() –
Constructor for class mars.tools.DigitalLabSim
DigitalLabSim.HexaKeyboard – Class in mars.tools
DigitalLabSim.HexaKeyboard() –
Constructor for class mars.tools.DigitalLabSim.HexaKeyboard
DigitalLabSim.HexaKeyboard.EcouteurClick – Class in mars.tools
DigitalLabSim.HexaKeyboard.EcouteurClick(int) –
Constructor for class mars.tools.DigitalLabSim.HexaKeyboard.EcouteurClick
DigitalLabSim.OneSecondCounter – Class in mars.tools
DigitalLabSim.OneSecondCounter() –
Constructor for class mars.tools.DigitalLabSim.OneSecondCounter
DigitalLabSim.SevenSegmentDisplay – Class in mars.tools
DigitalLabSim.SevenSegmentDisplay(char) –
Constructor for class mars.tools.DigitalLabSim.SevenSegmentDisplay
DigitalLabSim.SevenSegmentPanel – Class in mars.tools
DigitalLabSim.SevenSegmentPanel() –
Constructor for class mars.tools.DigitalLabSim.SevenSegmentPanel
DIRECTIVE –
Static variable in class mars.assembler.TokenTypes
Directives – Class in mars.assembler
Class representing MIPS assembler directives.
discardAllUndoableEdits() –
Method in class mars.venus.editors.generic.GenericTextArea
Tell UndoManager to discard all its collected undoable edits.
discardAllUndoableEdits() –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Get rid of any accumulated undoable edits.
discardAllUndoableEdits() –
Method in interface mars.venus.editors.MARSTextEditingArea
discardAllUndoableEdits() –
Method in class mars.venus.EditPane
Get rid of any accumulated undoable edits.
disconnect() –
Method in class mars.tools.AbstractMarsToolAndApplication.ConnectButton
dispatchEventToMenu(KeyEvent) –
Method in class mars.venus.VenusUI
Send keyboard event to menu for possible processing.
display –
Variable in class mars.tools.DigitalLabSim.SevenSegmentPanel
DISPLAY_ADDRESSES_IN_HEX –
Static variable in class mars.Settings
Default setting for displaying addresses and values in hexidecimal in the Execute
pane.
DISPLAY_VALUES_IN_HEX –
Static variable in class mars.Settings
displayCaretPosition(int) –
Method in class mars.venus.EditPane
Update the caret position label on the editor’s border to
display the current line and column.
displayCaretPosition(Point) –
Method in class mars.venus.EditPane
Display cursor coordinates
DIVIDE_BY_ZERO_EXCEPTION –
Static variable in class mars.simulator.Exceptions
document –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
document –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
DOCUMENT_END –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
DOCUMENT_HOME –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
documentChanged(DocumentEvent) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
documentHandler –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
doFindText(String, boolean) –
Method in class mars.venus.editors.generic.GenericTextArea
Finds next occurrence of text in a forward search of a string.
doFindText(String, boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Finds next occurrence of text in a forward search of a string.
doFindText(String, boolean) –
Method in interface mars.venus.editors.MARSTextEditingArea
doFindText(String, boolean) –
Method in class mars.venus.EditPane
Finds next occurrence of text in a forward search of a string.
doReplace(String, String, boolean) –
Method in class mars.venus.editors.generic.GenericTextArea
Finds and replaces next occurrence of text in a string in a forward search.
doReplace(String, String, boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Finds and replaces next occurrence of text in a string in a forward search.
doReplace(String, String, boolean) –
Method in interface mars.venus.editors.MARSTextEditingArea
doReplace(String, String, boolean) –
Method in class mars.venus.EditPane
Finds and replaces next occurrence of text in a string in a forward search.
doReplaceAll(String, String, boolean) –
Method in class mars.venus.editors.generic.GenericTextArea
Finds and replaces ALL occurrences of text in a string in a forward search.
doReplaceAll(String, String, boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Finds and replaces ALL occurrences of text in a string in a forward search.
doReplaceAll(String, String, boolean) –
Method in interface mars.venus.editors.MARSTextEditingArea
doReplaceAll(String, String, boolean) –
Method in class mars.venus.EditPane
Finds and replaces ALL occurrences of text in a string in a forward search.
DOUBLE –
Static variable in class mars.assembler.Directives
DOUBLE_SIZE –
Static variable in class mars.assembler.DataTypes
Number of bytes occupied by MIPS double is 8.
doublewordAligned(int) –
Static method in class mars.mips.hardware.Memory
Utility to determine if given address is doubleword-aligned.
DumpFormat – Interface in mars.mips.dump
Interface for memory dump file formats.
DumpFormatLoader – Class in mars.mips.dump
DumpFormatLoader() –
Constructor for class mars.mips.dump.DumpFormatLoader
dumpMemoryRange(File, int, int) –
Method in class mars.mips.dump.AbstractDumpFormat
Write MIPS memory contents according to the
specification for this format.
dumpMemoryRange(File, int, int) –
Method in class mars.mips.dump.AsciiTextDumpFormat
Interpret MIPS memory contents as ASCII characters.
dumpMemoryRange(File, int, int) –
Method in class mars.mips.dump.BinaryDumpFormat
Write MIPS memory contents in pure binary format.
dumpMemoryRange(File, int, int) –
Method in class mars.mips.dump.BinaryTextDumpFormat
Write MIPS memory contents in binary text format.
dumpMemoryRange(File, int, int) –
Method in interface mars.mips.dump.DumpFormat
Write MIPS memory contents according to the
specification for this format.
dumpMemoryRange(File, int, int) –
Method in class mars.mips.dump.HexTextDumpFormat
Write MIPS memory contents in hexadecimal text format.
dumpMemoryRange(File, int, int) –
Method in class mars.mips.dump.IntelHexDumpFormat
Write MIPS memory contents according to the Memory Initialization File
(MIF) specification.
dumpMemoryRange(File, int, int) –
Method in class mars.mips.dump.MIFDumpFormat
Write MIPS memory contents according to the Memory Initialization File
(MIF) specification.
dumpMemoryRange(File, int, int) –
Method in class mars.mips.dump.SegmentWindowDumpFormat
Write MIPS memory contents in Segment Window format.
dumpTriples –
Static variable in class mars.util.MemoryDump
A list of segmentname/dumpformat/filename triples which should be dumped
E
editable –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
editable –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
EditCopyAction – Class in mars.venus
Action for the Edit -> Copy menu item
EditCopyAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.EditCopyAction
EditCutAction – Class in mars.venus
Action for the Edit -> Cut menu item
EditCutAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.EditCutAction
EDITED –
Static variable in class mars.venus.FileStatus
open/saved edit window with unsaved edits
EditFindReplaceAction – Class in mars.venus
Action for the Edit -> Find/Replace menu item
EditFindReplaceAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.EditFindReplaceAction
Editor – Class in mars.venus
Manage the file being edited.
Editor(VenusUI) –
Constructor for class mars.venus.Editor
Create editor.
EDITOR_CURRENT_LINE_HIGHLIGHTING –
Static variable in class mars.Settings
Flag to control whether or not editor will highlight the line currently being edited
EDITOR_FONT –
Static variable in class mars.Settings
Font for the text editor
EDITOR_LINE_NUMBERS_DISPLAYED –
Static variable in class mars.Settings
Flag to determine whether or not the editor will display line numbers.
EDITOR_POPUP_PREFIX_LENGTH –
Static variable in class mars.Settings
Number of letters to be matched by editor’s instruction guide before popup generated (if popup enabled)
EDITOR_TAB_SIZE –
Static variable in class mars.Settings
Editor tab size in characters.
EditorFont – Class in mars.util
Specialized Font class designed to be used by both the
settings menu methods and the Settings class.
EditorFont() –
Constructor for class mars.util.EditorFont
EditPane – Class in mars.venus
Represents one file opened for editing.
EditPane(VenusUI) –
Constructor for class mars.venus.EditPane
Constructor for the EditPane class.
EditPasteAction – Class in mars.venus
Action for the Edit -> Paste menu item
EditPasteAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.EditPasteAction
EditRedoAction – Class in mars.venus
Action for the Edit -> Redo menu item
EditRedoAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.EditRedoAction
EditSelectAllAction – Class in mars.venus
Action for the Edit -> Copy menu item
EditSelectAllAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.EditSelectAllAction
editsSavedOrAbandoned() –
Method in class mars.venus.Editor
Called by several of the Action objects when there is potential
loss of editing changes.
editsSavedOrAbandoned() –
Method in class mars.venus.EditTabbedPane
Check whether file has unsaved edits and, if so, check with user about saving them.
EditTabbedPane – Class in mars.venus
Tabbed pane for the editor.
EditTabbedPane(VenusUI, Editor, MainPane) –
Constructor for class mars.venus.EditTabbedPane
Constructor for the EditTabbedPane class.
EditUndoAction – Class in mars.venus
Action for the Edit -> Undo menu item
EditUndoAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.EditUndoAction
electricScroll –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
electricScroll –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
empty() –
Method in class mars.simulator.BackStepper
Test whether there are steps that can be undone.
enabled() –
Method in class mars.simulator.BackStepper
Determine whether execution “undo” steps are currently being recorded.
END –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
END –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
The token type, that along with a length of 0
marks the end of the token list.
END_MACRO –
Static variable in class mars.assembler.Directives
endCompoundEdit() –
Method in class mars.venus.editors.jeditsyntax.SyntaxDocument
Ends a compound edit that can be undone in one operation.
ensureCapacity(int) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Ensures that the lineInfo array can contain the
specified index.
eolMarkerColor –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
eolMarkerColor –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
eolMarkers –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
eolMarkers –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
EPC –
Static variable in class mars.mips.hardware.Coprocessor0
equals(Object) –
Method in class mars.assembler.Macro
EQV –
Static variable in class mars.assembler.Directives
ERROR –
Static variable in class mars.assembler.TokenTypes
ERROR –
Static variable in class mars.ErrorMessage
Constant to indicate this message is error not warning
ERROR_MESSAGE_PREFIX –
Static variable in class mars.ErrorList
errorCount() –
Method in class mars.ErrorList
Count of number of error messages in list.
errorLimitExceeded() –
Method in class mars.ErrorList
Check to see if error limit has been exceeded.
ErrorList – Class in mars
Maintains list of generated error messages, regardless of source (tokenizing, parsing,
assembly, execution).
ErrorList() –
Constructor for class mars.ErrorList
Constructor for ErrorList
ErrorMessage – Class in mars
Represents occurrance of an error detected during tokenizing, assembly or simulation.
ErrorMessage(String, int, int, String) –
Constructor for class mars.ErrorMessage
Deprecated. Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
ErrorMessage(String, int, int, String, String) –
Constructor for class mars.ErrorMessage
Deprecated. Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
ErrorMessage(boolean, String, int, int, String, String) –
Constructor for class mars.ErrorMessage
Deprecated. Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
ErrorMessage(MIPSprogram, int, int, String) –
Constructor for class mars.ErrorMessage
Constructor for ErrorMessage.
ErrorMessage(boolean, MIPSprogram, int, int, String) –
Constructor for class mars.ErrorMessage
Constructor for ErrorMessage.
ErrorMessage(ProgramStatement, String) –
Constructor for class mars.ErrorMessage
Constructor for ErrorMessage, to be used for runtime exceptions.
errors() –
Method in exception mars.ProcessingException
Produce the list of error messages.
errorsOccurred() –
Method in class mars.ErrorList
Determine whether error has occured or not.
EVEN_ROW_BACKGROUND –
Static variable in class mars.Settings
RGB color for table even row background (text, data, register displays)
EVEN_ROW_FONT –
Static variable in class mars.Settings
Font for table even row background (text, data, register displays)
EVEN_ROW_FOREGROUND –
Static variable in class mars.Settings
RGB color for table even row foreground (text, data, register displays)
exampleFormat –
Variable in class mars.mips.instructions.Instruction
Example usage of this instruction.
EXCEPTION –
Static variable in class mars.simulator.Simulator
EXCEPTION_HANDLER –
Static variable in class mars.Settings
Current specified exception handler file (a MIPS assembly source file)
EXCEPTION_HANDLER_ENABLED –
Static variable in class mars.Settings
Flag to determine whether the currently selected exception handler source file will
be included in each assembly operation.
EXCEPTION_LEVEL –
Static variable in class mars.mips.hardware.Coprocessor0
exceptionHandlerAddress –
Static variable in class mars.mips.hardware.Memory
starting address for exception handlers: 0x80000180
Exceptions – Class in mars.simulator
Represents an error/interrupt that occurs during execution (simulation).
Exceptions() –
Constructor for class mars.simulator.Exceptions
executeAction(ActionListener, Object, String) –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Executes the specified action, repeating and recording it as
necessary.
ExecutePane – Class in mars.venus
Container for the execution-related windows.
ExecutePane(VenusUI, RegistersWindow, Coprocessor1Window, Coprocessor0Window) –
Constructor for class mars.venus.ExecutePane
initialize the Execute pane with major components
exitCode –
Static variable in class mars.Globals
MARS exit code — useful with SYSCALL 17 when running from command line (not GUI)
EXTENDED_ASSEMBLER_ENABLED –
Static variable in class mars.Settings
Flag to determine whether or not program being assembled is limited to
basic MIPS instructions and formats.
ExtendedInstruction – Class in mars.mips.instructions
ExtendedInstruction represents a MIPS extended (a.k.a pseudo) instruction.
ExtendedInstruction(String, String, String, String) –
Constructor for class mars.mips.instructions.ExtendedInstruction
Constructor for ExtendedInstruction.
ExtendedInstruction(String, String, String) –
Constructor for class mars.mips.instructions.ExtendedInstruction
Constructor for ExtendedInstruction.
ExtendedInstruction(String, String) –
Constructor for class mars.mips.instructions.ExtendedInstruction
Constructor for ExtendedInstruction, where no instruction description or
compact translation is provided.
EXTERN –
Static variable in class mars.assembler.Directives
EXTERNAL_INTERRUPT_DISPLAY –
Static variable in class mars.simulator.Exceptions
EXTERNAL_INTERRUPT_HEXA_KEYBOARD –
Static variable in class mars.tools.DigitalLabSim
EXTERNAL_INTERRUPT_KEYBOARD –
Static variable in class mars.simulator.Exceptions
The exception number is stored in coprocessor 0 cause register ($13)
Note: the codes for External Interrupts have been modified from MIPS
specs in order to encode two pieces of information.
EXTERNAL_INTERRUPT_TIMER –
Static variable in class mars.tools.DigitalLabSim
externalInterruptingDevice –
Static variable in class mars.simulator.Simulator
externBaseAddress –
Static variable in class mars.mips.hardware.Memory
base address for .extern directive: 0x10000000
extractBranchAddress(ProgramStatement) –
Static method in class mars.tools.BHTSimulator
Extracts the target address of the branch.
extractOperator(String) –
Method in class mars.mips.instructions.Instruction
Used by subclass constructors to extract operator mnemonic from the
instruction example.
F
FileCloseAction – Class in mars.venus
Action for the File -> Close menu item
FileCloseAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.FileCloseAction
FileCloseAllAction – Class in mars.venus
Action for the File -> Close All menu item
FileCloseAllAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.FileCloseAllAction
FileDumpMemoryAction – Class in mars.venus
Action for the File -> Save For Dump Memory menu item
FileDumpMemoryAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.FileDumpMemoryAction
fileErrorString –
Static variable in class mars.util.SystemIO
String used for description of file error
FileExitAction – Class in mars.venus
Action for the File -> Exit menu item
FileExitAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.FileExitAction
fileExtensionMatch(String, String) –
Static method in class mars.util.FilenameFinder
Determine if given filename ends with given extension.
fileExtensions –
Static variable in class mars.Globals
List of accepted file extensions for MIPS assembly source files.
FILENAME_PREFIX –
Static variable in class mars.ErrorList
FilenameFinder – Class in mars.util
Utility class to perform necessary file-related search
operations.
FilenameFinder() –
Constructor for class mars.util.FilenameFinder
FileNewAction – Class in mars.venus
Action for the File -> New menu item
FileNewAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.FileNewAction
FileOpenAction – Class in mars.venus
Action for the File -> Open menu item
FileOpenAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.FileOpenAction
FilePrintAction – Class in mars.venus
Action for the File -> Print menu item
FilePrintAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.FilePrintAction
FileSaveAction – Class in mars.venus
Action for the File -> Save menu item
FileSaveAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.FileSaveAction
FileSaveAllAction – Class in mars.venus
Action for the File -> Close All menu item
FileSaveAllAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.FileSaveAllAction
FileSaveAsAction – Class in mars.venus
Action for the File -> Save As menu item
FileSaveAsAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.FileSaveAsAction
FileStatus – Class in mars.venus
Used to store and return information on the status of the current ASM file that
is being edited in the program.
FileStatus() –
Constructor for class mars.venus.FileStatus
Create a FileStatus object with FileStatis.NO_FILE for status and null for file getters.
FileStatus(int, String) –
Constructor for class mars.venus.FileStatus
Create a FileStatus object with given status and file pathname.
findByBinaryCode(int) –
Method in class mars.mips.instructions.InstructionSet
findDumpFormatGivenCommandDescriptor(ArrayList, String) –
Static method in class mars.mips.dump.DumpFormatLoader
findMatchingBracket(Document, int) –
Static method in class mars.venus.editors.jeditsyntax.TextUtilities
Returns the offset of the bracket matching the one at the
specified offset of the document, or -1 if the bracket is
unmatched (or if the character is not a bracket).
findWordEnd(String, int, String) –
Static method in class mars.venus.editors.jeditsyntax.TextUtilities
Locates the end of the word at the specified position.
findWordStart(String, int, String) –
Static method in class mars.venus.editors.jeditsyntax.TextUtilities
Locates the start of the word at the specified position.
finished() –
Method in class mars.simulator.SwingWorker
Called on the event dispatching thread (not on the worker thread)
after the construct method has returned.
fireCaretEvent() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
fireInsertUpdate(DocumentEvent) –
Method in class mars.venus.editors.jeditsyntax.SyntaxDocument
We overwrite this method to update the token marker
state immediately so that any event listeners get a
consistent token marker.
fireRemoveUpdate(DocumentEvent) –
Method in class mars.venus.editors.jeditsyntax.SyntaxDocument
We overwrite this method to update the token marker
state immediately so that any event listeners get a
consistent token marker.
firstLine –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
firstToken –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
The first token in the list.
fixSymbolTableAddress(int, int) –
Method in class mars.assembler.SymbolTable
Fix address in symbol table entry.
FLOAT –
Static variable in class mars.assembler.Directives
FLOAT_SIZE –
Static variable in class mars.assembler.DataTypes
Number of bytes occupied by MIPS float is 4.
FLOATING_POINT_OVERFLOW –
Static variable in class mars.simulator.Exceptions
FLOATING_POINT_UNDERFLOW –
Static variable in class mars.simulator.Exceptions
FloatRepresentation – Class in mars.tools
Tool to help students learn about IEEE 754 representation of 32 bit
floating point values.
FloatRepresentation(String, String) –
Constructor for class mars.tools.FloatRepresentation
Simple constructor, likely used to run a stand-alone memory reference visualizer.
FloatRepresentation() –
Constructor for class mars.tools.FloatRepresentation
Simple constructor, likely used by the MARS Tools menu mechanism
flush() –
Method in class mars.venus.HardcopyWriter
This is the flush( ) method that all Writer subclasses must implement.
fm –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
focusedComponent –
Static variable in class mars.venus.editors.jeditsyntax.JEditTextArea
font –
Variable in class mars.venus.HardcopyWriter
fontsize –
Variable in class mars.venus.HardcopyWriter
formatDoubleNumber(long, int) –
Static method in class mars.venus.NumberDisplayBaseChooser
Produces a string form of a double given a long containing
the 64 bit pattern and the numerical base to use (10 or 16).
formatFloatNumber(int, int) –
Static method in class mars.venus.NumberDisplayBaseChooser
Produces a string form of a float given an integer containing
the 32 bit pattern and the numerical base to use (10 or 16).
formatNumber(int, int) –
Static method in class mars.venus.NumberDisplayBaseChooser
Produces a string form of an integer given the value and the
numerical base to convert it to.
formatNumber(float, int) –
Static method in class mars.venus.NumberDisplayBaseChooser
Produces a string form of a float given the value and the
numerical base to convert it to.
formatNumber(double, int) –
Static method in class mars.venus.NumberDisplayBaseChooser
Produces a string form of a double given the value and the
numerical base to convert it to.
formatNumber(int) –
Method in class mars.venus.NumberDisplayBaseChooser
Produces a string form of a number given the value.
formatUnsignedInteger(int, int) –
Static method in class mars.venus.NumberDisplayBaseChooser
Produces a string form of an unsigned given the value and the
numerical base to convert it to.
formatUnsignedInteger(int) –
Method in class mars.venus.NumberDisplayBaseChooser
Produces a string form of an unsigned integer given the value.
FP_REGISTER_NAME –
Static variable in class mars.assembler.TokenTypes
G
generateErrorAndWarningReport() –
Method in class mars.ErrorList
Produce report containing both warnings and errors, warnings first.
generateErrorReport() –
Method in class mars.ErrorList
Produce error report.
generateWarningReport() –
Method in class mars.ErrorList
Produce warning report.
GENERIC_TEXT_EDITOR –
Static variable in class mars.Settings
Flag to control whether or not to use generic text editor instead of language-aware styled editor
GenericTextArea – Class in mars.venus.editors.generic
GenericTextArea(EditPane, JComponent) –
Constructor for class mars.venus.editors.generic.GenericTextArea
get(int) –
Method in class mars.assembler.TokenList
Returns requested token given position number (starting at 0).
get(int, int) –
Method in class mars.mips.hardware.Memory
Starting at the given word address, read the given number of bytes (max 4).
get() –
Method in class mars.simulator.SwingWorker
Return the value created by the construct method.
get() –
Static method in class mars.venus.FileStatus
Get file status
getAccessType() –
Method in class mars.mips.hardware.AccessNotice
Get the access type: READ or WRITE.
getAction() –
Method in class mars.simulator.SimulatorNotice
Fetch the memory address that was accessed.
getAction(String) –
Static method in class mars.venus.editors.jeditsyntax.InputHandler
Returns a named text area action.
getActionName(ActionListener) –
Static method in class mars.venus.editors.jeditsyntax.InputHandler
Returns the name of the specified text area action.
getActions() –
Static method in class mars.venus.editors.jeditsyntax.InputHandler
Returns an enumeration of all available actions.
getAddress() –
Method in class mars.assembler.Symbol
Returns the address of the the Symbol.
getAddress(String) –
Method in class mars.assembler.SymbolTable
Method to return the address associated with the given label.
getAddress() –
Method in exception mars.mips.hardware.AddressErrorException
Get the erroneous memory address.
getAddress() –
Method in class mars.mips.hardware.MemoryAccessNotice
Fetch the memory address that was accessed.
getAddress() –
Method in class mars.ProgramStatement
Produces Text Segment address where the binary machine statement is stored.
getAddressDisplayBase() –
Method in class mars.venus.ExecutePane
Retrieve the number system base for displaying memory addresses
getAddressDisplayBaseChooser() –
Method in class mars.venus.ExecutePane
Retrieve component used to set numerical base (10 or 16) of address display.
getAddressDisplayBaseMenuItem() –
Method in class mars.venus.VenusUI
Get reference to settings menu item for display base of memory/register values.
getAddressLocalOrGlobal(String) –
Method in class mars.assembler.SymbolTable
Method to return the address associated with the given label.
getAddressOfFirstNull(int, int) –
Method in class mars.mips.hardware.Memory
Look for first “null” memory value in an address range.
getAddressOfFirstNull(int, int) –
Static method in class mars.util.MemoryDump
Look for first “null” memory value in an address range.
getAllFamilies() –
Static method in class mars.util.EditorFont
Obtain an array of all available font family names.
getAllSymbols() –
Method in class mars.assembler.SymbolTable
For obtaining all the Symbols.
getArgs() –
Method in class mars.assembler.Macro
getAsciiNonPrint() –
Static method in class mars.Globals
getAsciiStrings() –
Static method in class mars.Globals
getAssembleAllEnabled() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ALL_ENABLED)
getAssembleOnOpenEnabled() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ON_OPEN_ENABLED)
getAssembleTextArea() –
Method in class mars.venus.MessagesPane
Returns component used to display assembler messages
getAutoIndent() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Constructs string for auto-indent feature.
getBackStepper() –
Method in class mars.MIPSprogram
Returns BackStepper associated with this program.
getBackSteppingEnabled() –
Method in class mars.Settings
Return whether backstepping is permitted at this time.
getBareMachineEnabled() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.BARE_MACHINE_ENABLED)
getBase() –
Method in class mars.venus.NumberDisplayBaseChooser
Retrieve the current number base.
getBase(boolean) –
Static method in class mars.venus.NumberDisplayBaseChooser
Return the number base corresponding to the specified setting.
getBaseAddresses(String[]) –
Static method in class mars.util.MemoryDump
Get the MIPS memory base address(es) of the specified segment name(s).
getBasicAssemblyStatement() –
Method in class mars.ProgramStatement
Produces Basic Assembly statement for this MIPS source statement.
getBasicIntructionTemplateList() –
Method in class mars.mips.instructions.ExtendedInstruction
Get ArrayList of Strings that represent list of templates for
basic instructions generated by this extended instruction.
getBinaryStatement() –
Method in class mars.ProgramStatement
Produces 32-bit binary machine statement as int.
getBooleanSetting(int) –
Method in class mars.Settings
Fetch value of a boolean setting given its identifier.
getBracketHighlightColor() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns the bracket highlight color.
getBracketLine() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the line of the highlighted bracket (the bracket
matching the one before the caret)
getBracketPosition() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the position of the highlighted bracket (the bracket
matching the one before the caret)
getBreakpointCount() –
Method in class mars.venus.TextSegmentWindow
Returns number of breakpoints currently set.
getByte(int) –
Method in class mars.mips.hardware.Memory
Reads specified Memory byte into low order 8 bits of int.
getByte(int, int) –
Static method in class mars.util.Binary
Gets the specified byte of the specified value.
getByteOrder() –
Method in class mars.mips.hardware.Memory
Retrieve memory byte order.
getCallStack() –
Method in class mars.assembler.MacroPool
getCaretBlinkRate() –
Method in class mars.Settings
Retrieve the caret blink rate in milliseconds.
getCaretColor() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns the caret color.
getCaretLine() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the caret line.
getCaretPosition() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the caret position.
getCaretPosition() –
Method in interface mars.venus.editors.MARSTextEditingArea
getCbBHTentries() –
Method in class mars.tools.BHTSimGUI
Returns the combo box for selecting the number of BHT entries.
getCbBHThistory() –
Method in class mars.tools.BHTSimGUI
Returns the combo box for selecting the size of the BHT history.
getCbBHTinitVal() –
Method in class mars.tools.BHTSimGUI
Returns the combo box for selecting the initial value of the BHT
getCharactersPerLine() –
Method in class mars.venus.HardcopyWriter
Return the number of columns of characters that fit on the page
getCodeHighlighting() –
Method in class mars.venus.TextSegmentWindow
Get code highlighting status.
getColor() –
Method in class mars.venus.editors.jeditsyntax.SyntaxStyle
Returns the color specified in this style.
getColorAsHexString() –
Method in class mars.venus.editors.jeditsyntax.SyntaxStyle
Returns the color coded as Stringified 32-bit hex with
Red in bits 16-23, Green in bits 8-15, Blue in bits 0-7
e.g.
getColorSettingByKey(String) –
Method in class mars.Settings
Get Color object for specified settings key.
getColorSettingByPosition(int) –
Method in class mars.Settings
Get Color object for specified settings name (a static constant).
getColumnClass(int) –
Method in class mars.tools.BHTableModel
Returns the class/type of the i-th column of the table.
getColumnCount() –
Method in class mars.tools.BHTableModel
Returns the number of columns.
getColumnName(int) –
Method in class mars.tools.BHTableModel
Returns the name of the i-th column of the table.
getCommandDescriptor() –
Method in class mars.mips.dump.AbstractDumpFormat
One-word description of format to be used by MARS command mode parser
and user in conjunction with the “dump” option.
getCommandDescriptor() –
Method in interface mars.mips.dump.DumpFormat
A short one-word descriptor that will be used by the MARS
command line parser (and the MARS command line user) to specify
that this format is to be used.
getCommonFamilies() –
Static method in class mars.util.EditorFont
Obtain an array of common font family names.
getCompactBasicIntructionTemplateList() –
Method in class mars.mips.instructions.ExtendedInstruction
Get ArrayList of Strings that represent list of templates for
basic instructions generated by the “compact” or 16-bit version
of this extended instruction.
getCompactInstructionLength() –
Method in class mars.mips.instructions.ExtendedInstruction
Get length in bytes that this extended instruction requires in its
binary form if it includes an alternative expansion for compact
memory (16 bit addressing) configuration.
getConditionFlag(int) –
Static method in class mars.mips.hardware.Coprocessor1
Get value of specified condition flag (0-7).
getConditionFlagCount() –
Static method in class mars.mips.hardware.Coprocessor1
Get count of condition flags.
getConditionFlags() –
Static method in class mars.mips.hardware.Coprocessor1
Get array of condition flags (0-7).
getConfigurationByName(String) –
Static method in class mars.mips.hardware.MemoryConfigurations
getConfigurationIdentifier() –
Method in class mars.mips.hardware.MemoryConfiguration
getConfigurationItemNames() –
Method in class mars.mips.hardware.MemoryConfiguration
getConfigurationItemValues() –
Method in class mars.mips.hardware.MemoryConfiguration
getConfigurationName() –
Method in class mars.mips.hardware.MemoryConfiguration
getConfigurationsIterator() –
Static method in class mars.mips.hardware.MemoryConfigurations
getCoprocessor0Window() –
Method in class mars.venus.ExecutePane
Access the coprocessor0 values window.
getCoprocessor0Window() –
Method in class mars.venus.RegistersPane
Return component containing coprocessor 0 (exceptions) register set.
getCoprocessor1Window() –
Method in class mars.venus.ExecutePane
Access the coprocessor1 values window.
getCoprocessor1Window() –
Method in class mars.venus.RegistersPane
Return component containing coprocessor 1 (floating point) register set.
getCurrent() –
Method in class mars.assembler.MacroPool
getCurrentConfiguration() –
Static method in class mars.mips.hardware.MemoryConfigurations
getCurrentEditTab() –
Method in class mars.venus.EditTabbedPane
The current EditPane representing a file.
getCurrentEditTabForFile(File) –
Method in class mars.venus.EditTabbedPane
If the given file is open in the tabbed pane, make it the
current tab.
getCurrentOpenDirectory() –
Method in class mars.venus.Editor
Get name of current directory for Open operation.
getCurrentSaveDirectory() –
Method in class mars.venus.Editor
Get name of current directory for Save or Save As operation.
getCurrentSyntaxStyles() –
Static method in class mars.venus.editors.jeditsyntax.SyntaxUtilities
Returns the CURRENT style table.
getDataBaseAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getDataSegmentBaseAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getDataSegmentHighlighting() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DATA_SEGMENT_HIGHLIGHTING)
getDataSegmentLimitAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getDataSegmentWindow() –
Method in class mars.venus.ExecutePane
Access the data segment window.
getDataSymbols() –
Method in class mars.assembler.SymbolTable
For obtaining the Data Symbols.
getDefaultColorSettingByKey(String) –
Method in class mars.Settings
Get default Color value for specified settings key.
getDefaultColorSettingByPosition(int) –
Method in class mars.Settings
Get default Color object for specified settings name (a static constant).
getDefaultConfiguration() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultDataBaseAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultDataSegmentBaseAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultDataSegmentLimitAddress() –
Method in class mars.mips.hardware.MemoryConfigurations
getDefaultEditorSyntaxStyleByPosition(int) –
Method in class mars.Settings
getDefaultEditorTabSize() –
Method in class mars.Settings
Get the text editor default tab size in characters
getDefaultExceptionHandlerAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultExternBaseAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultFontByPosition(int) –
Method in class mars.Settings
Retrieve a default Font setting
getDefaultGlobalPointer() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultHeapBaseAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultKernelBaseAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultKernelDataBaseAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultKernelDataSegmentLimitAddress() –
Method in class mars.mips.hardware.MemoryConfigurations
getDefaultKernelHighAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultKernelTextBaseAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultKernelTextLimitAddress() –
Method in class mars.mips.hardware.MemoryConfigurations
getDefaultMemoryMapBaseAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaults() –
Static method in class mars.venus.editors.jeditsyntax.TextAreaDefaults
Returns a new TextAreaDefaults object with the default values filled
in.
getDefaultStackBaseAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultStackLimitAddress() –
Method in class mars.mips.hardware.MemoryConfigurations
getDefaultStackPointer() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultSyntaxStyles() –
Static method in class mars.venus.editors.jeditsyntax.SyntaxUtilities
Returns the default style table.
getDefaultTextBaseAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDefaultTextLimitAddress() –
Method in class mars.mips.hardware.MemoryConfigurations
getDefaultUserHighAddress() –
Static method in class mars.mips.hardware.MemoryConfigurations
getDelay() –
Method in class mars.venus.RepeatButton
Gets the delay for the timer of this button.
getDelayedBranchingEnabled() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
getDescription() –
Method in class mars.assembler.Directives
Get description of this Directives object
getDescription() –
Method in class mars.mips.dump.AbstractDumpFormat
Get a short description of the format, suitable for displaying along with
the extension, in the file save dialog, or as a tool tip.
getDescription() –
Method in interface mars.mips.dump.DumpFormat
Get a short description of the format, suitable
for displaying along with the extension, if any, in the file
save dialog and also for displaying as a tool tip.
getDescription() –
Method in class mars.mips.instructions.Instruction
Get string describing the instruction.
getDescription() –
Method in class mars.venus.editors.jeditsyntax.PopupHelpItem
getDirectiveList() –
Static method in class mars.assembler.Directives
Produces List of Directive objects
getDisplayAddressesInHex() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_ADDRESSES_IN_HEX)
getDisplayValuesInHex() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_VALUES_IN_HEX)
getDocument() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the document this text area is editing.
getDocument() –
Method in interface mars.venus.editors.MARSTextEditingArea
getDocumentLength() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the length of the document.
getDoubleFromRegisterPair(int) –
Static method in class mars.mips.hardware.Coprocessor1
Gets the double value stored in the given FPU register.
getDoubleFromRegisterPair(String) –
Static method in class mars.mips.hardware.Coprocessor1
Gets the double value stored in the given FPU register.
getEditor() –
Method in class mars.venus.VenusUI
Get reference to Editor object associated with this GUI.
getEditorFont() –
Method in class mars.Settings
Current editor font.
getEditorLineNumbersDisplayed() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EDITOR_LINE_NUMBERS_DISPLAYED)
getEditorPopupPrefixLength() –
Method in class mars.Settings
Get number of letters to be matched by editor’s instruction guide before popup generated (if popup enabled).
getEditorSyntaxStyleByPosition(int) –
Method in class mars.Settings
getEditorTabSize() –
Method in class mars.Settings
Get the tab size in characters.
getEditPane() –
Method in class mars.venus.MainPane
Returns current edit pane.
getEditPaneForFile(String) –
Method in class mars.venus.EditTabbedPane
If there is an EditPane for the given file pathname, return it else return null.
getEditTabbedPane() –
Method in class mars.venus.MainPane
Returns component containing editor display
getElectricScroll() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the number of lines from the top and button of the
text area that are always visible.
getEOLMarkerColor() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns the EOL marker color.
getEOLMarkersPainted() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns true if EOL markers are drawn, false otherwise.
getErrorLimit() –
Method in class mars.ErrorList
Get limit on number of error messages to be generated
by one assemble operation.
getErrorList() –
Method in class mars.assembler.Assembler
Get list of assembler errors and warnings
getErrorMessages() –
Method in class mars.ErrorList
Get ArrayList of error messages.
getErrors() –
Method in class mars.assembler.Tokenizer
Fetch this Tokenizer’s error list.
getExact() –
Method in class mars.venus.editors.jeditsyntax.PopupHelpItem
Determines whether match occurred in an exact-match or prefix-match search.
getExample() –
Method in class mars.venus.editors.jeditsyntax.PopupHelpItem
getExampleFormat() –
Method in class mars.mips.instructions.Instruction
Get string descriptor of instruction’s format.
getExampleLength() –
Method in class mars.venus.editors.jeditsyntax.PopupHelpItem
getExamplePaddedToLength(int) –
Method in class mars.venus.editors.jeditsyntax.PopupHelpItem
getExceptionHandler() –
Method in class mars.Settings
Name of currently selected exception handler file.
getExceptionHandlerAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getExceptionHandlerEnabled() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EXCEPTION_HANDLER_ENABLED)
getExecutePane() –
Method in class mars.venus.MainPane
returns component containing execution-time display
getExecuteTab() –
Method in class mars.venus.MainPane
returns component containing execution-time display.
getExpansionHistory() –
Method in class mars.assembler.MacroPool
getExtendedAssemblerEnabled() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EXTENDED_ASSEMBLER_ENABLED)
getExtension(File) –
Static method in class mars.util.FilenameFinder
Get the filename extension of the specified File.
getExternalTools() –
Static method in class mars.Globals
Get list of MarsTools that reside outside the MARS distribution.
getExternBaseAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getFile() –
Static method in class mars.venus.FileStatus
Returns the ASM file.
getFileErrorMessage() –
Static method in class mars.util.SystemIO
Retrieve file operation or error message
getFileExtension() –
Method in class mars.mips.dump.AbstractDumpFormat
Get the file extension associated with this format.
getFileExtension() –
Method in interface mars.mips.dump.DumpFormat
Get the file extension associated with this format.
getFileFilter(ArrayList, String, boolean) –
Static method in class mars.util.FilenameFinder
Get a FileFilter that will filter files based on the given list of filename extensions.
getFileFilter(ArrayList, String) –
Static method in class mars.util.FilenameFinder
Get a FileFilter that will filter files based on the given list of filename extensions.
getFileFilter(String, String, boolean) –
Static method in class mars.util.FilenameFinder
Get a FileFilter that will filter files based on the given filename extension.
getFileFilter(String, String) –
Static method in class mars.util.FilenameFinder
Get a FileFilter that will filter files based on the given filename extension.
getFilename() –
Method in class mars.assembler.SourceLine
Retrieve name of file containing source statement
getFilename() –
Method in class mars.ErrorMessage
Produce name of file containing error.
getFilename() –
Method in class mars.MIPSprogram
Produces name of associated source code file.
getFilename() –
Method in class mars.venus.EditPane
Delegates to corresponding FileStatus method
getFilename() –
Method in class mars.venus.FileStatus
Get file name with no path information.
getFilenameList(ClassLoader, String, String) –
Static method in class mars.util.FilenameFinder
Locate files and return list of file names.
getFilenameList(ClassLoader, String, ArrayList) –
Static method in class mars.util.FilenameFinder
Locate files and return list of file names.
getFilenameList(String, String) –
Static method in class mars.util.FilenameFinder
Locate files and return list of file names.
getFilenameList(String, ArrayList) –
Static method in class mars.util.FilenameFinder
Locate files and return list of file names.
getFilenameList(ArrayList, String) –
Static method in class mars.util.FilenameFinder
Return list of file names.
getFilenameList(ArrayList, ArrayList) –
Static method in class mars.util.FilenameFinder
Return list of file names.
getFileStatus() –
Method in class mars.venus.EditPane
Get the editing status for this EditPane’s associated document.
getFileStatus() –
Method in class mars.venus.FileStatus
Get editing status of this file.
getFirstLine() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the line displayed at the text area’s origin.
getFloatFromRegister(int) –
Static method in class mars.mips.hardware.Coprocessor1
Gets the float value stored in the given FPU register.
getFloatFromRegister(String) –
Static method in class mars.mips.hardware.Coprocessor1
Gets the float value stored in the given FPU register.
getFont() –
Method in class mars.venus.AbstractFontSettingDialog
getFont() –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
getFont() –
Method in interface mars.venus.editors.MARSTextEditingArea
getFontByPosition(int) –
Method in class mars.Settings
Retrieve a Font setting
getFontMetrics(Font) –
Method in class mars.venus.editors.jeditsyntax.SyntaxStyle
Returns the font metrics for the styled font.
getFontMetrics() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns the font metrics used by this component.
getFontMetrics(Font) –
Method in interface mars.venus.editors.MARSTextEditingArea
getFontStyleStrings() –
Static method in class mars.util.EditorFont
Get array containing String values for font style names.
getFromLine() –
Method in class mars.assembler.Macro
getGlobalPointer() –
Method in class mars.mips.hardware.MemoryConfiguration
getGui() –
Static method in class mars.Globals
getHalf(int) –
Method in class mars.mips.hardware.Memory
Starting at the given word address, read a 2 byte word into lower 16 bits of int.
getHeapBaseAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getHelpComponent() –
Method in class mars.tools.AbstractMarsToolAndApplication
Override this method to provide a JComponent (probably a JButton) of your choice
to be placed just left of the Close/Exit button.
getHelpComponent() –
Method in class mars.tools.BitmapDisplay
Overrides default method, to provide a Help button for this tool/app.
getHelpComponent() –
Method in class mars.tools.DigitalLabSim
getHelpComponent() –
Method in class mars.tools.KeyboardAndDisplaySimulator
Overrides default method, to provide a Help button for this tool/app.
getHelpComponent() –
Method in class mars.tools.MemoryReferenceVisualization
Overrides default method, to provide a Help button for this tool/app.
getHistoryAsStr() –
Method in class mars.tools.BHTEntry
Builds a string representation of the BHT entry’s history.
getHorizontalOffset() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the horizontal offset of drawn lines.
getIdxForAddress(int) –
Method in class mars.tools.BHTableModel
Returns the index into the BHT for a given branch instruction address.
getIgnoreCase() –
Method in class mars.venus.editors.jeditsyntax.KeywordMap
Returns true if the keyword map is set to be case insensitive,
false otherwise.
getInitialDelay() –
Method in class mars.venus.RepeatButton
Gets the initial delay for the timer of this button.
getInitialProgramCounter() –
Static method in class mars.mips.hardware.RegisterFile
For returning the program counter’s initial (reset) value.
getInputHandler() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the input handler.
getInputString(String) –
Method in class mars.venus.MessagesPane
Method used by the SystemIO class to get interactive user input
requested by a running MIPS program (e.g.
getInputString(int) –
Method in class mars.venus.MessagesPane
Method used by the SystemIO class to get interactive user input
requested by a running MIPS program (e.g.
getInstance() –
Static method in class mars.mips.hardware.Memory
Returns the unique Memory instance, which becomes in essence global.
getInstance() –
Static method in class mars.simulator.Simulator
Returns the Simulator object
getInstance() –
Static method in class mars.venus.RunSpeedPanel
Retrieve the run speed panel object
getInstruction() –
Method in class mars.ProgramStatement
Produces Instruction object corresponding to this statement’s operator.
getInstructionCategory(ProgramStatement) –
Method in class mars.tools.InstructionStatistics
decodes the instruction and determines the category of the instruction.
getInstructionFormat() –
Method in class mars.mips.instructions.BasicInstruction
Gets the operand format of the instruction.
getInstructionLength() –
Method in class mars.mips.instructions.ExtendedInstruction
Get length in bytes that this extended instruction requires in its
binary form.
getInstructionLength() –
Method in class mars.mips.instructions.Instruction
Get length in bytes that this instruction requires in its binary form.
getInstructionList() –
Method in class mars.mips.instructions.InstructionSet
Retrieve the current instruction set.
getIntFromRegister(int) –
Static method in class mars.mips.hardware.Coprocessor1
Gets the 32-bit int bit pattern stored in the given FPU register.
getIntFromRegister(String) –
Static method in class mars.mips.hardware.Coprocessor1
Gets the 32-bit int bit pattern stored in the given FPU register.
getInvalidLinesPainted() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns true if invalid lines are painted as red tildes (~),
false otherwise.
getKernelBaseAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getKernelDataBaseAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getKernelDataSegmentLimitAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getKernelHighAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getKernelTextBaseAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getKernelTextLimitAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getKeywords() –
Static method in class mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
Get KeywordMap containing all MIPS key words.
getLabelSortState() –
Method in class mars.Settings
Get the saved state of the Labels Window sorting (can sort by either
label or address and either ascending or descending order).
getLabelsWindow() –
Method in class mars.venus.ExecutePane
Access the label values window.
getLabelWindowVisibility() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.LABEL_WINDOW_VISIBILITY)
getLeadingWhiteSpace() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Makes a copy of leading white space (tab or space) from the current line and
returns it.
getLength() –
Method in class mars.mips.hardware.MemoryAccessNotice
Fetch the length in bytes of the access operation (4,2,1).
getLengthInBytes(Directives) –
Static method in class mars.assembler.DataTypes
Get length in bytes for numeric MIPS directives.
getLimitAddresses(String[]) –
Static method in class mars.util.MemoryDump
Get the MIPS memory limit address(es) of the specified segment name(s).
getLine() –
Method in class mars.ErrorMessage
Produce line number of error.
getLineCount() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the number of lines in the document.
getLineCount() –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Returns the number of lines in this token marker.
getLineEndOffset(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the end offset of the specified line.
getLineHighlightColor() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns the line highlight color.
getLineLength(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the length of the specified line.
getLineNumber() –
Method in class mars.assembler.SourceLine
Retrieve line number of source statement
getLineNumbersList(Document) –
Method in class mars.venus.EditPane
getLineOfOffset(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the line containing the specified offset.
getLinesPerPage() –
Method in class mars.venus.HardcopyWriter
Return the number of lines that fit on a page
getLineStartOffset(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the start offset of the specified line.
getLineText(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the text on the specified line.
getLineText(int, Segment) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Copies the text on the specified line into a segment.
getLocalMacroPool() –
Method in class mars.MIPSprogram
Gets local macro pool MacroPool for this program
getLocalSymbolTable() –
Method in class mars.MIPSprogram
Returns SymbolTable associated with this program.
getLongFromRegisterPair(int) –
Static method in class mars.mips.hardware.Coprocessor1
Gets a long representing the double value stored in the given double
precision FPU register.
getLongFromRegisterPair(String) –
Static method in class mars.mips.hardware.Coprocessor1
Gets the double value stored in the given FPU register.
getMachineList() –
Method in class mars.MIPSprogram
Produces list of machine statements that are assembled from the program.
getMachineStatement() –
Method in class mars.ProgramStatement
Produces binary machine statement as 32 character string, all ‘0’ and ‘1’ chars.
getMacroExpansionHistory() –
Method in class mars.ErrorMessage
Returns string describing macro expansion.
getMacroRecorder() –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Returns the macro recorder.
getMagicCaretPosition() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the `magic’ caret position.
getMainPane() –
Method in class mars.venus.VenusUI
Get reference to messages pane associated with this GUI.
getMarkLine() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the mark line.
getMarkPosition() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the mark position.
getMatchingMacro(TokenList, int) –
Method in class mars.assembler.MacroPool
Will be called by parser when reaches a macro expansion call
getMaxSteps() –
Method in class mars.simulator.SimulatorNotice
Fetch the length in bytes of the access operation (4,2,1).
getMemoryConfiguration() –
Method in class mars.Settings
Returns identifier of current built-in memory configuration.
getMemoryMapBaseAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getMemoryMapLimitAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getMemoryMapLimitAddress() –
Method in class mars.mips.hardware.MemoryConfigurations
getMenuState() –
Static method in class mars.venus.VenusUI
Get current menu state.
getMessage() –
Method in class mars.ErrorMessage
Produce error message.
getMessagesPane() –
Method in class mars.venus.VenusUI
Get reference to messages pane associated with this GUI.
getMinimumSize() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns the painter’s minimum size.
getMIPSprogram() –
Method in class mars.assembler.SourceLine
Retrieve MIPSprogram object containing source statement
getMIPSTokenExamples() –
Static method in class mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
getMIPSTokenLabels() –
Static method in class mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
getName() –
Method in class mars.assembler.Directives
Get name of this Directives object
getName() –
Method in class mars.assembler.Macro
getName() –
Method in class mars.assembler.Symbol
Returns the label of the the Symbol.
getName() –
Method in class mars.mips.hardware.Register
Returns the name of the Register.
getName() –
Method in class mars.mips.instructions.Instruction
Get operation mnemonic
getName() –
Method in class mars.mips.instructions.syscalls.AbstractSyscall
Return the name you have chosen for this syscall.
getName() –
Method in interface mars.mips.instructions.syscalls.Syscall
Return a name you have chosen for this syscall.
getName() –
Method in class mars.mips.instructions.syscalls.SyscallNumberOverride
Get the service name as a String.
getName() –
Method in class mars.tools.AbstractMarsToolAndApplication
Required MarsTool method to return Tool name.
getName() –
Method in class mars.tools.BHTSimulator
Returns the name of the tool.
getName() –
Method in class mars.tools.BitmapDisplay
Required MarsTool method to return Tool name.
getName() –
Method in class mars.tools.CacheSimulator
Required MarsTool method to return Tool name.
getName() –
Method in class mars.tools.DigitalLabSim
getName() –
Method in class mars.tools.FloatRepresentation
Fetch tool name (for display in MARS Tools menu)
getName() –
Method in class mars.tools.InstructionCounter
getName() –
Method in class mars.tools.InstructionStatistics
returns the name of the tool
getName() –
Method in class mars.tools.IntroToTools
Required method to return Tool name.
getName() –
Method in class mars.tools.KeyboardAndDisplaySimulator
Required MarsTool method to return Tool name.
getName() –
Method in class mars.tools.MarsBot
getName() –
Method in interface mars.tools.MarsTool
Return a name you have chosen for this tool.
getName() –
Method in class mars.tools.MemoryReferenceVisualization
Required MarsTool method to return Tool name.
getName() –
Method in class mars.tools.ScavengerHunt
getName() –
Method in class mars.tools.ScreenMagnifier
getName() –
Static method in class mars.venus.FileStatus
Returns the name of the file.
getNextCounter() –
Method in class mars.assembler.MacroPool
MacroPool.counter will be set to 0 on construction of this class and will
be incremented by each call.
getNextDefaultFilename() –
Method in class mars.venus.Editor
Generates a default file name
getNumber(String) –
Static method in class mars.mips.hardware.Coprocessor0
For getting the number representation of the register.
getNumber() –
Method in class mars.mips.hardware.Register
Returns the number of the Register.
getNumber(String) –
Static method in class mars.mips.hardware.RegisterFile
For getting the number representation of the register.
getNumber() –
Method in class mars.mips.instructions.syscalls.AbstractSyscall
Return the assigned service number.
getNumber() –
Method in interface mars.mips.instructions.syscalls.Syscall
Return the assigned service number.
getNumber() –
Method in class mars.mips.instructions.syscalls.SyscallNumberOverride
Get the new service number as an int.
getOpcodeMask() –
Method in class mars.mips.instructions.BasicInstruction
getOpcodeMatch() –
Method in class mars.mips.instructions.BasicInstruction
getOperand(int) –
Method in class mars.ProgramStatement
Produces operand value from given array position (first operand is position 0).
getOperands() –
Method in class mars.ProgramStatement
Produces int array of operand values for this statement.
getOperationMask() –
Method in class mars.mips.instructions.BasicInstruction
Gets the 32-character operation mask.
getOriginalFromLine() –
Method in class mars.assembler.Macro
getOriginalProgram() –
Method in class mars.assembler.Token
Produces original program containing this token.
getOriginalSourceLine() –
Method in class mars.assembler.Token
Produces original line number of this token.
getOriginalTokenList() –
Method in class mars.ProgramStatement
Produces token list generated from original source statement.
getOriginalToLine() –
Method in class mars.assembler.Macro
getOuterComponent() –
Method in class mars.venus.editors.generic.GenericTextArea
getOuterComponent() –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
getOuterComponent() –
Method in interface mars.venus.editors.MARSTextEditingArea
getPainter() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the object responsible for painting this text area.
getParent() –
Method in class mars.venus.FileStatus
Get file parent pathname.
getParsedList() –
Method in class mars.MIPSprogram
Produces existing list of parsed source code statements.
getPathname() –
Method in class mars.venus.EditPane
Delegates to corresponding FileStatus method
getPathname() –
Method in class mars.venus.FileStatus
Get full file pathname.
getPosition() –
Method in class mars.ErrorMessage
Produce position within erroneous line.
getPrediction() –
Method in class mars.tools.BHTEntry
Returns the branch prediction based on the history.
getPredictionAsStr() –
Method in class mars.tools.BHTEntry
Returns a string representation of the BHT entry’s current prediction.
getPredictionAtIdx(int) –
Method in class mars.tools.BHTableModel
Retrieve the prediction for the i-th BHT entry.
getPreferredSize() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns the painter’s preferred size.
getPrintableBasicAssemblyStatement() –
Method in class mars.ProgramStatement
Produces printable Basic Assembly statement for this MIPS source
statement.
getProcessedLine() –
Method in class mars.assembler.TokenList
Retrieve the source line String associated with this
token list.
getProgram() –
Method in class mars.assembler.Macro
getProgramArguments() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.PROGRAM_ARGUMENTS)
getProgramArguments() –
Method in class mars.venus.TextSegmentWindow
Get program arguments from text field in south border of text segment window.
getProgramCounter() –
Static method in class mars.mips.hardware.RegisterFile
For returning the program counters value.
getProgramCounter() –
Method in class mars.simulator.SimulatorNotice
Fetch the value of the access operation (the value read or written).
getProgramCounterRegister() –
Static method in class mars.mips.hardware.RegisterFile
Returns Register object for program counter.
getPropertyEntry(String, String) –
Static method in class mars.Globals
Read and return property file value (if any) for requested property.
getRawWord(int) –
Method in class mars.mips.hardware.Memory
Starting at the given word address, read a 4 byte word as an int.
getRawWordOrNull(int) –
Method in class mars.mips.hardware.Memory
Starting at the given word address, read a 4 byte word as an int and return Integer.
getRegister(String) –
Static method in class mars.mips.hardware.Coprocessor0
Get register object corresponding to given name.
getRegister(String) –
Static method in class mars.mips.hardware.Coprocessor1
Get register object corresponding to given name.
getRegisterName() –
Method in class mars.mips.hardware.RegisterAccessNotice
Fetch the register number of register accessed.
getRegisterNumber(String) –
Static method in class mars.mips.hardware.Coprocessor1
For getting the number representation of the FPU register.
getRegisterPosition(Register) –
Static method in class mars.mips.hardware.Coprocessor0
Coprocessor0 implements only selected registers, so the register number
(8, 12, 13, 14) does not correspond to its position in the list of registers
(0, 1, 2, 3).
getRegisters() –
Static method in class mars.mips.hardware.Coprocessor0
For returning the set of registers.
getRegisters() –
Static method in class mars.mips.hardware.Coprocessor1
For returning the set of registers.
getRegisters() –
Static method in class mars.mips.hardware.RegisterFile
For returning the set of registers.
getRegistersHighlighting() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.REGISTERS_HIGHLIGHTING)
getRegistersPane() –
Method in class mars.venus.VenusUI
Get reference to registers pane associated with this GUI.
getRegistersWindow() –
Method in class mars.venus.ExecutePane
Access the register values window.
getRegistersWindow() –
Method in class mars.venus.RegistersPane
Return component containing integer register set.
getRepeatCount() –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Returns the number of times the next action will be repeated.
getReset() –
Static method in class mars.venus.VenusUI
To find out whether the register values are reset.
getResetValue() –
Method in class mars.mips.hardware.Register
Returns the reset value of the Register.
getRightClickPopup() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the right click popup menu.
getRowCount() –
Method in class mars.tools.BHTableModel
Returns the number of entries of the BHT.
getRunAssembleAction() –
Method in class mars.venus.VenusUI
Return reference tothe Run->Assemble item’s action.
getRunSpeed() –
Method in class mars.simulator.SimulatorNotice
Fetch the value of the access operation (the value read or written).
getRunSpeed() –
Method in class mars.venus.RunSpeedPanel
returns current run speed setting, in instructions/second.
getRunTextArea() –
Method in class mars.venus.MessagesPane
Returns component used to display runtime messages
getSegmentBounds(String) –
Static method in class mars.util.MemoryDump
Return array with segment address bounds for specified segment.
getSegmentMapKey(Segment, int, int) –
Method in class mars.venus.editors.jeditsyntax.KeywordMap
getSegmentNames() –
Static method in class mars.util.MemoryDump
Get the names of segments available for memory dump.
getSelectedText() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the selected text, or null if no selection is active.
getSelectedText() –
Method in interface mars.venus.editors.MARSTextEditingArea
getSelectionColor() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns the selection color.
getSelectionEnd() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the selection end offset.
getSelectionEnd(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the offset where the selection ends on the specified
line.
getSelectionEnd() –
Method in interface mars.venus.editors.MARSTextEditingArea
getSelectionEndLine() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the selection end line.
getSelectionStart() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the selection start offset.
getSelectionStart(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the offset where the selection starts on the specified
line.
getSelectionStart() –
Method in interface mars.venus.editors.MARSTextEditingArea
getSelectionStartLine() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the selection start line.
getSettings() –
Static method in class mars.Globals
getSimulationCode() –
Method in class mars.mips.instructions.BasicInstruction
Gets the SimulationCode object.
getSize() –
Method in class mars.assembler.SymbolTable
Get the count of entries currently in the table.
getSortedBreakPointsArray() –
Method in class mars.venus.TextSegmentWindow
Returns array of current breakpoints, each represented by a MIPS program counter address.
getSource() –
Method in class mars.assembler.SourceLine
Retrieve source statement itself
getSource() –
Method in class mars.ProgramStatement
Produces MIPS source statement.
getSource() –
Method in class mars.venus.EditPane
Get source code text
getSourceFile() –
Method in class mars.ProgramStatement
Produces String name of the source file containing this statement.
getSourceLine() –
Method in class mars.assembler.Token
Produces line number of MIPS program of this token.
getSourceLine(int) –
Method in class mars.MIPSprogram
Produces specified line of MIPS source program.
getSourceLine() –
Method in class mars.ProgramStatement
Produces line number of MIPS source statement.
getSourceLineCount() –
Method in class mars.venus.EditPane
Calculate and return number of lines in source code text.
getSourceLineList() –
Method in class mars.MIPSprogram
Retrieve list of source statements that comprise the program.
getSourceList() –
Method in class mars.MIPSprogram
Produces list of source statements that comprise the program.
getSourceMIPSprogram() –
Method in class mars.assembler.Token
Produces MIPSprogram object associated with this token.
getSourceMIPSprogram() –
Method in class mars.ProgramStatement
Produces MIPSprogram object representing the source file containing this statement.
getStackBaseAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getStackLimitAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getStackPointer() –
Method in class mars.mips.hardware.MemoryConfiguration
getStartAtMain() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.START_AT_MAIN)
getStarted() –
Static method in class mars.venus.VenusUI
To find out whether MIPS program is currently executing.
getStartLabel() –
Static method in class mars.assembler.SymbolTable
Fetches the text segment label (symbol) which, if declared global, indicates
the starting address for execution.
getStartPos() –
Method in class mars.assembler.Token
Produces position within source line of this token.
getStatement(int) –
Method in class mars.mips.hardware.Memory
Gets ProgramStatement from Text Segment.
getStatementNoNotify(int) –
Method in class mars.mips.hardware.Memory
Gets ProgramStatement from Text Segment without notifying observers.
getStatsPredCorrect() –
Method in class mars.tools.BHTEntry
Get the absolute number of correct predictions.
getStatsPredIncorrect() –
Method in class mars.tools.BHTEntry
Get the absolute number of mispredictions.
getStatsPredPrecision() –
Method in class mars.tools.BHTEntry
Get the percentage of correct predictions.
getStringMapKey(String) –
Method in class mars.venus.editors.jeditsyntax.KeywordMap
getStrippedTokenList() –
Method in class mars.ProgramStatement
Produces token list stripped of all but operator and operand tokens.
getStyledFont(Font) –
Method in class mars.venus.editors.jeditsyntax.SyntaxStyle
Returns the specified font, but with the style’s bold and
italic flags applied.
getStyles() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns the syntax styles used to paint colorized text.
getSubstitutedLine(int, TokenList, long, ErrorList) –
Method in class mars.assembler.Macro
Substitutes macro arguments in a line of source code inside macro
definition to be parsed after macro expansion.
getSymbol(String) –
Method in class mars.assembler.SymbolTable
Produce Symbol object from symbol table that corresponds to given String.
getSymbolGivenAddress(String) –
Method in class mars.assembler.SymbolTable
Produce Symbol object from symbol table that has the given address.
getSymbolGivenAddressLocalOrGlobal(String) –
Method in class mars.assembler.SymbolTable
Produce Symbol object from either local or global symbol table that has the
given address.
getSyntaxSensitiveToolTipText(int, int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Return any relevant tool tip text for token at specified position.
getSyscallOverrides() –
Method in class mars.Globals
Read any syscall number assignment overrides from config file.
getTabBHT() –
Method in class mars.tools.BHTSimGUI
Returns the table representing the BHT.
getTabSize() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Fetch the tab size in characters.
getTaLog() –
Method in class mars.tools.BHTSimGUI
Returns the text area for log purposes.
getText() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the entire text of this text area.
getText(int, int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the specified substring of the document.
getText(int, int, Segment) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Copies the specified substring of the document into a segment.
getText() –
Method in interface mars.venus.editors.MARSTextEditingArea
getTextArea(EventObject) –
Static method in class mars.venus.editors.jeditsyntax.InputHandler
Returns the text area that fired the specified event.
getTextBaseAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getTextColumnOrder() –
Method in class mars.Settings
Order of text segment display columns (there are 5, numbered 0 to 4).
getTextLimitAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getTextSegmentWindow() –
Method in class mars.venus.ExecutePane
Access the text segment window.
getTextSymbols() –
Method in class mars.assembler.SymbolTable
For obtaining the Text Symbols.
getTfAddress() –
Method in class mars.tools.BHTSimGUI
Returns the text field for displaying the address of the most recent branch instruction
getTfIndex() –
Method in class mars.tools.BHTSimGUI
Returns the text field for displaying the corresponding index into the BHT
getTfInstruction() –
Method in class mars.tools.BHTSimGUI
Returns the text field for displaying the most recent branch instruction
getThread() –
Method in class mars.mips.hardware.AccessNotice
Get reference to thread that created this notice
getTokenExactMatchHelp(Token, String) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
Construct and return any appropriate help information for
the given token.
getTokenExactMatchHelp(Token, String) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Construct and return any appropriate help information for
the given token.
getTokenizer() –
Method in class mars.MIPSprogram
Retrieves Tokenizer for this program
getTokenList() –
Method in class mars.mips.instructions.Instruction
Get TokenList corresponding to correct instruction syntax.
getTokenList() –
Method in class mars.MIPSprogram
Produces list of tokens that comprise the program.
getTokenMarker() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the document’s token marker.
getTokenMarker() –
Method in class mars.venus.editors.jeditsyntax.SyntaxDocument
Returns the token marker that is to be used to split lines
of this document up into tokens.
getTokenPrefixMatchHelp(String, Token, Token, String) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
Construct and return any appropriate help information for
prefix match based on current line’s token list.
getTokenPrefixMatchHelp(String, Token, Token, String) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Construct and return any appropriate help information for
the given token or “token prefix”.
getTokenText() –
Method in class mars.venus.editors.jeditsyntax.PopupHelpItem
The document text that mached this item
getToLine() –
Method in class mars.assembler.Macro
getToolTipText(MouseEvent) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns the tool tip to display at the specified location.
getToolTipText(MouseEvent) –
Method in interface mars.venus.editors.jeditsyntax.TextAreaPainter.Highlight
Returns the tool tip to display at the specified
location.
getType() –
Method in class mars.assembler.Symbol
Finds the type of symbol, text or data.
getType() –
Method in class mars.assembler.Token
Produces token type of this token.
getType() –
Method in exception mars.mips.hardware.AddressErrorException
Get the exception type (load or store).
getUndoManager() –
Method in class mars.venus.editors.generic.GenericTextArea
Returns the undo manager for this editing area
getUndoManager() –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Returns the undo manager for this editing area
getUndoManager() –
Method in interface mars.venus.editors.MARSTextEditingArea
getUndoManager() –
Method in class mars.venus.EditPane
get the manager in charge of Undo and Redo operations
getUserHighAddress() –
Method in class mars.mips.hardware.MemoryConfiguration
getUserRegister(String) –
Static method in class mars.mips.hardware.RegisterFile
Get register object corresponding to given name.
getValue() –
Method in class mars.assembler.Token
Produces source code of this token.
getValue(int) –
Static method in class mars.mips.hardware.Coprocessor0
Returns the value of the register who’s number is num.
getValue(int) –
Static method in class mars.mips.hardware.Coprocessor1
Returns the value of the FPU register who’s number is num.
getValue() –
Method in class mars.mips.hardware.MemoryAccessNotice
Fetch the value of the access operation (the value read or written).
getValue() –
Method in class mars.mips.hardware.Register
Returns the value of the Register.
getValue(int) –
Static method in class mars.mips.hardware.RegisterFile
Returns the value of the register who’s number is num.
getValue() –
Method in class mars.simulator.SwingWorker
Get the value produced by the worker thread, or null if it
hasn’t been constructed yet.
getValueAt(int, int) –
Method in class mars.tools.BHTableModel
Returns the value of the cell at the given row and column
Required by the TableModel interface.
getValueDisplayBase() –
Method in class mars.venus.ExecutePane
Retrieve the number system base for displaying values (mem/register contents)
getValueDisplayBaseChooser() –
Method in class mars.venus.ExecutePane
Retrieve component used to set numerical base (10 or 16) of data value display.
getValueDisplayBaseMenuItem() –
Method in class mars.venus.VenusUI
Get reference to settings menu item for display base of memory/register values.
getValueNoNotify() –
Method in class mars.mips.hardware.Register
Returns the value of the Register.
getVisibleLines() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns the number of lines visible in this text area.
getWarningsAreErrors() –
Method in class mars.Settings
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.WARNINGS_ARE_ERRORS)
getWord(int) –
Method in class mars.mips.hardware.Memory
Starting at the given word address, read a 4 byte word as an int.
getWordNoNotify(int) –
Method in class mars.mips.hardware.Memory
Starting at the given word address, read a 4 byte word as an int.
GLOBAL_POINTER_REGISTER –
Static variable in class mars.mips.hardware.RegisterFile
globalPointer –
Static variable in class mars.mips.hardware.Memory
base address for storing globals
Globals – Class in mars
Collection of globally-available data structures.
Globals() –
Constructor for class mars.Globals
GLOBL –
Static variable in class mars.assembler.Directives
go() –
Method in class mars.tools.AbstractMarsToolAndApplication
Run the simulator as stand-alone application.
grabAction –
Variable in class mars.venus.editors.jeditsyntax.InputHandler
grabFocus() –
Method in interface mars.venus.editors.MARSTextEditingArea
grabNextKeyStroke(ActionListener) –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Grabs the next key typed event and invokes the specified
action with the key as a the action command.
GuiAction – Class in mars.venus
parent class for Action subclasses to be defined for every menu/toolbar
option.
GuiAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.GuiAction
H
HALF –
Static variable in class mars.assembler.Directives
HALF_SIZE –
Static variable in class mars.assembler.DataTypes
Number of bytes occupied by MIPS halfword is 2.
handleExecBranchInst(int, boolean) –
Method in class mars.tools.BHTSimulator
Handles the execution of the branch instruction.
handleGrabAction(KeyEvent) –
Method in class mars.venus.editors.jeditsyntax.InputHandler
If a key is being grabbed, this method should be called with
the appropriate key event.
handlePreBranchInst(ProgramStatement) –
Method in class mars.tools.BHTSimulator
Handles the execution branch instruction.
HardcopyWriter – Class in mars.venus
HardcopyWriter(Frame, String, int, double, double, double, double) –
Constructor for class mars.venus.HardcopyWriter
The constructor for this class has a bunch of arguments:
The frame argument is required for all printing in Java.
HardcopyWriter.PrintCanceledException – Exception in mars.venus
This is the exception class that the HardcopyWriter constructor
throws when the user clicks “Cancel” in the print dialog box.
HardcopyWriter.PrintCanceledException(String) –
Constructor for exception mars.venus.HardcopyWriter.PrintCanceledException
hasCompactTranslation() –
Method in class mars.mips.instructions.ExtendedInstruction
Determine whether or not this pseudo-instruction has a second
translation optimized for 16 bit address space: a compact version.
hasUnsavedEdits() –
Method in class mars.venus.EditPane
Delegates to corresponding FileStatus method
hasUnsavedEdits() –
Method in class mars.venus.FileStatus
Determine if file has been modified since last save or, if not yet saved, since
being created using New or Open.
haveMenuRequestFocus() –
Method in class mars.venus.VenusUI
Have the menu request keyboard focus.
headerfont –
Variable in class mars.venus.HardcopyWriter
headermetrics –
Variable in class mars.venus.HardcopyWriter
headery –
Variable in class mars.venus.HardcopyWriter
heapAddress –
Static variable in class mars.mips.hardware.Memory
heapBaseAddress –
Static variable in class mars.mips.hardware.Memory
base address for heap: 0x10040000 (I think from SPIM not MIPS)
height –
Variable in class mars.venus.HardcopyWriter
HelpAboutAction – Class in mars.venus
Action for the Help -> About menu item
HelpAboutAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.HelpAboutAction
HelpHelpAction – Class in mars.venus
Action for the Help -> Help menu item
HelpHelpAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.HelpHelpAction
helpPath –
Static variable in class mars.Globals
Path to folder that contains help text
HEXADECIMAL –
Static variable in class mars.venus.NumberDisplayBaseChooser
hexStringToBinaryString(String) –
Static method in class mars.util.Binary
Translate String consisting of hexadecimal digits into String consisting of
corresponding binary digits (‘1’s and ‘0’s).
HexTextDumpFormat – Class in mars.mips.dump
Class that represents the “hexadecimal text” memory dump format.
HexTextDumpFormat() –
Constructor for class mars.mips.dump.HexTextDumpFormat
Constructor.
highlights –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
highlightStepAtAddress(int) –
Method in class mars.venus.TextSegmentWindow
Highlights the source code line whose address matches the given
text segment address.
highlightStepAtAddress(int, boolean) –
Method in class mars.venus.TextSegmentWindow
Highlights the source code line whose address matches the given
text segment address.
highlightStepAtPC() –
Method in class mars.venus.TextSegmentWindow
Highlights the source code line whose address matches the current
program counter value.
highlightStepAtPC(boolean) –
Method in class mars.venus.TextSegmentWindow
Highlights the source code line whose address matches the current
program counter value.
highOrderLongToInt(long) –
Static method in class mars.util.Binary
Returns int representing the bit values of the high order 32 bits of given
64 bit long value.
HOME –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
horizontal –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
horizontalOffset –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
I
I_BRANCH_FORMAT –
Static variable in class mars.mips.instructions.BasicInstructionFormat
I_FORMAT –
Static variable in class mars.mips.instructions.BasicInstructionFormat
id –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
The id of this token.
ID_COUNT –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
The total number of defined token ids.
IDENTIFIER –
Static variable in class mars.assembler.TokenTypes
imagesPath –
Static variable in class mars.Globals
Path to folder that contains images
INCLUDE –
Static variable in class mars.assembler.Directives
incrementPC() –
Static method in class mars.mips.hardware.RegisterFile
Method to increment the Program counter in the general case (not a jump or branch).
inDataSegment(int) –
Static method in class mars.mips.hardware.Memory
Handy little utility to find out if given address is in MARS data
segment (starts at Memory.dataSegmentBaseAddress).
inDelaySlot() –
Method in class mars.simulator.BackStepper
Determine whether the next back-step action occurred as the result of
an instruction that executed in the “delay slot” of a delayed branch.
inDelaySlot() –
Static method in class mars.simulator.Simulator
Determine whether or not the next instruction to be executed is in a
“delay slot”.
init(JEditTextArea, TextAreaPainter.Highlight) –
Method in interface mars.venus.editors.jeditsyntax.TextAreaPainter.Highlight
Called after the highlight painter has been added.
initBHT(int, int, boolean) –
Method in class mars.tools.BHTableModel
Initializes the BHT with the given size and history.
initialize(boolean) –
Static method in class mars.Globals
Method called once upon system initialization to create the global data structures.
initializePostGUI() –
Method in class mars.tools.AbstractMarsToolAndApplication
Method that will be called once just after the GUI is constructed in the go() and action()
methods.
initializePostGUI() –
Method in class mars.tools.BitmapDisplay
The only post-GUI initialization is to create the initial Grid object based on the default settings
of the various combo boxes.
initializePostGUI() –
Method in class mars.tools.CacheSimulator
The only post-GUI initialization is to create the initial cache object based on the default settings
of the various combo boxes.
initializePostGUI() –
Method in class mars.tools.KeyboardAndDisplaySimulator
Initialization code to be executed after the GUI is configured.
initializePostGUI() –
Method in class mars.tools.MemoryReferenceVisualization
The only post-GUI initialization is to create the initial Grid object based on the default settings
of the various combo boxes.
initializePreGUI() –
Method in class mars.tools.AbstractMarsToolAndApplication
Method that will be called once just before the GUI is constructed in the go() and action()
methods.
initializePreGUI() –
Method in class mars.tools.BitmapDisplay
Initialize all JComboBox choice structures not already initialized at declaration.
initializePreGUI() –
Method in class mars.tools.CacheSimulator
Initialize all JComboBox choice structures not already initialized at declaration.
initializePreGUI() –
Method in class mars.tools.InstructionCounter
initializePreGUI() –
Method in class mars.tools.InstructionStatistics
performs initialization tasks of the counters before the GUI is created.
initializePreGUI() –
Method in class mars.tools.KeyboardAndDisplaySimulator
initializePreGUI() –
Method in class mars.tools.MemoryReferenceVisualization
Initialize all JComboBox choice structures not already initialized at declaration.
initializeProgramCounter(int) –
Static method in class mars.mips.hardware.RegisterFile
For initializing the Program Counter.
initializeProgramCounter(boolean) –
Static method in class mars.mips.hardware.RegisterFile
Will initialize the Program Counter to either the default reset value, or the address
associated with source program global label “main”, if it exists as a text segment label
and the global setting is set.
inKernelDataSegment(int) –
Static method in class mars.mips.hardware.Memory
Handy little utility to find out if given address is in MARS kernel data
segment (starts at Memory.kernelDataSegmentBaseAddress).
inKernelTextSegment(int) –
Static method in class mars.mips.hardware.Memory
Handy little utility to find out if given address is in MARS kernel
text segment (starts at Memory.kernelTextBaseAddress).
inMemoryMapSegment(int) –
Static method in class mars.mips.hardware.Memory
Handy little utility to find out if given address is in the Memory Map area
starts at Memory.memoryMapBaseAddress, range 0xffff0000 to 0xffffffff.
InputHandler – Class in mars.venus.editors.jeditsyntax
An input handler converts the user’s key strokes into concrete actions.
InputHandler() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler
inputHandler –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
inputHandler –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
InputHandler.backspace – Class in mars.venus.editors.jeditsyntax
InputHandler.backspace() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.backspace
InputHandler.backspace_word – Class in mars.venus.editors.jeditsyntax
InputHandler.backspace_word() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.backspace_word
InputHandler.clip_copy – Class in mars.venus.editors.jeditsyntax
InputHandler.clip_copy() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.clip_copy
InputHandler.clip_cut – Class in mars.venus.editors.jeditsyntax
InputHandler.clip_cut() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.clip_cut
InputHandler.clip_paste – Class in mars.venus.editors.jeditsyntax
InputHandler.clip_paste() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.clip_paste
InputHandler.delete – Class in mars.venus.editors.jeditsyntax
InputHandler.delete() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.delete
InputHandler.delete_word – Class in mars.venus.editors.jeditsyntax
InputHandler.delete_word() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.delete_word
InputHandler.document_end – Class in mars.venus.editors.jeditsyntax
InputHandler.document_end(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.document_end
InputHandler.document_home – Class in mars.venus.editors.jeditsyntax
InputHandler.document_home(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.document_home
InputHandler.end – Class in mars.venus.editors.jeditsyntax
InputHandler.end(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.end
InputHandler.home – Class in mars.venus.editors.jeditsyntax
InputHandler.home(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.home
InputHandler.insert_break – Class in mars.venus.editors.jeditsyntax
InputHandler.insert_break() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.insert_break
InputHandler.insert_char – Class in mars.venus.editors.jeditsyntax
InputHandler.insert_char() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.insert_char
InputHandler.insert_tab – Class in mars.venus.editors.jeditsyntax
InputHandler.insert_tab() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.insert_tab
InputHandler.MacroRecorder – Interface in mars.venus.editors.jeditsyntax
Macro recorder.
InputHandler.next_char – Class in mars.venus.editors.jeditsyntax
InputHandler.next_char(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.next_char
InputHandler.next_line – Class in mars.venus.editors.jeditsyntax
InputHandler.next_line(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.next_line
InputHandler.next_page – Class in mars.venus.editors.jeditsyntax
InputHandler.next_page(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.next_page
InputHandler.next_word – Class in mars.venus.editors.jeditsyntax
InputHandler.next_word(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.next_word
InputHandler.NonRecordable – Interface in mars.venus.editors.jeditsyntax
If an action implements this interface, it should not be recorded
by the macro recorder.
InputHandler.NonRepeatable – Interface in mars.venus.editors.jeditsyntax
If an action implements this interface, it should not be repeated.
InputHandler.overwrite – Class in mars.venus.editors.jeditsyntax
InputHandler.overwrite() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.overwrite
InputHandler.prev_char – Class in mars.venus.editors.jeditsyntax
InputHandler.prev_char(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.prev_char
InputHandler.prev_line – Class in mars.venus.editors.jeditsyntax
InputHandler.prev_line(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.prev_line
InputHandler.prev_page – Class in mars.venus.editors.jeditsyntax
InputHandler.prev_page(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.prev_page
InputHandler.prev_word – Class in mars.venus.editors.jeditsyntax
InputHandler.prev_word(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.prev_word
InputHandler.repeat – Class in mars.venus.editors.jeditsyntax
InputHandler.repeat() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.repeat
InputHandler.select_all – Class in mars.venus.editors.jeditsyntax
InputHandler.select_all() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.select_all
InputHandler.toggle_rect – Class in mars.venus.editors.jeditsyntax
InputHandler.toggle_rect() –
Constructor for class mars.venus.editors.jeditsyntax.InputHandler.toggle_rect
InputHandler.Wrapper – Interface in mars.venus.editors.jeditsyntax
For use by EditAction.Wrapper only.
INSERT_BREAK –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
INSERT_CHAR –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
INSERT_TAB –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
insertLines(int, int) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Informs the token marker that lines have been inserted into
the document.
inSteppedExecution() –
Method in class mars.MIPSprogram
Will be true only while in process of simulating a program statement
in step mode (e.g.
Instruction – Class in mars.mips.instructions
Base class to represent member of MIPS instruction set.
Instruction() –
Constructor for class mars.mips.instructions.Instruction
INSTRUCTION_LENGTH –
Static variable in class mars.mips.instructions.Instruction
Length in bytes of a machine instruction.
INSTRUCTION_LENGTH_BITS –
Static variable in class mars.mips.instructions.Instruction
InstructionCounter – Class in mars.tools
Instruction counter tool.
InstructionCounter(String, String) –
Constructor for class mars.tools.InstructionCounter
Simple constructor, likely used to run a stand-alone memory reference visualizer.
InstructionCounter() –
Constructor for class mars.tools.InstructionCounter
Simple construction, likely used by the MARS Tools menu mechanism.
instructionSet –
Static variable in class mars.Globals
The set of implemented MIPS instructions.
InstructionSet – Class in mars.mips.instructions
The list of Instruction objects, each of which represents a MIPS instruction.
InstructionSet() –
Constructor for class mars.mips.instructions.InstructionSet
Creates a new InstructionSet object.
InstructionStatistics – Class in mars.tools
A MARS tool for obtaining instruction statistics by instruction category.
InstructionStatistics(String, String) –
Constructor for class mars.tools.InstructionStatistics
Simple constructor, likely used to run a stand-alone enhanced instruction counter.
InstructionStatistics() –
Constructor for class mars.tools.InstructionStatistics
Simple construction, likely used by the MARS Tools menu mechanism.
INTEGER_16 –
Static variable in class mars.assembler.TokenTypes
INTEGER_16U –
Static variable in class mars.assembler.TokenTypes
INTEGER_32 –
Static variable in class mars.assembler.TokenTypes
INTEGER_5 –
Static variable in class mars.assembler.TokenTypes
IntelHexDumpFormat – Class in mars.mips.dump
Intel’s Hex memory initialization format
IntelHexDumpFormat() –
Constructor for class mars.mips.dump.IntelHexDumpFormat
Constructor.
INTERNAL_FIRST –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
The first id that can be used for internal state
in a token marker.
INTERNAL_LAST –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
The last id that can be used for internal state
in a token marker.
interrupt() –
Method in class mars.simulator.SwingWorker
A new method that interrupts the worker thread.
inTextSegment(int) –
Static method in class mars.mips.hardware.Memory
Handy little utility to find out if given address is in MARS text
segment (starts at Memory.textBaseAddress).
IntroToTools – Class in mars.tools
The “hello world” of MarsTools!
IntroToTools(String, String) –
Constructor for class mars.tools.IntroToTools
Simple constructor, likely used to run a stand-alone memory reference visualizer.
IntroToTools() –
Constructor for class mars.tools.IntroToTools
Simple constructor, likely used by the MARS Tools menu mechanism
intToAscii(int) –
Static method in class mars.util.Binary
Produce ASCII string equivalent of integer value, interpreting it as 4 one-byte
characters.
intToBinaryString(int, int) –
Static method in class mars.util.Binary
Translate int value into a String consisting of ‘1’s and ‘0’s.
intToBinaryString(int) –
Static method in class mars.util.Binary
Translate int value into a String consisting of ‘1’s and ‘0’s.
intToHalfHexString(int) –
Static method in class mars.util.Binary
Returns a 6 character string representing the 16-bit hexadecimal equivalent of the
given integer value.
intToHexString(int) –
Static method in class mars.util.Binary
Prefix a hexadecimal-indicating string “0x” to the string which is
returned by the method “Integer.toHexString”.
INVALID –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Invalid token id.
invalidateLine(int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Marks a line as needing a repaint.
invalidateLineRange(int, int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Marks a range of lines as needing a repaint.
invalidateSelectedLines() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Repaints the lines containing the selection.
InvalidRegisterAccessException – Exception in mars.mips.hardware
Represents attempt to access double precision register using an odd
(e.g.
InvalidRegisterAccessException() –
Constructor for exception mars.mips.hardware.InvalidRegisterAccessException
Constructor for IllegalRegisterException.
isAssembled() –
Static method in class mars.venus.FileStatus
Tells whether the file has been assembled.
isBeingUsedAsAMarsTool –
Variable in class mars.tools.AbstractMarsToolAndApplication
isBlockCaretEnabled() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns true if the caret should be drawn as a block, false otherwise.
isBold() –
Method in class mars.venus.editors.jeditsyntax.SyntaxStyle
Returns true if boldface is enabled for this style.
isBracketHighlightEnabled() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns true if bracket highlighting is enabled, false otherwise.
isBranchInstruction(ProgramStatement) –
Static method in class mars.tools.BHTSimulator
Determines if the instruction is a branch instruction or not.
isCaretBlinkEnabled() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns true if the caret is blinking, false otherwise.
isCaretVisible() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns true if the caret is visible, false otherwise.
isConnected() –
Method in class mars.tools.AbstractMarsToolAndApplication.ConnectButton
isEditable() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns true if this text area is editable, false otherwise.
isEdited() –
Static method in class mars.venus.FileStatus
Tells whether the file has been edited since it has been saved.
isEmpty() –
Method in class mars.assembler.TokenList
Returns empty/non-empty status of list.
isFloatingDirective(Directives) –
Static method in class mars.assembler.Directives
Lets you know whether given directive is for floating number (FLOAT,DOUBLE).
isFloatingTokenType(TokenTypes) –
Static method in class mars.assembler.TokenTypes
Lets you know if given tokentype is for floating point numbers (REAL_NUMBER).
isHex(String) –
Static method in class mars.util.Binary
Parsing method to see if a string represents a hex number.
isIntegerDirective(Directives) –
Static method in class mars.assembler.Directives
Lets you know whether given directive is for integer (WORD,HALF,BYTE).
isIntegerTokenType(TokenTypes) –
Static method in class mars.assembler.TokenTypes
Lets you know if given tokentype is for integers (INTGER_5, INTEGER_16, INTEGER_32).
isItalic() –
Method in class mars.venus.editors.jeditsyntax.SyntaxStyle
Returns true if italics is enabled for this style.
isLineHighlightEnabled() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns true if line highlight is enabled, false otherwise.
isManagingFocus() –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Returns if this component can be traversed by pressing the
Tab key.
isNew() –
Method in class mars.venus.EditPane
Delegates to corresponding FileStatus method
isNew() –
Method in class mars.venus.FileStatus
Determine if file is “new”, which means created using New but not yet saved.
isNextLineRequested() –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Returns true if the next line should be repainted.
isObserving() –
Method in class mars.tools.AbstractMarsToolAndApplication
Query method to let you know if the tool/app is (or could be) currently
“observing” any MIPS resources.
isOctal(String) –
Static method in class mars.util.Binary
Parsing method to see if a string represents an octal number.
isOverwriteEnabled() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns true if overwrite mode is enabled, false otherwise.
isPlain() –
Method in class mars.venus.editors.jeditsyntax.SyntaxStyle
Returns true if no font styles are enabled.
isRepeatEnabled() –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Returns if repeating is enabled.
isRepeatEnabled() –
Method in class mars.venus.RepeatButton
Checks if the button should fire events when held.
isSaved() –
Static method in class mars.venus.FileStatus
Tells whether the file has been saved.
isSelectionRectangular() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Returns true if the selection is rectangular, false otherwise.
isValidIdentifier(String) –
Static method in class mars.assembler.TokenTypes
isWarning() –
Method in class mars.ErrorMessage
Determine whether this message represents error or warning.
J
J_FORMAT –
Static variable in class mars.mips.instructions.BasicInstructionFormat
JEditBasedTextArea – Class in mars.venus.editors.jeditsyntax
Adaptor subclass for JEditTextArea
Provides those methods required by the MARSTextEditingArea interface
that are not defined by JEditTextArea.
JEditBasedTextArea(EditPane, JComponent) –
Constructor for class mars.venus.editors.jeditsyntax.JEditBasedTextArea
JEditTextArea – Class in mars.venus.editors.jeditsyntax
jEdit’s text area component.
JEditTextArea(JComponent) –
Constructor for class mars.venus.editors.jeditsyntax.JEditTextArea
Creates a new JEditTextArea with the default settings.
JEditTextArea(TextAreaDefaults, JComponent) –
Constructor for class mars.venus.editors.jeditsyntax.JEditTextArea
job –
Variable in class mars.venus.HardcopyWriter
jobname –
Variable in class mars.venus.HardcopyWriter
K
KDATA –
Static variable in class mars.assembler.Directives
kernelBaseAddress –
Static variable in class mars.mips.hardware.Memory
kernel boundary.
kernelDataBaseAddress –
Static variable in class mars.mips.hardware.Memory
base address for kernel data segment: 0x90000000
kernelDataSegmentLimitAddress –
Static variable in class mars.mips.hardware.Memory
kernelHighAddress –
Static variable in class mars.mips.hardware.Memory
highest address acessible in kernel mode.
kernelTextBaseAddress –
Static variable in class mars.mips.hardware.Memory
base address for kernel text segment: 0x80000000
kernelTextLimitAddress –
Static variable in class mars.mips.hardware.Memory
KeyboardAndDisplaySimulator – Class in mars.tools
Keyboard and Display Simulator.
KeyboardAndDisplaySimulator(String, String) –
Constructor for class mars.tools.KeyboardAndDisplaySimulator
Simple constructor, likely used to run a stand-alone keyboard/display simulator.
KeyboardAndDisplaySimulator() –
Constructor for class mars.tools.KeyboardAndDisplaySimulator
Simple constructor, likely used by the MARS Tools menu mechanism
keyPressed(KeyEvent) –
Method in class mars.tools.AbstractMarsToolAndApplication.EnterKeyListener
keyPressed(KeyEvent) –
Method in class mars.venus.editors.jeditsyntax.DefaultInputHandler
Handle a key pressed event.
keyTyped(KeyEvent) –
Method in class mars.venus.editors.jeditsyntax.DefaultInputHandler
Handle a key typed event.
KEYWORD1 –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Keyword 1 token id.
KEYWORD2 –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Keyword 2 token id.
KEYWORD3 –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Keyword 3 token id.
KeywordMap – Class in mars.venus.editors.jeditsyntax
A KeywordMap is similar to a hashtable in that it maps keys
to values.
KeywordMap(boolean) –
Constructor for class mars.venus.editors.jeditsyntax.KeywordMap
Creates a new KeywordMap.
KeywordMap(boolean, int) –
Constructor for class mars.venus.editors.jeditsyntax.KeywordMap
Creates a new KeywordMap.
KTEXT –
Static variable in class mars.assembler.Directives
L
LABEL –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Label token id.
LABEL_SORT_STATE –
Static variable in class mars.Settings
State for sorting label window display
LABEL_WINDOW_VISIBILITY –
Static variable in class mars.Settings
Default visibilty of label window (symbol table).
LabelsWindow – Class in mars.venus
Represents the Labels window, which is a type of JInternalFrame.
LabelsWindow() –
Constructor for class mars.venus.LabelsWindow
Constructor for the Labels (symbol table) window.
lastAddress –
Variable in class mars.tools.InstructionCounter
The last address we saw.
lastAddress –
Variable in class mars.tools.InstructionStatistics
The last address we saw.
lastLine –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
The last tokenized line.
lastToken –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
The last token in the list.
LEFT_OF_SCROLLBAR –
Static variable in class mars.venus.editors.jeditsyntax.JEditTextArea
Adding components with this name to the text area will place
them left of the horizontal scroll bar.
LEFT_PAREN –
Static variable in class mars.assembler.TokenTypes
length –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
The length of this token.
length –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
The number of lines in the model being tokenized.
LINE_PREFIX –
Static variable in class mars.ErrorList
lineascent –
Variable in class mars.venus.HardcopyWriter
lineheight –
Variable in class mars.venus.HardcopyWriter
lineHighlight –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
lineHighlight –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
lineHighlightColor –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
lineHighlightColor –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
lineInfo –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
An array for storing information about lines.
linenum –
Variable in class mars.venus.HardcopyWriter
lines_per_page –
Variable in class mars.venus.HardcopyWriter
lineSegment –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
lineToY(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Converts a line index to a y co-ordinate.
listenerList –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
LITERAL1 –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Literal 1 token id.
LITERAL2 –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Literal 2 token id.
LITTLE_ENDIAN –
Static variable in class mars.mips.hardware.Memory
Constant representing byte order of each memory word.
loadDumpFormats() –
Method in class mars.mips.dump.DumpFormatLoader
Dynamically loads dump formats into an ArrayList.
loadPropertiesFromFile(String) –
Static method in class mars.util.PropertiesFile
Produce Properties (a Hashtable) object containing key-value pairs
from specified properties file.
longToBinaryString(long, int) –
Static method in class mars.util.Binary
Translate long value into a String consisting of ‘1’s and ‘0’s.
longToBinaryString(long) –
Static method in class mars.util.Binary
Translate long value into a String consisting of ‘1’s and ‘0’s.
longToHexString(long) –
Static method in class mars.util.Binary
Prefix a hexadecimal-indicating string “0x” to the string equivalent to the
hexadecimal value in the long parameter.
lookup(Segment, int, int) –
Method in class mars.venus.editors.jeditsyntax.KeywordMap
Looks up a key.
LOW_DOUBLE_VALUE –
Static variable in class mars.assembler.DataTypes
Largest magnitude negative value that can be stored in a MIPS double(negative of the max)
LOW_FLOAT_VALUE –
Static variable in class mars.assembler.DataTypes
Largest magnitude negative value that can be stored in a MIPS float (negative of the max)
lowOrderLongToInt(long) –
Static method in class mars.util.Binary
Returns int representing the bit values of the low order 32 bits of given
64 bit long value.
M
MACRO –
Static variable in class mars.assembler.Directives
Macro – Class in mars.assembler
Stores information of a macro definition.
Macro() –
Constructor for class mars.assembler.Macro
MACRO_ARG –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Macro parameter token.
MACRO_PARAMETER –
Static variable in class mars.assembler.TokenTypes
MacroPool – Class in mars.assembler
Stores information of macros defined by now.
MacroPool(MIPSprogram) –
Constructor for class mars.assembler.MacroPool
Create an empty MacroPool for given program
magicCaret –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
main(String[]) –
Static method in class Mars
main(String[]) –
Static method in class mars.tools.BitmapDisplay
Main provided for pure stand-alone use.
main(String[]) –
Static method in class mars.tools.CacheSimulator
Main provided for pure stand-alone use.
main(String[]) –
Static method in class mars.tools.DigitalLabSim
main(String[]) –
Static method in class mars.tools.FloatRepresentation
Main provided for pure stand-alone use.
main(String[]) –
Static method in class mars.tools.IntroToTools
Main provided for pure stand-alone use.
main(String[]) –
Static method in class mars.tools.KeyboardAndDisplaySimulator
Main provided for pure stand-alone use.
main(String[]) –
Static method in class mars.tools.MemoryReferenceVisualization
Main provided for pure stand-alone use.
main(String[]) –
Static method in class mars.tools.ScreenMagnifier
main(String[]) –
Static method in class mars.venus.HardcopyWriter
A program that prints the specified file using HardcopyWriter
main(String[]) –
Static method in class mars.venus.RepeatButton
Main method, for testing.
MainPane – Class in mars.venus
Creates the tabbed areas in the UI and also created the internal windows that
exist in them.
MainPane(VenusUI, Editor, RegistersWindow, Coprocessor1Window, Coprocessor0Window) –
Constructor for class mars.venus.MainPane
Constructor for the MainPane class.
mainUI –
Variable in class mars.venus.GuiAction
makeTemplateSubstitutions(MIPSprogram, String, TokenList) –
Static method in class mars.mips.instructions.ExtendedInstruction
Given a basic instruction template and the list of tokens from an extended
instruction statement, substitute operands from the token list appropriately into the
template to generate the basic statement.
mapLength –
Variable in class mars.venus.editors.jeditsyntax.KeywordMap
markTokens(Segment, int) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
A wrapper for the lower-level markTokensImpl method
that is called to split a line up into tokens.
markTokensImpl(byte, Segment, int) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
markTokensImpl(byte, Segment, int) –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
An abstract method that splits a line up into tokens.
mars – package mars
Mars – Class in
Portal to Mars
Mars() –
Constructor for class Mars
mars.assembler – package mars.assembler
mars.mips.dump – package mars.mips.dump
mars.mips.hardware – package mars.mips.hardware
mars.mips.instructions – package mars.mips.instructions
mars.mips.instructions.syscalls – package mars.mips.instructions.syscalls
mars.simulator – package mars.simulator
mars.tools – package mars.tools
mars.util – package mars.util
mars.venus – package mars.venus
mars.venus.editors – package mars.venus.editors
mars.venus.editors.generic – package mars.venus.editors.generic
mars.venus.editors.jeditsyntax – package mars.venus.editors.jeditsyntax
mars.venus.editors.jeditsyntax.tokenmarker – package mars.venus.editors.jeditsyntax.tokenmarker
MarsBot – Class in mars.tools
Simple Demo of Mars tool capability
MarsBot() –
Constructor for class mars.tools.MarsBot
MarsLaunch – Class in mars
Launch the Mars application
MarsLaunch(String[]) –
Constructor for class mars.MarsLaunch
MarsSplashScreen – Class in mars
Produces MARS splash screen.
Adapted from http://www.java-tips.org/content/view/1267/2/
MarsSplashScreen(int) –
Constructor for class mars.MarsSplashScreen
MARSTextEditingArea – Interface in mars.venus.editors
Specifies capabilities that any test editor used in MARS must have.
MarsTool – Interface in mars.tools
Interface for any tool that interacts with an executing MIPS program.
MATCH_ALL_EXTENSIONS –
Static variable in class mars.util.FilenameFinder
matchDirective(String) –
Static method in class mars.assembler.Directives
Find Directive object, if any, which matches the given String.
matchesAnyMacroName(String) –
Method in class mars.assembler.MacroPool
matchOperator(String) –
Method in class mars.mips.instructions.InstructionSet
Given an operator mnemonic, will return the corresponding Instruction object(s)
from the instruction set.
matchTokenType(String) –
Static method in class mars.assembler.TokenTypes
Classifies the given token into one of the MIPS types.
MAX_BLINK_RATE –
Static variable in class mars.venus.Editor
MAX_BYTE_VALUE –
Static variable in class mars.assembler.DataTypes
Maximum value that can be stored in a MIPS byte is 27-1
MAX_DOUBLE_VALUE –
Static variable in class mars.assembler.DataTypes
Maximum positive finite value that can be stored in a MIPS double is same as Java Double
MAX_FLOAT_VALUE –
Static variable in class mars.assembler.DataTypes
Maximum positive finite value that can be stored in a MIPS float is same as Java Float
MAX_HALF_VALUE –
Static variable in class mars.assembler.DataTypes
Maximum value that can be stored in a MIPS halfword is 215-1
MAX_SIZE –
Static variable in class mars.util.EditorFont
MAX_STEPS –
Static variable in class mars.simulator.Simulator
MAX_TAB_SIZE –
Static variable in class mars.venus.Editor
MAX_UHALF_VALUE –
Static variable in class mars.assembler.DataTypes
Maximum value that can be stored in an unsigned MIPS halfword is 216-1
MAX_WORD_VALUE –
Static variable in class mars.assembler.DataTypes
Maximum value that can be stored in a MIPS word is 231-1
maxExampleLength(ArrayList) –
Static method in class mars.venus.editors.jeditsyntax.PopupHelpItem
MAXIMUM_SCROLLED_CHARACTERS –
Static variable in class mars.venus.MessagesPane
maximumBacksteps –
Static variable in class mars.Globals
Maximum number of back-step operations to buffer
maximumErrorMessages –
Static variable in class mars.Globals
Maximum number of assembler errors produced by one assemble operation
maximumMessageCharacters –
Static variable in class mars.Globals
Maximum length of scrolled message window (MARS Messages and Run I/O)
maxSteps –
Static variable in class mars.venus.RunGoAction
memory –
Static variable in class mars.Globals
Simulated MIPS memory component.
Memory – Class in mars.mips.hardware
Represents MIPS memory.
MEMORY_CONFIGURATION –
Static variable in class mars.Settings
Identifier of current memory configuration
MemoryAccessNotice – Class in mars.mips.hardware
Object provided to Observers of runtime access to MIPS memory.
MemoryAccessNotice(int, int, int) –
Constructor for class mars.mips.hardware.MemoryAccessNotice
Constructor will be called only within this package, so assume
address is in valid range.
memoryAndRegistersLock –
Static variable in class mars.Globals
Lock variable used at head of synchronized block to guard MIPS memory and registers
MemoryConfiguration – Class in mars.mips.hardware
Models the memory configuration for the simulated MIPS machine.
MemoryConfiguration(String, String, String[], int[]) –
Constructor for class mars.mips.hardware.MemoryConfiguration
MemoryConfigurations – Class in mars.mips.hardware
Models the collection of MIPS memory configurations.
MemoryConfigurations() –
Constructor for class mars.mips.hardware.MemoryConfigurations
MemoryDump – Class in mars.util
MemoryDump() –
Constructor for class mars.util.MemoryDump
memoryMapBaseAddress –
Static variable in class mars.mips.hardware.Memory
starting address for memory mapped I/O: 0xffff0000 (-65536)
memoryMapLimitAddress –
Static variable in class mars.mips.hardware.Memory
MemoryReferenceVisualization – Class in mars.tools
Memory reference visualization.
MemoryReferenceVisualization(String, String) –
Constructor for class mars.tools.MemoryReferenceVisualization
Simple constructor, likely used to run a stand-alone memory reference visualizer.
MemoryReferenceVisualization() –
Constructor for class mars.tools.MemoryReferenceVisualization
Simple constructor, likely used by the MARS Tools menu mechanism
menu –
Variable in class mars.venus.VenusUI
MESSAGE_SEPARATOR –
Static variable in class mars.ErrorList
MessagesPane – Class in mars.venus
Creates the message window at the bottom of the UI.
MessagesPane() –
Constructor for class mars.venus.MessagesPane
Constructor for the class, sets up two fresh tabbed text areas for program feedback.
metrics –
Variable in class mars.venus.HardcopyWriter
MIFDumpFormat – Class in mars.mips.dump
The Memory Initialization File (.mif) VHDL-supported file format
This is documented for the Altera platform at
www.altera.com/support/software/nativelink/quartus2/glossary/def_mif.html.
MIFDumpFormat() –
Constructor for class mars.mips.dump.MIFDumpFormat
Constructor.
MIN_BLINK_RATE –
Static variable in class mars.venus.Editor
MIN_BYTE_VALUE –
Static variable in class mars.assembler.DataTypes
Lowest value that can be stored in a MIPS byte is -27
MIN_HALF_VALUE –
Static variable in class mars.assembler.DataTypes
Lowest value that can be stored in a MIPS halfword is -215
MIN_SIZE –
Static variable in class mars.util.EditorFont
MIN_TAB_SIZE –
Static variable in class mars.venus.Editor
MIN_UHALF_VALUE –
Static variable in class mars.assembler.DataTypes
Lowest value that can be stored in na unsigned MIPS halfword is 0
MIN_WORD_VALUE –
Static variable in class mars.assembler.DataTypes
Lowest value that can be stored in a MIPS word is -231
MINUS –
Static variable in class mars.assembler.TokenTypes
MIPSprogram – Class in mars
Internal representations of MIPS program.
MIPSprogram() –
Constructor for class mars.MIPSprogram
MIPSTokenMarker – Class in mars.venus.editors.jeditsyntax.tokenmarker
MIPS token marker.
MIPSTokenMarker() –
Constructor for class mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
MIPSTokenMarker(KeywordMap) –
Constructor for class mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
mnemonic –
Variable in class mars.mips.instructions.Instruction
The instruction name.
modifyDisplay(char) –
Method in class mars.tools.DigitalLabSim.SevenSegmentDisplay
modifyDisplay(int, char) –
Method in class mars.tools.DigitalLabSim.SevenSegmentPanel
mouseClicked(MouseEvent) –
Method in class mars.tools.DigitalLabSim.HexaKeyboard.EcouteurClick
mouseClicked(MouseEvent) –
Method in class mars.venus.RepeatButton
Handle mouse clicked events.
mouseEntered(MouseEvent) –
Method in class mars.tools.DigitalLabSim.HexaKeyboard.EcouteurClick
mouseEntered(MouseEvent) –
Method in class mars.venus.RepeatButton
Handle mouse entered events.
mouseExited(MouseEvent) –
Method in class mars.tools.DigitalLabSim.HexaKeyboard.EcouteurClick
mouseExited(MouseEvent) –
Method in class mars.venus.RepeatButton
Handle mouse exited events.
mousePressed(MouseEvent) –
Method in class mars.tools.DigitalLabSim.HexaKeyboard.EcouteurClick
mousePressed(MouseEvent) –
Method in class mars.venus.PopupListener
mousePressed(MouseEvent) –
Method in class mars.venus.RepeatButton
Handle mouse pressed events.
mouseReleased(MouseEvent) –
Method in class mars.tools.DigitalLabSim.HexaKeyboard.EcouteurClick
mouseReleased(MouseEvent) –
Method in class mars.venus.PopupListener
mouseReleased(MouseEvent) –
Method in class mars.venus.RepeatButton
Handle mouse released events.
N
NEW_EDITED –
Static variable in class mars.venus.FileStatus
New edit window with unsaved edits
NEW_NOT_EDITED –
Static variable in class mars.venus.FileStatus
New edit window with no edits
newFile() –
Method in class mars.venus.Editor
Perform “new” operation to create an empty tab.
newFile() –
Method in class mars.venus.EditTabbedPane
Carries out all necessary operations to implement
the New operation from the File menu.
newline() –
Method in class mars.venus.HardcopyWriter
This internal method begins a new line
newpage() –
Method in class mars.venus.HardcopyWriter
This internal method begins a new page and prints the header.
next –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
The next token in the linked list.
NEXT_CHAR –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
NEXT_LINE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
NEXT_PAGE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
NEXT_WORD –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
nextIndex(String, String, int, boolean) –
Method in class mars.venus.editors.generic.GenericTextArea
Returns next posn of word in text – forward search.
nextIndex(String, String, int, boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Returns next posn of word in text – forward search.
nextLineRequested –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
True if the next line should be painted.
nextTabStop(float, int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Implementation of TabExpander interface.
NO_DEVICE –
Static variable in class mars.simulator.Simulator
NO_FILE –
Static variable in class mars.venus.FileStatus
initial state or after close
NORMAL_TERMINATION –
Static variable in class mars.simulator.Simulator
NOT_EDITED –
Static variable in class mars.venus.FileStatus
open/saved edit window with no edits
NOT_FOUND –
Static variable in class mars.assembler.SymbolTable
notifyObservers() –
Method in class mars.mips.hardware.Memory
Overridden to be unavailable.
notifyObservers(Object) –
Method in class mars.mips.hardware.Memory
Overridden to be unavailable.
NULL –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Normal text token id.
NUMBER_OF_CHARACTERS_TO_CUT –
Static variable in class mars.venus.MessagesPane
numberDisplayBaseChanged(NumberDisplayBaseChooser) –
Method in class mars.venus.ExecutePane
Update display of columns based on state of given chooser.
NumberDisplayBaseChooser – Class in mars.venus
Use to select base for displaying numbers.
NumberDisplayBaseChooser(String, boolean) –
Constructor for class mars.venus.NumberDisplayBaseChooser
constructor.
O
obj –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker.LineInfo
This is for use by the token marker implementations
themselves.
ODD_ROW_BACKGROUND –
Static variable in class mars.Settings
RGB color for table odd row background (text, data, register displays)
ODD_ROW_FONT –
Static variable in class mars.Settings
Font for table odd row background (text, data, register displays)
ODD_ROW_FOREGROUND –
Static variable in class mars.Settings
RGB color for table odd row foreground (text, data, register displays)
offsetToX(int, int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Converts an offset in a line into an x co-ordinate.
open() –
Method in class mars.venus.Editor
Open file in a new tab.
openFile(String, int) –
Static method in class mars.util.SystemIO
Open a file for either reading or writing.
openFile() –
Method in class mars.venus.EditTabbedPane
Carries out all necessary operations to implement
the Open operation from the File menu.
openFile(File) –
Method in class mars.venus.EditTabbedPane
Carries out all necessary operations to open the
specified file in the editor.
OPENING –
Static variable in class mars.venus.FileStatus
file is being opened.
OperandFormat – Class in mars.assembler
Provides utility method related to MIPS operand formats.
operandMask –
Static variable in class mars.mips.instructions.Instruction
Characters used in instruction mask to indicate bit positions
for ‘f’irst, ‘s’econd, and ‘t’hird operands.
OPERATOR –
Static variable in class mars.assembler.TokenTypes
OPERATOR –
Static variable in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Operator token id.
outOfRange(Directives, int) –
Static method in class mars.assembler.DataTypes
Determines whether given integer value falls within value range for given directive.
outOfRange(Directives, double) –
Static method in class mars.assembler.DataTypes
Determines whether given floating point value falls within value range for given directive.
OVERWRITE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
overwrite –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
overwriteSetSelectedText(String) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Similar to setSelectedText(), but overstrikes the
appropriate number of characters if overwrite mode is enabled.
P
page –
Variable in class mars.venus.HardcopyWriter
pageBreak() –
Method in class mars.venus.HardcopyWriter
End the current page.
pagedpi –
Variable in class mars.venus.HardcopyWriter
pagenum –
Variable in class mars.venus.HardcopyWriter
pagesize –
Variable in class mars.venus.HardcopyWriter
paint(Graphics) –
Method in class mars.tools.DigitalLabSim.SevenSegmentDisplay
paint(Graphics) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Repaints the text.
paintBracketHighlight(Graphics, int, int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
paintCaret(Graphics, int, int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
painter –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
paintHighlight(Graphics, int, int) –
Method in interface mars.venus.editors.jeditsyntax.TextAreaPainter.Highlight
This should paint the highlight and delgate to the
next highlight painter.
paintHighlight(Graphics, int, int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
paintInvalid –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
paintInvalid –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
paintLine(Graphics, TokenMarker, int, int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
paintLineHighlight(Graphics, int, int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
paintPlainLine(Graphics, int, Font, Color, int, int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
paintSyntaxLine(Segment, Token, SyntaxStyle[], TabExpander, Graphics, int, int) –
Static method in class mars.venus.editors.jeditsyntax.SyntaxUtilities
paintSyntaxLine(Graphics, TokenMarker, int, Font, Color, int, int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
parseKeyStroke(String) –
Static method in class mars.venus.editors.jeditsyntax.DefaultInputHandler
Converts a string to a keystroke.
paste() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Inserts the clipboard contents into the text.
paste() –
Method in interface mars.venus.editors.MARSTextEditingArea
pasteText() –
Method in class mars.venus.EditPane
paste clipboard contents at cursor position
PAUSE_OR_STOP –
Static variable in class mars.simulator.Simulator
paused(boolean, int, ProcessingException) –
Method in class mars.venus.RunGoAction
Method to be called when Pause is selected through menu/toolbar/shortcut.
performApply() –
Method in class mars.venus.AbstractFontSettingDialog
performSpecialClosingDuties() –
Method in class mars.tools.AbstractMarsToolAndApplication
This method is called when tool/app is exited either through the close/exit button or the window’s X box.
PLUS –
Static variable in class mars.assembler.TokenTypes
popFromCallStack() –
Method in class mars.assembler.MacroPool
populate() –
Method in class mars.mips.instructions.InstructionSet
Adds all instructions to the set.
popup –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
popup –
Static variable in class mars.venus.editors.jeditsyntax.SyntaxUtilities
popup –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
POPUP_INSTRUCTION_GUIDANCE –
Static variable in class mars.Settings
Flag to control whether or not editor will provide popup instruction guidance while typing
POPUP_SYSCALL_INPUT –
Static variable in class mars.Settings
Flag to control whether or not simulator will use popup dialog for input syscalls
PopupHelpItem – Class in mars.venus.editors.jeditsyntax
Handly little class to contain help information for a popupMenu or
tool tip item.
PopupHelpItem(String, String, String, boolean) –
Constructor for class mars.venus.editors.jeditsyntax.PopupHelpItem
Create popup help item.
PopupHelpItem(String, String, String) –
Constructor for class mars.venus.editors.jeditsyntax.PopupHelpItem
Create popup help item, where match is result of an exact-match search.
PopupListener – Class in mars.venus
PopupListener(JPopupMenu) –
Constructor for class mars.venus.PopupListener
popupShowing –
Static variable in class mars.venus.editors.jeditsyntax.SyntaxUtilities
Paints the specified line onto the graphics context.
POSITION_PREFIX –
Static variable in class mars.ErrorList
postMarsMessage(String) –
Method in class mars.venus.MessagesPane
Post a message to the assembler display
postRunMessage(String) –
Method in class mars.venus.MessagesPane
Post a message to the runtime display
preferredTextAreaDimension –
Static variable in class mars.tools.KeyboardAndDisplaySimulator
prefixMatchDirectives(String) –
Static method in class mars.assembler.Directives
Find Directive object, if any, which contains the given string as a prefix.
prefixMatchOperator(String) –
Method in class mars.mips.instructions.InstructionSet
Given a string, will return the Instruction object(s) from the instruction
set whose operator mnemonic prefix matches it.
prepareFilesForAssembly(ArrayList, String, String) –
Method in class mars.MIPSprogram
Prepares the given list of files for assembly.
PREV_CHAR –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
PREV_LINE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
PREV_PAGE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
PREV_WORD –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
printprops –
Static variable in class mars.venus.HardcopyWriter
printString(String) –
Static method in class mars.util.SystemIO
Implements syscall having 4 in $v0, to print a string.
ProcessingException – Exception in mars
Class to represent error that occurs while assembling or running a MIPS program.
ProcessingException(ErrorList) –
Constructor for exception mars.ProcessingException
Constructor for ProcessingException.
ProcessingException(ErrorList, AddressErrorException) –
Constructor for exception mars.ProcessingException
Constructor for ProcessingException.
ProcessingException(ProgramStatement, String) –
Constructor for exception mars.ProcessingException
Constructor for ProcessingException to handle runtime exceptions
ProcessingException(ProgramStatement, String, int) –
Constructor for exception mars.ProcessingException
Constructor for ProcessingException to handle runtime exceptions
ProcessingException(ProgramStatement, AddressErrorException) –
Constructor for exception mars.ProcessingException
Constructor for ProcessingException to handle address runtime exceptions
ProcessingException() –
Constructor for exception mars.ProcessingException
Constructor for ProcessingException.
processKeyEvent(KeyEvent) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Forwards key events directly to the input handler.
processMIPSUpdate(Observable, AccessNotice) –
Method in class mars.tools.AbstractMarsToolAndApplication
Override this method to process a received notice from MIPS Observable (memory or register)
It will only be called if the notice was generated as the result of MIPS instruction execution.
processMIPSUpdate(Observable, AccessNotice) –
Method in class mars.tools.BHTSimulator
Callback for text segment access by the MIPS simulator.
processMIPSUpdate(Observable, AccessNotice) –
Method in class mars.tools.BitmapDisplay
Update display when connected MIPS program accesses (data) memory.
processMIPSUpdate(Observable, AccessNotice) –
Method in class mars.tools.CacheSimulator
Apply caching policies and update display when connected MIPS program accesses (data) memory.
processMIPSUpdate(Observable, AccessNotice) –
Method in class mars.tools.InstructionCounter
processMIPSUpdate(Observable, AccessNotice) –
Method in class mars.tools.InstructionStatistics
method that is called each time the MIPS simulator accesses the text segment.
processMIPSUpdate(Observable, AccessNotice) –
Method in class mars.tools.KeyboardAndDisplaySimulator
Update display when connected MIPS program accesses (data) memory.
processMIPSUpdate(Observable, AccessNotice) –
Method in class mars.tools.MemoryReferenceVisualization
Update display when connected MIPS program accesses (data) memory.
program –
Static variable in class mars.Globals
the program currently being worked with.
PROGRAM_ARGUMENTS –
Static variable in class mars.Settings
Flag to determine whether or not to display and use program arguments
ProgramArgumentList – Class in mars.simulator
Models Program Arguments, one or more strings provided to the MIPS
program at runtime.
ProgramArgumentList(String) –
Constructor for class mars.simulator.ProgramArgumentList
Constructor that parses string to produce list.
ProgramArgumentList(String[]) –
Constructor for class mars.simulator.ProgramArgumentList
Constructor that gets list from String array, one argument per element.
ProgramArgumentList(String[], int) –
Constructor for class mars.simulator.ProgramArgumentList
Constructor that gets list from section of String array, one
argument per element.
ProgramArgumentList(ArrayList) –
Constructor for class mars.simulator.ProgramArgumentList
Constructor that gets list from ArrayList of String, one argument per element.
ProgramArgumentList(ArrayList, int) –
Constructor for class mars.simulator.ProgramArgumentList
Constructor that gets list from section of String ArrayList, one
argument per element.
ProgramStatement – Class in mars
Represents one assembly/machine statement.
ProgramStatement(MIPSprogram, String, TokenList, TokenList, Instruction, int, int) –
Constructor for class mars.ProgramStatement
Constructor for ProgramStatement when there are links back to all source and token
information.
ProgramStatement(int, int) –
Constructor for class mars.ProgramStatement
Constructor for ProgramStatement used only for writing a binary machine
instruction with no source code to refer back to.
PropertiesFile – Class in mars.util
Provides means to work with “.properties” files which are used to store
various MARS settings.
PropertiesFile() –
Constructor for class mars.util.PropertiesFile
pushOnCallStack(Token) –
Method in class mars.assembler.MacroPool
Q
QUOTED_STRING –
Static variable in class mars.assembler.TokenTypes
R
R_FORMAT –
Static variable in class mars.mips.instructions.BasicInstructionFormat
RandomStreams – Class in mars.mips.instructions.syscalls
This small class serves only to hold a static HashMap for storing
random number generators for use by all the random number generator
syscalls.
RandomStreams() –
Constructor for class mars.mips.instructions.syscalls.RandomStreams
READ –
Static variable in class mars.mips.hardware.AccessNotice
Indicates the purpose of access was to read.
readChar(int) –
Static method in class mars.util.SystemIO
Implements syscall having 12 in $v0, to read a char value.
readDouble(int) –
Static method in class mars.util.SystemIO
Implements syscall to read a double value.
readFloat(int) –
Static method in class mars.util.SystemIO
Implements syscall to read a float value.
readFromFile(int, byte[], int) –
Static method in class mars.util.SystemIO
Read bytes from file.
readInteger(int) –
Static method in class mars.util.SystemIO
Implements syscall to read an integer value.
readSource(String) –
Method in class mars.MIPSprogram
Reads MIPS source code from file into structure.
readString(int, int) –
Static method in class mars.util.SystemIO
Implements syscall to read a string.
readyForCommit() –
Method in class mars.assembler.Macro
Operations to be done on this macro before it is committed in macro pool.
REAL_NUMBER –
Static variable in class mars.assembler.TokenTypes
recalculateVisibleLines() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Recalculates the number of visible lines.
RECEIVER_CONTROL –
Static variable in class mars.tools.KeyboardAndDisplaySimulator
RECEIVER_DATA –
Static variable in class mars.tools.KeyboardAndDisplaySimulator
recorder –
Variable in class mars.venus.editors.jeditsyntax.InputHandler
rectSelect –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
redo() –
Method in class mars.venus.editors.generic.GenericTextArea
Redo previous edit
redo() –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Redo previous edit
redo() –
Method in interface mars.venus.editors.MARSTextEditingArea
redo() –
Method in class mars.venus.EditPane
Redo previous edit
refresh() –
Method in class mars.venus.Coprocessor0Window
Refresh the table, triggering re-rendering.
refresh() –
Method in class mars.venus.Coprocessor1Window
Refresh the table, triggering re-rendering.
refresh() –
Method in class mars.venus.RegistersWindow
Refresh the table, triggering re-rendering.
regionMatches(boolean, Segment, int, String) –
Static method in class mars.venus.editors.jeditsyntax.SyntaxUtilities
Checks if a subregion of a Segment is equal to a
string.
regionMatches(boolean, Segment, int, char[]) –
Static method in class mars.venus.editors.jeditsyntax.SyntaxUtilities
Checks if a subregion of a Segment is equal to a
character array.
Register – Class in mars.mips.hardware
Abstraction to represent a register of a MIPS Assembler.
Register(String, int, int) –
Constructor for class mars.mips.hardware.Register
Creates a new register with specified name, number, and value.
register(int) –
Static method in class mars.simulator.DelayedBranch
Register the fact that a successful branch is to occur.
REGISTER_HIGHLIGHT_BACKGROUND –
Static variable in class mars.Settings
RGB color for register highlighted background
REGISTER_HIGHLIGHT_FONT –
Static variable in class mars.Settings
Font for register highlighted background
REGISTER_HIGHLIGHT_FOREGROUND –
Static variable in class mars.Settings
RGB color for register highlighted foreground
REGISTER_NAME –
Static variable in class mars.assembler.TokenTypes
note: REGISTER_NAME is token of form $zero whereas REGISTER_NUMBER is token
of form $0.
REGISTER_NUMBER –
Static variable in class mars.assembler.TokenTypes
RegisterAccessNotice – Class in mars.mips.hardware
Object provided to Observers of runtime access to MIPS register.
RegisterFile – Class in mars.mips.hardware
Represents the collection of MIPS registers.
RegisterFile() –
Constructor for class mars.mips.hardware.RegisterFile
REGISTERS_HIGHLIGHTING –
Static variable in class mars.Settings
Flag to control whether or not highlighting is applied to register windows
RegistersPane – Class in mars.venus
Contains tabbed areas in the UI to display register contents
RegistersPane(VenusUI, RegistersWindow, Coprocessor1Window, Coprocessor0Window) –
Constructor for class mars.venus.RegistersPane
Constructor for the RegistersPane class.
RegistersWindow – Class in mars.venus
Sets up a window to display registers in the UI.
RegistersWindow() –
Constructor for class mars.venus.RegistersWindow
Constructor which sets up a fresh window with a table that contains the register values.
registerTableModelListener(TableModelListener) –
Method in class mars.venus.TextSegmentWindow
Assign listener to Table model.
remove(int) –
Method in class mars.assembler.TokenList
Removes Token object at specified list position.
remove(EditPane) –
Method in class mars.venus.EditTabbedPane
Remove the pane and update menu status
removeAllKeyBindings() –
Method in class mars.venus.editors.jeditsyntax.DefaultInputHandler
Removes all key bindings from this input handler.
removeAllKeyBindings() –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Removes all key bindings from this input handler.
removeCaretListener(CaretListener) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Removes a caret change listener from this text area.
removeKeyBinding(String) –
Method in class mars.venus.editors.jeditsyntax.DefaultInputHandler
Removes a key binding from this input handler.
removeKeyBinding(String) –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Removes a key binding from this input handler.
removeNotify() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Called by the AWT when this component is removed from it’s parent.
removeProgramArgumentsPanel() –
Method in class mars.venus.TextSegmentWindow
removeStopListener(Simulator.StopListener) –
Method in class mars.simulator.Simulator
removeSymbol(Token) –
Method in class mars.assembler.SymbolTable
Removes a symbol from the Symbol table.
REPEAT –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
repeat –
Variable in class mars.venus.editors.jeditsyntax.InputHandler
RepeatButton – Class in mars.venus
RepeatButton is a JButton which contains a timer
for firing events while the button is held down.
RepeatButton() –
Constructor for class mars.venus.RepeatButton
Creates a button with no set text or icon.
RepeatButton(Action) –
Constructor for class mars.venus.RepeatButton
Creates a button where properties are taken from the Action supplied.
RepeatButton(Icon) –
Constructor for class mars.venus.RepeatButton
Creates a button with an icon.
RepeatButton(String) –
Constructor for class mars.venus.RepeatButton
Creates a button with text.
RepeatButton(String, Icon) –
Constructor for class mars.venus.RepeatButton
Creates a button with initial text and an icon.
repeatCount –
Variable in class mars.venus.editors.jeditsyntax.InputHandler
replaceSelection(String) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Same as setSelectedText but named for compatibility with
JTextComponent method replaceSelection.
replaceSelection(String) –
Method in interface mars.venus.editors.MARSTextEditingArea
requestFocusInWindow() –
Method in interface mars.venus.editors.MARSTextEditingArea
RESERVED_INSTRUCTION_EXCEPTION –
Static variable in class mars.simulator.Exceptions
reset(boolean) –
Method in class mars.Settings
Reset settings to default values, as described in the constructor comments.
reset() –
Method in class mars.tools.AbstractMarsToolAndApplication
Method that will be called each time the default Reset button is clicked.
reset() –
Method in class mars.tools.BHTSimulator
Performs a reset of the simulator.
reset() –
Method in class mars.tools.BitmapDisplay
Method to reset counters and display when the Reset button selected.
reset() –
Method in class mars.tools.CacheSimulator
Method to reset cache, counters and display when the Reset button selected.
reset() –
Method in class mars.tools.DigitalLabSim
reset() –
Method in class mars.tools.FloatRepresentation
Method to reset display values to 0 when the Reset button selected.
reset() –
Method in class mars.tools.InstructionCounter
reset() –
Method in class mars.tools.InstructionStatistics
resets the counter values of the tool and updates the display.
reset() –
Method in class mars.tools.KeyboardAndDisplaySimulator
Method to reset counters and display when the Reset button selected.
reset() –
Method in class mars.tools.MemoryReferenceVisualization
Method to reset counters and display when the Reset button selected.
reset() –
Method in class mars.venus.AbstractFontSettingDialog
reset() –
Static method in class mars.venus.FileStatus
Resets all the values in FileStatus
RESET_TOOL_TIP_TEXT –
Static variable in class mars.venus.SettingsHighlightingAction
resetFiles() –
Static method in class mars.util.SystemIO
Reset all files — clears out the file descriptor table.
resetHexaKeyboard() –
Method in class mars.tools.DigitalLabSim.HexaKeyboard
resetMaxSteps() –
Static method in class mars.venus.RunGoAction
Reset max steps limit to default value at termination of a simulated execution.
resetMemoryRange() –
Method in class mars.venus.DataSegmentWindow
Reset range of memory addresses to base address of currently selected segment and update display.
resetOneSecondCounter() –
Method in class mars.tools.DigitalLabSim.OneSecondCounter
resetRegisters() –
Static method in class mars.mips.hardware.Coprocessor0
Method to reinitialize the values of the registers.
resetRegisters() –
Static method in class mars.mips.hardware.Coprocessor1
Method to reinitialize the values of the registers.
resetRegisters() –
Static method in class mars.mips.hardware.RegisterFile
Method to reinitialize the values of the registers.
resetSevenSegment() –
Method in class mars.tools.DigitalLabSim.SevenSegmentPanel
resetSimulator() –
Method in class mars.tools.BHTSimulator
Resets the simulator by clearing the GUI elements and resetting the BHT.
resetValue() –
Method in class mars.mips.hardware.Register
Resets the value of the register to the value it was constructed with.
resetValues() –
Method in class mars.venus.DataSegmentWindow
Reset all data display values to 0
revalidate() –
Method in interface mars.venus.editors.MARSTextEditingArea
RIGHT –
Static variable in class mars.venus.editors.jeditsyntax.JEditTextArea
RIGHT_PAREN –
Static variable in class mars.assembler.TokenTypes
rows –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
rows –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
RunAssembleAction – Class in mars.venus
Action class for the Run -> Assemble menu item (and toolbar icon)
RunAssembleAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.RunAssembleAction
RunBackstepAction – Class in mars.venus
Action for the Run -> Backstep menu item
RunBackstepAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.RunBackstepAction
RunClearBreakpointsAction – Class in mars.venus
Action class for the Run menu item to clear execution breakpoints that have been set.
RunClearBreakpointsAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.RunClearBreakpointsAction
Create the object and register with text segment window as a listener on its table model.
RunGoAction – Class in mars.venus
Action class for the Run -> Go menu item (and toolbar icon)
RunGoAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.RunGoAction
RUNNABLE –
Static variable in class mars.venus.FileStatus
successful assembly
RUNNING –
Static variable in class mars.venus.FileStatus
execution is under way
RunPauseAction – Class in mars.venus
Action class for the Run -> Pause menu item (and toolbar icon)
RunPauseAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.RunPauseAction
RunResetAction – Class in mars.venus
Action for the Run -> Reset menu item
RunResetAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.RunResetAction
RunSpeedPanel – Class in mars.venus
Class for the Run speed slider control.
runSpeedPanelExists –
Static variable in class mars.Globals
RunStepAction – Class in mars.venus
Action for the Run -> Step menu item
RunStepAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.RunStepAction
RunStopAction – Class in mars.venus
Action class for the Run -> Stop menu item (and toolbar icon)
RunStopAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.RunStopAction
RunToggleBreakpointsAction – Class in mars.venus
Action class for the Run menu item to clear execution breakpoints that have been set.
RunToggleBreakpointsAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.RunToggleBreakpointsAction
Create the object and register with text segment window as a listener on its table model.
S
save() –
Method in class mars.venus.Editor
Perform “save” operation on current tab’s file.
saveAll() –
Method in class mars.venus.Editor
Perform save operation on all open files (tabs).
saveAllFiles() –
Method in class mars.venus.EditTabbedPane
Saves all files currently open in the editor.
saveAs() –
Method in class mars.venus.Editor
Perform “save as” operation on current tab’s file.
saveAsCurrentFile() –
Method in class mars.venus.EditTabbedPane
Pops up a dialog box to do “Save As” operation.
saveCurrentFile() –
Method in class mars.venus.EditTabbedPane
Saves file under existing name.
ScavengerHunt – Class in mars.tools
Demo of Mars tool capability.
ScavengerHunt() –
Constructor for class mars.tools.ScavengerHunt
ScreenMagnifier – Class in mars.tools
Handy little tool to magnify a selected section of the screen
by a given scale and display it.
ScreenMagnifier() –
Constructor for class mars.tools.ScreenMagnifier
scrollBarsInitialized –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
scrollTo(int, int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Ensures that the specified line and offset is visible by scrolling
the text area if necessary.
scrollToCaret() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Ensures that the caret is visible by scrolling the text area if
necessary.
SegmentWindowDumpFormat – Class in mars.mips.dump
Dump MIPS memory contents in Segment Window format.
SegmentWindowDumpFormat() –
Constructor for class mars.mips.dump.SegmentWindowDumpFormat
Constructor.
select(int, int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Selects from the start offset to the end offset.
select(int, int) –
Method in interface mars.venus.editors.MARSTextEditingArea
SELECT_ALL –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_DOC_END –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_DOC_HOME –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_END –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_HOME –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_NEXT_CHAR –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_NEXT_LINE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_NEXT_PAGE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_NEXT_WORD –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_PREV_CHAR –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_PREV_LINE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_PREV_PAGE –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
SELECT_PREV_WORD –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
selectAll() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Selects all text in the document.
selectAll() –
Method in interface mars.venus.editors.MARSTextEditingArea
selectAllText() –
Method in class mars.venus.EditPane
select all text
selectEditorTextLine(String, int, int) –
Method in class mars.venus.MessagesPane
Will select the specified line in an editor tab.
selectErrorMessage(String, int, int) –
Method in class mars.venus.MessagesPane
Will select the Mars Messages tab error message that matches the given
specifications, if it is found.
selectionColor –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
selectionColor –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
selectionEnd –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
selectionEndLine –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
selectionStart –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
selectionStartLine –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
selectLine(int) –
Method in class mars.venus.EditPane
Select the specified editor text line.
selectLine(int, int) –
Method in class mars.venus.EditPane
Select the specified editor text line.
selectMarsMessageTab() –
Method in class mars.venus.MessagesPane
Make the assembler message tab current (up front)
selectNone() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Moves the mark to the caret position.
selectRunMessageTab() –
Method in class mars.venus.MessagesPane
Make the runtime message tab current (up front)
SELF_MODIFYING_CODE_ENABLED –
Static variable in class mars.Settings
Flag to determine whether a program can write binary code to the text or data segment and
execute that code.
SET –
Static variable in class mars.assembler.Directives
set(int, Token) –
Method in class mars.assembler.TokenList
Replaces token at position with different one.
set(int, int, int) –
Method in class mars.mips.hardware.Memory
Starting at the given address, write the given value over the given number of bytes.
set(int) –
Static method in class mars.venus.FileStatus
Set file status.
setAddress(int) –
Method in class mars.assembler.Symbol
Sets (replaces) the address of the the Symbol.
setArgs(ArrayList
Method in class mars.assembler.Macro
setAssembleAllEnabled(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ALL_ENABLED)
setAssembled(boolean) –
Static method in class mars.venus.FileStatus
Changes the value of assenbked to the parameter given.
setAssembleOnOpenEnabled(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ON_OPEN_ENABLED)
setBackground(Color) –
Method in interface mars.venus.editors.MARSTextEditingArea
setBase(int) –
Method in class mars.venus.NumberDisplayBaseChooser
Set the current number base.
setBasicAssemblyStatement(String) –
Method in class mars.ProgramStatement
Assigns given String to be Basic Assembly statement equivalent to this source line.
setBinaryStatement(int) –
Method in class mars.ProgramStatement
Assigns given int to be binary machine code equivalent to this source line.
setBit(int, int) –
Static method in class mars.util.Binary
Sets the specified bit of the specified value to 1, and returns the result.
setBlockCaretEnabled(boolean) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Sets if the caret should be drawn as a block, false otherwise.
setBooleanSetting(int, boolean) –
Method in class mars.Settings
Set value of a boolean setting given its id and the value.
setBooleanSettingNonPersistent(int, boolean) –
Method in class mars.Settings
Temporarily establish boolean setting.
setBracketHighlightColor(Color) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Sets the bracket highlight color.
setBracketHighlightEnabled(boolean) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Enables or disables bracket highlighting.
setByte(int, int) –
Method in class mars.mips.hardware.Memory
Writes low order 8 bits of given value into specified Memory byte.
setByte(int, int, int) –
Static method in class mars.util.Binary
Sets the specified byte of the specified value to the low order 8 bits of
specified replacement value, and returns the result.
setByteOrder(boolean) –
Method in class mars.mips.hardware.Memory
Set byte order to either LITTLE_ENDIAN or BIG_ENDIAN.
setCaretBlinkEnabled(boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Toggles caret blinking.
setCaretBlinkRate(int) –
Method in class mars.Settings
Set the caret blinking rate in milliseconds.
setCaretBlinkRate(int) –
Method in class mars.venus.editors.generic.GenericTextArea
Set the caret blinking rate in milliseconds.
setCaretBlinkRate(int) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Set the caret blinking rate in milliseconds.
setCaretBlinkRate(int) –
Method in interface mars.venus.editors.MARSTextEditingArea
setCaretColor(Color) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Sets the caret color.
setCaretPosition(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the caret position.
setCaretPosition(int) –
Method in interface mars.venus.editors.MARSTextEditingArea
setCaretVisible(boolean) –
Method in class mars.venus.editors.generic.GenericTextArea
Control caret visibility
setCaretVisible(boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets if the caret should be visible.
setCaretVisible(boolean) –
Method in interface mars.venus.editors.MARSTextEditingArea
setCodeHighlighting(boolean) –
Method in class mars.venus.TextSegmentWindow
Used to enable or disable source code highlighting.
setColorSettingByKey(String, Color) –
Method in class mars.Settings
Set Color object for specified settings key.
setColorSettingByPosition(int, Color) –
Method in class mars.Settings
Set Color object for specified settings name (a static constant).
setConditionFlag(int) –
Static method in class mars.mips.hardware.Coprocessor1
Set condition flag to 1 (true).
setConditionFlags() –
Static method in class mars.mips.hardware.Coprocessor1
Set all condition flags (0-7).
setConfiguration() –
Static method in class mars.mips.hardware.Memory
Sets current memory configuration for simulated MIPS.
setCurrent(Macro) –
Method in class mars.assembler.MacroPool
setCurrentConfiguration(MemoryConfiguration) –
Static method in class mars.mips.hardware.MemoryConfigurations
setCurrentEditTab(EditPane) –
Method in class mars.venus.EditTabbedPane
Select the specified EditPane to be the current tab.
setDataSegmentHighlighting(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DATA_SEGMENT_HIGHLIGHTING)
setDelay(int) –
Method in class mars.venus.RepeatButton
Set the delay for the timer of this button.
setDelayedBranchingEnabled(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
setDelayedBranchingEnabledNonPersistent(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSettingNonPersistent(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
setDescription(String) –
Method in class mars.venus.editors.jeditsyntax.PopupHelpItem
setDisplayAddressesInHex(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_ADDRESSES_IN_HEX)
setDisplayValuesInHex(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_VALUES_IN_HEX)
setDocument(SyntaxDocument) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the document this text area is editing.
setDouble(int, double) –
Method in class mars.mips.hardware.Memory
Writes 64 bit double value starting at specified Memory address.
setEditable(boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets if this component is editable.
setEditable(boolean) –
Method in interface mars.venus.editors.MARSTextEditingArea
setEdited(boolean) –
Static method in class mars.venus.FileStatus
Changes the value of edited to the parameter given.
setEditorFont(Font) –
Method in class mars.Settings
Set editor font to the specified Font object and write it to persistent storage.
setEditorLineNumbersDisplayed(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EDITOR_LINE_NUMBERS_DISPLAYED)
setEditorPopupPrefixLength(int) –
Method in class mars.Settings
Set number of letters to be matched by editor’s instruction guide before popup generated (if popup enabled).
setEditorSyntaxStyleByPosition(int, SyntaxStyle) –
Method in class mars.Settings
setEditorTabSize(int) –
Method in class mars.Settings
Set the tab size in characters.
setEditTabbedPane(EditTabbedPane) –
Method in class mars.venus.Editor
Set associated EditTabbedPane.
setElectricScroll(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the number of lines from the top and bottom of the text
area that are always visible
setEnabled(boolean) –
Method in class mars.simulator.BackStepper
Set enable status.
setEnabled(boolean) –
Method in interface mars.venus.editors.MARSTextEditingArea
setEnabled(boolean) –
Method in class mars.venus.RepeatButton
Sets the enabled state of this button.
setEOLMarkerColor(Color) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Sets the EOL marker color.
setEOLMarkersPainted(boolean) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Sets if EOL markers are to be drawn.
setExample(String) –
Method in class mars.venus.editors.jeditsyntax.PopupHelpItem
setExceptionHandler(String) –
Method in class mars.Settings
Set name of exception handler file and write it to persistent storage.
setExceptionHandlerEnabled(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EXCEPTION_HANDLER_ENABLED)
setExtendedAssemblerEnabled(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EXTENDED_ASSEMBLER_ENABLED)
setFile(File) –
Static method in class mars.venus.FileStatus
Sets the file to the ASM file passed.
setFileStatus(int) –
Method in class mars.venus.EditPane
Set the editing status for this EditPane’s associated document.
setFileStatus(int) –
Method in class mars.venus.FileStatus
Set editing status of this file.
setFirstLine(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the line displayed at the text area’s origin and
updates the scroll bars.
setFont(Font) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
setFont(Font) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Sets the font for this component.
setFont(Font) –
Method in interface mars.venus.editors.MARSTextEditingArea
setFontByPosition(int, Font) –
Method in class mars.Settings
Store a Font setting
setFontStyle(int) –
Method in class mars.venus.HardcopyWriter
Set the font style.
setFromLine(int) –
Method in class mars.assembler.Macro
setGraphicsFlags(Graphics, Font) –
Method in class mars.venus.editors.jeditsyntax.SyntaxStyle
Sets the foreground color and font of the specified graphics
context to that specified in this style.
setGui(VenusUI) –
Static method in class mars.Globals
setHalf(int, int) –
Method in class mars.mips.hardware.Memory
Starting at the given halfword address, write the lower 16 bits of given value
into 2 bytes (a halfword).
setHorizontalOffset(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the horizontal offset of drawn lines.
setIgnoreCase(boolean) –
Method in class mars.venus.editors.jeditsyntax.KeywordMap
Sets if the keyword map should be case insensitive.
setInitialDelay(int) –
Method in class mars.venus.RepeatButton
Sets the initial delay for the timer of this button.
setInputHandler(InputHandler) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the input handler.
setInvalidLinesPainted(boolean) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Sets if invalid lines are to be painted as red tildes.
setLabelSortState(String) –
Method in class mars.Settings
Store the current state of the Labels Window sorter.
setLabelWindowVisibility(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.LABEL_WINDOW_VISIBILITY)
setLabelWindowVisibility(boolean) –
Method in class mars.venus.ExecutePane
Show or hide the label window (symbol table).
setLineHighlightColor(Color) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Sets the line highlight color.
setLineHighlightEnabled(boolean) –
Method in class mars.venus.editors.generic.GenericTextArea
Does nothing, but required by the interface.
setLineHighlightEnabled(boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Use for highlighting the line currently being edited.
setLineHighlightEnabled(boolean) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Enables or disables current line highlighting.
setLineHighlightEnabled(boolean) –
Method in interface mars.venus.editors.MARSTextEditingArea
setLocalMacroPool(MacroPool) –
Method in class mars.MIPSprogram
Sets local macro pool MacroPool for this program
setMachineStatement(String) –
Method in class mars.ProgramStatement
Assigns given String to be binary machine code (32 characters, all of them 0 or 1)
equivalent to this source line.
setMacroRecorder(InputHandler.MacroRecorder) –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Sets the macro recorder.
setMagicCaretPosition(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the `magic’ caret position.
setMemoryConfiguration(String) –
Method in class mars.Settings
Store the identifier of the memory configuration.
setName(String) –
Method in class mars.assembler.Macro
setName(String) –
Static method in class mars.venus.FileStatus
Changes the value of name to the parameter given.
setNumber(int) –
Method in class mars.mips.instructions.syscalls.AbstractSyscall
Set the service number.
setNumber(int) –
Method in interface mars.mips.instructions.syscalls.Syscall
Set the service number.
setOrigin(int, int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
A fast way of changing both the first line and horizontal
offset.
setOriginal(MIPSprogram, int) –
Method in class mars.assembler.Token
Set original program and line number for this token.
setOriginalFromLine(int) –
Method in class mars.assembler.Macro
setOriginalToLine(int) –
Method in class mars.assembler.Macro
setOverwriteEnabled(boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets if overwrite mode should be enabled.
setPathname(String) –
Method in class mars.venus.EditPane
Delegates to corresponding FileStatus method
setPathname(String) –
Method in class mars.venus.FileStatus
Set full file pathname.
setPathname(String, String) –
Method in class mars.venus.FileStatus
Set full file pathname.
setProcessedLine(String) –
Method in class mars.assembler.TokenList
Use this to record the source line String for this token list
after possible modification (textual substitution) during
assembly preprocessing.
setProgram(MIPSprogram) –
Method in class mars.assembler.Macro
setProgramArguments(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.PROGRAM_ARGUMENTS)
setProgramCounter(int) –
Static method in class mars.mips.hardware.RegisterFile
For setting the Program Counter.
setRawWord(int, int) –
Method in class mars.mips.hardware.Memory
Starting at the given word address, write the given value over 4 bytes (a word).
setRegisterPairToDouble(int, double) –
Static method in class mars.mips.hardware.Coprocessor1
Sets the value of the FPU register given to the double value given.
setRegisterPairToDouble(String, double) –
Static method in class mars.mips.hardware.Coprocessor1
Sets the value of the FPU register given to the double value given.
setRegisterPairToLong(int, long) –
Static method in class mars.mips.hardware.Coprocessor1
Sets the value of the FPU register pair given to the long value containing 64 bit pattern
given.
setRegisterPairToLong(String, long) –
Static method in class mars.mips.hardware.Coprocessor1
Sets the value of the FPU register pair given to the long value containing 64 bit pattern
given.
setRegisters(int) –
Static method in class mars.simulator.Exceptions
Given MIPS exception cause code, will place that code into
coprocessor 0 CAUSE register ($13), set the EPC register to
“current” program counter, and set Exception Level bit in STATUS register.
setRegisters(int, int) –
Static method in class mars.simulator.Exceptions
Given MIPS exception cause code and bad address, place the bad address into VADDR
register ($8) then call overloaded setRegisters with the cause code to do the rest.
setRegistersHighlighting(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.REGISTERS_HIGHLIGHTING)
setRegisterToFloat(String, float) –
Static method in class mars.mips.hardware.Coprocessor1
Sets the value of the FPU register given to the value given.
setRegisterToFloat(int, float) –
Static method in class mars.mips.hardware.Coprocessor1
Sets the value of the FPU register given to the value given.
setRegisterToInt(String, int) –
Static method in class mars.mips.hardware.Coprocessor1
Sets the value of the FPU register given to the 32-bit
pattern given by the int parameter.
setRegisterToInt(int, int) –
Static method in class mars.mips.hardware.Coprocessor1
Sets the value of the FPU register given to the 32-bit
pattern given by the int parameter.
setRepeatCount(int) –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Sets the number of times the next action will be repeated.
setRepeatEnabled(boolean) –
Method in class mars.venus.editors.jeditsyntax.InputHandler
Enables repeating.
setRepeatEnabled(boolean) –
Method in class mars.venus.RepeatButton
Sets if the button should fire events when held.
setReset(boolean) –
Static method in class mars.venus.VenusUI
To set whether the register values are reset.
setRightClickPopup(JPopupMenu) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the right click popup menu.
setSaved(boolean) –
Static method in class mars.venus.FileStatus
Changes the value of saved to the parameter given.
setSelectedText(String) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Replaces the selection with the specified text.
setSelectionColor(Color) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Sets the selection color.
setSelectionEnd(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the selection end.
setSelectionEnd(int) –
Method in interface mars.venus.editors.MARSTextEditingArea
setSelectionRectangular(boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets if the selection should be rectangular.
setSelectionStart(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the selection start.
setSelectionStart(int) –
Method in interface mars.venus.editors.MARSTextEditingArea
setSelectionVisible(boolean) –
Method in class mars.venus.editors.generic.GenericTextArea
Control selection visibility
setSelectionVisible(boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
setSelectionVisible(boolean) –
Method in interface mars.venus.editors.MARSTextEditingArea
setSettingsMenuItem(JCheckBoxMenuItem) –
Method in class mars.venus.NumberDisplayBaseChooser
Set the menu item from Settings menu that corresponds to this chooser.
setShowLineNumbersEnabled(boolean) –
Method in class mars.venus.EditPane
enable or disable checkbox that controls display of line numbers
setSource(String) –
Method in class mars.ProgramStatement
associates MIPS source statement.
setSourceCode(String, boolean) –
Method in class mars.venus.editors.generic.GenericTextArea
For initalizing the source code when opening an ASM file
setSourceCode(String, boolean) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
setSourceCode(String, boolean) –
Method in interface mars.venus.editors.MARSTextEditingArea
setSourceCode(String, boolean) –
Method in class mars.venus.EditPane
For initalizing the source code when opening an ASM file
setSourceLineList(ArrayList
Method in class mars.MIPSprogram
Set list of source statements that comprise the program.
setStartAtMain(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.START_AT_MAIN)
setStarted(boolean) –
Static method in class mars.venus.VenusUI
To set whether MIPS program execution has started.
setStatement(int, ProgramStatement) –
Method in class mars.mips.hardware.Memory
Stores ProgramStatement in Text Segment.
setStyles(SyntaxStyle[]) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Sets the syntax styles used to paint colorized text.
setTabSize(int) –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Set the number of characters a tab will expand to.
setTabSize(int) –
Method in class mars.venus.editors.jeditsyntax.TextAreaPainter
Set the tab size in characters.
setTabSize(int) –
Method in interface mars.venus.editors.MARSTextEditingArea
setText(String) –
Method in class mars.venus.editors.generic.GenericTextArea
Override inherited setText to temporarily remove UndoableEditListener because this
operation is not undoable.
setText(String) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the entire text of this text area.
setText(String) –
Method in interface mars.venus.editors.MARSTextEditingArea
setTextColumnOrder(int[]) –
Method in class mars.Settings
Store the current order of Text Segment window table columns, so the ordering
can be preserved and restored.
Settings – Class in mars
Contains various IDE settings.
Settings() –
Constructor for class mars.Settings
Create Settings object and set to saved values.
Settings(boolean) –
Constructor for class mars.Settings
Create Settings object and set to saved values.
SettingsAddressDisplayBaseAction – Class in mars.venus
Action class for the Settings menu item to control number base (10 or 16) of memory addresses.
SettingsAddressDisplayBaseAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsAddressDisplayBaseAction
SettingsAssembleAllAction – Class in mars.venus
Action class for the Settings menu item to determine whether assemble operation applies
only to current file or to all files in its directory.
SettingsAssembleAllAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsAssembleAllAction
SettingsAssembleOnOpenAction – Class in mars.venus
Action class for the Settings menu item to control automatic assemble of file upon opening.
SettingsAssembleOnOpenAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsAssembleOnOpenAction
SettingsDelayedBranchingAction – Class in mars.venus
Action class for the Settings menu item to control delayed branching.
SettingsDelayedBranchingAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsDelayedBranchingAction
SettingsEditorAction – Class in mars.venus
Action class for the Settings menu item for text editor settings.
SettingsEditorAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsEditorAction
Create a new SettingsEditorAction.
SettingsExceptionHandlerAction – Class in mars.venus
Action class for the Settings menu item for optionally loading a MIPS exception handler.
SettingsExceptionHandlerAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsExceptionHandlerAction
SettingsExtendedAction – Class in mars.venus
Action class for the Settings menu item to control use of extended (pseudo) instructions or formats.
SettingsExtendedAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsExtendedAction
SettingsHighlightingAction – Class in mars.venus
Action class for the Settings menu item for text editor settings.
SettingsHighlightingAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsHighlightingAction
Create a new SettingsEditorAction.
SettingsLabelAction – Class in mars.venus
Action class for the Settings menu item to control display of Labels window (symbol table).
SettingsLabelAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsLabelAction
SettingsMemoryConfigurationAction – Class in mars.venus
Action class for the Settings menu item for text editor settings.
SettingsMemoryConfigurationAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsMemoryConfigurationAction
Create a new SettingsEditorAction.
SettingsPopupInputAction – Class in mars.venus
Action class for the Settings menu item to control use of popup dialog for input syscalls.
SettingsPopupInputAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsPopupInputAction
SettingsProgramArgumentsAction – Class in mars.venus
Action class for the Settings menu item to control whether or not
program arguments can be entered and used.
SettingsProgramArgumentsAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsProgramArgumentsAction
SettingsSelfModifyingCodeAction – Class in mars.venus
Action class for the Settings menu item to control whether
the running MIPS program can write to the text segment or
branch to the data segment.
SettingsSelfModifyingCodeAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsSelfModifyingCodeAction
SettingsStartAtMainAction – Class in mars.venus
Action class for the Settings menu item to control whether or not
assembler warnings are considered errors.
SettingsStartAtMainAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsStartAtMainAction
SettingsValueDisplayBaseAction – Class in mars.venus
Action class for the Settings menu item to control number base (10 or 16) of memory/register contents.
SettingsValueDisplayBaseAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsValueDisplayBaseAction
SettingsWarningsAreErrorsAction – Class in mars.venus
Action class for the Settings menu item to control whether or not
assembler warnings are considered errors.
SettingsWarningsAreErrorsAction(String, Icon, String, Integer, KeyStroke, VenusUI) –
Constructor for class mars.venus.SettingsWarningsAreErrorsAction
setTitle(String, String, int) –
Method in class mars.venus.Editor
Places name of file currently being edited into its edit tab and
the application’s title bar.
setTokenMarker(TokenMarker) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Sets the document’s token marker.
setTokenMarker(TokenMarker) –
Method in class mars.venus.editors.jeditsyntax.SyntaxDocument
Sets the token marker that is to be used to split lines of
this document up into tokens.
setToLine(int) –
Method in class mars.assembler.Macro
setType(TokenTypes) –
Method in class mars.assembler.Token
Set or modify token type.
setupTable() –
Method in class mars.venus.DataSegmentWindow
Generates and displays fresh table, typically done upon successful assembly.
setupTable() –
Method in class mars.venus.LabelsWindow
Initialize table of labels (symbol table)
setupTable() –
Method in class mars.venus.TextSegmentWindow
Method to be called once the user compiles the program.
setupWindow() –
Method in class mars.venus.Coprocessor0Window
Sets up the data for the window.
setupWindow() –
Method in class mars.venus.Coprocessor1Window
Sets up the data for the window.
setupWindow() –
Method in class mars.venus.RegistersWindow
Sets up the data for the window.
setValue(int) –
Method in class mars.mips.hardware.Register
Sets the value of the register to the val passed to it.
setWarningsAreErrors(boolean) –
Method in class mars.Settings
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.WARNINGS_ARE_ERRORS)
setWindowBounds() –
Method in class mars.venus.ExecutePane
This method will set the bounds of this JDesktopPane’s internal windows
relative to the current size of this JDesktopPane.
setWord(int, int) –
Method in class mars.mips.hardware.Memory
Starting at the given word address, write the given value over 4 bytes (a word).
showingLineNumbers() –
Method in class mars.venus.EditPane
get editor’s line number display status
showRegisters() –
Static method in class mars.mips.hardware.Coprocessor0
Method for displaying the register values for debugging.
showRegisters() –
Static method in class mars.mips.hardware.Coprocessor1
Method for displaying the register values for debugging.
showRegisters() –
Static method in class mars.mips.hardware.RegisterFile
Method for displaying the register values for debugging.
showSplash() –
Method in class mars.MarsSplashScreen
A simple little method to show a title screen in the center
of the screen for the amount of time given in the constructor
simulate(ProgramStatement) –
Method in interface mars.mips.instructions.SimulationCode
Method to simulate the execution of a specific MIPS basic instruction.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.AbstractSyscall
Performs syscall function.
simulate(ProgramStatement) –
Method in interface mars.mips.instructions.syscalls.Syscall
Performs syscall function.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallClose
Performs syscall function to close file descriptor given in $a0.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallConfirmDialog
System call to display a message to user.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallExit
Performs syscall function to exit the MIPS program.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallExit2
Performs syscall function to exit the MIPS program with return value given in $a0.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallInputDialogDouble
System call to input data.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallInputDialogFloat
System call to input data.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallInputDialogInt
System call to input data.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallInputDialogString
System call to input data.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallMessageDialog
System call to display a message to user.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallMessageDialogDouble
System call to display a message to user.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallMessageDialogFloat
System call to display a message to user.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallMessageDialogInt
System call to display a message to user.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallMessageDialogString
System call to display a message to user.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallMidiOut
Performs syscall function to send MIDI output to sound card.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallMidiOutSync
Performs syscall function to send MIDI output to sound card.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallOpen
Performs syscall function to open file name specified by $a0.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallPrintChar
Performs syscall function to print on the console the character stored in $a0.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallPrintDouble
Performs syscall function to print double whose bits are stored in $f12 & $f13.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallPrintFloat
Performs syscall function to display float whose bits are stored in $f12
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallPrintInt
Performs syscall function to print on the console the integer stored in $a0.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallPrintIntBinary
Performs syscall function to print on the console the integer stored in $a0, in hexadecimal format.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallPrintIntHex
Performs syscall function to print on the console the integer stored in $a0, in hexadecimal format.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallPrintIntUnsigned
Performs syscall function to print on the console the integer stored in $a0.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallPrintString
Performs syscall function to print string stored starting at address in $a0.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallRandDouble
System call to the random number generator.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallRandFloat
System call to the random number generator.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallRandInt
System call to the random number generator.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallRandIntRange
System call to the random number generator, with an upper range specified.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallRandSeed
Set the seed of the underlying Java pseudorandom number generator.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallRead
Performs syscall function to read from file descriptor given in $a0.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallReadChar
Performs syscall function to read a character from input console into $a0
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallReadDouble
Performs syscall function to read the bits of input double into $f0 and $f1.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallReadFloat
Performs syscall function to read the bits of input float into $f0
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallReadInt
Performs syscall function to read an integer from input console into $v0
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallReadString
Performs syscall function to read console input string into buffer starting at address in $a0.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallSbrk
Performs syscall function to allocate amount of heap memory specified in $a0, putting address into $v0.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallSleep
System call to cause the MARS Java thread to sleep for (at least) the specified number of milliseconds.
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallTime
Performs syscall function to place current system time into $a0 (low order 32 bits)
and $a1 (high order 32 bits).
simulate(ProgramStatement) –
Method in class mars.mips.instructions.syscalls.SyscallWrite
Performs syscall function to write to file descriptor given in $a0.
simulate(int[]) –
Method in class mars.MIPSprogram
Simulates execution of the MIPS program.
simulate(int) –
Method in class mars.MIPSprogram
Simulates execution of the MIPS program.
simulate(MIPSprogram, int, int, int[], AbstractAction) –
Method in class mars.simulator.Simulator
Simulate execution of given MIPS program.
simulateFromPC(int[], int, AbstractAction) –
Method in class mars.MIPSprogram
Simulates execution of the MIPS program.
simulateStepAtPC(AbstractAction) –
Method in class mars.MIPSprogram
Simulates execution of the MIPS program.
SimulationCode – Interface in mars.mips.instructions
Interface to represent the method for simulating the execution of a specific MIPS basic
instruction.
Simulator – Class in mars.simulator
Used to simulate the execution of an assembled MIPS program.
Simulator.StopListener – Interface in mars.simulator
SIMULATOR_START –
Static variable in class mars.simulator.SimulatorNotice
SIMULATOR_STOP –
Static variable in class mars.simulator.SimulatorNotice
SimulatorNotice – Class in mars.simulator
Object provided to Observers of the Simulator.
SimulatorNotice(int, int, double, int) –
Constructor for class mars.simulator.SimulatorNotice
Constructor will be called only within this package, so assume
address and length are in valid ranges.
size() –
Method in class mars.assembler.TokenList
Returns number of tokens in list.
sizeIntToSizeString(int) –
Static method in class mars.util.EditorFont
Given an int representing font size, returns corresponding string.
sizeStringToSizeInt(String) –
Static method in class mars.util.EditorFont
Given a String representing font size, returns corresponding int.
SMART_HOME_END_PROPERTY –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
If this client property is set to Boolean.TRUE on the text area,
the home/end keys will support ‘smart’ BRIEF-like behaviour
(one press = start/end of line, two presses = start/end of
viewscreen, three presses = start/end of document).
SourceLine – Class in mars.assembler
Handy class to represent, for a given line of source code, the code
itself, the program containing it, and its line number within that program.
SourceLine(String, MIPSprogram, int) –
Constructor for class mars.assembler.SourceLine
SourceLine constructor
SPACE –
Static variable in class mars.assembler.Directives
STACK_POINTER_REGISTER –
Static variable in class mars.mips.hardware.RegisterFile
stackBaseAddress –
Static variable in class mars.mips.hardware.Memory
base address for stack: 0x7ffffffc (this is mine – start of highest word below kernel space)
stackLimitAddress –
Static variable in class mars.mips.hardware.Memory
stackPointer –
Static variable in class mars.mips.hardware.Memory
starting address for stack: 0x7fffeffc (this is from SPIM not MIPS)
start() –
Method in class mars.simulator.SwingWorker
Start the worker thread.
START_AT_MAIN –
Static variable in class mars.Settings
Flag to control whether or not assembler automatically initializes program counter to ‘main’s address
STATUS –
Static variable in class mars.mips.hardware.Coprocessor0
stepped(boolean, int, ProcessingException) –
Method in class mars.venus.RunStepAction
stopExecution(AbstractAction) –
Method in class mars.simulator.Simulator
Set the volatile stop boolean variable checked by the execution
thread at the end of each MIPS instruction execution.
stopped(Simulator) –
Method in interface mars.simulator.Simulator.StopListener
stopped(ProcessingException, int) –
Method in class mars.venus.RunGoAction
Method to be called when Stop is selected through menu/toolbar/shortcut.
storeProgramArguments() –
Method in class mars.simulator.ProgramArgumentList
stringToInt(String) –
Static method in class mars.util.Binary
Attempt to validate given string whose characters represent a 32 bit integer.
stringToLong(String) –
Static method in class mars.util.Binary
Attempt to validate given string whose characters represent a 64 bit long.
styleIntToStyleString(int) –
Static method in class mars.util.EditorFont
Given an int that represents a font style from the Font class,
returns the corresponding String.
styles –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
styles –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
styleStringToStyleInt(String) –
Static method in class mars.util.EditorFont
Given a string that represents a font style, returns the
corresponding final int defined in Font: PLAIN, BOLD, ITALIC.
substituteSpacesForTabs(String) –
Static method in class mars.util.EditorFont
substituteSpacesForTabs(String, int) –
Static method in class mars.util.EditorFont
Handy utility to produce a string that substitutes spaces for all tab characters
in the given string.
supportsMultilineTokens() –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Returns if the token marker supports tokens that span multiple
lines.
SwingWorker – Class in mars.simulator
This is the 3rd version of SwingWorker (also known as
SwingWorker 3), an abstract class that you subclass to
perform GUI-related work in a dedicated thread.
SwingWorker(boolean) –
Constructor for class mars.simulator.SwingWorker
Start a thread that will call the construct method
and then exit.
SwitchSegment(Graphics, char) –
Method in class mars.tools.DigitalLabSim.SevenSegmentDisplay
Symbol – Class in mars.assembler
Represents a MIPS program identifier to be stored in the symbol table.
Symbol(String, int, boolean) –
Constructor for class mars.assembler.Symbol
Basic constructor, creates a symbol object.
SymbolTable – Class in mars.assembler
Creats a table of Symbol objects.
SymbolTable(String) –
Constructor for class mars.assembler.SymbolTable
Create a new empty symbol table for given file
symbolTable –
Static variable in class mars.Globals
Symbol table for file currently being assembled.
SyntaxDocument – Class in mars.venus.editors.jeditsyntax
A document implementation that can be tokenized by the syntax highlighting
system.
SyntaxDocument() –
Constructor for class mars.venus.editors.jeditsyntax.SyntaxDocument
SyntaxStyle – Class in mars.venus.editors.jeditsyntax
A simple text style class.
SyntaxStyle(Color, boolean, boolean) –
Constructor for class mars.venus.editors.jeditsyntax.SyntaxStyle
Creates a new SyntaxStyle.
SyntaxUtilities – Class in mars.venus.editors.jeditsyntax
Class with several utility functions used by jEdit’s syntax colorizing
subsystem.
Syscall – Interface in mars.mips.instructions.syscalls
Interface for any MIPS syscall system service.
SYSCALL_BUFSIZE –
Static variable in class mars.util.SystemIO
Buffer size for syscalls for file I/O
SYSCALL_EXCEPTION –
Static variable in class mars.simulator.Exceptions
SYSCALL_MAXFILES –
Static variable in class mars.util.SystemIO
Maximum number of files that can be open
SyscallClose – Class in mars.mips.instructions.syscalls
Service to close file descriptor given in $a0.
SyscallClose() –
Constructor for class mars.mips.instructions.syscalls.SyscallClose
Build an instance of the Close syscall.
SyscallConfirmDialog – Class in mars.mips.instructions.syscalls
Service to display a message to user.
SyscallConfirmDialog() –
Constructor for class mars.mips.instructions.syscalls.SyscallConfirmDialog
Build an instance of the syscall with its default service number and name.
SyscallExit – Class in mars.mips.instructions.syscalls
Service to exit the MIPS program.
SyscallExit() –
Constructor for class mars.mips.instructions.syscalls.SyscallExit
Build an instance of the Exit syscall.
SyscallExit2 – Class in mars.mips.instructions.syscalls
Service to exit the MIPS program with return value given in $a0.
SyscallExit2() –
Constructor for class mars.mips.instructions.syscalls.SyscallExit2
Build an instance of the Exit2 syscall.
SyscallInputDialogDouble – Class in mars.mips.instructions.syscalls
Service to input data.
SyscallInputDialogDouble() –
Constructor for class mars.mips.instructions.syscalls.SyscallInputDialogDouble
Build an instance of the syscall with its default service number and name.
SyscallInputDialogFloat – Class in mars.mips.instructions.syscalls
Service to input data.
SyscallInputDialogFloat() –
Constructor for class mars.mips.instructions.syscalls.SyscallInputDialogFloat
Build an instance of the syscall with its default service number and name.
SyscallInputDialogInt – Class in mars.mips.instructions.syscalls
Service to input data.
SyscallInputDialogInt() –
Constructor for class mars.mips.instructions.syscalls.SyscallInputDialogInt
Build an instance of the syscall with its default service number and name.
SyscallInputDialogString – Class in mars.mips.instructions.syscalls
Service to input data.
SyscallInputDialogString() –
Constructor for class mars.mips.instructions.syscalls.SyscallInputDialogString
Build an instance of the syscall with its default service number and name.
SyscallMessageDialog – Class in mars.mips.instructions.syscalls
Service to display a message to user.
SyscallMessageDialog() –
Constructor for class mars.mips.instructions.syscalls.SyscallMessageDialog
Build an instance of the syscall with its default service number and name.
SyscallMessageDialogDouble – Class in mars.mips.instructions.syscalls
Service to display a message to user.
SyscallMessageDialogDouble() –
Constructor for class mars.mips.instructions.syscalls.SyscallMessageDialogDouble
Build an instance of the syscall with its default service number and name.
SyscallMessageDialogFloat – Class in mars.mips.instructions.syscalls
Service to display a message to user.
SyscallMessageDialogFloat() –
Constructor for class mars.mips.instructions.syscalls.SyscallMessageDialogFloat
Build an instance of the syscall with its default service number and name.
SyscallMessageDialogInt – Class in mars.mips.instructions.syscalls
Service to display a message to user.
SyscallMessageDialogInt() –
Constructor for class mars.mips.instructions.syscalls.SyscallMessageDialogInt
Build an instance of the syscall with its default service number and name.
SyscallMessageDialogString – Class in mars.mips.instructions.syscalls
Service to display a message to user.
SyscallMessageDialogString() –
Constructor for class mars.mips.instructions.syscalls.SyscallMessageDialogString
Build an instance of the syscall with its default service number and name.
SyscallMidiOut – Class in mars.mips.instructions.syscalls
Service to output simulated MIDI tone to sound card.
SyscallMidiOut() –
Constructor for class mars.mips.instructions.syscalls.SyscallMidiOut
Build an instance of the MIDI (simulated) out syscall.
SyscallMidiOutSync – Class in mars.mips.instructions.syscalls
Service to output simulated MIDI tone to sound card.
SyscallMidiOutSync() –
Constructor for class mars.mips.instructions.syscalls.SyscallMidiOutSync
Build an instance of the MIDI (simulated) out syscall.
SyscallNumberOverride – Class in mars.mips.instructions.syscalls
Represents User override of default syscall number assignment.
SyscallNumberOverride(String, String) –
Constructor for class mars.mips.instructions.syscalls.SyscallNumberOverride
Constructor is called with two strings: service name and desired
number.
SyscallOpen – Class in mars.mips.instructions.syscalls
Service to open file name specified by $a0.
SyscallOpen() –
Constructor for class mars.mips.instructions.syscalls.SyscallOpen
Build an instance of the Open file syscall.
SyscallPrintChar – Class in mars.mips.instructions.syscalls
Service to display character stored in $a0 on the console.
SyscallPrintChar() –
Constructor for class mars.mips.instructions.syscalls.SyscallPrintChar
Build an instance of the Print Char syscall.
SyscallPrintDouble – Class in mars.mips.instructions.syscalls
Service to display double whose bits are stored in $f12 & $f13 onto the console.
SyscallPrintDouble() –
Constructor for class mars.mips.instructions.syscalls.SyscallPrintDouble
Build an instance of the Print Double syscall.
SyscallPrintFloat – Class in mars.mips.instructions.syscalls
Service to display on the console float whose bits are stored in $f12
SyscallPrintFloat() –
Constructor for class mars.mips.instructions.syscalls.SyscallPrintFloat
Build an instance of the Print Float syscall.
SyscallPrintInt – Class in mars.mips.instructions.syscalls
Service to display integer stored in $a0 on the console.
SyscallPrintInt() –
Constructor for class mars.mips.instructions.syscalls.SyscallPrintInt
Build an instance of the Print Integer syscall.
SyscallPrintIntBinary – Class in mars.mips.instructions.syscalls
Service to display integer stored in $a0 on the console.
SyscallPrintIntBinary() –
Constructor for class mars.mips.instructions.syscalls.SyscallPrintIntBinary
Build an instance of the Print Integer syscall.
SyscallPrintIntHex – Class in mars.mips.instructions.syscalls
Service to display integer stored in $a0 on the console.
SyscallPrintIntHex() –
Constructor for class mars.mips.instructions.syscalls.SyscallPrintIntHex
Build an instance of the Print Integer syscall.
SyscallPrintIntUnsigned – Class in mars.mips.instructions.syscalls
Service to display integer stored in $a0 on the console as unsigned decimal.
SyscallPrintIntUnsigned() –
Constructor for class mars.mips.instructions.syscalls.SyscallPrintIntUnsigned
Build an instance of the Print Integer Unsigned syscall.
SyscallPrintString – Class in mars.mips.instructions.syscalls
Service to display string stored starting at address in $a0 onto the console.
SyscallPrintString() –
Constructor for class mars.mips.instructions.syscalls.SyscallPrintString
Build an instance of the Print String syscall.
SyscallRandDouble – Class in mars.mips.instructions.syscalls
Service to return a random floating point value.
SyscallRandDouble() –
Constructor for class mars.mips.instructions.syscalls.SyscallRandDouble
Build an instance of the syscall with its default service number and name.
SyscallRandFloat – Class in mars.mips.instructions.syscalls
Service to return a random floating point value.
SyscallRandFloat() –
Constructor for class mars.mips.instructions.syscalls.SyscallRandFloat
Build an instance of the syscall with its default service number and name.
SyscallRandInt – Class in mars.mips.instructions.syscalls
Service to return a random integer.
SyscallRandInt() –
Constructor for class mars.mips.instructions.syscalls.SyscallRandInt
Build an instance of the syscall with its default service number and name.
SyscallRandIntRange – Class in mars.mips.instructions.syscalls
Service to return a random integer in a specified range.
SyscallRandIntRange() –
Constructor for class mars.mips.instructions.syscalls.SyscallRandIntRange
Build an instance of the syscall with its default service number and name.
SyscallRandSeed – Class in mars.mips.instructions.syscalls
Service to set seed for the underlying Java pseudorandom number generator.
SyscallRandSeed() –
Constructor for class mars.mips.instructions.syscalls.SyscallRandSeed
Build an instance of the syscall with its default service number and name.
SyscallRead – Class in mars.mips.instructions.syscalls
Service to read from file descriptor given in $a0.
SyscallRead() –
Constructor for class mars.mips.instructions.syscalls.SyscallRead
Build an instance of the Read file syscall.
SyscallReadChar – Class in mars.mips.instructions.syscalls
Service to read a character from input console into $a0.
SyscallReadChar() –
Constructor for class mars.mips.instructions.syscalls.SyscallReadChar
Build an instance of the Read Char syscall.
SyscallReadDouble – Class in mars.mips.instructions.syscalls
Service to read the bits of console input double into $f0 and $f1.
SyscallReadDouble() –
Constructor for class mars.mips.instructions.syscalls.SyscallReadDouble
Build an instance of the Read Double syscall.
SyscallReadFloat – Class in mars.mips.instructions.syscalls
Service to read the bits of input float into $f0
SyscallReadFloat() –
Constructor for class mars.mips.instructions.syscalls.SyscallReadFloat
Build an instance of the Read Float syscall.
SyscallReadInt – Class in mars.mips.instructions.syscalls
Service to read an integer from input console into $v0.
SyscallReadInt() –
Constructor for class mars.mips.instructions.syscalls.SyscallReadInt
Build an instance of the Read Integer syscall.
SyscallReadString – Class in mars.mips.instructions.syscalls
Service to read console input string into buffer starting at address in $a0.
SyscallReadString() –
Constructor for class mars.mips.instructions.syscalls.SyscallReadString
Build an instance of the Read String syscall.
SyscallSbrk – Class in mars.mips.instructions.syscalls
Service to allocate amount of heap memory specified in $a0, putting address into $v0.
SyscallSbrk() –
Constructor for class mars.mips.instructions.syscalls.SyscallSbrk
Build an instance of the Sbrk syscall.
SyscallSleep – Class in mars.mips.instructions.syscalls
Service to cause the MARS Java thread to sleep for (at least) the specified number of milliseconds.
SyscallSleep() –
Constructor for class mars.mips.instructions.syscalls.SyscallSleep
Build an instance of the syscall with its default service number and name.
SyscallTime – Class in mars.mips.instructions.syscalls
Service to read a character from input console into $a0.
SyscallTime() –
Constructor for class mars.mips.instructions.syscalls.SyscallTime
Build an instance of the Read Char syscall.
SyscallWrite – Class in mars.mips.instructions.syscalls
Service to write to file descriptor given in $a0.
SyscallWrite() –
Constructor for class mars.mips.instructions.syscalls.SyscallWrite
Build an instance of the Write file syscall.
SystemIO – Class in mars.util
Provides standard i/o services needed to simulate the MIPS syscall
routines.
SystemIO() –
Constructor for class mars.util.SystemIO
T
tableChanged(TableModelEvent) –
Method in class mars.venus.RunClearBreakpointsAction
Required TableModelListener method.
tabSize –
Variable in class mars.venus.editors.jeditsyntax.TextAreaDefaults
tabSize –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
tabSizeChars –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
tellEditingComponentToRequestFocusInWindow() –
Method in class mars.venus.EditPane
Delegates to text area’s requestFocusInWindow method.
TERMINATED –
Static variable in class mars.venus.FileStatus
execution terminated
TEXT –
Static variable in class mars.assembler.Directives
TEXT_COLUMN_ORDER –
Static variable in class mars.Settings
Order of text segment table columns
TEXT_FOUND –
Static variable in interface mars.venus.editors.MARSTextEditingArea
TEXT_NOT_FOUND –
Static variable in interface mars.venus.editors.MARSTextEditingArea
TEXT_REPLACED_FOUND_NEXT –
Static variable in interface mars.venus.editors.MARSTextEditingArea
TEXT_REPLACED_NOT_FOUND_NEXT –
Static variable in interface mars.venus.editors.MARSTextEditingArea
TEXT_SYMBOL –
Static variable in class mars.assembler.Symbol
textArea –
Variable in class mars.venus.editors.jeditsyntax.TextAreaPainter
TextAreaDefaults – Class in mars.venus.editors.jeditsyntax
Encapsulates default settings for a text area.
TextAreaDefaults() –
Constructor for class mars.venus.editors.jeditsyntax.TextAreaDefaults
TextAreaPainter – Class in mars.venus.editors.jeditsyntax
The text area repaint manager.
TextAreaPainter(JEditTextArea, TextAreaDefaults) –
Constructor for class mars.venus.editors.jeditsyntax.TextAreaPainter
Creates a new repaint manager.
TextAreaPainter.Highlight – Interface in mars.venus.editors.jeditsyntax
Highlight interface.
textBaseAddress –
Static variable in class mars.mips.hardware.Memory
base address for (user) text segment: 0x00400000
textLimitAddress –
Static variable in class mars.mips.hardware.Memory
TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_BACKGROUND –
Static variable in class mars.Settings
RGB color for text segment delay slot highlighted background
TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FONT –
Static variable in class mars.Settings
Font for text segment delay slot highlighted background
TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FOREGROUND –
Static variable in class mars.Settings
RGB color for text segment delay slot highlighted foreground
TEXTSEGMENT_HIGHLIGHT_BACKGROUND –
Static variable in class mars.Settings
RGB color for text segment highlighted background
TEXTSEGMENT_HIGHLIGHT_FONT –
Static variable in class mars.Settings
Font for table odd row foreground (text, data, register displays)
TEXTSEGMENT_HIGHLIGHT_FOREGROUND –
Static variable in class mars.Settings
RGB color for text segment highlighted foreground
TextSegmentWindow – Class in mars.venus
Creates the Text Segment window in the Execute tab of the UI
TextSegmentWindow() –
Constructor for class mars.venus.TextSegmentWindow
Constructor, sets up a new JInternalFrame.
TextUtilities – Class in mars.venus.editors.jeditsyntax
Class with several utility functions used by the text area component.
TextUtilities() –
Constructor for class mars.venus.editors.jeditsyntax.TextUtilities
theWindow –
Variable in class mars.tools.AbstractMarsToolAndApplication
thisMarsApp –
Variable in class mars.tools.AbstractMarsToolAndApplication
time –
Variable in class mars.venus.HardcopyWriter
TOGGLE_RECT –
Static variable in class mars.venus.editors.jeditsyntax.InputHandler
toggleBreakpoints() –
Method in class mars.venus.TextSegmentWindow
Enable or disable all items in the Breakpoints column.
Token – Class in mars.assembler
Represents one token in the input MIPS program.
Token(TokenTypes, String, MIPSprogram, int, int) –
Constructor for class mars.assembler.Token
Constructor for Token class.
Token – Class in mars.venus.editors.jeditsyntax.tokenmarker
A linked list of tokens.
Token(int, byte) –
Constructor for class mars.venus.editors.jeditsyntax.tokenmarker.Token
Creates a new token.
token –
Variable in class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker.LineInfo
The id of the last token of the line.
TOKEN_DELIMITERS –
Static variable in class mars.assembler.TokenTypes
tokenIsMacroParameter(String, boolean) –
Static method in class mars.assembler.Macro
returns whether tokenValue is macro parameter or not
tokenize(MIPSprogram) –
Method in class mars.assembler.Tokenizer
Will tokenize a complete MIPS program.
tokenize() –
Method in class mars.MIPSprogram
Tokenizes the MIPS source program.
tokenizeExampleInstruction(String) –
Method in class mars.assembler.Tokenizer
Used only to create a token list for the example provided with each instruction
specification.
tokenizeLine(int, String) –
Method in class mars.assembler.Tokenizer
Will tokenize one line of source code.
tokenizeLine(int, String, ErrorList) –
Method in class mars.assembler.Tokenizer
Will tokenize one line of source code.
tokenizeLine(int, String, ErrorList, boolean) –
Method in class mars.assembler.Tokenizer
Will tokenize one line of source code.
tokenizeLine(MIPSprogram, int, String, boolean) –
Method in class mars.assembler.Tokenizer
Will tokenize one line of source code.
tokenizeLines() –
Method in class mars.venus.editors.jeditsyntax.SyntaxDocument
Reparses the document, by passing all lines to the token
marker.
tokenizeLines(int, int) –
Method in class mars.venus.editors.jeditsyntax.SyntaxDocument
Reparses the document, by passing the specified lines to the
token marker.
Tokenizer – Class in mars.assembler
A tokenizer is capable of tokenizing a complete MIPS program, or a given line from
a MIPS program.
Tokenizer() –
Constructor for class mars.assembler.Tokenizer
Simple constructor.
Tokenizer(MIPSprogram) –
Constructor for class mars.assembler.Tokenizer
Constructor for use with existing MIPSprogram.
TokenList – Class in mars.assembler
Represents the list of tokens in a single line of MIPS code.
TokenList() –
Constructor for class mars.assembler.TokenList
Constructor for objects of class TokenList
tokenList –
Variable in class mars.mips.instructions.Instruction
List of tokens generated by tokenizing example usage (see exampleFormat).
tokenMarker –
Variable in class mars.venus.editors.jeditsyntax.SyntaxDocument
TokenMarker – Class in mars.venus.editors.jeditsyntax.tokenmarker
A token marker that splits lines of text into tokens.
TokenMarker() –
Constructor for class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Creates a new TokenMarker.
TokenMarker.LineInfo – Class in mars.venus.editors.jeditsyntax.tokenmarker
Inner class for storing information about tokenized lines.
TokenMarker.LineInfo() –
Constructor for class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker.LineInfo
Creates a new LineInfo object with token = Token.NULL
and obj = null.
TokenMarker.LineInfo(byte, Object) –
Constructor for class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker.LineInfo
Creates a new LineInfo object with the specified
parameters.
TokenTypes – Class in mars.assembler
Constants to identify the types of tokens found in MIPS programs.
ToolAction – Class in mars.venus
Connects a MarsTool class (class that implements MarsTool interface) to
the Mars menu system by supplying the response to that tool’s menu item
selection.
ToolAction(Class, String) –
Constructor for class mars.venus.ToolAction
Simple constructor.
ToolLoader – Class in mars.venus
This class provides functionality to bring external Mars tools into the Mars
system by adding them to its Tools menu.
ToolLoader() –
Constructor for class mars.venus.ToolLoader
toString() –
Method in class mars.assembler.Directives
Produces String-ified version of Directive object
toString() –
Method in class mars.assembler.Token
Get a String representing the token.
toString() –
Method in class mars.assembler.TokenList
Get a String representing the token list.
toString() –
Method in class mars.assembler.TokenTypes
Produces String equivalent of this token type, which is its name.
toString() –
Method in class mars.mips.dump.AbstractDumpFormat
String representing this object.
toString() –
Method in interface mars.mips.dump.DumpFormat
Descriptive name for the format.
toString() –
Method in class mars.mips.hardware.MemoryAccessNotice
String representation indicates access type, address and length in bytes
toString() –
Method in class mars.mips.hardware.RegisterAccessNotice
String representation indicates access type and which register
toString() –
Method in class mars.ProgramStatement
Crude attempt at building String representation of this complex structure.
toString() –
Method in class mars.simulator.SimulatorNotice
String representation indicates access type, address and length in bytes
toString() –
Method in class mars.venus.editors.jeditsyntax.SyntaxStyle
Returns a string representation of this object.
toString() –
Method in class mars.venus.editors.jeditsyntax.tokenmarker.Token
Returns a string representation of this token.
toTypeString() –
Method in class mars.assembler.TokenList
Get a String representing the sequence of token types for this list.
translate() –
Method in interface mars.assembler.TranslationCode
This is a callback method defined in anonymous class specified as
argument to ExtendedInstruction constructor.
TranslationCode – Interface in mars.assembler
This interface is intended for use by ExtendedInstruction objects to define, using
the translate() method, how to translate the extended (pseudo) instruction into
a sequence of one or more basic instructions, which can then be translated into
binary machine code.
TRANSMITTER_CONTROL –
Static variable in class mars.tools.KeyboardAndDisplaySimulator
TRANSMITTER_DATA –
Static variable in class mars.tools.KeyboardAndDisplaySimulator
TRAP_EXCEPTION –
Static variable in class mars.simulator.Exceptions
twoIntsToLong(int, int) –
Static method in class mars.util.Binary
Returns long (64 bit integer) combining the bit values of two given 32 bit
integer values.
U
undo() –
Method in class mars.venus.editors.generic.GenericTextArea
Undo previous edit
undo() –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Undo previous edit
undo() –
Method in interface mars.venus.editors.MARSTextEditingArea
undo() –
Method in class mars.venus.EditPane
Undo previous edit
unhighlightAllSteps() –
Method in class mars.venus.TextSegmentWindow
If any steps are highlighted, this erases the highlighting.
UNLIMITED_SPEED –
Static variable in class mars.venus.RunSpeedPanel
Constant that represents unlimited run speed.
unredoing –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
unsignedIntToIntString(int) –
Static method in class mars.util.Binary
Produce String equivalent of integer value interpreting it as an unsigned integer.
update(Observable, Object) –
Method in class mars.tools.AbstractMarsToolAndApplication
Called when receiving notice of access to MIPS memory or registers.
update(Observable, Object) –
Method in class mars.tools.DigitalLabSim
update(Observable, Object) –
Method in class mars.tools.FloatRepresentation
Override inherited update() to update display when “attached” register is modified
either by MIPS program or by user editing it on the MARS user interface.
update(Observable, Object) –
Method in class mars.tools.MarsBot
update(Observable, Object) –
Method in class mars.tools.ScavengerHunt
update(Observable, Object) –
Method in class mars.venus.Coprocessor0Window
Required by Observer interface.
update(Observable, Object) –
Method in class mars.venus.Coprocessor1Window
Required by Observer interface.
update(Observable, Object) –
Method in class mars.venus.DataSegmentWindow
Required by Observer interface.
update(Observable, Object) –
Method in class mars.venus.EditPane
Update, if source code is visible, when Font setting changes.
update(Observable, Object) –
Method in class mars.venus.RegistersWindow
Required by Observer interface.
update(Observable, Object) –
Method in class mars.venus.TextSegmentWindow
Required by Observer interface.
updateBaseAddressComboBox() –
Method in class mars.venus.DataSegmentWindow
updateBasicStatements() –
Method in class mars.venus.TextSegmentWindow
Redisplay the basic statements.
updateBracketHighlight(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
updateCell(int, int) –
Method in class mars.venus.DataSegmentWindow
Update data display to show this value (I’m not sure it is being called).
updateCodeAddresses() –
Method in class mars.venus.TextSegmentWindow
Redisplay the addresses.
updateDataAddresses() –
Method in class mars.venus.DataSegmentWindow
Redisplay the addresses.
updateDisplay() –
Method in class mars.tools.AbstractMarsToolAndApplication
Override this method to implement updating of GUI after each MIPS instruction is executed,
while running in “timed” mode (user specifies execution speed on the slider control).
updateDisplay() –
Method in class mars.tools.BitmapDisplay
Updates display immediately after each update (AccessNotice) is processed, after
display configuration changes as needed, and after each execution step when Mars
is running in timed mode.
updateDisplay() –
Method in class mars.tools.CacheSimulator
Updates display immediately after each update (AccessNotice) is processed, after
cache configuration changes as needed, and after each execution step when Mars
is running in timed mode.
updateDisplay() –
Method in class mars.tools.InstructionCounter
updateDisplay() –
Method in class mars.tools.InstructionStatistics
updates the text fields and progress bars according to the current counter values.
updateDisplay() –
Method in class mars.tools.MemoryReferenceVisualization
Updates display immediately after each update (AccessNotice) is processed, after
display configuration changes as needed, and after each execution step when Mars
is running in timed mode.
updateDoubleRegisterValue(int, int) –
Method in class mars.venus.Coprocessor1Window
This method handles the updating of the GUI.
updateFloatRegisterValue(int, int, int) –
Method in class mars.venus.Coprocessor1Window
This method handles the updating of the GUI.
updateHexaKeyboard(char) –
Method in class mars.tools.DigitalLabSim
updateLabelAddresses() –
Method in class mars.venus.LabelsWindow
Method to update display of label addresses.
updateModelForMemoryRange(int) –
Method in class mars.venus.DataSegmentWindow
Update table model with contents of new memory “chunk”.
updateOneSecondCounter(char) –
Method in class mars.tools.DigitalLabSim
updatePrediction(boolean) –
Method in class mars.tools.BHTEntry
Updates the entry’s history and prediction.
updatePredictionAtIdx(int, boolean) –
Method in class mars.tools.BHTableModel
Updates the BHT entry with the outcome of the branch instruction.
updateRedoState() –
Method in class mars.venus.EditPane
Update state of Edit menu’s Redo menu item.
updateRegister(String, int) –
Static method in class mars.mips.hardware.Coprocessor0
Sets the value of the register given to the value given.
updateRegister(int, int) –
Static method in class mars.mips.hardware.Coprocessor0
This method updates the register value who’s number is num.
updateRegister(int, int) –
Static method in class mars.mips.hardware.Coprocessor1
This method updates the FPU register value who’s number is num.
updateRegister(int, int) –
Static method in class mars.mips.hardware.RegisterFile
This method updates the register value who’s number is num.
updateRegister(String, int) –
Static method in class mars.mips.hardware.RegisterFile
Sets the value of the register given to the value given.
updateRegisters() –
Method in class mars.venus.Coprocessor0Window
Update register display using current display base (10 or 16)
updateRegisters(int) –
Method in class mars.venus.Coprocessor0Window
Update register display using specified display base
updateRegisters() –
Method in class mars.venus.Coprocessor1Window
Redisplay registers using current display number base (10 or 16)
updateRegisters(int) –
Method in class mars.venus.Coprocessor1Window
Redisplay registers using specified display number base (10 or 16)
updateRegisters() –
Method in class mars.venus.RegistersWindow
update register display using current number base (10 or 16)
updateRegisters(int) –
Method in class mars.venus.RegistersWindow
update register display using specified number base (10 or 16)
updateRegisterValue(int, int, int) –
Method in class mars.venus.Coprocessor0Window
This method handles the updating of the GUI.
updateRegisterValue(int, int, int) –
Method in class mars.venus.RegistersWindow
This method handles the updating of the GUI.
updateScrollBars() –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Updates the state of the scroll bars.
updateSevenSegment(int, char) –
Method in class mars.tools.DigitalLabSim
updateStaticFileStatus() –
Method in class mars.venus.EditPane
Delegates to corresponding FileStatus method
updateStaticFileStatus() –
Method in class mars.venus.FileStatus
Update static FileStatus fields with values from this FileStatus object
To support legacy code that depends on the static.
updateSyntaxStyles() –
Method in class mars.venus.editors.generic.GenericTextArea
Does nothing, but required by the interface.
updateSyntaxStyles() –
Method in class mars.venus.editors.jeditsyntax.JEditBasedTextArea
Update the syntax style table, which is obtained from
SyntaxUtilities.
updateSyntaxStyles() –
Method in interface mars.venus.editors.MARSTextEditingArea
updateUndoState() –
Method in class mars.venus.EditPane
Update state of Edit menu’s Undo menu item.
updateValues() –
Method in class mars.venus.DataSegmentWindow
Update data display to show all values
userHighAddress –
Static variable in class mars.mips.hardware.Memory
highest address accessible in user (not kernel) mode.
userInputAlert –
Static variable in class mars.Globals
String to GUI’s RunI/O text area when echoing user input from pop-up dialog.
usingCompactMemoryConfiguration() –
Method in class mars.mips.hardware.Memory
Determine whether the current memory configuration has a maximum address that can be stored
in 16 bits.
V
VADDR –
Static variable in class mars.mips.hardware.Coprocessor0
Coprocessor register names
VenusUI – Class in mars.venus
Top level container for Venus GUI.
VenusUI(String) –
Constructor for class mars.venus.VenusUI
Constructor for the Class.
version –
Static variable in class mars.Globals
The current MARS version number.
vertical –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
visibleLines –
Variable in class mars.venus.editors.jeditsyntax.JEditTextArea
W
WARNING –
Static variable in class mars.ErrorMessage
Constant to indicate this message is warning not error
WARNING_MESSAGE_PREFIX –
Static variable in class mars.ErrorList
warningCount() –
Method in class mars.ErrorList
Count of number of warning messages in list.
WARNINGS_ARE_ERRORS –
Static variable in class mars.Settings
Flag to determine whether or not assembler warnings are considered errors.
warningsOccurred() –
Method in class mars.ErrorList
Determine whether warning has occured or not.
width –
Variable in class mars.venus.HardcopyWriter
willBranch(ProgramStatement) –
Static method in class mars.tools.BHTSimulator
Checks if the branch instruction delivered as parameter will branch or not.
WORD –
Static variable in class mars.assembler.Directives
WORD_LENGTH_BYTES –
Static variable in class mars.mips.hardware.Memory
MIPS word length in bytes.
WORD_SIZE –
Static variable in class mars.assembler.DataTypes
Number of bytes occupied by MIPS word is 4.
wordAligned(int) –
Static method in class mars.mips.hardware.Memory
Utility to determine if given address is word-aligned.
WRITE –
Static variable in class mars.mips.hardware.AccessNotice
Indicates the purpose of access was to write.
write(char[], int, int) –
Method in class mars.venus.HardcopyWriter
This is the write( ) method of the stream.
writeToFile(int, byte[], int) –
Static method in class mars.util.SystemIO
Write bytes to file.
X
x0 –
Variable in class mars.venus.HardcopyWriter
xToOffset(int, int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Converts an x co-ordinate to an offset within a line.
xyToOffset(int, int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Converts a point to an offset, from the start of the text.
Y
y0 –
Variable in class mars.venus.HardcopyWriter
yToLine(int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Converts a y co-ordinate to a line index.
_
_offsetToX(int, int) –
Method in class mars.venus.editors.jeditsyntax.JEditTextArea
Converts an offset in a line into an x co-ordinate.
A B C D E F G H I J K L M N O P Q R S T U V W X Y _
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Deprecated List
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Deprecated API
Contents Deprecated Methods
Deprecated Constructors
Deprecated Methods
mars.Settings.getAssembleAllEnabled()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ALL_ENABLED)
mars.Settings.getAssembleOnOpenEnabled()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ON_OPEN_ENABLED)
mars.Settings.getBareMachineEnabled()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.BARE_MACHINE_ENABLED)
mars.Settings.getDataSegmentHighlighting()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DATA_SEGMENT_HIGHLIGHTING)
mars.Settings.getDelayedBranchingEnabled()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
mars.Settings.getDisplayAddressesInHex()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_ADDRESSES_IN_HEX)
mars.Settings.getDisplayValuesInHex()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_VALUES_IN_HEX)
mars.Settings.getEditorLineNumbersDisplayed()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EDITOR_LINE_NUMBERS_DISPLAYED)
mars.Settings.getExceptionHandlerEnabled()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EXCEPTION_HANDLER_ENABLED)
mars.Settings.getExtendedAssemblerEnabled()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EXTENDED_ASSEMBLER_ENABLED)
mars.Settings.getLabelWindowVisibility()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.LABEL_WINDOW_VISIBILITY)
mars.Settings.getProgramArguments()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.PROGRAM_ARGUMENTS)
mars.Settings.getRegistersHighlighting()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.REGISTERS_HIGHLIGHTING)
mars.Settings.getStartAtMain()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.START_AT_MAIN)
mars.Settings.getWarningsAreErrors()
Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.WARNINGS_ARE_ERRORS)
mars.Settings.setAssembleAllEnabled(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ALL_ENABLED)
mars.Settings.setAssembleOnOpenEnabled(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ON_OPEN_ENABLED)
mars.Settings.setDataSegmentHighlighting(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DATA_SEGMENT_HIGHLIGHTING)
mars.Settings.setDelayedBranchingEnabled(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
mars.Settings.setDelayedBranchingEnabledNonPersistent(boolean)
Use setBooleanSettingNonPersistent(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
mars.Settings.setDisplayAddressesInHex(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_ADDRESSES_IN_HEX)
mars.Settings.setDisplayValuesInHex(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_VALUES_IN_HEX)
mars.Settings.setEditorLineNumbersDisplayed(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EDITOR_LINE_NUMBERS_DISPLAYED)
mars.Settings.setExceptionHandlerEnabled(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EXCEPTION_HANDLER_ENABLED)
mars.Settings.setExtendedAssemblerEnabled(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EXTENDED_ASSEMBLER_ENABLED)
mars.Settings.setLabelWindowVisibility(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.LABEL_WINDOW_VISIBILITY)
mars.Settings.setProgramArguments(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.PROGRAM_ARGUMENTS)
mars.Settings.setRegistersHighlighting(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.REGISTERS_HIGHLIGHTING)
mars.Settings.setStartAtMain(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.START_AT_MAIN)
mars.Settings.setWarningsAreErrors(boolean)
Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.WARNINGS_ARE_ERRORS)
Deprecated Constructors
mars.ErrorMessage(boolean, String, int, int, String, String)
Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
mars.ErrorMessage(String, int, int, String)
Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
mars.ErrorMessage(String, int, int, String, String)
Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Classes
Mars
/* Javadoc style sheet */
/* Define colors, fonts and other style attributes here to override the defaults */
/* Page background color */
body { background-color: #FFFFFF; color:#000000 }
/* Headings */
h1 { font-size: 145% }
/* Table colors */
.TableHeadingColor { background: #CCCCFF; color:#000000 } /* Dark mauve */
.TableSubHeadingColor { background: #EEEEFF; color:#000000 } /* Light mauve */
.TableRowColor { background: #FFFFFF; color:#000000 } /* White */
/* Font used in left-hand frame lists */
.FrameTitleFont { font-size: 100%; font-family: Helvetica, Arial, sans-serif; color:#000000 }
.FrameHeadingFont { font-size: 90%; font-family: Helvetica, Arial, sans-serif; color:#000000 }
.FrameItemFont { font-size: 90%; font-family: Helvetica, Arial, sans-serif; color:#000000 }
/* Navigation bar fonts and colors */
.NavBarCell1 { background-color:#EEEEFF; color:#000000} /* Light mauve */
.NavBarCell1Rev { background-color:#00008B; color:#FFFFFF} /* Dark Blue */
.NavBarFont1 { font-family: Arial, Helvetica, sans-serif; color:#000000;color:#000000;}
.NavBarFont1Rev { font-family: Arial, Helvetica, sans-serif; color:#FFFFFF;color:#FFFFFF;}
.NavBarCell2 { font-family: Arial, Helvetica, sans-serif; background-color:#FFFFFF; color:#000000}
.NavBarCell3 { font-family: Arial, Helvetica, sans-serif; background-color:#FFFFFF; color:#000000}
Overview
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Packages
mars
mars.assembler
mars.mips.dump
mars.mips.hardware
mars.mips.instructions
mars.mips.instructions.syscalls
mars.simulator
mars.tools
mars.util
mars.venus
mars.venus.editors
mars.venus.editors.generic
mars.venus.editors.jeditsyntax
mars.venus.editors.jeditsyntax.tokenmarker
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
API Help
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
How This API Document Is Organized
This API (Application Programming Interface) document has pages corresponding to the items in the navigation bar, described as follows.
Overview
The Overview page is the front page of this API document and provides a list of all packages with a summary for each. This page can also contain an overall description of the set of packages.
Package
Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain four categories:
Interfaces (italic)
Classes
Enums
Exceptions
Errors
Annotation Types
Class/Interface
Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
Class inheritance diagram
Direct Subclasses
All Known Subinterfaces
All Known Implementing Classes
Class/interface declaration
Class/interface description
Nested Class Summary
Field Summary
Constructor Summary
Method Summary
Field Detail
Constructor Detail
Method Detail
Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
Annotation Type
Each annotation type has its own separate page with the following sections:
Annotation Type declaration
Annotation Type description
Required Element Summary
Optional Element Summary
Element Detail
Enum
Each enum has its own separate page with the following sections:
Enum declaration
Enum description
Enum Constant Summary
Enum Constant Detail
Tree (Class Hierarchy)
There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object. The interfaces do not inherit from java.lang.Object. When viewing the Overview page, clicking on “Tree” displays the hierarchy for all packages.
When viewing a particular package, class or interface page, clicking “Tree” displays the hierarchy for only that package.
Deprecated API
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
Index
The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
Prev/Next
These links take you to the next or previous class, interface, package, or related page.
Frames/No Frames
These links show and hide the HTML frames. All pages are available with or without frames.
Serialized Form
Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking “Serialized Form” in the “See also” section of the class description.
Constant Field Values
The Constant Field Values page lists the static final fields and their values.
This help file applies to API documentation generated using the standard doclet.
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package
Class Summary
Mars Portal to Mars
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
All Classes
All Classes
AbstractDumpFormat
AbstractFontSettingDialog
AbstractMarsToolAndApplication
AbstractSyscall
AccessNotice
AddressErrorException
AsciiTextDumpFormat
Assembler
BackStepper
BasicInstruction
BasicInstructionFormat
BHTableModel
BHTEntry
BHTSimGUI
BHTSimulator
Binary
BinaryDumpFormat
BinaryTextDumpFormat
BitmapDisplay
CacheSimulator
Coprocessor0
Coprocessor0Window
Coprocessor1
Coprocessor1Window
DataSegmentWindow
DataTypes
DefaultInputHandler
DelayedBranch
DigitalLabSim
Directives
DumpFormat
DumpFormatLoader
EditCopyAction
EditCutAction
EditFindReplaceAction
Editor
EditorFont
EditPane
EditPasteAction
EditRedoAction
EditSelectAllAction
EditTabbedPane
EditUndoAction
ErrorList
ErrorMessage
Exceptions
ExecutePane
ExtendedInstruction
FileCloseAction
FileCloseAllAction
FileDumpMemoryAction
FileExitAction
FilenameFinder
FileNewAction
FileOpenAction
FilePrintAction
FileSaveAction
FileSaveAllAction
FileSaveAsAction
FileStatus
FloatRepresentation
GenericTextArea
Globals
GuiAction
HardcopyWriter
HardcopyWriter.PrintCanceledException
HelpAboutAction
HelpHelpAction
HexTextDumpFormat
InputHandler
InputHandler.backspace
InputHandler.backspace_word
InputHandler.clip_copy
InputHandler.clip_cut
InputHandler.clip_paste
InputHandler.delete
InputHandler.delete_word
InputHandler.document_end
InputHandler.document_home
InputHandler.end
InputHandler.home
InputHandler.insert_break
InputHandler.insert_char
InputHandler.insert_tab
InputHandler.MacroRecorder
InputHandler.next_char
InputHandler.next_line
InputHandler.next_page
InputHandler.next_word
InputHandler.NonRecordable
InputHandler.NonRepeatable
InputHandler.overwrite
InputHandler.prev_char
InputHandler.prev_line
InputHandler.prev_page
InputHandler.prev_word
InputHandler.repeat
InputHandler.select_all
InputHandler.toggle_rect
InputHandler.Wrapper
Instruction
InstructionCounter
InstructionSet
InstructionStatistics
IntelHexDumpFormat
IntroToTools
InvalidRegisterAccessException
JEditBasedTextArea
JEditTextArea
KeyboardAndDisplaySimulator
KeywordMap
LabelsWindow
Macro
MacroPool
MainPane
Mars
MarsBot
MarsLaunch
MarsSplashScreen
MARSTextEditingArea
MarsTool
Memory
MemoryAccessNotice
MemoryConfiguration
MemoryConfigurations
MemoryDump
MemoryReferenceVisualization
MessagesPane
MIFDumpFormat
MIPSprogram
MIPSTokenMarker
NumberDisplayBaseChooser
OperandFormat
PopupHelpItem
PopupListener
ProcessingException
ProgramArgumentList
ProgramStatement
PropertiesFile
RandomStreams
Register
RegisterAccessNotice
RegisterFile
RegistersPane
RegistersWindow
RepeatButton
RunAssembleAction
RunBackstepAction
RunClearBreakpointsAction
RunGoAction
RunPauseAction
RunResetAction
RunSpeedPanel
RunStepAction
RunStopAction
RunToggleBreakpointsAction
ScavengerHunt
ScreenMagnifier
SegmentWindowDumpFormat
Settings
SettingsAddressDisplayBaseAction
SettingsAssembleAllAction
SettingsAssembleOnOpenAction
SettingsDelayedBranchingAction
SettingsEditorAction
SettingsExceptionHandlerAction
SettingsExtendedAction
SettingsHighlightingAction
SettingsLabelAction
SettingsMemoryConfigurationAction
SettingsPopupInputAction
SettingsProgramArgumentsAction
SettingsSelfModifyingCodeAction
SettingsStartAtMainAction
SettingsValueDisplayBaseAction
SettingsWarningsAreErrorsAction
SimulationCode
Simulator
Simulator.StopListener
SimulatorNotice
SourceLine
SwingWorker
Symbol
SymbolTable
SyntaxDocument
SyntaxStyle
SyntaxUtilities
Syscall
SyscallClose
SyscallConfirmDialog
SyscallExit
SyscallExit2
SyscallInputDialogDouble
SyscallInputDialogFloat
SyscallInputDialogInt
SyscallInputDialogString
SyscallMessageDialog
SyscallMessageDialogDouble
SyscallMessageDialogFloat
SyscallMessageDialogInt
SyscallMessageDialogString
SyscallMidiOut
SyscallMidiOutSync
SyscallNumberOverride
SyscallOpen
SyscallPrintChar
SyscallPrintDouble
SyscallPrintFloat
SyscallPrintInt
SyscallPrintIntBinary
SyscallPrintIntHex
SyscallPrintIntUnsigned
SyscallPrintString
SyscallRandDouble
SyscallRandFloat
SyscallRandInt
SyscallRandIntRange
SyscallRandSeed
SyscallRead
SyscallReadChar
SyscallReadDouble
SyscallReadFloat
SyscallReadInt
SyscallReadString
SyscallSbrk
SyscallSleep
SyscallTime
SyscallWrite
SystemIO
TextAreaDefaults
TextAreaPainter
TextAreaPainter.Highlight
TextSegmentWindow
TextUtilities
Token
Token
Tokenizer
TokenList
TokenMarker
TokenTypes
ToolAction
ToolLoader
TranslationCode
VenusUI
mars
mars.assembler
mars.mips.dump
mars.mips.hardware
mars.mips.instructions
mars.mips.instructions.syscalls
mars.simulator
mars.tools
mars.util
mars.venus
mars.venus.editors
mars.venus.editors.generic
mars.venus.editors.jeditsyntax
mars.venus.editors.jeditsyntax.tokenmarker
Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object Mars
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
IntroToTools
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class IntroToTools
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
mars.tools.IntroToTools
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
public class IntroToTools
extends AbstractMarsToolAndApplication
The “hello world” of MarsTools!
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class mars.tools.AbstractMarsToolAndApplication
AbstractMarsToolAndApplication.ConnectButton, AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class mars.tools.AbstractMarsToolAndApplication
connectButton, isBeingUsedAsAMarsTool, theWindow, thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
IntroToTools()
Simple constructor, likely used by the MARS Tools menu mechanism
IntroToTools(String title,
String heading)
Simple constructor, likely used to run a stand-alone memory reference visualizer.
Method Summary
protected JComponent buildMainDisplayArea()
Implementation of the inherited abstract method to build the main
display area of the GUI.
String getName()
Required method to return Tool name.
static void main(String[] args)
Main provided for pure stand-alone use.
Methods inherited from class mars.tools.AbstractMarsToolAndApplication
action, addAsObserver, addAsObserver, addAsObserver, buildButtonAreaMarsTool, buildButtonAreaStandAlone, buildHeadingArea, deleteAsObserver, deleteAsObserver, getHelpComponent, go, initializePostGUI, initializePreGUI, isObserving, performSpecialClosingDuties, processMIPSUpdate, reset, update, updateDisplay
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Constructor Detail
IntroToTools
public IntroToTools(String title,
String heading)
Simple constructor, likely used to run a stand-alone memory reference visualizer.
Parameters:
title – String containing title for title bar
heading – String containing text for heading shown in upper part of window.
IntroToTools
public IntroToTools()
Simple constructor, likely used by the MARS Tools menu mechanism
Method Detail
main
public static void main(String[] args)
Main provided for pure stand-alone use. Recommended stand-alone use is to write a
driver program that instantiates a MemoryReferenceVisualization object then invokes its go() method.
“stand-alone” means it is not invoked from the MARS Tools menu. “Pure” means there
is no driver program to invoke the application.
getName
public String getName()
Required method to return Tool name.
Specified by:
getName in interface MarsTool
Specified by:
getName in class AbstractMarsToolAndApplication
Returns:
Tool name. MARS will display this in menu item.
buildMainDisplayArea
protected JComponent buildMainDisplayArea()
Implementation of the inherited abstract method to build the main
display area of the GUI. It will be placed in the CENTER area of a
BorderLayout. The title is in the NORTH area, and the controls are
in the SOUTH area.
Specified by:
buildMainDisplayArea in class AbstractMarsToolAndApplication
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DigitalLabSim
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class DigitalLabSim
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
mars.tools.DigitalLabSim
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
public class DigitalLabSim
extends AbstractMarsToolAndApplication
See Also:
Serialized Form
Nested Class Summary
class DigitalLabSim.HexaKeyboard
class DigitalLabSim.OneSecondCounter
class DigitalLabSim.SevenSegmentDisplay
class DigitalLabSim.SevenSegmentPanel
Nested classes/interfaces inherited from class mars.tools.AbstractMarsToolAndApplication
AbstractMarsToolAndApplication.ConnectButton, AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
static int EXTERNAL_INTERRUPT_HEXA_KEYBOARD
static int EXTERNAL_INTERRUPT_TIMER
Fields inherited from class mars.tools.AbstractMarsToolAndApplication
connectButton, isBeingUsedAsAMarsTool, theWindow, thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
DigitalLabSim()
DigitalLabSim(String title,
String heading)
Method Summary
protected void addAsObserver()
Add this app/tool as an Observer of desired MIPS Observables (memory and registers).
protected JComponent buildMainDisplayArea()
Abstract method that must be instantiated by subclass to build the main display area
of the GUI.
protected JComponent getHelpComponent()
Override this method to provide a JComponent (probably a JButton) of your choice
to be placed just left of the Close/Exit button.
String getName()
Required MarsTool method to return Tool name.
static void main(String[] args)
protected void reset()
Method that will be called each time the default Reset button is clicked.
void update(Observable ressource,
Object accessNotice)
Called when receiving notice of access to MIPS memory or registers.
void updateHexaKeyboard(char row)
void updateOneSecondCounter(char value)
void updateSevenSegment(int number,
char value)
Methods inherited from class mars.tools.AbstractMarsToolAndApplication
action, addAsObserver, addAsObserver, buildButtonAreaMarsTool, buildButtonAreaStandAlone, buildHeadingArea, deleteAsObserver, deleteAsObserver, go, initializePostGUI, initializePreGUI, isObserving, performSpecialClosingDuties, processMIPSUpdate, updateDisplay
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Field Detail
EXTERNAL_INTERRUPT_TIMER
public static final int EXTERNAL_INTERRUPT_TIMER
See Also:
Constant Field Values
EXTERNAL_INTERRUPT_HEXA_KEYBOARD
public static final int EXTERNAL_INTERRUPT_HEXA_KEYBOARD
See Also:
Constant Field Values
Constructor Detail
DigitalLabSim
public DigitalLabSim(String title,
String heading)
DigitalLabSim
public DigitalLabSim()
Method Detail
main
public static void main(String[] args)
getName
public String getName()
Description copied from class: AbstractMarsToolAndApplication
Required MarsTool method to return Tool name. Must be defined by subclass.
Specified by:
getName in interface MarsTool
Specified by:
getName in class AbstractMarsToolAndApplication
Returns:
Tool name. MARS will display this in menu item.
addAsObserver
protected void addAsObserver()
Description copied from class: AbstractMarsToolAndApplication
Add this app/tool as an Observer of desired MIPS Observables (memory and registers).
By default, will add as an Observer of the entire Data Segment in memory.
Override if you want something different. Note that the Memory methods to add an
Observer to memory are flexible (you can register for a range of addresses) but
may throw an AddressErrorException that you need to catch.
This method is called whenever the default “Connect” button on a MarsTool or the
default “Assemble and run” on a stand-alone Mars app is selected. The corresponding
NOTE: if you do not want to register as an Observer of the entire data segment
(starts at address 0x10000000) then override this to either do some alternative
or nothing at all. This method is also overloaded to allow arbitrary memory
subrange.
Overrides:
addAsObserver in class AbstractMarsToolAndApplication
update
public void update(Observable ressource,
Object accessNotice)
Description copied from class: AbstractMarsToolAndApplication
Called when receiving notice of access to MIPS memory or registers. Default
implementation of method required by Observer interface. This method will filter out
notices originating from the MARS GUI or from direct user editing of memory or register
displays. Only notices arising from MIPS program access are allowed in.
It then calls two methods to be overridden by the subclass (since they do
nothing by default): processMIPSUpdate() then updateDisplay().
Specified by:
update in interface Observer
Overrides:
update in class AbstractMarsToolAndApplication
Parameters:
ressource – the attached MIPS resource
accessNotice – AccessNotice information provided by the resource
reset
protected void reset()
Description copied from class: AbstractMarsToolAndApplication
Method that will be called each time the default Reset button is clicked.
Use it to reset any data structures and/or GUI components. By default it does nothing.
Overrides:
reset in class AbstractMarsToolAndApplication
buildMainDisplayArea
protected JComponent buildMainDisplayArea()
Description copied from class: AbstractMarsToolAndApplication
Abstract method that must be instantiated by subclass to build the main display area
of the GUI. It will be placed in the CENTER area of a BorderLayout. The title
is in the NORTH area, and the controls are in the SOUTH area.
Specified by:
buildMainDisplayArea in class AbstractMarsToolAndApplication
getHelpComponent
protected JComponent getHelpComponent()
Description copied from class: AbstractMarsToolAndApplication
Override this method to provide a JComponent (probably a JButton) of your choice
to be placed just left of the Close/Exit button. Its anticipated use is for a
“help” button that launches a help message or dialog. But it can be any valid
JComponent that doesn’t mind co-existing among a bunch of JButtons.
Overrides:
getHelpComponent in class AbstractMarsToolAndApplication
updateSevenSegment
public void updateSevenSegment(int number,
char value)
updateHexaKeyboard
public void updateHexaKeyboard(char row)
updateOneSecondCounter
public void updateOneSecondCounter(char value)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FloatRepresentation
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class FloatRepresentation
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
mars.tools.FloatRepresentation
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
public class FloatRepresentation
extends AbstractMarsToolAndApplication
Tool to help students learn about IEEE 754 representation of 32 bit
floating point values. This representation is used by MIPS “float”
directive and instructions and also the Java (and most other languages)
“float” data type. As written, it can ALMOST be adapted to 64 bit by
changing a few constants.
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class mars.tools.AbstractMarsToolAndApplication
AbstractMarsToolAndApplication.ConnectButton, AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class mars.tools.AbstractMarsToolAndApplication
connectButton, isBeingUsedAsAMarsTool, theWindow, thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
FloatRepresentation()
Simple constructor, likely used by the MARS Tools menu mechanism
FloatRepresentation(String title,
String heading)
Simple constructor, likely used to run a stand-alone memory reference visualizer.
Method Summary
protected void addAsObserver()
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only.
protected JComponent buildDisplayArea()
protected JComponent buildMainDisplayArea()
Method that constructs the main display area.
protected void deleteAsObserver()
Delete this app/tool as an Observer of the attached register.
String getName()
Fetch tool name (for display in MARS Tools menu)
static void main(String[] args)
Main provided for pure stand-alone use.
protected void reset()
Method to reset display values to 0 when the Reset button selected.
void update(Observable register,
Object accessNotice)
Override inherited update() to update display when “attached” register is modified
either by MIPS program or by user editing it on the MARS user interface.
Methods inherited from class mars.tools.AbstractMarsToolAndApplication
action, addAsObserver, addAsObserver, buildButtonAreaMarsTool, buildButtonAreaStandAlone, buildHeadingArea, deleteAsObserver, getHelpComponent, go, initializePostGUI, initializePreGUI, isObserving, performSpecialClosingDuties, processMIPSUpdate, updateDisplay
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Constructor Detail
FloatRepresentation
public FloatRepresentation(String title,
String heading)
Simple constructor, likely used to run a stand-alone memory reference visualizer.
Parameters:
title – String containing title for title bar
heading – String containing text for heading shown in upper part of window.
FloatRepresentation
public FloatRepresentation()
Simple constructor, likely used by the MARS Tools menu mechanism
Method Detail
main
public static void main(String[] args)
Main provided for pure stand-alone use. Recommended stand-alone use is to write a
driver program that instantiates a FloatRepresentation object then invokes its go() method.
“stand-alone” means it is not invoked from the MARS Tools menu. “Pure” means there
is no driver program to invoke the application.
getName
public String getName()
Fetch tool name (for display in MARS Tools menu)
Specified by:
getName in interface MarsTool
Specified by:
getName in class AbstractMarsToolAndApplication
Returns:
String containing tool name
addAsObserver
protected void addAsObserver()
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only. This version will register us as observer over the selected
floating point register, if any. If no register is selected, it will not do anything.
If you use the inherited GUI buttons, this method is invoked when you click “Connect” button
on MarsTool or the “Assemble and Run” button on a Mars-based app.
Overrides:
addAsObserver in class AbstractMarsToolAndApplication
deleteAsObserver
protected void deleteAsObserver()
Delete this app/tool as an Observer of the attached register. This overrides
the inherited version which deletes only as an Observer of memory.
This method is called when the default “Disconnect” button on a MarsTool is selected or
when the MIPS program execution triggered by the default “Assemble and run” on a stand-alone
Mars app terminates (e.g. when the button is re-enabled).
Overrides:
deleteAsObserver in class AbstractMarsToolAndApplication
buildMainDisplayArea
protected JComponent buildMainDisplayArea()
Method that constructs the main display area. This will be vertically sandwiched between
the standard heading area at the top and the control area at the bottom.
Specified by:
buildMainDisplayArea in class AbstractMarsToolAndApplication
Returns:
the GUI component containing the application/tool-specific part of the user interface
update
public void update(Observable register,
Object accessNotice)
Override inherited update() to update display when “attached” register is modified
either by MIPS program or by user editing it on the MARS user interface.
The latter is the reason for overriding the inherited update() method.
The inherited method will filter out notices triggered by the MARS GUI or the user.
Specified by:
update in interface Observer
Overrides:
update in class AbstractMarsToolAndApplication
Parameters:
register – the attached register
accessNotice – information provided by register in RegisterAccessNotice object
reset
protected void reset()
Method to reset display values to 0 when the Reset button selected.
If attached to a MIPS register at the time, the register will be reset as well.
Overrides inherited method that does nothing.
Overrides:
reset in class AbstractMarsToolAndApplication
buildDisplayArea
protected JComponent buildDisplayArea()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
BHTSimulator
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class BHTSimulator
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
mars.tools.BHTSimulator
All Implemented Interfaces:
ActionListener, ImageObserver, MenuContainer, Serializable, EventListener, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
public class BHTSimulator
extends AbstractMarsToolAndApplication
implements ActionListener
A MARS tool for simulating branch prediction with a Branch History Table (BHT)
The simulation is based on observing the access to the instruction memory area (text segment).
If a branch instruction is encountered, a prediction based on a BHT is performed.
The outcome of the branch is compared with the prediction and the prediction is updated accordingly.
Statistics about the correct and incorrect number of predictions can be obtained for each BHT entry.
The number of entries in the BHT and the history that is considered for each prediction can be configured interactively.
A change of the configuration however causes a re-initialization of the BHT.
The tool can be used to show how branch prediction works in case of loops and how effective such simple methods are.
In case of nested loops the difference of BHT with 1 or 2 Bit history can be explored and visualized.
Author:
ingo.kofler@itec.uni-klu.ac.at
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class mars.tools.AbstractMarsToolAndApplication
AbstractMarsToolAndApplication.ConnectButton, AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
static int BHT_DEFAULT_HISTORY
constant for the default history size
static boolean BHT_DEFAULT_INITVAL
constant for the default inital value
static int BHT_DEFAULT_SIZE
constant for the default size of the BHT
static String BHT_HEADING
the heading of the tool
static String BHT_NAME
the name of the tool
static String BHT_VERSION
the version of the tool
Fields inherited from class mars.tools.AbstractMarsToolAndApplication
connectButton, isBeingUsedAsAMarsTool, theWindow, thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
BHTSimulator()
Creates a BHT Simulator with given name and heading.
Method Summary
void actionPerformed(ActionEvent event)
Handles the actions when selecting another value in one of the two combo boxes.
protected void addAsObserver()
Adds BHTSimulator as observer of the text segment.
protected JComponent buildMainDisplayArea()
Creates a GUI and initialize the GUI with the default values.
protected static int extractBranchAddress(ProgramStatement stmt)
Extracts the target address of the branch.
String getName()
Returns the name of the tool.
protected void handleExecBranchInst(int branchInstAddr,
boolean branchTaken)
Handles the execution of the branch instruction.
protected void handlePreBranchInst(ProgramStatement stmt)
Handles the execution branch instruction.
protected static boolean isBranchInstruction(ProgramStatement stmt)
Determines if the instruction is a branch instruction or not.
protected void processMIPSUpdate(Observable resource,
AccessNotice notice)
Callback for text segment access by the MIPS simulator.
protected void reset()
Performs a reset of the simulator.
protected void resetSimulator()
Resets the simulator by clearing the GUI elements and resetting the BHT.
protected static boolean willBranch(ProgramStatement stmt)
Checks if the branch instruction delivered as parameter will branch or not.
Methods inherited from class mars.tools.AbstractMarsToolAndApplication
action, addAsObserver, addAsObserver, buildButtonAreaMarsTool, buildButtonAreaStandAlone, buildHeadingArea, deleteAsObserver, deleteAsObserver, getHelpComponent, go, initializePostGUI, initializePreGUI, isObserving, performSpecialClosingDuties, update, updateDisplay
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Field Detail
BHT_DEFAULT_SIZE
public static final int BHT_DEFAULT_SIZE
constant for the default size of the BHT
See Also:
Constant Field Values
BHT_DEFAULT_HISTORY
public static final int BHT_DEFAULT_HISTORY
constant for the default history size
See Also:
Constant Field Values
BHT_DEFAULT_INITVAL
public static final boolean BHT_DEFAULT_INITVAL
constant for the default inital value
See Also:
Constant Field Values
BHT_NAME
public static final String BHT_NAME
the name of the tool
See Also:
Constant Field Values
BHT_VERSION
public static final String BHT_VERSION
the version of the tool
See Also:
Constant Field Values
BHT_HEADING
public static final String BHT_HEADING
the heading of the tool
See Also:
Constant Field Values
Constructor Detail
BHTSimulator
public BHTSimulator()
Creates a BHT Simulator with given name and heading.
Method Detail
addAsObserver
protected void addAsObserver()
Adds BHTSimulator as observer of the text segment.
Overrides:
addAsObserver in class AbstractMarsToolAndApplication
buildMainDisplayArea
protected JComponent buildMainDisplayArea()
Creates a GUI and initialize the GUI with the default values.
Specified by:
buildMainDisplayArea in class AbstractMarsToolAndApplication
getName
public String getName()
Returns the name of the tool.
Specified by:
getName in interface MarsTool
Specified by:
getName in class AbstractMarsToolAndApplication
Returns:
the tool’s name as String
reset
protected void reset()
Performs a reset of the simulator.
This causes the BHT to be reseted and the log messages to be cleared.
Overrides:
reset in class AbstractMarsToolAndApplication
actionPerformed
public void actionPerformed(ActionEvent event)
Handles the actions when selecting another value in one of the two combo boxes.
Selecting a different BHT size or history causes a reset of the simulator.
Specified by:
actionPerformed in interface ActionListener
resetSimulator
protected void resetSimulator()
Resets the simulator by clearing the GUI elements and resetting the BHT.
handlePreBranchInst
protected void handlePreBranchInst(ProgramStatement stmt)
Handles the execution branch instruction.
This method is called each time a branch instruction is executed.
Based on the address of the instruction the corresponding index into the BHT is calculated.
The prediction is obtained from the BHT at the calculated index and is visualized appropriately.
Parameters:
stmt – the branch statement that is executed
handleExecBranchInst
protected void handleExecBranchInst(int branchInstAddr,
boolean branchTaken)
Handles the execution of the branch instruction.
The correctness of the prediction is visualized in both the table and the log message area.
The BHT is updated based on the information if the branch instruction was taken or not.
Parameters:
branchInstAddr – the address of the branch instruction
branchTaken – the information if the branch is taken or not (determined in a step before)
isBranchInstruction
protected static boolean isBranchInstruction(ProgramStatement stmt)
Determines if the instruction is a branch instruction or not.
Parameters:
stmt – the statement to investigate
Returns:
true, if stmt is a branch instruction, otherwise false
willBranch
protected static boolean willBranch(ProgramStatement stmt)
Checks if the branch instruction delivered as parameter will branch or not.
Parameters:
stmt – the branch instruction to be investigated
Returns:
true if the branch will be taken, otherwise false
extractBranchAddress
protected static int extractBranchAddress(ProgramStatement stmt)
Extracts the target address of the branch.
In MIPS the target address is encoded as 16-bit value.
The target address is encoded relative to the address of the instruction after the branch instruction
Parameters:
stmt – the branch instruction
Returns:
the address of the instruction that is executed if the branch is taken
processMIPSUpdate
protected void processMIPSUpdate(Observable resource,
AccessNotice notice)
Callback for text segment access by the MIPS simulator.
The method is called each time the text segment is accessed to fetch the next instruction.
If the next instruction to execute was a branch instruction, the branch prediction is performed and visualized.
In case the last instruction was a branch instruction, the outcome of the branch prediction is analyzed and visualized.
Overrides:
processMIPSUpdate in class AbstractMarsToolAndApplication
Parameters:
resource – the observed resource
notice – signals the type of access (memory, register etc.)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
KeyboardAndDisplaySimulator
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class KeyboardAndDisplaySimulator
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
mars.tools.KeyboardAndDisplaySimulator
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
public class KeyboardAndDisplaySimulator
extends AbstractMarsToolAndApplication
Keyboard and Display Simulator. It can be run either as a stand-alone Java application having
access to the mars package, or through MARS as an item in its Tools menu. It makes
maximum use of methods inherited from its abstract superclass AbstractMarsToolAndApplication.
Pete Sanderson
Version 1.0, 24 July 2008.
Version 1.1, 24 November 2008 corrects two omissions: (1) the tool failed to register as an observer
of kernel text memory when counting instruction executions for transmitter ready bit
reset delay, and (2) the tool failed to test the Status register’s Exception Level bit before
raising the exception that results in the interrupt (if the Exception Level bit is 1, that
means an interrupt is being processed, so disable further interrupts).
Version 1.2, 6 August 2009, soft-codes the MMIO register locations for new memory configuration
feature of MARS 3.7. Previously memory segment addresses were fixed and final. Now they
can be modified dynamically so the tool has to get its values dynamically as well.
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class mars.tools.AbstractMarsToolAndApplication
AbstractMarsToolAndApplication.ConnectButton, AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
static Dimension preferredTextAreaDimension
static int RECEIVER_CONTROL
static int RECEIVER_DATA
static int TRANSMITTER_CONTROL
static int TRANSMITTER_DATA
Fields inherited from class mars.tools.AbstractMarsToolAndApplication
connectButton, isBeingUsedAsAMarsTool, theWindow, thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
KeyboardAndDisplaySimulator()
Simple constructor, likely used by the MARS Tools menu mechanism
KeyboardAndDisplaySimulator(String title,
String heading)
Simple constructor, likely used to run a stand-alone keyboard/display simulator.
Method Summary
protected void addAsObserver()
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only.
protected JComponent buildMainDisplayArea()
Method that constructs the main display area.
protected JComponent getHelpComponent()
Overrides default method, to provide a Help button for this tool/app.
String getName()
Required MarsTool method to return Tool name.
protected void initializePostGUI()
Initialization code to be executed after the GUI is configured.
protected void initializePreGUI()
Method that will be called once just before the GUI is constructed in the go() and action()
methods.
static void main(String[] args)
Main provided for pure stand-alone use.
protected void processMIPSUpdate(Observable memory,
AccessNotice accessNotice)
Update display when connected MIPS program accesses (data) memory.
protected void reset()
Method to reset counters and display when the Reset button selected.
Methods inherited from class mars.tools.AbstractMarsToolAndApplication
action, addAsObserver, addAsObserver, buildButtonAreaMarsTool, buildButtonAreaStandAlone, buildHeadingArea, deleteAsObserver, deleteAsObserver, go, isObserving, performSpecialClosingDuties, update, updateDisplay
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Field Detail
preferredTextAreaDimension
public static Dimension preferredTextAreaDimension
RECEIVER_CONTROL
public static int RECEIVER_CONTROL
RECEIVER_DATA
public static int RECEIVER_DATA
TRANSMITTER_CONTROL
public static int TRANSMITTER_CONTROL
TRANSMITTER_DATA
public static int TRANSMITTER_DATA
Constructor Detail
KeyboardAndDisplaySimulator
public KeyboardAndDisplaySimulator(String title,
String heading)
Simple constructor, likely used to run a stand-alone keyboard/display simulator.
Parameters:
title – String containing title for title bar
heading – String containing text for heading shown in upper part of window.
KeyboardAndDisplaySimulator
public KeyboardAndDisplaySimulator()
Simple constructor, likely used by the MARS Tools menu mechanism
Method Detail
main
public static void main(String[] args)
Main provided for pure stand-alone use. Recommended stand-alone use is to write a
driver program that instantiates a KeyboardAndDisplaySimulator object then invokes its go() method.
“stand-alone” means it is not invoked from the MARS Tools menu. “Pure” means there
is no driver program to invoke the application.
getName
public String getName()
Required MarsTool method to return Tool name.
Specified by:
getName in interface MarsTool
Specified by:
getName in class AbstractMarsToolAndApplication
Returns:
Tool name. MARS will display this in menu item.
initializePreGUI
protected void initializePreGUI()
Description copied from class: AbstractMarsToolAndApplication
Method that will be called once just before the GUI is constructed in the go() and action()
methods. Use it to initialize any data structures needed for the application whose values
will be needed to determine the initial state of GUI components. By default it does nothing.
Overrides:
initializePreGUI in class AbstractMarsToolAndApplication
addAsObserver
protected void addAsObserver()
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only.
When user enters keystroke, set RECEIVER_CONTROL and RECEIVER_DATA using the action listener.
When user loads word (lw) from RECEIVER_DATA (we are notified of the read), then clear RECEIVER_CONTROL.
When user stores word (sw) to TRANSMITTER_DATA (we are notified of the write), then clear TRANSMITTER_CONTROL, read TRANSMITTER_DATA,
echo the character to display, wait for delay period, then set TRANSMITTER_CONTROL.
If you use the inherited GUI buttons, this method is invoked when you click “Connect” button on MarsTool or the
“Assemble and Run” button on a Mars-based app.
Overrides:
addAsObserver in class AbstractMarsToolAndApplication
buildMainDisplayArea
protected JComponent buildMainDisplayArea()
Method that constructs the main display area. It is organized vertically
into two major components: the display and the keyboard. The display itself
is a JTextArea and it echoes characters placed into the low order byte of
the Transmitter Data location, 0xffff000c. They keyboard is also a JTextArea
places each typed character into the Receive Data location 0xffff0004.
Specified by:
buildMainDisplayArea in class AbstractMarsToolAndApplication
Returns:
the GUI component containing these two areas
processMIPSUpdate
protected void processMIPSUpdate(Observable memory,
AccessNotice accessNotice)
Update display when connected MIPS program accesses (data) memory.
Overrides:
processMIPSUpdate in class AbstractMarsToolAndApplication
Parameters:
memory – the attached memory
accessNotice – information provided by memory in MemoryAccessNotice object
initializePostGUI
protected void initializePostGUI()
Initialization code to be executed after the GUI is configured. Overrides inherited default.
Overrides:
initializePostGUI in class AbstractMarsToolAndApplication
reset
protected void reset()
Method to reset counters and display when the Reset button selected.
Overrides inherited method that does nothing.
Overrides:
reset in class AbstractMarsToolAndApplication
getHelpComponent
protected JComponent getHelpComponent()
Overrides default method, to provide a Help button for this tool/app.
Overrides:
getHelpComponent in class AbstractMarsToolAndApplication
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InstructionStatistics
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class InstructionStatistics
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
mars.tools.InstructionStatistics
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
public class InstructionStatistics
extends AbstractMarsToolAndApplication
A MARS tool for obtaining instruction statistics by instruction category.
The code of this tools is initially based on the Instruction counter tool by Felipe Lassa.
Author:
Ingo Kofler
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class mars.tools.AbstractMarsToolAndApplication
AbstractMarsToolAndApplication.ConnectButton, AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
protected int lastAddress
The last address we saw.
Fields inherited from class mars.tools.AbstractMarsToolAndApplication
connectButton, isBeingUsedAsAMarsTool, theWindow, thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
InstructionStatistics()
Simple construction, likely used by the MARS Tools menu mechanism.
InstructionStatistics(String title,
String heading)
Simple constructor, likely used to run a stand-alone enhanced instruction counter.
Method Summary
protected void addAsObserver()
registers the tool as observer for the text segment of the MIPS program
protected JComponent buildMainDisplayArea()
creates the display area for the tool as required by the API
protected int getInstructionCategory(ProgramStatement stmt)
decodes the instruction and determines the category of the instruction.
String getName()
returns the name of the tool
protected void initializePreGUI()
performs initialization tasks of the counters before the GUI is created.
protected void processMIPSUpdate(Observable resource,
AccessNotice notice)
method that is called each time the MIPS simulator accesses the text segment.
protected void reset()
resets the counter values of the tool and updates the display.
protected void updateDisplay()
updates the text fields and progress bars according to the current counter values.
Methods inherited from class mars.tools.AbstractMarsToolAndApplication
action, addAsObserver, addAsObserver, buildButtonAreaMarsTool, buildButtonAreaStandAlone, buildHeadingArea, deleteAsObserver, deleteAsObserver, getHelpComponent, go, initializePostGUI, isObserving, performSpecialClosingDuties, update
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Field Detail
lastAddress
protected int lastAddress
The last address we saw. We ignore it because the only way for a
program to execute twice the same instruction is to enter an infinite
loop, which is not insteresting in the POV of counting instructions.
Constructor Detail
InstructionStatistics
public InstructionStatistics(String title,
String heading)
Simple constructor, likely used to run a stand-alone enhanced instruction counter.
Parameters:
title – String containing title for title bar
heading – String containing text for heading shown in upper part of window.
InstructionStatistics
public InstructionStatistics()
Simple construction, likely used by the MARS Tools menu mechanism.
Method Detail
getName
public String getName()
returns the name of the tool
Specified by:
getName in interface MarsTool
Specified by:
getName in class AbstractMarsToolAndApplication
Returns:
the tools’s name
buildMainDisplayArea
protected JComponent buildMainDisplayArea()
creates the display area for the tool as required by the API
Specified by:
buildMainDisplayArea in class AbstractMarsToolAndApplication
Returns:
a panel that holds the GUI of the tool
addAsObserver
protected void addAsObserver()
registers the tool as observer for the text segment of the MIPS program
Overrides:
addAsObserver in class AbstractMarsToolAndApplication
getInstructionCategory
protected int getInstructionCategory(ProgramStatement stmt)
decodes the instruction and determines the category of the instruction.
The instruction is decoded by extracting the operation and function code of the 32-bit instruction.
Only the most relevant instructions are decoded and categorized.
Parameters:
stmt – the instruction to decode
Returns:
the category of the instruction
See Also:
CATEGORY_ALU,
CATEGORY_JUMP,
CATEGORY_BRANCH,
CATEGORY_MEM,
CATEGORY_OTHER
processMIPSUpdate
protected void processMIPSUpdate(Observable resource,
AccessNotice notice)
method that is called each time the MIPS simulator accesses the text segment.
Before an instruction is executed by the simulator, the instruction is fetched from the program memory.
This memory access is observed and the corresponding instruction is decoded and categorized by the tool.
According to the category the counter values are increased and the display gets updated.
Overrides:
processMIPSUpdate in class AbstractMarsToolAndApplication
Parameters:
resource – the observed resource
notice – signals the type of access (memory, register etc.)
initializePreGUI
protected void initializePreGUI()
performs initialization tasks of the counters before the GUI is created.
Overrides:
initializePreGUI in class AbstractMarsToolAndApplication
reset
protected void reset()
resets the counter values of the tool and updates the display.
Overrides:
reset in class AbstractMarsToolAndApplication
updateDisplay
protected void updateDisplay()
updates the text fields and progress bars according to the current counter values.
Overrides:
updateDisplay in class AbstractMarsToolAndApplication
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DigitalLabSim.SevenSegmentPanel
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class DigitalLabSim.SevenSegmentPanel
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
mars.tools.DigitalLabSim.SevenSegmentPanel
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible
Enclosing class:
DigitalLabSim
public class DigitalLabSim.SevenSegmentPanel
extends JPanel
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
DigitalLabSim.SevenSegmentDisplay[] display
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
DigitalLabSim.SevenSegmentPanel()
Method Summary
void modifyDisplay(int num,
char val)
void resetSevenSegment()
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
display
public DigitalLabSim.SevenSegmentDisplay[] display
Constructor Detail
DigitalLabSim.SevenSegmentPanel
public DigitalLabSim.SevenSegmentPanel()
Method Detail
modifyDisplay
public void modifyDisplay(int num,
char val)
resetSevenSegment
public void resetSevenSegment()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InstructionCounter
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class InstructionCounter
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
mars.tools.InstructionCounter
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
public class InstructionCounter
extends AbstractMarsToolAndApplication
Instruction counter tool. Can be used to know how many instructions
were executed to complete a given program.
Code slightly based on MemoryReferenceVisualization.
Author:
Felipe Lessa
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class mars.tools.AbstractMarsToolAndApplication
AbstractMarsToolAndApplication.ConnectButton, AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
protected int counter
Number of instructions executed until now.
protected int counterI
Number of instructions of type I.
protected int counterJ
Number of instructions of type J.
protected int counterR
Number of instructions of type R.
protected int lastAddress
The last address we saw.
Fields inherited from class mars.tools.AbstractMarsToolAndApplication
connectButton, isBeingUsedAsAMarsTool, theWindow, thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
InstructionCounter()
Simple construction, likely used by the MARS Tools menu mechanism.
InstructionCounter(String title,
String heading)
Simple constructor, likely used to run a stand-alone memory reference visualizer.
Method Summary
protected void addAsObserver()
Add this app/tool as an Observer of desired MIPS Observables (memory and registers).
protected JComponent buildMainDisplayArea()
Abstract method that must be instantiated by subclass to build the main display area
of the GUI.
String getName()
Required MarsTool method to return Tool name.
protected void initializePreGUI()
Method that will be called once just before the GUI is constructed in the go() and action()
methods.
protected void processMIPSUpdate(Observable resource,
AccessNotice notice)
Override this method to process a received notice from MIPS Observable (memory or register)
It will only be called if the notice was generated as the result of MIPS instruction execution.
protected void reset()
Method that will be called each time the default Reset button is clicked.
protected void updateDisplay()
Override this method to implement updating of GUI after each MIPS instruction is executed,
while running in “timed” mode (user specifies execution speed on the slider control).
Methods inherited from class mars.tools.AbstractMarsToolAndApplication
action, addAsObserver, addAsObserver, buildButtonAreaMarsTool, buildButtonAreaStandAlone, buildHeadingArea, deleteAsObserver, deleteAsObserver, getHelpComponent, go, initializePostGUI, isObserving, performSpecialClosingDuties, update
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Field Detail
counter
protected int counter
Number of instructions executed until now.
counterR
protected int counterR
Number of instructions of type R.
counterI
protected int counterI
Number of instructions of type I.
counterJ
protected int counterJ
Number of instructions of type J.
lastAddress
protected int lastAddress
The last address we saw. We ignore it because the only way for a
program to execute twice the same instruction is to enter an infinite
loop, which is not insteresting in the POV of counting instructions.
Constructor Detail
InstructionCounter
public InstructionCounter(String title,
String heading)
Simple constructor, likely used to run a stand-alone memory reference visualizer.
Parameters:
title – String containing title for title bar
heading – String containing text for heading shown in upper part of window.
InstructionCounter
public InstructionCounter()
Simple construction, likely used by the MARS Tools menu mechanism.
Method Detail
getName
public String getName()
Description copied from class: AbstractMarsToolAndApplication
Required MarsTool method to return Tool name. Must be defined by subclass.
Specified by:
getName in interface MarsTool
Specified by:
getName in class AbstractMarsToolAndApplication
Returns:
Tool name. MARS will display this in menu item.
buildMainDisplayArea
protected JComponent buildMainDisplayArea()
Description copied from class: AbstractMarsToolAndApplication
Abstract method that must be instantiated by subclass to build the main display area
of the GUI. It will be placed in the CENTER area of a BorderLayout. The title
is in the NORTH area, and the controls are in the SOUTH area.
Specified by:
buildMainDisplayArea in class AbstractMarsToolAndApplication
addAsObserver
protected void addAsObserver()
Description copied from class: AbstractMarsToolAndApplication
Add this app/tool as an Observer of desired MIPS Observables (memory and registers).
By default, will add as an Observer of the entire Data Segment in memory.
Override if you want something different. Note that the Memory methods to add an
Observer to memory are flexible (you can register for a range of addresses) but
may throw an AddressErrorException that you need to catch.
This method is called whenever the default “Connect” button on a MarsTool or the
default “Assemble and run” on a stand-alone Mars app is selected. The corresponding
NOTE: if you do not want to register as an Observer of the entire data segment
(starts at address 0x10000000) then override this to either do some alternative
or nothing at all. This method is also overloaded to allow arbitrary memory
subrange.
Overrides:
addAsObserver in class AbstractMarsToolAndApplication
processMIPSUpdate
protected void processMIPSUpdate(Observable resource,
AccessNotice notice)
Description copied from class: AbstractMarsToolAndApplication
Override this method to process a received notice from MIPS Observable (memory or register)
It will only be called if the notice was generated as the result of MIPS instruction execution.
By default it does nothing. After this method is complete, the updateDisplay() method will be
invoked automatically.
Overrides:
processMIPSUpdate in class AbstractMarsToolAndApplication
initializePreGUI
protected void initializePreGUI()
Description copied from class: AbstractMarsToolAndApplication
Method that will be called once just before the GUI is constructed in the go() and action()
methods. Use it to initialize any data structures needed for the application whose values
will be needed to determine the initial state of GUI components. By default it does nothing.
Overrides:
initializePreGUI in class AbstractMarsToolAndApplication
reset
protected void reset()
Description copied from class: AbstractMarsToolAndApplication
Method that will be called each time the default Reset button is clicked.
Use it to reset any data structures and/or GUI components. By default it does nothing.
Overrides:
reset in class AbstractMarsToolAndApplication
updateDisplay
protected void updateDisplay()
Description copied from class: AbstractMarsToolAndApplication
Override this method to implement updating of GUI after each MIPS instruction is executed,
while running in “timed” mode (user specifies execution speed on the slider control).
Does nothing by default.
Overrides:
updateDisplay in class AbstractMarsToolAndApplication
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MarsBot
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class MarsBot
java.lang.Object
mars.tools.MarsBot
All Implemented Interfaces:
Observer, MarsTool
public class MarsBot
extends Object
implements Observer, MarsTool
Simple Demo of Mars tool capability
Constructor Summary
MarsBot()
Method Summary
void action()
Performs tool functions.
String getName()
Return a name you have chosen for this tool.
void update(Observable o,
Object arg)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
MarsBot
public MarsBot()
Method Detail
getName
public String getName()
Description copied from interface: MarsTool
Return a name you have chosen for this tool. It will appear as the
menu item.
Specified by:
getName in interface MarsTool
action
public void action()
Description copied from interface: MarsTool
Performs tool functions. It will be invoked when the tool is selected
from the Tools menu.
Specified by:
action in interface MarsTool
update
public void update(Observable o,
Object arg)
Specified by:
update in interface Observer
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
CacheSimulator
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class CacheSimulator
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
mars.tools.CacheSimulator
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
public class CacheSimulator
extends AbstractMarsToolAndApplication
A data cache simulator. It can be run either as a stand-alone Java application having
access to the mars package, or through MARS as an item in its Tools menu. It makes
maximum use of methods inherited from its abstract superclass AbstractMarsToolOrApp.
Pete Sanderson, v 1.0: 16-18 October 2006, v 1.1: 7 November 2006. v 1.2: 23 December 2010.
Version 1.2 fixes a bug in the hit/miss animator under full or N-way set associative. It was
animating the block of initial access (first block of set). Now it animates the block
of final access (where address found or stored). Also added log display to GUI (previously System.out).
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class mars.tools.AbstractMarsToolAndApplication
AbstractMarsToolAndApplication.ConnectButton, AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class mars.tools.AbstractMarsToolAndApplication
connectButton, isBeingUsedAsAMarsTool, theWindow, thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
CacheSimulator()
Simple constructor, likely used by the MARS Tools menu mechanism
CacheSimulator(String title,
String heading)
Simple constructor, likely used to run a stand-alone cache simulator.
Method Summary
protected JComponent buildMainDisplayArea()
Method that constructs the main cache simulator display area.
String getName()
Required MarsTool method to return Tool name.
protected void initializePostGUI()
The only post-GUI initialization is to create the initial cache object based on the default settings
of the various combo boxes.
protected void initializePreGUI()
Initialize all JComboBox choice structures not already initialized at declaration.
static void main(String[] args)
Main provided for pure stand-alone use.
protected void processMIPSUpdate(Observable memory,
AccessNotice accessNotice)
Apply caching policies and update display when connected MIPS program accesses (data) memory.
protected void reset()
Method to reset cache, counters and display when the Reset button selected.
protected void updateDisplay()
Updates display immediately after each update (AccessNotice) is processed, after
cache configuration changes as needed, and after each execution step when Mars
is running in timed mode.
Methods inherited from class mars.tools.AbstractMarsToolAndApplication
action, addAsObserver, addAsObserver, addAsObserver, buildButtonAreaMarsTool, buildButtonAreaStandAlone, buildHeadingArea, deleteAsObserver, deleteAsObserver, getHelpComponent, go, isObserving, performSpecialClosingDuties, update
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Constructor Detail
CacheSimulator
public CacheSimulator(String title,
String heading)
Simple constructor, likely used to run a stand-alone cache simulator.
Parameters:
title – String containing title for title bar
heading – String containing text for heading shown in upper part of window.
CacheSimulator
public CacheSimulator()
Simple constructor, likely used by the MARS Tools menu mechanism
Method Detail
main
public static void main(String[] args)
Main provided for pure stand-alone use. Recommended stand-alone use is to write a
driver program that instantiates a CacheSimulator object then invokes its go() method.
“stand-alone” means it is not invoked from the MARS Tools menu. “Pure” means there
is no driver program to invoke the Cache Simulator.
getName
public String getName()
Required MarsTool method to return Tool name.
Specified by:
getName in interface MarsTool
Specified by:
getName in class AbstractMarsToolAndApplication
Returns:
Tool name. MARS will display this in menu item.
buildMainDisplayArea
protected JComponent buildMainDisplayArea()
Method that constructs the main cache simulator display area. It is organized vertically
into three major components: the cache configuration which an be modified
using combo boxes, the cache performance which is updated as the
attached MIPS program executes, and the runtime log which is optionally used
to display log of each cache access.
Specified by:
buildMainDisplayArea in class AbstractMarsToolAndApplication
Returns:
the GUI component containing these three areas
processMIPSUpdate
protected void processMIPSUpdate(Observable memory,
AccessNotice accessNotice)
Apply caching policies and update display when connected MIPS program accesses (data) memory.
Overrides:
processMIPSUpdate in class AbstractMarsToolAndApplication
Parameters:
memory – the attached memory
accessNotice – information provided by memory in MemoryAccessNotice object
initializePreGUI
protected void initializePreGUI()
Initialize all JComboBox choice structures not already initialized at declaration.
Also creates initial default cache object. Overrides inherited method that does nothing.
Overrides:
initializePreGUI in class AbstractMarsToolAndApplication
initializePostGUI
protected void initializePostGUI()
The only post-GUI initialization is to create the initial cache object based on the default settings
of the various combo boxes. Overrides inherited method that does nothing.
Overrides:
initializePostGUI in class AbstractMarsToolAndApplication
reset
protected void reset()
Method to reset cache, counters and display when the Reset button selected.
Overrides inherited method that does nothing.
Overrides:
reset in class AbstractMarsToolAndApplication
updateDisplay
protected void updateDisplay()
Updates display immediately after each update (AccessNotice) is processed, after
cache configuration changes as needed, and after each execution step when Mars
is running in timed mode. Overrides inherited method that does nothing.
Overrides:
updateDisplay in class AbstractMarsToolAndApplication
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DigitalLabSim.HexaKeyboard.EcouteurClick
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class DigitalLabSim.HexaKeyboard.EcouteurClick
java.lang.Object
mars.tools.DigitalLabSim.HexaKeyboard.EcouteurClick
All Implemented Interfaces:
MouseListener, EventListener
Enclosing class:
DigitalLabSim.HexaKeyboard
public class DigitalLabSim.HexaKeyboard.EcouteurClick
extends Object
implements MouseListener
Constructor Summary
DigitalLabSim.HexaKeyboard.EcouteurClick(int val)
Method Summary
void mouseClicked(MouseEvent arg0)
void mouseEntered(MouseEvent arg0)
void mouseExited(MouseEvent arg0)
void mousePressed(MouseEvent arg0)
void mouseReleased(MouseEvent arg0)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
DigitalLabSim.HexaKeyboard.EcouteurClick
public DigitalLabSim.HexaKeyboard.EcouteurClick(int val)
Method Detail
mouseEntered
public void mouseEntered(MouseEvent arg0)
Specified by:
mouseEntered in interface MouseListener
mouseExited
public void mouseExited(MouseEvent arg0)
Specified by:
mouseExited in interface MouseListener
mousePressed
public void mousePressed(MouseEvent arg0)
Specified by:
mousePressed in interface MouseListener
mouseReleased
public void mouseReleased(MouseEvent arg0)
Specified by:
mouseReleased in interface MouseListener
mouseClicked
public void mouseClicked(MouseEvent arg0)
Specified by:
mouseClicked in interface MouseListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
ScreenMagnifier
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class ScreenMagnifier
java.lang.Object
mars.tools.ScreenMagnifier
All Implemented Interfaces:
MarsTool
public class ScreenMagnifier
extends Object
implements MarsTool
Handy little tool to magnify a selected section of the screen
by a given scale and display it. The screen image snapshot
will be of the screen pixels beneath the tool’s frame. The
scale can be adjusted. The image is displayed in the tool’s
scrollable panel. You can highlight items on the image using
the scribbler (hold down mouse button and move it on the
image). The magnification scale adjustment is on the tool’s
window, but other settings can be modified on a button-
triggered dialog. It will capture the contents of the
underlying MARS graphical user interface, but NOT the
contents of other Mars Tools frames.
Author:
Pete Sanderson
Constructor Summary
ScreenMagnifier()
Method Summary
void action()
Performs tool functions.
String getName()
Return a name you have chosen for this tool.
static void main(String[] args)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
ScreenMagnifier
public ScreenMagnifier()
Method Detail
getName
public String getName()
Description copied from interface: MarsTool
Return a name you have chosen for this tool. It will appear as the
menu item.
Specified by:
getName in interface MarsTool
action
public void action()
Description copied from interface: MarsTool
Performs tool functions. It will be invoked when the tool is selected
from the Tools menu.
Specified by:
action in interface MarsTool
main
public static void main(String[] args)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
AbstractMarsToolAndApplication.ConnectButton
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class AbstractMarsToolAndApplication.ConnectButton
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.AbstractButton
javax.swing.JButton
mars.tools.AbstractMarsToolAndApplication.ConnectButton
All Implemented Interfaces:
ImageObserver, ItemSelectable, MenuContainer, Serializable, Accessible, SwingConstants
Enclosing class:
AbstractMarsToolAndApplication
protected class AbstractMarsToolAndApplication.ConnectButton
extends JButton
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JButton
JButton.AccessibleJButton
Nested classes/interfaces inherited from class javax.swing.AbstractButton
AbstractButton.AccessibleAbstractButton, AbstractButton.ButtonChangeListener
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.AbstractButton
actionListener, BORDER_PAINTED_CHANGED_PROPERTY, changeEvent, changeListener, CONTENT_AREA_FILLED_CHANGED_PROPERTY, DISABLED_ICON_CHANGED_PROPERTY, DISABLED_SELECTED_ICON_CHANGED_PROPERTY, FOCUS_PAINTED_CHANGED_PROPERTY, HORIZONTAL_ALIGNMENT_CHANGED_PROPERTY, HORIZONTAL_TEXT_POSITION_CHANGED_PROPERTY, ICON_CHANGED_PROPERTY, itemListener, MARGIN_CHANGED_PROPERTY, MNEMONIC_CHANGED_PROPERTY, model, MODEL_CHANGED_PROPERTY, PRESSED_ICON_CHANGED_PROPERTY, ROLLOVER_ENABLED_CHANGED_PROPERTY, ROLLOVER_ICON_CHANGED_PROPERTY, ROLLOVER_SELECTED_ICON_CHANGED_PROPERTY, SELECTED_ICON_CHANGED_PROPERTY, TEXT_CHANGED_PROPERTY, VERTICAL_ALIGNMENT_CHANGED_PROPERTY, VERTICAL_TEXT_POSITION_CHANGED_PROPERTY
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
AbstractMarsToolAndApplication.ConnectButton()
Method Summary
void connect()
void disconnect()
boolean isConnected()
Methods inherited from class javax.swing.JButton
getAccessibleContext, getUIClassID, isDefaultButton, isDefaultCapable, paramString, removeNotify, setDefaultCapable, updateUI
Methods inherited from class javax.swing.AbstractButton
actionPropertyChanged, addActionListener, addChangeListener, addImpl, addItemListener, checkHorizontalKey, checkVerticalKey, configurePropertiesFromAction, createActionListener, createActionPropertyChangeListener, createChangeListener, createItemListener, doClick, doClick, fireActionPerformed, fireItemStateChanged, fireStateChanged, getAction, getActionCommand, getActionListeners, getChangeListeners, getDisabledIcon, getDisabledSelectedIcon, getDisplayedMnemonicIndex, getHideActionText, getHorizontalAlignment, getHorizontalTextPosition, getIcon, getIconTextGap, getItemListeners, getLabel, getMargin, getMnemonic, getModel, getMultiClickThreshhold, getPressedIcon, getRolloverIcon, getRolloverSelectedIcon, getSelectedIcon, getSelectedObjects, getText, getUI, getVerticalAlignment, getVerticalTextPosition, imageUpdate, init, isBorderPainted, isContentAreaFilled, isFocusPainted, isRolloverEnabled, isSelected, paintBorder, removeActionListener, removeChangeListener, removeItemListener, setAction, setActionCommand, setBorderPainted, setContentAreaFilled, setDisabledIcon, setDisabledSelectedIcon, setDisplayedMnemonicIndex, setEnabled, setFocusPainted, setHideActionText, setHorizontalAlignment, setHorizontalTextPosition, setIcon, setIconTextGap, setLabel, setLayout, setMargin, setMnemonic, setMnemonic, setModel, setMultiClickThreshhold, setPressedIcon, setRolloverEnabled, setRolloverIcon, setRolloverSelectedIcon, setSelected, setSelectedIcon, setText, setUI, setVerticalAlignment, setVerticalTextPosition
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
AbstractMarsToolAndApplication.ConnectButton
public AbstractMarsToolAndApplication.ConnectButton()
Method Detail
connect
public void connect()
disconnect
public void disconnect()
isConnected
public boolean isConnected()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DigitalLabSim.SevenSegmentDisplay
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class DigitalLabSim.SevenSegmentDisplay
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
mars.tools.DigitalLabSim.SevenSegmentDisplay
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable
Enclosing class:
DigitalLabSim
public class DigitalLabSim.SevenSegmentDisplay
extends JComponent
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
char aff
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
DigitalLabSim.SevenSegmentDisplay(char aff)
Method Summary
void modifyDisplay(char val)
void paint(Graphics g)
void SwitchSegment(Graphics g,
char segment)
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getUIClassID, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, paramString, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update, updateUI
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
aff
public char aff
Constructor Detail
DigitalLabSim.SevenSegmentDisplay
public DigitalLabSim.SevenSegmentDisplay(char aff)
Method Detail
modifyDisplay
public void modifyDisplay(char val)
SwitchSegment
public void SwitchSegment(Graphics g,
char segment)
paint
public void paint(Graphics g)
Overrides:
paint in class JComponent
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MemoryReferenceVisualization
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class MemoryReferenceVisualization
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
mars.tools.MemoryReferenceVisualization
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
public class MemoryReferenceVisualization
extends AbstractMarsToolAndApplication
Memory reference visualization. It can be run either as a stand-alone Java application having
access to the mars package, or through MARS as an item in its Tools menu. It makes
maximum use of methods inherited from its abstract superclass AbstractMarsToolAndApplication.
Pete Sanderson, verison 1.0, 14 November 2006.
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class mars.tools.AbstractMarsToolAndApplication
AbstractMarsToolAndApplication.ConnectButton, AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class mars.tools.AbstractMarsToolAndApplication
connectButton, isBeingUsedAsAMarsTool, theWindow, thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
MemoryReferenceVisualization()
Simple constructor, likely used by the MARS Tools menu mechanism
MemoryReferenceVisualization(String title,
String heading)
Simple constructor, likely used to run a stand-alone memory reference visualizer.
Method Summary
protected void addAsObserver()
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only.
protected JComponent buildMainDisplayArea()
Method that constructs the main display area.
protected JComponent getHelpComponent()
Overrides default method, to provide a Help button for this tool/app.
String getName()
Required MarsTool method to return Tool name.
protected void initializePostGUI()
The only post-GUI initialization is to create the initial Grid object based on the default settings
of the various combo boxes.
protected void initializePreGUI()
Initialize all JComboBox choice structures not already initialized at declaration.
static void main(String[] args)
Main provided for pure stand-alone use.
protected void processMIPSUpdate(Observable memory,
AccessNotice accessNotice)
Update display when connected MIPS program accesses (data) memory.
protected void reset()
Method to reset counters and display when the Reset button selected.
protected void updateDisplay()
Updates display immediately after each update (AccessNotice) is processed, after
display configuration changes as needed, and after each execution step when Mars
is running in timed mode.
Methods inherited from class mars.tools.AbstractMarsToolAndApplication
action, addAsObserver, addAsObserver, buildButtonAreaMarsTool, buildButtonAreaStandAlone, buildHeadingArea, deleteAsObserver, deleteAsObserver, go, isObserving, performSpecialClosingDuties, update
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Constructor Detail
MemoryReferenceVisualization
public MemoryReferenceVisualization(String title,
String heading)
Simple constructor, likely used to run a stand-alone memory reference visualizer.
Parameters:
title – String containing title for title bar
heading – String containing text for heading shown in upper part of window.
MemoryReferenceVisualization
public MemoryReferenceVisualization()
Simple constructor, likely used by the MARS Tools menu mechanism
Method Detail
main
public static void main(String[] args)
Main provided for pure stand-alone use. Recommended stand-alone use is to write a
driver program that instantiates a MemoryReferenceVisualization object then invokes its go() method.
“stand-alone” means it is not invoked from the MARS Tools menu. “Pure” means there
is no driver program to invoke the application.
getName
public String getName()
Required MarsTool method to return Tool name.
Specified by:
getName in interface MarsTool
Specified by:
getName in class AbstractMarsToolAndApplication
Returns:
Tool name. MARS will display this in menu item.
addAsObserver
protected void addAsObserver()
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only. This version will register us as observer over the
the memory range as selected by the base address combo box and capacity of the visualization display
(number of visualization elements times the number of memory words each one represents).
It does so by calling the inherited 2-parameter overload of this method.
If you use the inherited GUI buttons, this
method is invoked when you click “Connect” button on MarsTool or the
“Assemble and Run” button on a Mars-based app.
Overrides:
addAsObserver in class AbstractMarsToolAndApplication
buildMainDisplayArea
protected JComponent buildMainDisplayArea()
Method that constructs the main display area. It is organized vertically
into two major components: the display configuration which an be modified
using combo boxes, and the visualization display which is updated as the
attached MIPS program executes.
Specified by:
buildMainDisplayArea in class AbstractMarsToolAndApplication
Returns:
the GUI component containing these two areas
processMIPSUpdate
protected void processMIPSUpdate(Observable memory,
AccessNotice accessNotice)
Update display when connected MIPS program accesses (data) memory.
Overrides:
processMIPSUpdate in class AbstractMarsToolAndApplication
Parameters:
memory – the attached memory
accessNotice – information provided by memory in MemoryAccessNotice object
initializePreGUI
protected void initializePreGUI()
Initialize all JComboBox choice structures not already initialized at declaration.
Overrides inherited method that does nothing.
Overrides:
initializePreGUI in class AbstractMarsToolAndApplication
initializePostGUI
protected void initializePostGUI()
The only post-GUI initialization is to create the initial Grid object based on the default settings
of the various combo boxes. Overrides inherited method that does nothing.
Overrides:
initializePostGUI in class AbstractMarsToolAndApplication
reset
protected void reset()
Method to reset counters and display when the Reset button selected.
Overrides inherited method that does nothing.
Overrides:
reset in class AbstractMarsToolAndApplication
updateDisplay
protected void updateDisplay()
Updates display immediately after each update (AccessNotice) is processed, after
display configuration changes as needed, and after each execution step when Mars
is running in timed mode. Overrides inherited method that does nothing.
Overrides:
updateDisplay in class AbstractMarsToolAndApplication
getHelpComponent
protected JComponent getHelpComponent()
Overrides default method, to provide a Help button for this tool/app.
Overrides:
getHelpComponent in class AbstractMarsToolAndApplication
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MarsTool
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Interface MarsTool
All Known Implementing Classes:
AbstractMarsToolAndApplication, BHTSimulator, BitmapDisplay, CacheSimulator, DigitalLabSim, FloatRepresentation, InstructionCounter, InstructionStatistics, IntroToTools, KeyboardAndDisplaySimulator, MarsBot, MemoryReferenceVisualization, ScavengerHunt, ScreenMagnifier
public interface MarsTool
Interface for any tool that interacts with an executing MIPS program.
A qualifying tool must be a class in the Tools package that
implements the MarsTool interface, must be compiled into a .class file,
and its .class file must be in the same Tools folder as MarsTool.class.
Mars will detect a qualifying tool upon startup, create an instance
using its no-argument constructor and add it to its Tools menu.
When its menu item is selected, the action() method will be invoked.
A tool may receive communication from MIPS system resources
(registers or memory) by registering as an Observer with
Mars.Memory and/or Mars.Register objects.
It may also
communicate directly with those resources through their
published methods PROVIDED any such communication is
wrapped inside a block synchronized on the
Mars.Globals.memoryAndRegistersLock object.
Method Summary
void action()
Performs tool functions.
String getName()
Return a name you have chosen for this tool.
Method Detail
getName
String getName()
Return a name you have chosen for this tool. It will appear as the
menu item.
action
void action()
Performs tool functions. It will be invoked when the tool is selected
from the Tools menu.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
mars.tools
Interfaces
MarsTool
Classes
AbstractMarsToolAndApplication
BHTableModel
BHTEntry
BHTSimGUI
BHTSimulator
BitmapDisplay
CacheSimulator
DigitalLabSim
FloatRepresentation
InstructionCounter
InstructionStatistics
IntroToTools
KeyboardAndDisplaySimulator
MarsBot
MemoryReferenceVisualization
ScavengerHunt
ScreenMagnifier
BHTSimGUI
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class BHTSimGUI
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
mars.tools.BHTSimGUI
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible
public class BHTSimGUI
extends JPanel
Represents the GUI of the BHT Simulator Tool.
The GUI consists of mainly four parts:
A configuration panel to select the number of entries and the history size
A information panel that displays the most recent branch instruction including its address and BHT index
A table representing the BHT with all entries and their internal state and statistics
A log panel that summarizes the predictions in a textual form
Author:
ingo.kofler@itec.uni-klu.ac.at
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
static String BHT_DO_NOT_TAKE_BRANCH
constant for the String representing “do not take the branch”
static String BHT_TAKE_BRANCH
constant for the String representing “take the branch”
static Color COLOR_PREDICTION_CORRECT
constant for the color to signal a correct prediction
static Color COLOR_PREDICTION_INCORRECT
constant for the color to signal a misprediction
static Color COLOR_PREPREDICTION
constant for the color that highlights the current BHT entry
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
BHTSimGUI()
Creates the GUI components of the BHT Simulator
The GUI is a subclass of JPanel which is integrated in the GUI of the MARS tool
Method Summary
JComboBox getCbBHTentries()
Returns the combo box for selecting the number of BHT entries.
JComboBox getCbBHThistory()
Returns the combo box for selecting the size of the BHT history.
JComboBox getCbBHTinitVal()
Returns the combo box for selecting the initial value of the BHT
JTable getTabBHT()
Returns the table representing the BHT.
JTextArea getTaLog()
Returns the text area for log purposes.
JTextField getTfAddress()
Returns the text field for displaying the address of the most recent branch instruction
JTextField getTfIndex()
Returns the text field for displaying the corresponding index into the BHT
JTextField getTfInstruction()
Returns the text field for displaying the most recent branch instruction
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
COLOR_PREPREDICTION
public static final Color COLOR_PREPREDICTION
constant for the color that highlights the current BHT entry
COLOR_PREDICTION_CORRECT
public static final Color COLOR_PREDICTION_CORRECT
constant for the color to signal a correct prediction
COLOR_PREDICTION_INCORRECT
public static final Color COLOR_PREDICTION_INCORRECT
constant for the color to signal a misprediction
BHT_TAKE_BRANCH
public static final String BHT_TAKE_BRANCH
constant for the String representing “take the branch”
See Also:
Constant Field Values
BHT_DO_NOT_TAKE_BRANCH
public static final String BHT_DO_NOT_TAKE_BRANCH
constant for the String representing “do not take the branch”
See Also:
Constant Field Values
Constructor Detail
BHTSimGUI
public BHTSimGUI()
Creates the GUI components of the BHT Simulator
The GUI is a subclass of JPanel which is integrated in the GUI of the MARS tool
Method Detail
getCbBHTentries
public JComboBox getCbBHTentries()
Returns the combo box for selecting the number of BHT entries.
Returns:
the reference to the combo box
getCbBHThistory
public JComboBox getCbBHThistory()
Returns the combo box for selecting the size of the BHT history.
Returns:
the reference to the combo box
getCbBHTinitVal
public JComboBox getCbBHTinitVal()
Returns the combo box for selecting the initial value of the BHT
Returns:
the reference to the combo box
getTabBHT
public JTable getTabBHT()
Returns the table representing the BHT.
Returns:
the reference to the table
getTaLog
public JTextArea getTaLog()
Returns the text area for log purposes.
Returns:
the reference to the text area
getTfInstruction
public JTextField getTfInstruction()
Returns the text field for displaying the most recent branch instruction
Returns:
the reference to the text field
getTfAddress
public JTextField getTfAddress()
Returns the text field for displaying the address of the most recent branch instruction
Returns:
the reference to the text field
getTfIndex
public JTextField getTfIndex()
Returns the text field for displaying the corresponding index into the BHT
Returns:
the reference to the text field
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
BHTableModel
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class BHTableModel
java.lang.Object
javax.swing.table.AbstractTableModel
mars.tools.BHTableModel
All Implemented Interfaces:
Serializable, TableModel
public class BHTableModel
extends AbstractTableModel
Simulates the actual functionality of a Branch History Table (BHT).
The BHT consists of a number of BHT entries which are used to perform branch prediction.
The entries of the BHT are stored as a Vector of BHTEntry objects.
The number of entries is configurable but has to be a power of 2.
The history kept by each BHT entry is also configurable during run-time.
A change of the configuration however causes a complete reset of the BHT.
The typical interaction is as follows:
Construction of a BHT with a certain number of entries with a given history size.
When encountering a branch instruction the index of the relevant BHT entry is calculated via the getIdxForAddress(int) method.
The current prediction of the BHT entry at the calculated index is obtained via the getPredictionAtIdx(int) method.
After detecting if the branch was really taken or not, this feedback is provided to the BHT by the updatePredictionAtIdx(int, boolean) method.
Additionally it serves as TableModel that can be directly used to render the state of the BHT in a JTable.
Feedback provided to the BHT causes a change of the internal state and a repaint of the table(s) associated to this model.
Author:
ingo.kofler@itec.uni-klu.ac.at
See Also:
Serialized Form
Field Summary
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
Constructor Summary
BHTableModel(int numEntries,
int historySize,
boolean initVal)
Constructs a new BHT with given number of entries and history size.
Method Summary
Class getColumnClass(int i)
Returns the class/type of the i-th column of the table.
int getColumnCount()
Returns the number of columns.
String getColumnName(int i)
Returns the name of the i-th column of the table.
int getIdxForAddress(int address)
Returns the index into the BHT for a given branch instruction address.
boolean getPredictionAtIdx(int index)
Retrieve the prediction for the i-th BHT entry.
int getRowCount()
Returns the number of entries of the BHT.
Object getValueAt(int row,
int col)
Returns the value of the cell at the given row and column
Required by the TableModel interface.
void initBHT(int numEntries,
int historySize,
boolean initVal)
Initializes the BHT with the given size and history.
void updatePredictionAtIdx(int index,
boolean branchTaken)
Updates the BHT entry with the outcome of the branch instruction.
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, isCellEditable, removeTableModelListener, setValueAt
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
BHTableModel
public BHTableModel(int numEntries,
int historySize,
boolean initVal)
Constructs a new BHT with given number of entries and history size.
Parameters:
numEntries – number of entries in the BHT
historySize – size of the history (in bits/number of past branches)
Method Detail
getColumnName
public String getColumnName(int i)
Returns the name of the i-th column of the table.
Required by the TableModel interface.
Specified by:
getColumnName in interface TableModel
Overrides:
getColumnName in class AbstractTableModel
Parameters:
i – the index of the column
Returns:
name of the i-th column
getColumnClass
public Class getColumnClass(int i)
Returns the class/type of the i-th column of the table.
Required by the TableModel interface.
Specified by:
getColumnClass in interface TableModel
Overrides:
getColumnClass in class AbstractTableModel
Parameters:
i – the index of the column
Returns:
class representing the type of the i-th column
getColumnCount
public int getColumnCount()
Returns the number of columns.
Required by the TableModel interface.
Returns:
currently the constant 6
getRowCount
public int getRowCount()
Returns the number of entries of the BHT.
Required by the TableModel interface.
Returns:
number of rows / entries of the BHT
getValueAt
public Object getValueAt(int row,
int col)
Returns the value of the cell at the given row and column
Required by the TableModel interface.
Parameters:
row – the row index
col – the column index
Returns:
the value of the cell
initBHT
public void initBHT(int numEntries,
int historySize,
boolean initVal)
Initializes the BHT with the given size and history.
All previous data like the BHT entries’ history and statistics will get lost.
A refresh of the table that use this BHT as model will be triggered.
Parameters:
numEntries – number of entries in the BHT (has to be a power of 2)
historySize – size of the history to consider
initVal – initial value for each entry (true means take branch, false do not take branch)
getIdxForAddress
public int getIdxForAddress(int address)
Returns the index into the BHT for a given branch instruction address.
A simple direct mapping is used.
Parameters:
address – the address of the branch instruction
Returns:
the index into the BHT
getPredictionAtIdx
public boolean getPredictionAtIdx(int index)
Retrieve the prediction for the i-th BHT entry.
Parameters:
index – the index of the entry in the BHT
Returns:
the prediction to take (true) or do not take (false) the branch
updatePredictionAtIdx
public void updatePredictionAtIdx(int index,
boolean branchTaken)
Updates the BHT entry with the outcome of the branch instruction.
This causes a change in the model and signals to update the connected table(s).
Parameters:
index – the index of the entry in the BHT
branchTaken –
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.tools
Interface Summary
MarsTool Interface for any tool that interacts with an executing MIPS program.
Class Summary
AbstractMarsToolAndApplication An abstract class that provides generic components to facilitate implementation of
a MarsTool and/or stand-alone Mars-based application.
BHTableModel Simulates the actual functionality of a Branch History Table (BHT).
BHTEntry Represents a single entry of the Branch History Table.
BHTSimGUI Represents the GUI of the BHT Simulator Tool.
BHTSimulator A MARS tool for simulating branch prediction with a Branch History Table (BHT)
BitmapDisplay Bitmapp display simulator.
CacheSimulator A data cache simulator.
DigitalLabSim
FloatRepresentation Tool to help students learn about IEEE 754 representation of 32 bit
floating point values.
InstructionCounter Instruction counter tool.
InstructionStatistics A MARS tool for obtaining instruction statistics by instruction category.
IntroToTools The “hello world” of MarsTools!
KeyboardAndDisplaySimulator Keyboard and Display Simulator.
MarsBot Simple Demo of Mars tool capability
MemoryReferenceVisualization Memory reference visualization.
ScavengerHunt Demo of Mars tool capability.
ScreenMagnifier Handy little tool to magnify a selected section of the screen
by a given scale and display it.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
AbstractMarsToolAndApplication
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class AbstractMarsToolAndApplication
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
Direct Known Subclasses:
BHTSimulator, BitmapDisplay, CacheSimulator, DigitalLabSim, FloatRepresentation, InstructionCounter, InstructionStatistics, IntroToTools, KeyboardAndDisplaySimulator, MemoryReferenceVisualization
public abstract class AbstractMarsToolAndApplication
extends JFrame
implements MarsTool, Observer
An abstract class that provides generic components to facilitate implementation of
a MarsTool and/or stand-alone Mars-based application. Provides default definitions
of both the action() method required to implement MarsTool and the go() method
conventionally used to launch a Mars-based stand-alone application. It also provides
generic definitions for interactively controlling the application. The generic controls
for MarsTools are 3 buttons: connect/disconnect to MIPS resource (memory and/or
registers), reset, and close (exit). The generic controls for stand-alone Mars apps
include: button that triggers a file open dialog, a text field to display status
messages, the run-speed slider to control execution rate when running a MIPS program,
a button that assembles and runs the current MIPS program, a button to interrupt
the running MIPS program, a reset button, and an exit button.
Pete Sanderson, 14 November 2006.
See Also:
Serialized Form
Nested Class Summary
protected class AbstractMarsToolAndApplication.ConnectButton
protected class AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
protected AbstractMarsToolAndApplication.ConnectButton connectButton
protected boolean isBeingUsedAsAMarsTool
protected Window theWindow
protected AbstractMarsToolAndApplication thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
protected AbstractMarsToolAndApplication(String title,
String heading)
Simple constructor
Method Summary
void action()
Required MarsTool method to carry out Tool functions.
protected void addAsObserver()
Add this app/tool as an Observer of desired MIPS Observables (memory and registers).
protected void addAsObserver(int lowEnd,
int highEnd)
Add this app/tool as an Observer of the specified subrange of MIPS memory.
protected void addAsObserver(Register reg)
Add this app/tool as an Observer of the specified MIPS register.
protected JComponent buildButtonAreaMarsTool()
The MarsTool default set of controls has one row of 3 buttons.
protected JComponent buildButtonAreaStandAlone()
The Mars stand-alone app default set of controls has two rows of controls.
protected JComponent buildHeadingArea()
Constructs GUI header as label with default positioning and font.
protected abstract JComponent buildMainDisplayArea()
Abstract method that must be instantiated by subclass to build the main display area
of the GUI.
protected void deleteAsObserver()
Delete this app/tool as an Observer of MIPS Observables (memory and registers).
protected void deleteAsObserver(Register reg)
Delete this app/tool as an Observer of the specified MIPS register
protected JComponent getHelpComponent()
Override this method to provide a JComponent (probably a JButton) of your choice
to be placed just left of the Close/Exit button.
abstract String getName()
Required MarsTool method to return Tool name.
void go()
Run the simulator as stand-alone application.
protected void initializePostGUI()
Method that will be called once just after the GUI is constructed in the go() and action()
methods.
protected void initializePreGUI()
Method that will be called once just before the GUI is constructed in the go() and action()
methods.
protected boolean isObserving()
Query method to let you know if the tool/app is (or could be) currently
“observing” any MIPS resources.
protected void performSpecialClosingDuties()
This method is called when tool/app is exited either through the close/exit button or the window’s X box.
protected void processMIPSUpdate(Observable resource,
AccessNotice notice)
Override this method to process a received notice from MIPS Observable (memory or register)
It will only be called if the notice was generated as the result of MIPS instruction execution.
protected void reset()
Method that will be called each time the default Reset button is clicked.
void update(Observable resource,
Object accessNotice)
Called when receiving notice of access to MIPS memory or registers.
protected void updateDisplay()
Override this method to implement updating of GUI after each MIPS instruction is executed,
while running in “timed” mode (user specifies execution speed on the slider control).
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Field Detail
isBeingUsedAsAMarsTool
protected boolean isBeingUsedAsAMarsTool
thisMarsApp
protected AbstractMarsToolAndApplication thisMarsApp
theWindow
protected Window theWindow
connectButton
protected AbstractMarsToolAndApplication.ConnectButton connectButton
Constructor Detail
AbstractMarsToolAndApplication
protected AbstractMarsToolAndApplication(String title,
String heading)
Simple constructor
Parameters:
title – String containing title bar text
Method Detail
getName
public abstract String getName()
Required MarsTool method to return Tool name. Must be defined by subclass.
Specified by:
getName in interface MarsTool
Overrides:
getName in class Component
Returns:
Tool name. MARS will display this in menu item.
buildMainDisplayArea
protected abstract JComponent buildMainDisplayArea()
Abstract method that must be instantiated by subclass to build the main display area
of the GUI. It will be placed in the CENTER area of a BorderLayout. The title
is in the NORTH area, and the controls are in the SOUTH area.
go
public void go()
Run the simulator as stand-alone application. For this default implementation,
the user-defined main display of the user interface is identical for both stand-alone
and MARS Tools menu use, but the control buttons are different because the stand-alone
must include a mechansim for controlling the opening, assembling, and executing of
an underlying MIPS program. The generic controls include: a button that triggers a
file open dialog, a text field to display status messages, the run-speed slider
to control execution rate when running a MIPS program, a button that assembles and
runs the current MIPS program, a reset button, and an exit button.
This method calls 3 methods that can be defined/overriden in the subclass: initializePreGUI()
for any special initialization that must be completed before building the user
interface (e.g. data structures whose properties determine default GUI settings),
initializePostGUI() for any special initialization that cannot be
completed until after the building the user interface (e.g. data structure whose
properties are determined by default GUI settings), and buildMainDisplayArea()
to contain application-specific displays of parameters and results.
action
public void action()
Required MarsTool method to carry out Tool functions. It is invoked when MARS
user selects this tool from the Tools menu. This default implementation provides
generic definitions for interactively controlling the tool. The generic controls
for MarsTools are 3 buttons: connect/disconnect to MIPS resource (memory and/or
registers), reset, and close (exit). Like “go()” above, this default version
calls 3 methods that can be defined/overriden in the subclass: initializePreGUI()
for any special initialization that must be completed before building the user
interface (e.g. data structures whose properties determine default GUI settings),
initializePostGUI() for any special initialization that cannot be
completed until after the building the user interface (e.g. data structure whose
properties are determined by default GUI settings), and buildMainDisplayArea()
to contain application-specific displays of parameters and results.
Specified by:
action in interface MarsTool
initializePreGUI
protected void initializePreGUI()
Method that will be called once just before the GUI is constructed in the go() and action()
methods. Use it to initialize any data structures needed for the application whose values
will be needed to determine the initial state of GUI components. By default it does nothing.
initializePostGUI
protected void initializePostGUI()
Method that will be called once just after the GUI is constructed in the go() and action()
methods. Use it to initialize data structures needed for the application whose values
may depend on the initial state of GUI components. By default it does nothing.
reset
protected void reset()
Method that will be called each time the default Reset button is clicked.
Use it to reset any data structures and/or GUI components. By default it does nothing.
buildHeadingArea
protected JComponent buildHeadingArea()
Constructs GUI header as label with default positioning and font. May be overridden.
buildButtonAreaMarsTool
protected JComponent buildButtonAreaMarsTool()
The MarsTool default set of controls has one row of 3 buttons. It includes a dual-purpose button to
attach or detach simulator to MIPS memory, a button to reset the cache, and one to close the tool.
buildButtonAreaStandAlone
protected JComponent buildButtonAreaStandAlone()
The Mars stand-alone app default set of controls has two rows of controls. It includes a text field for
displaying status messages, a button to trigger an open file dialog, the MARS run speed slider
to control timed execution, a button to assemble and run the program, a reset button
whose action is determined by the subclass reset() method, and an exit button.
update
public void update(Observable resource,
Object accessNotice)
Called when receiving notice of access to MIPS memory or registers. Default
implementation of method required by Observer interface. This method will filter out
notices originating from the MARS GUI or from direct user editing of memory or register
displays. Only notices arising from MIPS program access are allowed in.
It then calls two methods to be overridden by the subclass (since they do
nothing by default): processMIPSUpdate() then updateDisplay().
Specified by:
update in interface Observer
Parameters:
resource – the attached MIPS resource
accessNotice – AccessNotice information provided by the resource
processMIPSUpdate
protected void processMIPSUpdate(Observable resource,
AccessNotice notice)
Override this method to process a received notice from MIPS Observable (memory or register)
It will only be called if the notice was generated as the result of MIPS instruction execution.
By default it does nothing. After this method is complete, the updateDisplay() method will be
invoked automatically.
performSpecialClosingDuties
protected void performSpecialClosingDuties()
This method is called when tool/app is exited either through the close/exit button or the window’s X box.
Override it to perform any special housecleaning needed. By default it does nothing.
addAsObserver
protected void addAsObserver()
Add this app/tool as an Observer of desired MIPS Observables (memory and registers).
By default, will add as an Observer of the entire Data Segment in memory.
Override if you want something different. Note that the Memory methods to add an
Observer to memory are flexible (you can register for a range of addresses) but
may throw an AddressErrorException that you need to catch.
This method is called whenever the default “Connect” button on a MarsTool or the
default “Assemble and run” on a stand-alone Mars app is selected. The corresponding
NOTE: if you do not want to register as an Observer of the entire data segment
(starts at address 0x10000000) then override this to either do some alternative
or nothing at all. This method is also overloaded to allow arbitrary memory
subrange.
addAsObserver
protected void addAsObserver(int lowEnd,
int highEnd)
Add this app/tool as an Observer of the specified subrange of MIPS memory. Note
that this method is not invoked automatically like the no-argument version, but
if you use this method, you can still take advantage of provided default deleteAsObserver()
since it will remove the app as a memory observer regardless of the subrange
or number of subranges it is registered for.
Parameters:
lowEnd – low end of memory address range.
highEnd – high end of memory address range; must be >= lowEnd
addAsObserver
protected void addAsObserver(Register reg)
Add this app/tool as an Observer of the specified MIPS register.
deleteAsObserver
protected void deleteAsObserver()
Delete this app/tool as an Observer of MIPS Observables (memory and registers).
By default, will delete as an Observer of memory.
Override if you want something different.
This method is called when the default “Disconnect” button on a MarsTool is selected or
when the MIPS program execution triggered by the default “Assemble and run” on a stand-alone
Mars app terminates (e.g. when the button is re-enabled).
deleteAsObserver
protected void deleteAsObserver(Register reg)
Delete this app/tool as an Observer of the specified MIPS register
isObserving
protected boolean isObserving()
Query method to let you know if the tool/app is (or could be) currently
“observing” any MIPS resources. When running as a MarsTool, this
will be true by default after clicking the “Connect to MIPS” button until “Disconnect
from MIPS” is clicked. When running as a stand-alone app, this will be
true by default after clicking the “Assemble and Run” button until until
program execution has terminated either normally or by clicking the “Stop”
button. The phrase “or could be” was added above because depending on how
the tool/app operates, it may be possible to run the MIPS program without
first registering as an Observer — i.e. addAsObserver() is overridden and
takes no action.
Returns:
true if tool/app is (or could be) currently active as an Observer.
updateDisplay
protected void updateDisplay()
Override this method to implement updating of GUI after each MIPS instruction is executed,
while running in “timed” mode (user specifies execution speed on the slider control).
Does nothing by default.
getHelpComponent
protected JComponent getHelpComponent()
Override this method to provide a JComponent (probably a JButton) of your choice
to be placed just left of the Close/Exit button. Its anticipated use is for a
“help” button that launches a help message or dialog. But it can be any valid
JComponent that doesn’t mind co-existing among a bunch of JButtons.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.tools
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object javax.swing.table.AbstractTableModel (implements java.io.Serializable, javax.swing.table.TableModel)
mars.tools.BHTableModel
mars.tools.BHTEntry
java.awt.Component (implements java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable)
java.awt.Container javax.swing.JComponent (implements java.io.Serializable)
javax.swing.AbstractButton (implements java.awt.ItemSelectable, javax.swing.SwingConstants)
javax.swing.JButton (implements javax.accessibility.Accessible)
mars.tools.AbstractMarsToolAndApplication.ConnectButton
mars.tools.DigitalLabSim.SevenSegmentDisplay
javax.swing.JPanel (implements javax.accessibility.Accessible)
mars.tools.BHTSimGUI
mars.tools.DigitalLabSim.HexaKeyboard
mars.tools.DigitalLabSim.SevenSegmentPanel
java.awt.Window (implements javax.accessibility.Accessible)
java.awt.Frame (implements java.awt.MenuContainer)
javax.swing.JFrame (implements javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants)
mars.tools.AbstractMarsToolAndApplication (implements mars.tools.MarsTool, java.util.Observer)
mars.tools.BHTSimulator (implements java.awt.event.ActionListener)
mars.tools.BitmapDisplay
mars.tools.CacheSimulator
mars.tools.DigitalLabSim
mars.tools.FloatRepresentation
mars.tools.InstructionCounter
mars.tools.InstructionStatistics
mars.tools.IntroToTools
mars.tools.KeyboardAndDisplaySimulator
mars.tools.MemoryReferenceVisualization
mars.tools.DigitalLabSim.HexaKeyboard.EcouteurClick (implements java.awt.event.MouseListener)
mars.tools.DigitalLabSim.OneSecondCounter
java.awt.event.KeyAdapter (implements java.awt.event.KeyListener)
mars.tools.AbstractMarsToolAndApplication.EnterKeyListener
mars.tools.MarsBot (implements mars.tools.MarsTool, java.util.Observer)
mars.tools.ScavengerHunt (implements mars.tools.MarsTool, java.util.Observer)
mars.tools.ScreenMagnifier (implements mars.tools.MarsTool)
Interface Hierarchy
mars.tools.MarsTool
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
ScavengerHunt
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class ScavengerHunt
java.lang.Object
mars.tools.ScavengerHunt
All Implemented Interfaces:
Observer, MarsTool
public class ScavengerHunt
extends Object
implements Observer, MarsTool
Demo of Mars tool capability. Ken Vollmar, 27 Oct 2006 KenVollmar@missouristate.edu
This tool displays movements by a series of players in a game of ScavengerHunt.
Players will read and write MIPS memory-mapped locations to move and regain energy.
See accompanying documentation for memory-mapped addresses, rules of the game, etc.
Constructor Summary
ScavengerHunt()
Method Summary
void action()
Performs tool functions.
String getName()
Return a name you have chosen for this tool.
void update(Observable o,
Object arg)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
ScavengerHunt
public ScavengerHunt()
Method Detail
getName
public String getName()
Description copied from interface: MarsTool
Return a name you have chosen for this tool. It will appear as the
menu item.
Specified by:
getName in interface MarsTool
action
public void action()
Description copied from interface: MarsTool
Performs tool functions. It will be invoked when the tool is selected
from the Tools menu.
Specified by:
action in interface MarsTool
update
public void update(Observable o,
Object arg)
Specified by:
update in interface Observer
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DigitalLabSim.OneSecondCounter
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class DigitalLabSim.OneSecondCounter
java.lang.Object
mars.tools.DigitalLabSim.OneSecondCounter
Enclosing class:
DigitalLabSim
public class DigitalLabSim.OneSecondCounter
extends Object
Constructor Summary
DigitalLabSim.OneSecondCounter()
Method Summary
void resetOneSecondCounter()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
DigitalLabSim.OneSecondCounter
public DigitalLabSim.OneSecondCounter()
Method Detail
resetOneSecondCounter
public void resetOneSecondCounter()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
BHTEntry
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class BHTEntry
java.lang.Object
mars.tools.BHTEntry
public class BHTEntry
extends Object
Represents a single entry of the Branch History Table.
The entry holds the information about former branch predictions and outcomes.
The number of past branch outcomes can be configured and is called the history.
The semantics of the history of size n is as follows.
The entry will change its prediction, if it mispredicts the branch n times in series.
The prediction of the entry can be obtained by the getPrediction() method.
Feedback of taken or not taken branches is provided to the entry via the updatePrediction(boolean) method.
This causes the history and the prediction to be updated.
Additionally the entry keeps track about how many times the prediction was correct or incorrect.
The statistics can be obtained by the methods getStatsPredCorrect(), getStatsPredIncorrect() and getStatsPredPrecision().
Author:
ingo.kofler@itec.uni-klu.ac.at
Constructor Summary
BHTEntry(int historySize,
boolean initVal)
Constructs a BHT entry with a given history size.
Method Summary
String getHistoryAsStr()
Builds a string representation of the BHT entry’s history.
boolean getPrediction()
Returns the branch prediction based on the history.
String getPredictionAsStr()
Returns a string representation of the BHT entry’s current prediction.
int getStatsPredCorrect()
Get the absolute number of correct predictions.
int getStatsPredIncorrect()
Get the absolute number of mispredictions.
double getStatsPredPrecision()
Get the percentage of correct predictions.
void updatePrediction(boolean branchTaken)
Updates the entry’s history and prediction.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
BHTEntry
public BHTEntry(int historySize,
boolean initVal)
Constructs a BHT entry with a given history size.
The size of the history can only be set via the constructor and cannot be changed afterwards.
Parameters:
historySize – number of past branch outcomes to remember
initVal – the initial value of the entry (take or do not take)
Method Detail
getPrediction
public boolean getPrediction()
Returns the branch prediction based on the history.
Returns:
true if prediction is to take the branch, false otherwise
updatePrediction
public void updatePrediction(boolean branchTaken)
Updates the entry’s history and prediction.
This method provides feedback for a prediction.
The history and the statistics are updated accordingly.
Based on the updated history a new prediction is calculated
Parameters:
branchTaken – signals if the branch was taken (true) or not (false)
getStatsPredIncorrect
public int getStatsPredIncorrect()
Get the absolute number of mispredictions.
Returns:
number of incorrect predictions (mispredictions)
getStatsPredCorrect
public int getStatsPredCorrect()
Get the absolute number of correct predictions.
Returns:
number of correct predictions
getStatsPredPrecision
public double getStatsPredPrecision()
Get the percentage of correct predictions.
Returns:
the percentage of correct predictions
getHistoryAsStr
public String getHistoryAsStr()
Builds a string representation of the BHT entry’s history.
The history is a sequence of flags that signal if the branch was taken (T) or not taken (NT).
Returns:
a string representation of the BHT entry’s history
getPredictionAsStr
public String getPredictionAsStr()
Returns a string representation of the BHT entry’s current prediction.
The prediction can be either to TAKE or do NOT TAKE the branch.
Returns:
a string representation of the BHT entry’s current prediction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
AbstractMarsToolAndApplication.EnterKeyListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class AbstractMarsToolAndApplication.EnterKeyListener
java.lang.Object
java.awt.event.KeyAdapter
mars.tools.AbstractMarsToolAndApplication.EnterKeyListener
All Implemented Interfaces:
KeyListener, EventListener
Enclosing class:
AbstractMarsToolAndApplication
protected class AbstractMarsToolAndApplication.EnterKeyListener
extends KeyAdapter
Constructor Summary
AbstractMarsToolAndApplication.EnterKeyListener(AbstractButton who)
Method Summary
void keyPressed(KeyEvent e)
Methods inherited from class java.awt.event.KeyAdapter
keyReleased, keyTyped
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
AbstractMarsToolAndApplication.EnterKeyListener
public AbstractMarsToolAndApplication.EnterKeyListener(AbstractButton who)
Method Detail
keyPressed
public void keyPressed(KeyEvent e)
Specified by:
keyPressed in interface KeyListener
Overrides:
keyPressed in class KeyAdapter
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
BitmapDisplay
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class BitmapDisplay
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.tools.AbstractMarsToolAndApplication
mars.tools.BitmapDisplay
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants, MarsTool
public class BitmapDisplay
extends AbstractMarsToolAndApplication
Bitmapp display simulator. It can be run either as a stand-alone Java application having
access to the mars package, or through MARS as an item in its Tools menu. It makes
maximum use of methods inherited from its abstract superclass AbstractMarsToolAndApplication.
Pete Sanderson, verison 1.0, 23 December 2010.
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class mars.tools.AbstractMarsToolAndApplication
AbstractMarsToolAndApplication.ConnectButton, AbstractMarsToolAndApplication.EnterKeyListener
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class mars.tools.AbstractMarsToolAndApplication
connectButton, isBeingUsedAsAMarsTool, theWindow, thisMarsApp
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
BitmapDisplay()
Simple constructor, likely used by the MARS Tools menu mechanism
BitmapDisplay(String title,
String heading)
Simple constructor, likely used to run a stand-alone bitmap display tool.
Method Summary
protected void addAsObserver()
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only.
protected JComponent buildMainDisplayArea()
Method that constructs the main display area.
protected JComponent getHelpComponent()
Overrides default method, to provide a Help button for this tool/app.
String getName()
Required MarsTool method to return Tool name.
protected void initializePostGUI()
The only post-GUI initialization is to create the initial Grid object based on the default settings
of the various combo boxes.
protected void initializePreGUI()
Initialize all JComboBox choice structures not already initialized at declaration.
static void main(String[] args)
Main provided for pure stand-alone use.
protected void processMIPSUpdate(Observable memory,
AccessNotice accessNotice)
Update display when connected MIPS program accesses (data) memory.
protected void reset()
Method to reset counters and display when the Reset button selected.
protected void updateDisplay()
Updates display immediately after each update (AccessNotice) is processed, after
display configuration changes as needed, and after each execution step when Mars
is running in timed mode.
Methods inherited from class mars.tools.AbstractMarsToolAndApplication
action, addAsObserver, addAsObserver, buildButtonAreaMarsTool, buildButtonAreaStandAlone, buildHeadingArea, deleteAsObserver, deleteAsObserver, go, isObserving, performSpecialClosingDuties, update
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Constructor Detail
BitmapDisplay
public BitmapDisplay(String title,
String heading)
Simple constructor, likely used to run a stand-alone bitmap display tool.
Parameters:
title – String containing title for title bar
heading – String containing text for heading shown in upper part of window.
BitmapDisplay
public BitmapDisplay()
Simple constructor, likely used by the MARS Tools menu mechanism
Method Detail
main
public static void main(String[] args)
Main provided for pure stand-alone use. Recommended stand-alone use is to write a
driver program that instantiates a Bitmap object then invokes its go() method.
“stand-alone” means it is not invoked from the MARS Tools menu. “Pure” means there
is no driver program to invoke the application.
getName
public String getName()
Required MarsTool method to return Tool name.
Specified by:
getName in interface MarsTool
Specified by:
getName in class AbstractMarsToolAndApplication
Returns:
Tool name. MARS will display this in menu item.
addAsObserver
protected void addAsObserver()
Override the inherited method, which registers us as an Observer over the static data segment
(starting address 0x10010000) only. This version will register us as observer over the
the memory range as selected by the base address combo box and capacity of the visualization display
(number of visualization elements times the number of memory words each one represents).
It does so by calling the inherited 2-parameter overload of this method.
If you use the inherited GUI buttons, this
method is invoked when you click “Connect” button on MarsTool or the
“Assemble and Run” button on a Mars-based app.
Overrides:
addAsObserver in class AbstractMarsToolAndApplication
buildMainDisplayArea
protected JComponent buildMainDisplayArea()
Method that constructs the main display area. It is organized vertically
into two major components: the display configuration which an be modified
using combo boxes, and the visualization display which is updated as the
attached MIPS program executes.
Specified by:
buildMainDisplayArea in class AbstractMarsToolAndApplication
Returns:
the GUI component containing these two areas
processMIPSUpdate
protected void processMIPSUpdate(Observable memory,
AccessNotice accessNotice)
Update display when connected MIPS program accesses (data) memory.
Overrides:
processMIPSUpdate in class AbstractMarsToolAndApplication
Parameters:
memory – the attached memory
accessNotice – information provided by memory in MemoryAccessNotice object
initializePreGUI
protected void initializePreGUI()
Initialize all JComboBox choice structures not already initialized at declaration.
Overrides inherited method that does nothing.
Overrides:
initializePreGUI in class AbstractMarsToolAndApplication
initializePostGUI
protected void initializePostGUI()
The only post-GUI initialization is to create the initial Grid object based on the default settings
of the various combo boxes. Overrides inherited method that does nothing.
Overrides:
initializePostGUI in class AbstractMarsToolAndApplication
reset
protected void reset()
Method to reset counters and display when the Reset button selected.
Overrides inherited method that does nothing.
Overrides:
reset in class AbstractMarsToolAndApplication
updateDisplay
protected void updateDisplay()
Updates display immediately after each update (AccessNotice) is processed, after
display configuration changes as needed, and after each execution step when Mars
is running in timed mode. Overrides inherited method that does nothing.
Overrides:
updateDisplay in class AbstractMarsToolAndApplication
getHelpComponent
protected JComponent getHelpComponent()
Overrides default method, to provide a Help button for this tool/app.
Overrides:
getHelpComponent in class AbstractMarsToolAndApplication
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DigitalLabSim.HexaKeyboard
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.tools
Class DigitalLabSim.HexaKeyboard
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
mars.tools.DigitalLabSim.HexaKeyboard
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible
Enclosing class:
DigitalLabSim
public class DigitalLabSim.HexaKeyboard
extends JPanel
See Also:
Serialized Form
Nested Class Summary
class DigitalLabSim.HexaKeyboard.EcouteurClick
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
JButton[] button
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
DigitalLabSim.HexaKeyboard()
Method Summary
void resetHexaKeyboard()
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
button
public JButton[] button
Constructor Detail
DigitalLabSim.HexaKeyboard
public DigitalLabSim.HexaKeyboard()
Method Detail
resetHexaKeyboard
public void resetHexaKeyboard()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MacroPool
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class MacroPool
java.lang.Object
mars.assembler.MacroPool
public class MacroPool
extends Object
Stores information of macros defined by now.
Will be used in first pass of assembling MIPS source code. When reached
.macro directive, parser calls
MacroPool#BeginMacro(String, int) and skips source code lines until
reaches .end_macro directive. then calls
MacroPool#CommitMacro(int) and the macro information stored in a
Macro instance will be added to macroList.
Each MIPSprogram will have one MacroPool
NOTE: Forward referencing macros (macro expansion before its definition in
source code) and Nested macro definition (defining a macro inside other macro
definition) are not supported.
Author:
M.H.Sekhavat
Constructor Summary
MacroPool(MIPSprogram mipsProgram)
Create an empty MacroPool for given program
Method Summary
void beginMacro(Token nameToken)
This method will be called by parser when reached .macro
directive.
Instantiates a new Macro object and stores it in current
.
void commitMacro(Token endToken)
This method will be called by parser when reached .end_macro
directive.
ArrayList
Macro getCurrent()
String getExpansionHistory()
Macro getMatchingMacro(TokenList tokens,
int callerLine)
Will be called by parser when reaches a macro expansion call
int getNextCounter()
counter will be set to 0 on construction of this class and will
be incremented by each call.
boolean matchesAnyMacroName(String value)
void popFromCallStack()
boolean pushOnCallStack(Token token)
void setCurrent(Macro current)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
MacroPool
public MacroPool(MIPSprogram mipsProgram)
Create an empty MacroPool for given program
Parameters:
mipsProgram – associated MIPS program
Method Detail
beginMacro
public void beginMacro(Token nameToken)
This method will be called by parser when reached .macro
directive.
Instantiates a new Macro object and stores it in current
. current will be added to macroList by
#CommitMacro(int)
Parameters:
nameToken – Token containing name of macro after .macro directive
commitMacro
public void commitMacro(Token endToken)
This method will be called by parser when reached .end_macro
directive.
Adds/Replaces current macro into the macroList.
Parameters:
endToken – Token containing .end_macro directive in source code
getMatchingMacro
public Macro getMatchingMacro(TokenList tokens,
int callerLine)
Will be called by parser when reaches a macro expansion call
Parameters:
tokens – tokens passed to macro expansion call
Returns:
Macro object matching the name and argument count of
tokens passed
matchesAnyMacroName
public boolean matchesAnyMacroName(String value)
Parameters:
value –
Returns:
true if any macros have been defined with name value
by now, not concerning arguments count.
getCurrent
public Macro getCurrent()
setCurrent
public void setCurrent(Macro current)
getNextCounter
public int getNextCounter()
counter will be set to 0 on construction of this class and will
be incremented by each call. parser calls this method once for every
expansions. it will be a unique id for each expansion of macro in a file
Returns:
counter value
getCallStack
public ArrayList
pushOnCallStack
public boolean pushOnCallStack(Token token)
popFromCallStack
public void popFromCallStack()
getExpansionHistory
public String getExpansionHistory()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Directives
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class Directives
java.lang.Object
mars.assembler.Directives
public final class Directives
extends Object
Class representing MIPS assembler directives. If Java had enumerated types, these
would probably be implemented that way. Each directive is represented by a unique object.
The directive name is indicative of the directive it represents. For example, DATA
represents the MIPS .data directive.
Author:
Pete Sanderson
Field Summary
static Directives ALIGN
static Directives ASCII
static Directives ASCIIZ
static Directives BYTE
static Directives DATA
static Directives DOUBLE
static Directives END_MACRO
static Directives EQV
static Directives EXTERN
static Directives FLOAT
static Directives GLOBL
static Directives HALF
static Directives INCLUDE
static Directives KDATA
static Directives KTEXT
static Directives MACRO
static Directives SET
static Directives SPACE
static Directives TEXT
static Directives WORD
Method Summary
String getDescription()
Get description of this Directives object
static ArrayList getDirectiveList()
Produces List of Directive objects
String getName()
Get name of this Directives object
static boolean isFloatingDirective(Directives direct)
Lets you know whether given directive is for floating number (FLOAT,DOUBLE).
static boolean isIntegerDirective(Directives direct)
Lets you know whether given directive is for integer (WORD,HALF,BYTE).
static Directives matchDirective(String str)
Find Directive object, if any, which matches the given String.
static ArrayList prefixMatchDirectives(String str)
Find Directive object, if any, which contains the given string as a prefix.
String toString()
Produces String-ified version of Directive object
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
DATA
public static final Directives DATA
TEXT
public static final Directives TEXT
WORD
public static final Directives WORD
ASCII
public static final Directives ASCII
ASCIIZ
public static final Directives ASCIIZ
BYTE
public static final Directives BYTE
ALIGN
public static final Directives ALIGN
HALF
public static final Directives HALF
SPACE
public static final Directives SPACE
DOUBLE
public static final Directives DOUBLE
FLOAT
public static final Directives FLOAT
EXTERN
public static final Directives EXTERN
KDATA
public static final Directives KDATA
KTEXT
public static final Directives KTEXT
GLOBL
public static final Directives GLOBL
SET
public static final Directives SET
EQV
public static final Directives EQV
MACRO
public static final Directives MACRO
END_MACRO
public static final Directives END_MACRO
INCLUDE
public static final Directives INCLUDE
Method Detail
matchDirective
public static Directives matchDirective(String str)
Find Directive object, if any, which matches the given String.
Parameters:
str – A String containing candidate directive name (e.g. “.ascii”)
Returns:
If match is found, returns matching Directives object, else returns null.
prefixMatchDirectives
public static ArrayList prefixMatchDirectives(String str)
Find Directive object, if any, which contains the given string as a prefix. For example,
“.a” will match “.ascii”, “.asciiz” and “.align”
Parameters:
str – A String
Returns:
If match is found, returns ArrayList of matching Directives objects, else returns null.
toString
public String toString()
Produces String-ified version of Directive object
Overrides:
toString in class Object
Returns:
String representing Directive: its MIPS name
getName
public String getName()
Get name of this Directives object
Returns:
name of this MIPS directive as a String
getDescription
public String getDescription()
Get description of this Directives object
Returns:
description of this MIPS directive (for help purposes)
getDirectiveList
public static ArrayList getDirectiveList()
Produces List of Directive objects
Returns:
MIPS Directive
isIntegerDirective
public static boolean isIntegerDirective(Directives direct)
Lets you know whether given directive is for integer (WORD,HALF,BYTE).
Parameters:
direct – a MIPS directive
Returns:
true if given directive is FLOAT or DOUBLE, false otherwise
isFloatingDirective
public static boolean isFloatingDirective(Directives direct)
Lets you know whether given directive is for floating number (FLOAT,DOUBLE).
Parameters:
direct – a MIPS directive
Returns:
true if given directive is FLOAT or DOUBLE, false otherwise.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SourceLine
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class SourceLine
java.lang.Object
mars.assembler.SourceLine
public class SourceLine
extends Object
Handy class to represent, for a given line of source code, the code
itself, the program containing it, and its line number within that program.
This is used to separately keep track of the original file/position of
a given line of code. When .include is used, it will migrate to a different
line and possibly different program but the migration should not be visible
to the user.
Constructor Summary
SourceLine(String source,
MIPSprogram mipsProgram,
int lineNumber)
SourceLine constructor
Method Summary
String getFilename()
Retrieve name of file containing source statement
int getLineNumber()
Retrieve line number of source statement
MIPSprogram getMIPSprogram()
Retrieve MIPSprogram object containing source statement
String getSource()
Retrieve source statement itself
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SourceLine
public SourceLine(String source,
MIPSprogram mipsProgram,
int lineNumber)
SourceLine constructor
Parameters:
source – The source code itself
mipsProgram – The program (object representing source file) containing that line
lineNumber – The line number within that program where source appears.
Method Detail
getSource
public String getSource()
Retrieve source statement itself
Returns:
Source statement as String
getFilename
public String getFilename()
Retrieve name of file containing source statement
Returns:
File name as String
getLineNumber
public int getLineNumber()
Retrieve line number of source statement
Returns:
Line number of source statement
getMIPSprogram
public MIPSprogram getMIPSprogram()
Retrieve MIPSprogram object containing source statement
Returns:
program as MIPSprogram object
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SymbolTable
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class SymbolTable
java.lang.Object
mars.assembler.SymbolTable
public class SymbolTable
extends Object
Creats a table of Symbol objects.
Author:
Jason Bumgarner, Jason Shrewsbury
Field Summary
static int NOT_FOUND
Constructor Summary
SymbolTable(String filename)
Create a new empty symbol table for given file
Method Summary
void addSymbol(Token token,
int address,
boolean b,
ErrorList errors)
Adds a Symbol object into the array of Symbols.
void clear()
Creates a fresh arrayList for a new table.
void fixSymbolTableAddress(int originalAddress,
int replacementAddress)
Fix address in symbol table entry.
int getAddress(String s)
Method to return the address associated with the given label.
int getAddressLocalOrGlobal(String s)
Method to return the address associated with the given label.
ArrayList getAllSymbols()
For obtaining all the Symbols.
ArrayList getDataSymbols()
For obtaining the Data Symbols.
int getSize()
Get the count of entries currently in the table.
static String getStartLabel()
Fetches the text segment label (symbol) which, if declared global, indicates
the starting address for execution.
Symbol getSymbol(String s)
Produce Symbol object from symbol table that corresponds to given String.
Symbol getSymbolGivenAddress(String s)
Produce Symbol object from symbol table that has the given address.
Symbol getSymbolGivenAddressLocalOrGlobal(String s)
Produce Symbol object from either local or global symbol table that has the
given address.
ArrayList getTextSymbols()
For obtaining the Text Symbols.
void removeSymbol(Token token)
Removes a symbol from the Symbol table.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
NOT_FOUND
public static final int NOT_FOUND
See Also:
Constant Field Values
Constructor Detail
SymbolTable
public SymbolTable(String filename)
Create a new empty symbol table for given file
Parameters:
filename – name of file this symbol table is associated with. Will be
used only for output/display so it can be any descriptive string.
Method Detail
addSymbol
public void addSymbol(Token token,
int address,
boolean b,
ErrorList errors)
Adds a Symbol object into the array of Symbols.
Parameters:
token – The token representing the Symbol.
address – The address of the Symbol.
b – The type of Symbol, true for data, false for text.
errors – List to which to add any processing errors that occur.
removeSymbol
public void removeSymbol(Token token)
Removes a symbol from the Symbol table. If not found, it does nothing.
This will rarely happen (only when variable is declared .globl after already
being defined in the local symbol table).
Parameters:
token – The token representing the Symbol.
getAddress
public int getAddress(String s)
Method to return the address associated with the given label.
Parameters:
s – The label.
Returns:
The memory address of the label given, or NOT_FOUND if not found in symbol table.
getAddressLocalOrGlobal
public int getAddressLocalOrGlobal(String s)
Method to return the address associated with the given label. Look first
in this (local) symbol table then in symbol table of labels declared
global (.globl directive).
Parameters:
s – The label.
Returns:
The memory address of the label given, or NOT_FOUND if not found in symbol table.
getSymbol
public Symbol getSymbol(String s)
Produce Symbol object from symbol table that corresponds to given String.
Parameters:
s – target String
Returns:
Symbol object for requested target, null if not found in symbol table.
getSymbolGivenAddress
public Symbol getSymbolGivenAddress(String s)
Produce Symbol object from symbol table that has the given address.
Parameters:
s – String representing address
Returns:
Symbol object having requested address, null if address not found in symbol table.
getSymbolGivenAddressLocalOrGlobal
public Symbol getSymbolGivenAddressLocalOrGlobal(String s)
Produce Symbol object from either local or global symbol table that has the
given address.
Parameters:
s – String representing address
Returns:
Symbol object having requested address, null if address not found in symbol table.
getDataSymbols
public ArrayList getDataSymbols()
For obtaining the Data Symbols.
Returns:
An ArrayList of Symbol objects.
getTextSymbols
public ArrayList getTextSymbols()
For obtaining the Text Symbols.
Returns:
An ArrayList of Symbol objects.
getAllSymbols
public ArrayList getAllSymbols()
For obtaining all the Symbols.
Returns:
An ArrayList of Symbol objects.
getSize
public int getSize()
Get the count of entries currently in the table.
Returns:
Number of symbol table entries.
clear
public void clear()
Creates a fresh arrayList for a new table.
fixSymbolTableAddress
public void fixSymbolTableAddress(int originalAddress,
int replacementAddress)
Fix address in symbol table entry. Any and all entries that match the original
address will be modified to contain the replacement address. There is no effect,
if none of the addresses matches.
Parameters:
originalAddress – Address associated with 0 or more symtab entries.
replacementAddress – Any entry that has originalAddress will have its
address updated to this value. Does nothing if none do.
getStartLabel
public static String getStartLabel()
Fetches the text segment label (symbol) which, if declared global, indicates
the starting address for execution.
Returns:
String containing global label whose text segment address is starting address for program execution.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
TokenTypes
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class TokenTypes
java.lang.Object
mars.assembler.TokenTypes
public final class TokenTypes
extends Object
Constants to identify the types of tokens found in MIPS programs. If Java had
enumerated types, that’s how these would probably be implemented.
Author:
Pete Sanderson
Field Summary
static TokenTypes COLON
static TokenTypes COMMENT
static TokenTypes DELIMITER
static TokenTypes DIRECTIVE
static TokenTypes ERROR
static TokenTypes FP_REGISTER_NAME
static TokenTypes IDENTIFIER
static TokenTypes INTEGER_16
static TokenTypes INTEGER_16U
static TokenTypes INTEGER_32
static TokenTypes INTEGER_5
static TokenTypes LEFT_PAREN
static TokenTypes MACRO_PARAMETER
static TokenTypes MINUS
static TokenTypes OPERATOR
static TokenTypes PLUS
static TokenTypes QUOTED_STRING
static TokenTypes REAL_NUMBER
static TokenTypes REGISTER_NAME
note: REGISTER_NAME is token of form $zero whereas REGISTER_NUMBER is token
of form $0.
static TokenTypes REGISTER_NUMBER
static TokenTypes RIGHT_PAREN
static String TOKEN_DELIMITERS
Method Summary
static boolean isFloatingTokenType(TokenTypes type)
Lets you know if given tokentype is for floating point numbers (REAL_NUMBER).
static boolean isIntegerTokenType(TokenTypes type)
Lets you know if given tokentype is for integers (INTGER_5, INTEGER_16, INTEGER_32).
static boolean isValidIdentifier(String value)
static TokenTypes matchTokenType(String value)
Classifies the given token into one of the MIPS types.
String toString()
Produces String equivalent of this token type, which is its name.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
TOKEN_DELIMITERS
public static final String TOKEN_DELIMITERS
See Also:
Constant Field Values
COMMENT
public static final TokenTypes COMMENT
DIRECTIVE
public static final TokenTypes DIRECTIVE
OPERATOR
public static final TokenTypes OPERATOR
DELIMITER
public static final TokenTypes DELIMITER
REGISTER_NAME
public static final TokenTypes REGISTER_NAME
note: REGISTER_NAME is token of form $zero whereas REGISTER_NUMBER is token
of form $0. The former is part of extended assembler, and latter is part
of basic assembler.
REGISTER_NUMBER
public static final TokenTypes REGISTER_NUMBER
FP_REGISTER_NAME
public static final TokenTypes FP_REGISTER_NAME
IDENTIFIER
public static final TokenTypes IDENTIFIER
LEFT_PAREN
public static final TokenTypes LEFT_PAREN
RIGHT_PAREN
public static final TokenTypes RIGHT_PAREN
INTEGER_5
public static final TokenTypes INTEGER_5
INTEGER_16
public static final TokenTypes INTEGER_16
INTEGER_16U
public static final TokenTypes INTEGER_16U
INTEGER_32
public static final TokenTypes INTEGER_32
REAL_NUMBER
public static final TokenTypes REAL_NUMBER
QUOTED_STRING
public static final TokenTypes QUOTED_STRING
PLUS
public static final TokenTypes PLUS
MINUS
public static final TokenTypes MINUS
COLON
public static final TokenTypes COLON
ERROR
public static final TokenTypes ERROR
MACRO_PARAMETER
public static final TokenTypes MACRO_PARAMETER
Method Detail
toString
public String toString()
Produces String equivalent of this token type, which is its name.
Overrides:
toString in class Object
Returns:
String containing descriptive name for token type.
matchTokenType
public static TokenTypes matchTokenType(String value)
Classifies the given token into one of the MIPS types.
Parameters:
value – String containing candidate language element, extracted from MIPS program.
Returns:
Returns the corresponding TokenTypes object if the parameter matches a
defined MIPS token type, else returns null.
isIntegerTokenType
public static boolean isIntegerTokenType(TokenTypes type)
Lets you know if given tokentype is for integers (INTGER_5, INTEGER_16, INTEGER_32).
Parameters:
type – the TokenType of interest
Returns:
true if type is an integer type, false otherwise.
isFloatingTokenType
public static boolean isFloatingTokenType(TokenTypes type)
Lets you know if given tokentype is for floating point numbers (REAL_NUMBER).
Parameters:
type – the TokenType of interest
Returns:
true if type is an floating point type, false otherwise.
isValidIdentifier
public static boolean isValidIdentifier(String value)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
OperandFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class OperandFormat
java.lang.Object
mars.assembler.OperandFormat
public class OperandFormat
extends Object
Provides utility method related to MIPS operand formats.
Author:
Pete Sanderson
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
TokenList
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class TokenList
java.lang.Object
mars.assembler.TokenList
All Implemented Interfaces:
Cloneable
public class TokenList
extends Object
implements Cloneable
Represents the list of tokens in a single line of MIPS code. It uses, but is not
a subclass of, ArrayList.
Author:
Pete Sanderson
Constructor Summary
TokenList()
Constructor for objects of class TokenList
Method Summary
void add(Token token)
Adds a Token object to the end of the list.
Object clone()
Makes clone (shallow copy) of this token list object.
Token get(int pos)
Returns requested token given position number (starting at 0).
String getProcessedLine()
Retrieve the source line String associated with this
token list.
boolean isEmpty()
Returns empty/non-empty status of list.
void remove(int pos)
Removes Token object at specified list position.
void set(int pos,
Token replacement)
Replaces token at position with different one.
void setProcessedLine(String line)
Use this to record the source line String for this token list
after possible modification (textual substitution) during
assembly preprocessing.
int size()
Returns number of tokens in list.
String toString()
Get a String representing the token list.
String toTypeString()
Get a String representing the sequence of token types for this list.
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
TokenList
public TokenList()
Constructor for objects of class TokenList
Method Detail
setProcessedLine
public void setProcessedLine(String line)
Use this to record the source line String for this token list
after possible modification (textual substitution) during
assembly preprocessing. The modified source will be displayed in
the Text Segment Display.
Parameters:
line – The source line, possibly modified (possibly not)
getProcessedLine
public String getProcessedLine()
Retrieve the source line String associated with this
token list. It may or may not have been modified during
assembly preprocessing.
Returns:
The source line for this token list.
get
public Token get(int pos)
Returns requested token given position number (starting at 0).
Parameters:
pos – Position in token list.
Returns:
the requested token, or ArrayIndexOutOfBounds exception
set
public void set(int pos,
Token replacement)
Replaces token at position with different one. Will throw
ArrayIndexOutOfBounds exception if position does not exist.
Parameters:
pos – Position in token list.
replacement – Replacement token
size
public int size()
Returns number of tokens in list.
Returns:
token count.
add
public void add(Token token)
Adds a Token object to the end of the list.
Parameters:
token – Token object to be added.
remove
public void remove(int pos)
Removes Token object at specified list position. Uses ArrayList remove method.
Parameters:
pos – Position in token list. Subsequent Tokens are shifted one position left.
Throws:
IndexOutOfBoundsException – if pos is < 0 or >= size()
isEmpty
public boolean isEmpty()
Returns empty/non-empty status of list.
Returns:
true if list has no tokens, else false.
toString
public String toString()
Get a String representing the token list.
Overrides:
toString in class Object
Returns:
String version of the token list
(a blank is inserted after each token).
toTypeString
public String toTypeString()
Get a String representing the sequence of token types for this list.
Returns:
String version of the token types for this list
(a blank is inserted after each token type).
clone
public Object clone()
Makes clone (shallow copy) of this token list object.
Overrides:
clone in class Object
Returns:
the cloned list.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
TranslationCode
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Interface TranslationCode
public interface TranslationCode
This interface is intended for use by ExtendedInstruction objects to define, using
the translate() method, how to translate the extended (pseudo) instruction into
a sequence of one or more basic instructions, which can then be translated into
binary machine code.
Author:
Pete Sanderson
Method Summary
void translate()
This is a callback method defined in anonymous class specified as
argument to ExtendedInstruction constructor.
Method Detail
translate
void translate()
This is a callback method defined in anonymous class specified as
argument to ExtendedInstruction constructor. It is called when
assembler finds a program statement matching that ExtendedInstruction,
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
mars.assembler
Interfaces
TranslationCode
Classes
Assembler
DataTypes
Directives
Macro
MacroPool
OperandFormat
SourceLine
Symbol
SymbolTable
Token
Tokenizer
TokenList
TokenTypes
Assembler
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class Assembler
java.lang.Object
mars.assembler.Assembler
public class Assembler
extends Object
An Assembler is capable of assembling a MIPS program. It has only one public
method, assemble(), which implements a two-pass assembler. It
translates MIPS source code into binary machine code.
Author:
Pete Sanderson
Constructor Summary
Assembler()
Method Summary
ArrayList assemble(ArrayList tokenizedProgramFiles,
boolean extendedAssemblerEnabled)
Parse and generate machine code for the given MIPS program.
ArrayList assemble(ArrayList tokenizedProgramFiles,
boolean extendedAssemblerEnabled,
boolean warningsAreErrors)
Parse and generate machine code for the given MIPS program.
ArrayList assemble(MIPSprogram p,
boolean extendedAssemblerEnabled)
Parse and generate machine code for the given MIPS program.
ArrayList assemble(MIPSprogram p,
boolean extendedAssemblerEnabled,
boolean warningsAreErrors)
Parse and generate machine code for the given MIPS program.
ErrorList getErrorList()
Get list of assembler errors and warnings
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
Assembler
public Assembler()
Method Detail
assemble
public ArrayList assemble(MIPSprogram p,
boolean extendedAssemblerEnabled)
throws ProcessingException
Parse and generate machine code for the given MIPS program. It must have
already been tokenized. Warnings are not considered errors.
Parameters:
p – A MIPSprogram object representing the program source.
extendedAssemblerEnabled – A boolean value that if true permits use of extended (pseudo)
instructions in the source code. If false, these are flagged
as errors.
Returns:
An ArrayList representing the assembled program. Each member of
the list is a ProgramStatement object containing the source,
intermediate, and machine binary representations of a program
statement.
Throws:
ProcessingException
See Also:
ProgramStatement
assemble
public ArrayList assemble(MIPSprogram p,
boolean extendedAssemblerEnabled,
boolean warningsAreErrors)
throws ProcessingException
Parse and generate machine code for the given MIPS program. It must have
already been tokenized.
Parameters:
p – A MIPSprogram object representing the program source.
extendedAssemblerEnabled – A boolean value that if true permits use of extended (pseudo)
instructions in the source code. If false, these are flagged
as errors.
warningsAreErrors – A boolean value – true means assembler warnings will be
considered errors and terminate the assemble; false means the
assembler will produce warning message but otherwise ignore
warnings.
Returns:
An ArrayList representing the assembled program. Each member of
the list is a ProgramStatement object containing the source,
intermediate, and machine binary representations of a program
statement.
Throws:
ProcessingException
See Also:
ProgramStatement
getErrorList
public ErrorList getErrorList()
Get list of assembler errors and warnings
Returns:
ErrorList of any assembler errors and warnings.
assemble
public ArrayList assemble(ArrayList tokenizedProgramFiles,
boolean extendedAssemblerEnabled)
throws ProcessingException
Parse and generate machine code for the given MIPS program. All source
files must have already been tokenized. Warnings will not be considered
errors.
Parameters:
tokenizedProgramFiles – An ArrayList of MIPSprogram objects, each produced from a
different source code file, representing the program source.
extendedAssemblerEnabled – A boolean value that if true permits use of extended (pseudo)
instructions in the source code. If false, these are flagged
as errors.
Returns:
An ArrayList representing the assembled program. Each member of
the list is a ProgramStatement object containing the source,
intermediate, and machine binary representations of a program
statement. Returns null if incoming array list is null or empty.
Throws:
ProcessingException
See Also:
ProgramStatement
assemble
public ArrayList assemble(ArrayList tokenizedProgramFiles,
boolean extendedAssemblerEnabled,
boolean warningsAreErrors)
throws ProcessingException
Parse and generate machine code for the given MIPS program. All source
files must have already been tokenized.
Parameters:
tokenizedProgramFiles – An ArrayList of MIPSprogram objects, each produced from a
different source code file, representing the program source.
extendedAssemblerEnabled – A boolean value that if true permits use of extended (pseudo)
instructions in the source code. If false, these are flagged
as errors.
warningsAreErrors – A boolean value – true means assembler warnings will be
considered errors and terminate the assemble; false means the
assembler will produce warning message but otherwise ignore
warnings.
Returns:
An ArrayList representing the assembled program. Each member of
the list is a ProgramStatement object containing the source,
intermediate, and machine binary representations of a program
statement. Returns null if incoming array list is null or empty.
Throws:
ProcessingException
See Also:
ProgramStatement
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Tokenizer
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class Tokenizer
java.lang.Object
mars.assembler.Tokenizer
public class Tokenizer
extends Object
A tokenizer is capable of tokenizing a complete MIPS program, or a given line from
a MIPS program. Since MIPS is line-oriented, each line defines a complete statement.
Tokenizing is the process of analyzing the input MIPS program for the purpose of
recognizing each MIPS language element. The types of language elements are known as “tokens”.
MIPS tokens are defined in the TokenTypes class.
Example:
The MIPS statement here: lw $t3, 8($t4) #load third member of array
generates the following token list
IDENTIFIER, COLON, OPERATOR, REGISTER_NAME, COMMA, INTEGER_5, LEFT_PAREN,
REGISTER_NAME, RIGHT_PAREN, COMMENT
Author:
Pete Sanderson
Constructor Summary
Tokenizer()
Simple constructor.
Tokenizer(MIPSprogram program)
Constructor for use with existing MIPSprogram.
Method Summary
ErrorList getErrors()
Fetch this Tokenizer’s error list.
ArrayList tokenize(MIPSprogram p)
Will tokenize a complete MIPS program.
TokenList tokenizeExampleInstruction(String example)
Used only to create a token list for the example provided with each instruction
specification.
TokenList tokenizeLine(int lineNum,
String theLine)
Will tokenize one line of source code.
TokenList tokenizeLine(int lineNum,
String theLine,
ErrorList callerErrorList)
Will tokenize one line of source code.
TokenList tokenizeLine(int lineNum,
String theLine,
ErrorList callerErrorList,
boolean doEqvSubstitutes)
Will tokenize one line of source code.
TokenList tokenizeLine(MIPSprogram program,
int lineNum,
String theLine,
boolean doEqvSubstitutes)
Will tokenize one line of source code.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
Tokenizer
public Tokenizer()
Simple constructor. Initializes empty error list.
Tokenizer
public Tokenizer(MIPSprogram program)
Constructor for use with existing MIPSprogram. Designed to be used with Macro feature.
Parameters:
program – A previously-existing MIPSprogram object or null if none.
Method Detail
tokenize
public ArrayList tokenize(MIPSprogram p)
throws ProcessingException
Will tokenize a complete MIPS program. MIPS is line oriented (not free format),
so we will be line-oriented too.
Parameters:
p – The MIPSprogram to be tokenized.
Returns:
An ArrayList representing the tokenized program. Each list member is a TokenList
that represents a tokenized source statement from the MIPS program.
Throws:
ProcessingException
tokenizeExampleInstruction
public TokenList tokenizeExampleInstruction(String example)
throws ProcessingException
Used only to create a token list for the example provided with each instruction
specification.
Parameters:
example – The example MIPS instruction to be tokenized.
Returns:
An TokenList representing the tokenized instruction. Each list member is a Token
that represents one language element.
Throws:
ProcessingException – This occurs only if the instruction specification itself
contains one or more lexical (i.e. token) errors.
tokenizeLine
public TokenList tokenizeLine(int lineNum,
String theLine)
Will tokenize one line of source code. If lexical errors are discovered,
they are noted in an ErrorMessage object which is added to the ErrorList.
Will NOT throw an exception yet because we want to persevere beyond first error.
Parameters:
lineNum – line number from source code (used in error message)
theLine – String containing source code
Returns:
the generated token list for that line
tokenizeLine
public TokenList tokenizeLine(int lineNum,
String theLine,
ErrorList callerErrorList)
Will tokenize one line of source code. If lexical errors are discovered,
they are noted in an ErrorMessage object which is added to the provided ErrorList
instead of the Tokenizer’s error list. Will NOT throw an exception.
Parameters:
lineNum – line number from source code (used in error message)
theLine – String containing source code
callerErrorList – errors will go into this list instead of tokenizer’s list.
Returns:
the generated token list for that line
tokenizeLine
public TokenList tokenizeLine(int lineNum,
String theLine,
ErrorList callerErrorList,
boolean doEqvSubstitutes)
Will tokenize one line of source code. If lexical errors are discovered,
they are noted in an ErrorMessage object which is added to the provided ErrorList
instead of the Tokenizer’s error list. Will NOT throw an exception.
Parameters:
lineNum – line number from source code (used in error message)
theLine – String containing source code
callerErrorList – errors will go into this list instead of tokenizer’s list.
doEqvSubstitutse – boolean param set true to perform .eqv substitutions, else false
Returns:
the generated token list for that line
tokenizeLine
public TokenList tokenizeLine(MIPSprogram program,
int lineNum,
String theLine,
boolean doEqvSubstitutes)
Will tokenize one line of source code. If lexical errors are discovered,
they are noted in an ErrorMessage object which is added to the provided ErrorList
instead of the Tokenizer’s error list. Will NOT throw an exception.
Parameters:
program – MIPSprogram containing this line of source
lineNum – line number from source code (used in error message)
theLine – String containing source code
doEqvSubstitutes – boolean param set true to perform .eqv substitutions, else false
Returns:
the generated token list for that line
getErrors
public ErrorList getErrors()
Fetch this Tokenizer’s error list.
Returns:
the error list
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Symbol
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class Symbol
java.lang.Object
mars.assembler.Symbol
public class Symbol
extends Object
Represents a MIPS program identifier to be stored in the symbol table.
Author:
Jason Bumgarner, Jason Shrewsbury
Field Summary
static boolean DATA_SYMBOL
static boolean TEXT_SYMBOL
Constructor Summary
Symbol(String name,
int address,
boolean data)
Basic constructor, creates a symbol object.
Method Summary
int getAddress()
Returns the address of the the Symbol.
String getName()
Returns the label of the the Symbol.
boolean getType()
Finds the type of symbol, text or data.
void setAddress(int newAddress)
Sets (replaces) the address of the the Symbol.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
TEXT_SYMBOL
public static final boolean TEXT_SYMBOL
See Also:
Constant Field Values
DATA_SYMBOL
public static final boolean DATA_SYMBOL
See Also:
Constant Field Values
Constructor Detail
Symbol
public Symbol(String name,
int address,
boolean data)
Basic constructor, creates a symbol object.
Parameters:
name – The name of the Symbol.
address – The memroy address that the Symbol refers to.
data – The type of Symbol that it is.
Method Detail
getAddress
public int getAddress()
Returns the address of the the Symbol.
Returns:
The address of the Symbol.
getName
public String getName()
Returns the label of the the Symbol.
Returns:
The label of the Symbol.
getType
public boolean getType()
Finds the type of symbol, text or data.
Returns:
The type of the data.
setAddress
public void setAddress(int newAddress)
Sets (replaces) the address of the the Symbol.
Parameters:
newAddress – The revised address of the Symbol.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.assembler
Interface Summary
TranslationCode This interface is intended for use by ExtendedInstruction objects to define, using
the translate() method, how to translate the extended (pseudo) instruction into
a sequence of one or more basic instructions, which can then be translated into
binary machine code.
Class Summary
Assembler An Assembler is capable of assembling a MIPS program.
DataTypes Information about MIPS data types.
Directives Class representing MIPS assembler directives.
Macro Stores information of a macro definition.
MacroPool Stores information of macros defined by now.
OperandFormat Provides utility method related to MIPS operand formats.
SourceLine Handy class to represent, for a given line of source code, the code
itself, the program containing it, and its line number within that program.
Symbol Represents a MIPS program identifier to be stored in the symbol table.
SymbolTable Creats a table of Symbol objects.
Token Represents one token in the input MIPS program.
Tokenizer A tokenizer is capable of tokenizing a complete MIPS program, or a given line from
a MIPS program.
TokenList Represents the list of tokens in a single line of MIPS code.
TokenTypes Constants to identify the types of tokens found in MIPS programs.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Macro
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class Macro
java.lang.Object
mars.assembler.Macro
public class Macro
extends Object
Stores information of a macro definition.
Author:
M.H.Sekhavat
Constructor Summary
Macro()
Method Summary
void addArg(String value)
void addLabel(String value)
boolean equals(Object obj)
ArrayList
int getFromLine()
String getName()
int getOriginalFromLine()
int getOriginalToLine()
MIPSprogram getProgram()
String getSubstitutedLine(int line,
TokenList args,
long counter,
ErrorList errors)
Substitutes macro arguments in a line of source code inside macro
definition to be parsed after macro expansion.
int getToLine()
void readyForCommit()
Operations to be done on this macro before it is committed in macro pool.
void setArgs(ArrayList
void setFromLine(int fromLine)
void setName(String name)
void setOriginalFromLine(int origFromLine)
void setOriginalToLine(int origToLine)
void setProgram(MIPSprogram program)
void setToLine(int toLine)
static boolean tokenIsMacroParameter(String tokenValue,
boolean acceptSpimStyleParameters)
returns whether tokenValue is macro parameter or not
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
Macro
public Macro()
Method Detail
getName
public String getName()
setName
public void setName(String name)
getProgram
public MIPSprogram getProgram()
setProgram
public void setProgram(MIPSprogram program)
getFromLine
public int getFromLine()
getOriginalFromLine
public int getOriginalFromLine()
setFromLine
public void setFromLine(int fromLine)
setOriginalFromLine
public void setOriginalFromLine(int origFromLine)
getToLine
public int getToLine()
getOriginalToLine
public int getOriginalToLine()
setToLine
public void setToLine(int toLine)
setOriginalToLine
public void setOriginalToLine(int origToLine)
getArgs
public ArrayList
setArgs
public void setArgs(ArrayList
equals
public boolean equals(Object obj)
Overrides:
equals in class Object
Parameters:
obj – Macro object to check if their name and count of
arguments are same
addArg
public void addArg(String value)
getSubstitutedLine
public String getSubstitutedLine(int line,
TokenList args,
long counter,
ErrorList errors)
Substitutes macro arguments in a line of source code inside macro
definition to be parsed after macro expansion.
Also appends “_M#” to all labels defined inside macro body where # is value of counter
Parameters:
line – source line number in macro definition to be substituted
args –
counter – unique macro expansion id
errors –
Returns:
line-th line of source code, with substituted
arguments
tokenIsMacroParameter
public static boolean tokenIsMacroParameter(String tokenValue,
boolean acceptSpimStyleParameters)
returns whether tokenValue is macro parameter or not
Parameters:
tokenValue –
acceptSpimStyleParameters – accepts SPIM-style parameters which begin with ‘$’ if true
Returns:
addLabel
public void addLabel(String value)
readyForCommit
public void readyForCommit()
Operations to be done on this macro before it is committed in macro pool.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DataTypes
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class DataTypes
java.lang.Object
mars.assembler.DataTypes
public final class DataTypes
extends Object
Information about MIPS data types.
Author:
Pete Sanderson
Field Summary
static int BYTE_SIZE
Number of bytes occupied by MIPS byte is 1.
static int CHAR_SIZE
Number of bytes occupied by MIPS character is 1.
static int DOUBLE_SIZE
Number of bytes occupied by MIPS double is 8.
static int FLOAT_SIZE
Number of bytes occupied by MIPS float is 4.
static int HALF_SIZE
Number of bytes occupied by MIPS halfword is 2.
static double LOW_DOUBLE_VALUE
Largest magnitude negative value that can be stored in a MIPS double(negative of the max)
static double LOW_FLOAT_VALUE
Largest magnitude negative value that can be stored in a MIPS float (negative of the max)
static int MAX_BYTE_VALUE
Maximum value that can be stored in a MIPS byte is 27-1
static double MAX_DOUBLE_VALUE
Maximum positive finite value that can be stored in a MIPS double is same as Java Double
static double MAX_FLOAT_VALUE
Maximum positive finite value that can be stored in a MIPS float is same as Java Float
static int MAX_HALF_VALUE
Maximum value that can be stored in a MIPS halfword is 215-1
static int MAX_UHALF_VALUE
Maximum value that can be stored in an unsigned MIPS halfword is 216-1
static int MAX_WORD_VALUE
Maximum value that can be stored in a MIPS word is 231-1
static int MIN_BYTE_VALUE
Lowest value that can be stored in a MIPS byte is -27
static int MIN_HALF_VALUE
Lowest value that can be stored in a MIPS halfword is -215
static int MIN_UHALF_VALUE
Lowest value that can be stored in na unsigned MIPS halfword is 0
static int MIN_WORD_VALUE
Lowest value that can be stored in a MIPS word is -231
static int WORD_SIZE
Number of bytes occupied by MIPS word is 4.
Constructor Summary
DataTypes()
Method Summary
static int getLengthInBytes(Directives direct)
Get length in bytes for numeric MIPS directives.
static boolean outOfRange(Directives direct,
double value)
Determines whether given floating point value falls within value range for given directive.
static boolean outOfRange(Directives direct,
int value)
Determines whether given integer value falls within value range for given directive.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
DOUBLE_SIZE
public static final int DOUBLE_SIZE
Number of bytes occupied by MIPS double is 8.
See Also:
Constant Field Values
FLOAT_SIZE
public static final int FLOAT_SIZE
Number of bytes occupied by MIPS float is 4.
See Also:
Constant Field Values
WORD_SIZE
public static final int WORD_SIZE
Number of bytes occupied by MIPS word is 4.
See Also:
Constant Field Values
HALF_SIZE
public static final int HALF_SIZE
Number of bytes occupied by MIPS halfword is 2.
See Also:
Constant Field Values
BYTE_SIZE
public static final int BYTE_SIZE
Number of bytes occupied by MIPS byte is 1.
See Also:
Constant Field Values
CHAR_SIZE
public static final int CHAR_SIZE
Number of bytes occupied by MIPS character is 1.
See Also:
Constant Field Values
MAX_WORD_VALUE
public static final int MAX_WORD_VALUE
Maximum value that can be stored in a MIPS word is 231-1
See Also:
Constant Field Values
MIN_WORD_VALUE
public static final int MIN_WORD_VALUE
Lowest value that can be stored in a MIPS word is -231
See Also:
Constant Field Values
MAX_HALF_VALUE
public static final int MAX_HALF_VALUE
Maximum value that can be stored in a MIPS halfword is 215-1
See Also:
Constant Field Values
MIN_HALF_VALUE
public static final int MIN_HALF_VALUE
Lowest value that can be stored in a MIPS halfword is -215
See Also:
Constant Field Values
MAX_UHALF_VALUE
public static final int MAX_UHALF_VALUE
Maximum value that can be stored in an unsigned MIPS halfword is 216-1
See Also:
Constant Field Values
MIN_UHALF_VALUE
public static final int MIN_UHALF_VALUE
Lowest value that can be stored in na unsigned MIPS halfword is 0
See Also:
Constant Field Values
MAX_BYTE_VALUE
public static final int MAX_BYTE_VALUE
Maximum value that can be stored in a MIPS byte is 27-1
See Also:
Constant Field Values
MIN_BYTE_VALUE
public static final int MIN_BYTE_VALUE
Lowest value that can be stored in a MIPS byte is -27
See Also:
Constant Field Values
MAX_FLOAT_VALUE
public static final double MAX_FLOAT_VALUE
Maximum positive finite value that can be stored in a MIPS float is same as Java Float
See Also:
Constant Field Values
LOW_FLOAT_VALUE
public static final double LOW_FLOAT_VALUE
Largest magnitude negative value that can be stored in a MIPS float (negative of the max)
See Also:
Constant Field Values
MAX_DOUBLE_VALUE
public static final double MAX_DOUBLE_VALUE
Maximum positive finite value that can be stored in a MIPS double is same as Java Double
See Also:
Constant Field Values
LOW_DOUBLE_VALUE
public static final double LOW_DOUBLE_VALUE
Largest magnitude negative value that can be stored in a MIPS double(negative of the max)
See Also:
Constant Field Values
Constructor Detail
DataTypes
public DataTypes()
Method Detail
getLengthInBytes
public static int getLengthInBytes(Directives direct)
Get length in bytes for numeric MIPS directives.
Parameters:
direct – Directive to be measured.
Returns:
Returns length in bytes for values of that type. If type is not numeric
(or not implemented yet), returns 0.
outOfRange
public static boolean outOfRange(Directives direct,
int value)
Determines whether given integer value falls within value range for given directive.
Parameters:
direct – Directive that controls storage allocation for value.
value – The value to be stored.
Returns:
Returns true if value can be stored in the number of bytes allowed
by the given directive (.word, .half, .byte), false otherwise.
outOfRange
public static boolean outOfRange(Directives direct,
double value)
Determines whether given floating point value falls within value range for given directive.
For float, this refers to range of the data type, not precision. Example: 1.23456789012345
be stored in a float with loss of precision. It’s within the range. But 1.23e500 cannot be
stored in a float because the exponent 500 is too large (float allows 8 bits for exponent).
Parameters:
direct – Directive that controls storage allocation for value.
value – The value to be stored.
Returns:
Returns true if value is within range of
the given directive (.float, .double), false otherwise.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.assembler
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object mars.assembler.Assembler
mars.assembler.DataTypes
mars.assembler.Directives
mars.assembler.Macro
mars.assembler.MacroPool
mars.assembler.OperandFormat
mars.assembler.SourceLine
mars.assembler.Symbol
mars.assembler.SymbolTable
mars.assembler.Token
mars.assembler.Tokenizer
mars.assembler.TokenList (implements java.lang.Cloneable)
mars.assembler.TokenTypes
Interface Hierarchy
mars.assembler.TranslationCode
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Token
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.assembler
Class Token
java.lang.Object
mars.assembler.Token
public class Token
extends Object
Represents one token in the input MIPS program. Each Token carries, along with its
type and value, the position (line, column) in which its source appears in the MIPS program.
Author:
Pete Sanderson
Constructor Summary
Token(TokenTypes type,
String value,
MIPSprogram sourceMIPSprogram,
int line,
int start)
Constructor for Token class.
Method Summary
MIPSprogram getOriginalProgram()
Produces original program containing this token.
int getOriginalSourceLine()
Produces original line number of this token.
int getSourceLine()
Produces line number of MIPS program of this token.
MIPSprogram getSourceMIPSprogram()
Produces MIPSprogram object associated with this token.
int getStartPos()
Produces position within source line of this token.
TokenTypes getType()
Produces token type of this token.
String getValue()
Produces source code of this token.
void setOriginal(MIPSprogram origProgram,
int origSourceLine)
Set original program and line number for this token.
void setType(TokenTypes type)
Set or modify token type.
String toString()
Get a String representing the token.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
Token
public Token(TokenTypes type,
String value,
MIPSprogram sourceMIPSprogram,
int line,
int start)
Constructor for Token class.
Parameters:
type – The token type that this token has. (e.g. REGISTER_NAME)
value – The source value for this token (e.g. $t3)
sourceMIPSprogram – The MIPSprogram object containing this token
line – The line number in source program in which this token appears.
start – The starting position in that line number of this token’s source value.
See Also:
TokenTypes
Method Detail
setOriginal
public void setOriginal(MIPSprogram origProgram,
int origSourceLine)
Set original program and line number for this token.
Line number or both may change during pre-assembly as a result
of the “.include” directive, and we need to keep the original
for later reference (error messages, text segment display).
Parameters:
origProgram – MIPS program containing this token.
origSourceLine – Line within that program of this token.
getOriginalProgram
public MIPSprogram getOriginalProgram()
Produces original program containing this token.
Returns:
MIPSprogram of origin for this token.
getOriginalSourceLine
public int getOriginalSourceLine()
Produces original line number of this token. It could change as result
of “.include”
Returns:
original line number of this token.
getType
public TokenTypes getType()
Produces token type of this token.
Returns:
TokenType of this token.
setType
public void setType(TokenTypes type)
Set or modify token type. Generally used to note that
an identifier that matches an instruction name is
actually being used as a label.
Parameters:
type – new TokenTypes for this token.
getValue
public String getValue()
Produces source code of this token.
Returns:
String containing source code of this token.
toString
public String toString()
Get a String representing the token. This method is
equivalent to getValue().
Overrides:
toString in class Object
Returns:
String version of the token.
getSourceMIPSprogram
public MIPSprogram getSourceMIPSprogram()
Produces MIPSprogram object associated with this token.
Returns:
MIPSprogram object associated with this token.
getSourceLine
public int getSourceLine()
Produces line number of MIPS program of this token.
Returns:
line number in source program of this token.
getStartPos
public int getStartPos()
Produces position within source line of this token.
Returns:
first character position within source program line of this token.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
PropertiesFile
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.util
Class PropertiesFile
java.lang.Object
mars.util.PropertiesFile
public class PropertiesFile
extends Object
Provides means to work with “.properties” files which are used to store
various MARS settings.
Author:
Pete Sanderson
Constructor Summary
PropertiesFile()
Method Summary
static Properties loadPropertiesFromFile(String file)
Produce Properties (a Hashtable) object containing key-value pairs
from specified properties file.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
PropertiesFile
public PropertiesFile()
Method Detail
loadPropertiesFromFile
public static Properties loadPropertiesFromFile(String file)
Produce Properties (a Hashtable) object containing key-value pairs
from specified properties file. This may be used as an alternative
to readPropertiesFile() which uses a different implementation.
Parameters:
file – Properties filename. Do NOT include the file extension as
it is assumed to be “.properties” and is added here.
Returns:
Properties (Hashtable) of key-value pairs read from the file.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Binary
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.util
Class Binary
java.lang.Object
mars.util.Binary
public class Binary
extends Object
Some utility methods for working with binary representations.
Author:
Pete Sanderson, Ken Vollmar, and Jason Bumgarner
Constructor Summary
Binary()
Method Summary
static char binaryStringToHexDigit(String value)
Translate String consisting of ‘1’s and ‘0’s into char equivalent of the corresponding
hexadecimal digit.
static String binaryStringToHexString(String value)
Translate String consisting of ‘1’s and ‘0’s into String equivalent of the corresponding
hexadecimal value.
static int binaryStringToInt(String value)
Translate String consisting of ‘1’s and ‘0’s into an int value having that binary representation.
static long binaryStringToLong(String value)
Translate String consisting of ‘1’s and ‘0’s into a long value having that binary representation.
static int bitValue(int value,
int bit)
Returns the bit value of the given bit position of the given int value.
static int bitValue(long value,
int bit)
Returns the bit value of the given bit position of the given long value.
static int clearBit(int value,
int bit)
Sets the specified bit of the specified value to 0, and returns the result.
static int getByte(int value,
int bite)
Gets the specified byte of the specified value.
static String hexStringToBinaryString(String value)
Translate String consisting of hexadecimal digits into String consisting of
corresponding binary digits (‘1’s and ‘0’s).
static int highOrderLongToInt(long longValue)
Returns int representing the bit values of the high order 32 bits of given
64 bit long value.
static String intToAscii(int d)
Produce ASCII string equivalent of integer value, interpreting it as 4 one-byte
characters.
static String intToBinaryString(int value)
Translate int value into a String consisting of ‘1’s and ‘0’s.
static String intToBinaryString(int value,
int length)
Translate int value into a String consisting of ‘1’s and ‘0’s.
static String intToHalfHexString(int d)
Returns a 6 character string representing the 16-bit hexadecimal equivalent of the
given integer value.
static String intToHexString(int d)
Prefix a hexadecimal-indicating string “0x” to the string which is
returned by the method “Integer.toHexString”.
static boolean isHex(String v)
Parsing method to see if a string represents a hex number.
static boolean isOctal(String v)
Parsing method to see if a string represents an octal number.
static String longToBinaryString(long value)
Translate long value into a String consisting of ‘1’s and ‘0’s.
static String longToBinaryString(long value,
int length)
Translate long value into a String consisting of ‘1’s and ‘0’s.
static String longToHexString(long value)
Prefix a hexadecimal-indicating string “0x” to the string equivalent to the
hexadecimal value in the long parameter.
static int lowOrderLongToInt(long longValue)
Returns int representing the bit values of the low order 32 bits of given
64 bit long value.
static int setBit(int value,
int bit)
Sets the specified bit of the specified value to 1, and returns the result.
static int setByte(int value,
int bite,
int replace)
Sets the specified byte of the specified value to the low order 8 bits of
specified replacement value, and returns the result.
static int stringToInt(String s)
Attempt to validate given string whose characters represent a 32 bit integer.
static long stringToLong(String s)
Attempt to validate given string whose characters represent a 64 bit long.
static long twoIntsToLong(int highOrder,
int lowOrder)
Returns long (64 bit integer) combining the bit values of two given 32 bit
integer values.
static String unsignedIntToIntString(int d)
Produce String equivalent of integer value interpreting it as an unsigned integer.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
Binary
public Binary()
Method Detail
intToBinaryString
public static String intToBinaryString(int value,
int length)
Translate int value into a String consisting of ‘1’s and ‘0’s.
Parameters:
value – The int value to convert.
length – The number of bit positions, starting at least significant, to process.
Returns:
String consisting of ‘1’ and ‘0’ characters corresponding to the requested binary sequence.
intToBinaryString
public static String intToBinaryString(int value)
Translate int value into a String consisting of ‘1’s and ‘0’s. Assumes all 32 bits are
to be translated.
Parameters:
value – The int value to convert.
Returns:
String consisting of ‘1’ and ‘0’ characters corresponding to the requested binary sequence.
longToBinaryString
public static String longToBinaryString(long value,
int length)
Translate long value into a String consisting of ‘1’s and ‘0’s.
Parameters:
value – The long value to convert.
length – The number of bit positions, starting at least significant, to process.
Returns:
String consisting of ‘1’ and ‘0’ characters corresponding to the requested binary sequence.
longToBinaryString
public static String longToBinaryString(long value)
Translate long value into a String consisting of ‘1’s and ‘0’s. Assumes all 64 bits are
to be translated.
Parameters:
value – The long value to convert.
Returns:
String consisting of ‘1’ and ‘0’ characters corresponding to the requested binary sequence.
binaryStringToInt
public static int binaryStringToInt(String value)
Translate String consisting of ‘1’s and ‘0’s into an int value having that binary representation.
The String is assumed to be at most 32 characters long. No error checking is performed.
String position 0 has most-significant bit, position length-1 has least-significant.
Parameters:
value – The String value to convert.
Returns:
int whose binary value corresponds to decoded String.
binaryStringToLong
public static long binaryStringToLong(String value)
Translate String consisting of ‘1’s and ‘0’s into a long value having that binary representation.
The String is assumed to be at most 64 characters long. No error checking is performed.
String position 0 has most-significant bit, position length-1 has least-significant.
Parameters:
value – The String value to convert.
Returns:
long whose binary value corresponds to decoded String.
binaryStringToHexString
public static String binaryStringToHexString(String value)
Translate String consisting of ‘1’s and ‘0’s into String equivalent of the corresponding
hexadecimal value. No length limit.
String position 0 has most-significant bit, position length-1 has least-significant.
Parameters:
value – The String value to convert.
Returns:
String containing ‘0’, ‘1’, …’F’ characters which form hexadecimal
equivalent of decoded String.
hexStringToBinaryString
public static String hexStringToBinaryString(String value)
Translate String consisting of hexadecimal digits into String consisting of
corresponding binary digits (‘1’s and ‘0’s). No length limit.
String position 0 will have most-significant bit, position length-1 has least-significant.
Parameters:
value – String containing ‘0’, ‘1’, …’f’
characters which form hexadecimal. Letters may be either upper or lower case.
Works either with or without leading “Ox”.
Returns:
String with equivalent value in binary.
binaryStringToHexDigit
public static char binaryStringToHexDigit(String value)
Translate String consisting of ‘1’s and ‘0’s into char equivalent of the corresponding
hexadecimal digit. String limited to length 4.
String position 0 has most-significant bit, position length-1 has least-significant.
Parameters:
value – The String value to convert.
Returns:
char ‘0’, ‘1’, …’F’ which form hexadecimal equivalent of decoded String.
If string length > 4, returns ‘0’.
intToHexString
public static String intToHexString(int d)
Prefix a hexadecimal-indicating string “0x” to the string which is
returned by the method “Integer.toHexString”. Prepend leading zeroes
to that string as necessary to make it always eight hexadecimal digits.
Parameters:
d – The int value to convert.
Returns:
String containing ‘0’, ‘1’, …’F’ which form hexadecimal equivalent of int.
intToHalfHexString
public static String intToHalfHexString(int d)
Returns a 6 character string representing the 16-bit hexadecimal equivalent of the
given integer value. First two characters are “0x”. It assumes value will “fit”
in 16 bits. If non-negative, prepend leading zeroes to that string as necessary
to make it always four hexadecimal digits. If negative, chop off the first
four ‘f’ digits so result is always four hexadecimal digits
Parameters:
d – The int value to convert.
Returns:
String containing ‘0’, ‘1’, …’F’ which form hexadecimal equivalent of int.
longToHexString
public static String longToHexString(long value)
Prefix a hexadecimal-indicating string “0x” to the string equivalent to the
hexadecimal value in the long parameter. Prepend leading zeroes
to that string as necessary to make it always sixteen hexadecimal digits.
Parameters:
value – The long value to convert.
Returns:
String containing ‘0’, ‘1’, …’F’ which form hexadecimal equivalent of long.
unsignedIntToIntString
public static String unsignedIntToIntString(int d)
Produce String equivalent of integer value interpreting it as an unsigned integer.
For instance, -1 (0xffffffff) produces “4294967295” instead of “-1”.
Parameters:
d – The int value to interpret.
Returns:
String which forms unsigned 32 bit equivalent of int.
intToAscii
public static String intToAscii(int d)
Produce ASCII string equivalent of integer value, interpreting it as 4 one-byte
characters. If the value in a given byte does not correspond to a printable
character, it will be assigned a default character (defined in config.properties)
for a placeholder.
Parameters:
d – The int value to interpret
Returns:
String that represents ASCII equivalent
stringToInt
public static int stringToInt(String s)
throws NumberFormatException
Attempt to validate given string whose characters represent a 32 bit integer.
Integer.decode() is insufficient because it will not allow incorporation of
hex two’s complement (i.e. 0x80…0 through 0xff…f). Allows
optional negative (-) sign but no embedded spaces.
Parameters:
s – candidate string
Returns:
returns int value represented by given string
Throws:
NumberFormatException – if string cannot be translated into an int
stringToLong
public static long stringToLong(String s)
throws NumberFormatException
Attempt to validate given string whose characters represent a 64 bit long.
Long.decode() is insufficient because it will not allow incorporation of
hex two’s complement (i.e. 0x80…0 through 0xff…f). Allows
optional negative (-) sign but no embedded spaces.
Parameters:
s – candidate string
Returns:
returns long value represented by given string
Throws:
NumberFormatException – if string cannot be translated into a long
highOrderLongToInt
public static int highOrderLongToInt(long longValue)
Returns int representing the bit values of the high order 32 bits of given
64 bit long value.
Parameters:
longValue – The long value from which to extract bits.
Returns:
int containing high order 32 bits of argument
lowOrderLongToInt
public static int lowOrderLongToInt(long longValue)
Returns int representing the bit values of the low order 32 bits of given
64 bit long value.
Parameters:
longValue – The long value from which to extract bits.
Returns:
int containing low order 32 bits of argument
twoIntsToLong
public static long twoIntsToLong(int highOrder,
int lowOrder)
Returns long (64 bit integer) combining the bit values of two given 32 bit
integer values.
Parameters:
highOrder – Integer to form the high-order 32 bits of result.
lowOrder – Integer to form the high-order 32 bits of result.
Returns:
long containing concatenated 32 bit int values.
bitValue
public static int bitValue(int value,
int bit)
Returns the bit value of the given bit position of the given int value.
Parameters:
value – The value to read the bit from.
bit – bit position in range 0 (least significant) to 31 (most)
Returns:
0 if the bit position contains 0, and 1 otherwise.
bitValue
public static int bitValue(long value,
int bit)
Returns the bit value of the given bit position of the given long value.
Parameters:
value – The value to read the bit from.
bit – bit position in range 0 (least significant) to 63 (most)
Returns:
0 if the bit position contains 0, and 1 otherwise.
setBit
public static int setBit(int value,
int bit)
Sets the specified bit of the specified value to 1, and returns the result.
Parameters:
value – The value in which the bit is to be set.
bit – bit position in range 0 (least significant) to 31 (most)
Returns:
value possibly modified with given bit set to 1.
clearBit
public static int clearBit(int value,
int bit)
Sets the specified bit of the specified value to 0, and returns the result.
Parameters:
value – The value in which the bit is to be set.
bit – bit position in range 0 (least significant) to 31 (most)
Returns:
value possibly modified with given bit set to 0.
setByte
public static int setByte(int value,
int bite,
int replace)
Sets the specified byte of the specified value to the low order 8 bits of
specified replacement value, and returns the result.
Parameters:
value – The value in which the byte is to be set.
bite – byte position in range 0 (least significant) to 3 (most)
replace – value to place into that byte position – use low order 8 bits
Returns:
value modified value.
getByte
public static int getByte(int value,
int bite)
Gets the specified byte of the specified value.
Parameters:
value – The value in which the byte is to be retrieved.
bite – byte position in range 0 (least significant) to 3 (most)
Returns:
zero-extended byte value in low order byte.
isHex
public static boolean isHex(String v)
Parsing method to see if a string represents a hex number.
As per http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Integer.html#decode(java.lang.String),
a string represents a hex number if the string is in the forms:
Signopt 0x HexDigits
Signopt 0X HexDigits
Signopt # HexDigits
Parameters:
v – String containing numeric digits (could be decimal, octal, or hex)
Returns:
Returns true if string represents a hex number, else returns false.
isOctal
public static boolean isOctal(String v)
Parsing method to see if a string represents an octal number.
As per http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Integer.html#decode(java.lang.String),
a string represents an octal number if the string is in the forms:
Signopt 0 OctalDigits
Parameters:
v – String containing numeric digits (could be decimal, octal, or hex)
Returns:
Returns true if string represents an octal number, else returns false.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FilenameFinder
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.util
Class FilenameFinder
java.lang.Object
mars.util.FilenameFinder
public class FilenameFinder
extends Object
Utility class to perform necessary file-related search
operations. One is to find file names in JAR file,
another is to find names of files in given directory
of normal file system.
Author:
Pete Sanderson
Field Summary
static String MATCH_ALL_EXTENSIONS
Constructor Summary
FilenameFinder()
Method Summary
static boolean fileExtensionMatch(String name,
String extension)
Determine if given filename ends with given extension.
static String getExtension(File file)
Get the filename extension of the specified File.
static FileFilter getFileFilter(ArrayList extensions,
String description)
Get a FileFilter that will filter files based on the given list of filename extensions.
static FileFilter getFileFilter(ArrayList extensions,
String description,
boolean acceptDirectories)
Get a FileFilter that will filter files based on the given list of filename extensions.
static FileFilter getFileFilter(String extension,
String description)
Get a FileFilter that will filter files based on the given filename extension.
static FileFilter getFileFilter(String extension,
String description,
boolean acceptDirectories)
Get a FileFilter that will filter files based on the given filename extension.
static ArrayList getFilenameList(ArrayList nameList,
ArrayList fileExtensions)
Return list of file names.
static ArrayList getFilenameList(ArrayList nameList,
String fileExtension)
Return list of file names.
static ArrayList getFilenameList(ClassLoader classLoader,
String directoryPath,
ArrayList fileExtensions)
Locate files and return list of file names.
static ArrayList getFilenameList(ClassLoader classLoader,
String directoryPath,
String fileExtension)
Locate files and return list of file names.
static ArrayList getFilenameList(String directoryPath,
ArrayList fileExtensions)
Locate files and return list of file names.
static ArrayList getFilenameList(String directoryPath,
String fileExtension)
Locate files and return list of file names.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
MATCH_ALL_EXTENSIONS
public static String MATCH_ALL_EXTENSIONS
Constructor Detail
FilenameFinder
public FilenameFinder()
Method Detail
getFilenameList
public static ArrayList getFilenameList(ClassLoader classLoader,
String directoryPath,
String fileExtension)
Locate files and return list of file names. Given a known relative directory path,
it will locate it and build list of all names of files in that directory
having the given file extension. If the “known file path” doesn’t work
because MARS is running from an executable JAR file, it will locate the
directory in the JAR file and proceed from there. NOTE: since this uses
the class loader to get the resource, the directory path needs to be
relative to classpath, not absolute. To work with an arbitrary file system,
use the other version of this overloaded method. Will NOT match directories
that happen to have the desired extension.
Parameters:
classLoader – class loader to use
directoryPath – Search will be confined to this directory. Use “/” as
separator but do NOT include starting or ending “/” (e.g. mars/tools)
fileExtension – Only files with this extension will be added
to the list. Do NOT include the “.” in extension.
Returns:
array list of matching file names as Strings. If none, list is empty.
getFilenameList
public static ArrayList getFilenameList(ClassLoader classLoader,
String directoryPath,
ArrayList fileExtensions)
Locate files and return list of file names. Given a known relative directory path,
it will locate it and build list of all names of files in that directory
having the given file extension. If the “known file path” doesn’t work
because MARS is running from an executable JAR file, it will locate the
directory in the JAR file and proceed from there. NOTE: since this uses
the class loader to get the resource, the directory path needs to be
relative to classpath, not absolute. To work with an arbitrary file system,
use the other version of this overloaded method.
Parameters:
classLoader – class loader to use
directoryPath – Search will be confined to this directory. Use “/” as
separator but do NOT include starting or ending “/” (e.g. mars/tools)
fileExtensions – ArrayList of Strings containing file extensions.
Only files with an extension in this list will be added to the list.
Do NOT include the “.”, eg “class” not “.class”. If Arraylist or
extension null or empty, all files are added.
Returns:
array list of matching file names as Strings. If none, list is empty.
getFilenameList
public static ArrayList getFilenameList(String directoryPath,
String fileExtension)
Locate files and return list of file names. Given a known directory path,
it will locate it and build list of all names of files in that directory
having the given file extension. If file extenion is null or empty, all
filenames are returned. Returned list contains absolute filename paths.
Parameters:
directoryPath – Search will be confined to this directory.
fileExtension – Only files with this extension will be added to the list.
Do NOT include “.” in extension.
If null or empty string, all files are added.
Returns:
array list of matching file names (absolute path). If none, list is empty.
getFilenameList
public static ArrayList getFilenameList(String directoryPath,
ArrayList fileExtensions)
Locate files and return list of file names. Given a known directory path,
it will locate it and build list of all names of files in that directory
having the given file extension. If file extenion is null or empty, all
filenames are returned. Returned list contains absolute filename paths.
Parameters:
directoryPath – Search will be confined to this directory.
fileExtensions – ArrayList of Strings containing file extensions.
Only files with an extension in this list will be added
to the list. Do NOT include the “.” in extensions. If Arraylist or
extension null or empty, all files are added.
Returns:
array list of matching file names (absolute path). If none, list is empty.
getFilenameList
public static ArrayList getFilenameList(ArrayList nameList,
String fileExtension)
Return list of file names. Given a list of file names, it will return the list
of all having the given file extension. If file extenion is null or empty, all
filenames are returned. Returned list contains absolute filename paths.
Parameters:
nameList – ArrayList of String containing file names.
fileExtension – Only files with this extension will be added to the list.
If null or empty string, all files are added. Do NOT include “.” in extension.
Returns:
array list of matching file names (absolute path). If none, list is empty.
getFilenameList
public static ArrayList getFilenameList(ArrayList nameList,
ArrayList fileExtensions)
Return list of file names. Given a list of file names, it will return the list
of all having the given file extension. If file extenion is null or empty, all
filenames are returned. Returned list contains absolute filename paths.
Parameters:
nameList – ArrayList of String containing file names.
fileExtensions – ArrayList of Strings containing file extensions.
Only files with an extension in this list will be added
to the list. Do NOT include the “.” in extensions. If Arraylist or
extension null or empty, all files are added.
Returns:
array list of matching file names (absolute path). If none, list is empty.
getExtension
public static String getExtension(File file)
Get the filename extension of the specified File.
Parameters:
file – the File object representing the file of interest
Returns:
The filename extension (everything that follows
last ‘.’ in filename) or null if none.
getFileFilter
public static FileFilter getFileFilter(ArrayList extensions,
String description,
boolean acceptDirectories)
Get a FileFilter that will filter files based on the given list of filename extensions.
Parameters:
extensions – ArrayList of Strings, each string is acceptable filename extension.
description – String containing description to be added in parentheses after list of extensions.
acceptDirectories – boolean value true if directories are accepted by the filter, false otherwise.
Returns:
a FileFilter object that accepts files with given extensions, and directories if so indicated.
getFileFilter
public static FileFilter getFileFilter(ArrayList extensions,
String description)
Get a FileFilter that will filter files based on the given list of filename extensions.
All directories are accepted by the filter.
Parameters:
extensions – ArrayList of Strings, each string is acceptable filename extension
description – String containing description to be added in parentheses after list of extensions.
Returns:
a FileFilter object that accepts files with given extensions, and directories if so indicated.
getFileFilter
public static FileFilter getFileFilter(String extension,
String description,
boolean acceptDirectories)
Get a FileFilter that will filter files based on the given filename extension.
Parameters:
extension – String containing acceptable filename extension.
description – String containing description to be added in parentheses after list of extensions.
acceptDirectories – boolean value true if directories are accepted by the filter, false otherwise.
Returns:
a FileFilter object that accepts files with given extensions, and directories if so indicated.
getFileFilter
public static FileFilter getFileFilter(String extension,
String description)
Get a FileFilter that will filter files based on the given filename extension.
All directories are accepted by the filter.
Parameters:
extension – String containing acceptable filename extension
description – String containing description to be added in parentheses after list of extensions.
Returns:
a FileFilter object that accepts files with given extensions, and directories if so indicated.
fileExtensionMatch
public static boolean fileExtensionMatch(String name,
String extension)
Determine if given filename ends with given extension.
Parameters:
name – A String containing the file name
extension – A String containing the file extension. Leading period is optional.
Returns:
Returns true if filename ends with given extension, false otherwise.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.util
mars.util
Classes
Binary
EditorFont
FilenameFinder
MemoryDump
PropertiesFile
SystemIO
EditorFont
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.util
Class EditorFont
java.lang.Object
mars.util.EditorFont
public class EditorFont
extends Object
Specialized Font class designed to be used by both the
settings menu methods and the Settings class.
Author:
Pete Sanderson
Field Summary
static int DEFAULT_SIZE
static int DEFAULT_STYLE_INT
static String DEFAULT_STYLE_STRING
static int MAX_SIZE
static int MIN_SIZE
Constructor Summary
EditorFont()
Method Summary
static Font createFontFromStringValues(String family,
String style,
String size)
Creates a new Font object based on the given String specifications.
static String[] getAllFamilies()
Obtain an array of all available font family names.
static String[] getCommonFamilies()
Obtain an array of common font family names.
static String[] getFontStyleStrings()
Get array containing String values for font style names.
static String sizeIntToSizeString(int size)
Given an int representing font size, returns corresponding string.
static int sizeStringToSizeInt(String size)
Given a String representing font size, returns corresponding int.
static String styleIntToStyleString(int style)
Given an int that represents a font style from the Font class,
returns the corresponding String.
static int styleStringToStyleInt(String style)
Given a string that represents a font style, returns the
corresponding final int defined in Font: PLAIN, BOLD, ITALIC.
static String substituteSpacesForTabs(String string)
static String substituteSpacesForTabs(String string,
int tabSize)
Handy utility to produce a string that substitutes spaces for all tab characters
in the given string.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
DEFAULT_STYLE_STRING
public static final String DEFAULT_STYLE_STRING
DEFAULT_STYLE_INT
public static final int DEFAULT_STYLE_INT
MIN_SIZE
public static final int MIN_SIZE
See Also:
Constant Field Values
MAX_SIZE
public static final int MAX_SIZE
See Also:
Constant Field Values
DEFAULT_SIZE
public static final int DEFAULT_SIZE
See Also:
Constant Field Values
Constructor Detail
EditorFont
public EditorFont()
Method Detail
getCommonFamilies
public static String[] getCommonFamilies()
Obtain an array of common font family names. These are guaranteed to
be available at runtime, as they were checked against the local
GraphicsEnvironment.
Returns:
Array of strings, each is a common and available font family name.
getAllFamilies
public static String[] getAllFamilies()
Obtain an array of all available font family names. These are guaranteed to
be available at runtime, as they come from the local GraphicsEnvironment.
Returns:
Array of strings, each is an available font family name.
getFontStyleStrings
public static String[] getFontStyleStrings()
Get array containing String values for font style names.
styleStringToStyleInt
public static int styleStringToStyleInt(String style)
Given a string that represents a font style, returns the
corresponding final int defined in Font: PLAIN, BOLD, ITALIC. It
is not case-sensitive.
Parameters:
style – String representing the font style name
Returns:
The int value of the corresponding Font style constant. If the
string does not match any style name, returns Font.PLAIN.
styleIntToStyleString
public static String styleIntToStyleString(int style)
Given an int that represents a font style from the Font class,
returns the corresponding String.
Parameters:
style – Must be one of Font.PLAIN, Font.BOLD, Font.ITALIC.
Returns:
The String representation of that style. If the parameter
is not one of the above, returns “Plain”.
sizeIntToSizeString
public static String sizeIntToSizeString(int size)
Given an int representing font size, returns corresponding string.
Parameters:
size – Int representing size.
Returns:
String value of parameter, unless it is less than MIN_SIZE (returns MIN_SIZE
as String) or greater than MAX_SIZE (returns MAX_SIZE as String).
sizeStringToSizeInt
public static int sizeStringToSizeInt(String size)
Given a String representing font size, returns corresponding int.
Parameters:
size – String representing size.
Returns:
int value of parameter, unless it is less than MIN_SIZE (returns
MIN_SIZE) or greater than MAX_SIZE (returns MAX_SIZE). If the string
cannot be parsed as a decimal integer, it returns DEFAULT_SIZE.
createFontFromStringValues
public static Font createFontFromStringValues(String family,
String style,
String size)
Creates a new Font object based on the given String specifications. This
is different than Font’s constructor, which requires ints for style and size.
It assures that defaults and size limits are applied when necessary.
Parameters:
family – String containing font family.
style – String containing font style. A list of available styles can
be obtained from getFontStyleStrings(). The default of styleStringToStyleInt()
is substituted if necessary.
size – String containing font size. The defaults and limits of
sizeStringToSizeInt() are substituted if necessary.
substituteSpacesForTabs
public static String substituteSpacesForTabs(String string)
substituteSpacesForTabs
public static String substituteSpacesForTabs(String string,
int tabSize)
Handy utility to produce a string that substitutes spaces for all tab characters
in the given string. The number of spaces generated is based on the position of
the tab character and the specified tab size.
Parameters:
string – The original string
tabSize – The number of spaces each tab character represents
Returns:
New string in which spaces are substituted for tabs
Throws:
NullPointerException – if string is null
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.util
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.util
Class Summary
Binary Some utility methods for working with binary representations.
EditorFont Specialized Font class designed to be used by both the
settings menu methods and the Settings class.
FilenameFinder Utility class to perform necessary file-related search
operations.
MemoryDump
PropertiesFile Provides means to work with “.properties” files which are used to store
various MARS settings.
SystemIO Provides standard i/o services needed to simulate the MIPS syscall
routines.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
mars.util Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.util
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object mars.util.Binary
mars.util.EditorFont
mars.util.FilenameFinder
mars.util.MemoryDump
mars.util.PropertiesFile
mars.util.SystemIO
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
SystemIO
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.util
Class SystemIO
java.lang.Object
mars.util.SystemIO
public class SystemIO
extends Object
Provides standard i/o services needed to simulate the MIPS syscall
routines. These methods will detect whether the simulator is being
run from the command line or through the GUI, then do I/O to
System.in and System.out in the former situation, and interact with
the GUI in the latter.
Author:
Pete Sanderson and Ken Vollmar
Field Summary
static String fileErrorString
String used for description of file error
static int SYSCALL_BUFSIZE
Buffer size for syscalls for file I/O
static int SYSCALL_MAXFILES
Maximum number of files that can be open
Constructor Summary
SystemIO()
Method Summary
static void closeFile(int fd)
Close the file with specified file descriptor
static String getFileErrorMessage()
Retrieve file operation or error message
static int openFile(String filename,
int flags)
Open a file for either reading or writing.
static void printString(String string)
Implements syscall having 4 in $v0, to print a string.
static int readChar(int serviceNumber)
Implements syscall having 12 in $v0, to read a char value.
static double readDouble(int serviceNumber)
Implements syscall to read a double value.
static float readFloat(int serviceNumber)
Implements syscall to read a float value.
static int readFromFile(int fd,
byte[] myBuffer,
int lengthRequested)
Read bytes from file.
static int readInteger(int serviceNumber)
Implements syscall to read an integer value.
static String readString(int serviceNumber,
int maxLength)
Implements syscall to read a string.
static void resetFiles()
Reset all files — clears out the file descriptor table.
static int writeToFile(int fd,
byte[] myBuffer,
int lengthRequested)
Write bytes to file.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
SYSCALL_BUFSIZE
public static final int SYSCALL_BUFSIZE
Buffer size for syscalls for file I/O
See Also:
Constant Field Values
SYSCALL_MAXFILES
public static final int SYSCALL_MAXFILES
Maximum number of files that can be open
See Also:
Constant Field Values
fileErrorString
public static String fileErrorString
String used for description of file error
Constructor Detail
SystemIO
public SystemIO()
Method Detail
readInteger
public static int readInteger(int serviceNumber)
Implements syscall to read an integer value.
Client is responsible for catching NumberFormatException.
Parameters:
serviceNumber – the number assigned to Read Int syscall (default 5)
Returns:
int value corresponding to user input
readFloat
public static float readFloat(int serviceNumber)
Implements syscall to read a float value.
Client is responsible for catching NumberFormatException.
Parameters:
serviceNumber – the number assigned to Read Float syscall (default 6)
Returns:
float value corresponding to user input
Feb 14 2005 Ken Vollmar
readDouble
public static double readDouble(int serviceNumber)
Implements syscall to read a double value.
Client is responsible for catching NumberFormatException.
Parameters:
serviceNumber – the number assigned to Read Double syscall (default 7)
Returns:
double value corresponding to user input
1 Aug 2005 DPS, based on Ken Vollmar’s readFloat
printString
public static void printString(String string)
Implements syscall having 4 in $v0, to print a string.
readString
public static String readString(int serviceNumber,
int maxLength)
Implements syscall to read a string.
Parameters:
serviceNumber – the number assigned to Read String syscall (default 8)
maxLength – the maximum string length
Returns:
the entered string, truncated to maximum length if necessary
readChar
public static int readChar(int serviceNumber)
Implements syscall having 12 in $v0, to read a char value.
Parameters:
serviceNumber – the number assigned to Read Char syscall (default 12)
Returns:
int value with lowest byte corresponding to user input
writeToFile
public static int writeToFile(int fd,
byte[] myBuffer,
int lengthRequested)
Write bytes to file.
Parameters:
fd – file descriptor
myBuffer – byte array containing characters to write
lengthRequested – number of bytes to write
Returns:
number of bytes written, or -1 on error
readFromFile
public static int readFromFile(int fd,
byte[] myBuffer,
int lengthRequested)
Read bytes from file.
Parameters:
fd – file descriptor
myBuffer – byte array to contain bytes read
lengthRequested – number of bytes to read
Returns:
number of bytes read, 0 on EOF, or -1 on error
openFile
public static int openFile(String filename,
int flags)
Open a file for either reading or writing. Note that read/write flag is NOT
IMPLEMENTED. Also note that file permission modes are also NOT IMPLEMENTED.
Parameters:
filename – string containing filename
flag – 0 for read, 1 for write
Returns:
file descriptor in the range 0 to SYSCALL_MAXFILES-1, or -1 if error
closeFile
public static void closeFile(int fd)
Close the file with specified file descriptor
Parameters:
fd – the file descriptor of an open file
resetFiles
public static void resetFiles()
Reset all files — clears out the file descriptor table.
getFileErrorMessage
public static String getFileErrorMessage()
Retrieve file operation or error message
Returns:
string containing message
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MemoryDump
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.util
Class MemoryDump
java.lang.Object
mars.util.MemoryDump
public class MemoryDump
extends Object
Field Summary
static ArrayList dumpTriples
A list of segmentname/dumpformat/filename triples which should be dumped
Constructor Summary
MemoryDump()
Method Summary
static int getAddressOfFirstNull(int baseAddress,
int limitAddress)
Look for first “null” memory value in an address range.
static int[] getBaseAddresses(String[] segments)
Get the MIPS memory base address(es) of the specified segment name(s).
static int[] getLimitAddresses(String[] segments)
Get the MIPS memory limit address(es) of the specified segment name(s).
static Integer[] getSegmentBounds(String segment)
Return array with segment address bounds for specified segment.
static String[] getSegmentNames()
Get the names of segments available for memory dump.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
dumpTriples
public static ArrayList dumpTriples
A list of segmentname/dumpformat/filename triples which should be dumped
Constructor Detail
MemoryDump
public MemoryDump()
Method Detail
getSegmentBounds
public static Integer[] getSegmentBounds(String segment)
Return array with segment address bounds for specified segment.
Parameters:
segment – String with segment name (initially “.text” and “.data”)
Returns:
array of two Integer, the base and limit address for that segment. Null if parameter
name does not match a known segment name.
getSegmentNames
public static String[] getSegmentNames()
Get the names of segments available for memory dump.
Returns:
array of Strings, each string is segment name (e.g. “.text”, “.data”)
getBaseAddresses
public static int[] getBaseAddresses(String[] segments)
Get the MIPS memory base address(es) of the specified segment name(s).
If invalid segment name is provided, will throw NullPointerException, so
I recommend getting segment names from getSegmentNames().
Parameters:
segments – Array of Strings containing segment names (“.text”, “.data”)
Returns:
Array of int containing corresponding base addresses.
getLimitAddresses
public static int[] getLimitAddresses(String[] segments)
Get the MIPS memory limit address(es) of the specified segment name(s).
If invalid segment name is provided, will throw NullPointerException, so
I recommend getting segment names from getSegmentNames().
Parameters:
segments – Array of Strings containing segment names (“.text”, “.data”)
Returns:
Array of int containing corresponding limit addresses.
getAddressOfFirstNull
public static int getAddressOfFirstNull(int baseAddress,
int limitAddress)
throws AddressErrorException
Look for first “null” memory value in an address range. For text segment (binary code), this
represents a word that does not contain an instruction. Normally use this to find the end of
the program. For data segment, this represents the first block of simulated memory (block length
currently 4K words) that has not been referenced by an assembled/executing program.
Parameters:
baseAddress – lowest MIPS address to be searched; the starting point
limitAddress – highest MIPS address to be searched
Returns:
lowest address within specified range that contains “null” value as described above.
Throws:
AddressErrorException – if the base address is not on a word boundary
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MarsSplashScreen
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
Class MarsSplashScreen
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
javax.swing.JWindow
mars.MarsSplashScreen
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, RootPaneContainer
public class MarsSplashScreen
extends JWindow
Produces MARS splash screen.
Adapted from http://www.java-tips.org/content/view/1267/2/
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JWindow
JWindow.AccessibleJWindow
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JWindow
accessibleContext, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
MarsSplashScreen(int d)
Method Summary
void showSplash()
A simple little method to show a title screen in the center
of the screen for the amount of time given in the constructor
Methods inherited from class javax.swing.JWindow
addImpl, createRootPane, getAccessibleContext, getContentPane, getGlassPane, getGraphics, getLayeredPane, getRootPane, getTransferHandler, isRootPaneCheckingEnabled, paramString, remove, repaint, setContentPane, setGlassPane, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update, windowInit
Methods inherited from class java.awt.Window
addNotify, addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowEvent, processWindowFocusEvent, processWindowStateEvent, removeNotify, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImage, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
MarsSplashScreen
public MarsSplashScreen(int d)
Method Detail
showSplash
public void showSplash()
A simple little method to show a title screen in the center
of the screen for the amount of time given in the constructor
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FileStatus
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FileStatus
java.lang.Object
mars.venus.FileStatus
public class FileStatus
extends Object
Used to store and return information on the status of the current ASM file that
is being edited in the program.
Author:
Team JSpim
Field Summary
static int EDITED
open/saved edit window with unsaved edits
static int NEW_EDITED
New edit window with unsaved edits
static int NEW_NOT_EDITED
New edit window with no edits
static int NO_FILE
initial state or after close
static int NOT_EDITED
open/saved edit window with no edits
static int OPENING
file is being opened.
static int RUNNABLE
successful assembly
static int RUNNING
execution is under way
static int TERMINATED
execution terminated
Constructor Summary
FileStatus()
Create a FileStatus object with FileStatis.NO_FILE for status and null for file getters.
FileStatus(int status,
String pathname)
Create a FileStatus object with given status and file pathname.
Method Summary
static int get()
Get file status
static File getFile()
Returns the ASM file.
String getFilename()
Get file name with no path information.
int getFileStatus()
Get editing status of this file.
static String getName()
Returns the name of the file.
String getParent()
Get file parent pathname.
String getPathname()
Get full file pathname.
boolean hasUnsavedEdits()
Determine if file has been modified since last save or, if not yet saved, since
being created using New or Open.
static boolean isAssembled()
Tells whether the file has been assembled.
static boolean isEdited()
Tells whether the file has been edited since it has been saved.
boolean isNew()
Determine if file is “new”, which means created using New but not yet saved.
static boolean isSaved()
Tells whether the file has been saved.
static void reset()
Resets all the values in FileStatus
static void set(int newStatus)
Set file status.
static void setAssembled(boolean b)
Changes the value of assenbked to the parameter given.
static void setEdited(boolean b)
Changes the value of edited to the parameter given.
static void setFile(File f)
Sets the file to the ASM file passed.
void setFileStatus(int newStatus)
Set editing status of this file.
static void setName(String s)
Changes the value of name to the parameter given.
void setPathname(String newPath)
Set full file pathname.
void setPathname(String parent,
String name)
Set full file pathname.
static void setSaved(boolean b)
Changes the value of saved to the parameter given.
void updateStaticFileStatus()
Update static FileStatus fields with values from this FileStatus object
To support legacy code that depends on the static.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
NO_FILE
public static final int NO_FILE
initial state or after close
See Also:
Constant Field Values
NEW_NOT_EDITED
public static final int NEW_NOT_EDITED
New edit window with no edits
See Also:
Constant Field Values
NEW_EDITED
public static final int NEW_EDITED
New edit window with unsaved edits
See Also:
Constant Field Values
NOT_EDITED
public static final int NOT_EDITED
open/saved edit window with no edits
See Also:
Constant Field Values
EDITED
public static final int EDITED
open/saved edit window with unsaved edits
See Also:
Constant Field Values
RUNNABLE
public static final int RUNNABLE
successful assembly
See Also:
Constant Field Values
RUNNING
public static final int RUNNING
execution is under way
See Also:
Constant Field Values
TERMINATED
public static final int TERMINATED
execution terminated
See Also:
Constant Field Values
OPENING
public static final int OPENING
file is being opened. DPS 9-Aug-2011
See Also:
Constant Field Values
Constructor Detail
FileStatus
public FileStatus()
Create a FileStatus object with FileStatis.NO_FILE for status and null for file getters.
FileStatus
public FileStatus(int status,
String pathname)
Create a FileStatus object with given status and file pathname.
Parameters:
status – Initial file status. See FileStatus static constants.
pathname – Full file pathname. See setPathname(String newPath) below.
Method Detail
set
public static void set(int newStatus)
Set file status. Also updates menu state accordingly.
Parameters:
newStatus – New status: EDITED, RUNNABLE, etc, see list above.
get
public static int get()
Get file status
Returns:
file status EDITED, RUNNABLE, etc, see list above
setAssembled
public static void setAssembled(boolean b)
Changes the value of assenbked to the parameter given.
Parameters:
b – boolean variable that tells what to set assembled to.
setSaved
public static void setSaved(boolean b)
Changes the value of saved to the parameter given.
Parameters:
b – boolean variable that tells what to set saved to .
setEdited
public static void setEdited(boolean b)
Changes the value of edited to the parameter given.
Parameters:
b – boolean variable that tells what to set edited to.
setName
public static void setName(String s)
Changes the value of name to the parameter given.
Parameters:
s – string variable tells what to set the name of the file to .
setFile
public static void setFile(File f)
Sets the file to the ASM file passed.
Parameters:
f – file object variable that stores the ASM file.
getFile
public static File getFile()
Returns the ASM file.
Returns:
The ASM file.
getName
public static String getName()
Returns the name of the file.
Returns:
The name of the ASM file.
isAssembled
public static boolean isAssembled()
Tells whether the file has been assembled.
Returns:
Boolean value that is true if the ASM file has been assembled.
isSaved
public static boolean isSaved()
Tells whether the file has been saved.
Returns:
Boolean variable that is true if the ASM file has been saved
isEdited
public static boolean isEdited()
Tells whether the file has been edited since it has been saved.
Returns:
Boolean value that returns true if the ASM file has been edited.
reset
public static void reset()
Resets all the values in FileStatus
setFileStatus
public void setFileStatus(int newStatus)
Set editing status of this file. See FileStatus static constants.
Parameters:
newStatus – the new status
getFileStatus
public int getFileStatus()
Get editing status of this file.
Returns:
current editing status. See FileStatus static constants.
isNew
public boolean isNew()
Determine if file is “new”, which means created using New but not yet saved.
If created using Open, it is not new.
Returns:
true if file was created using New and has not yet been saved, false otherwise.
hasUnsavedEdits
public boolean hasUnsavedEdits()
Determine if file has been modified since last save or, if not yet saved, since
being created using New or Open.
Returns:
true if file has been modified since save or creation, false otherwise.
setPathname
public void setPathname(String newPath)
Set full file pathname. See java.io.File(String pathname) for parameter specs.
Parameters:
newPath – the new pathname. If no directory path, getParent() will return null.
setPathname
public void setPathname(String parent,
String name)
Set full file pathname. See java.io.File(String parent, String child) for parameter specs.
Parameters:
parent – the parent directory of the file. If null, getParent() will return null.
name – the name of the file (no directory path)
getPathname
public String getPathname()
Get full file pathname. See java.io.File.getPath()
Returns:
full pathname as a String. Null if
getFilename
public String getFilename()
Get file name with no path information. See java.io.File.getName()
Returns:
filename as a String
getParent
public String getParent()
Get file parent pathname. See java.io.File.getParent()
Returns:
parent full pathname as a String
updateStaticFileStatus
public void updateStaticFileStatus()
Update static FileStatus fields with values from this FileStatus object
To support legacy code that depends on the static.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsAssembleAllAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsAssembleAllAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsAssembleAllAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsAssembleAllAction
extends GuiAction
Action class for the Settings menu item to determine whether assemble operation applies
only to current file or to all files in its directory.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsAssembleAllAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsAssembleAllAction
public SettingsAssembleAllAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FilePrintAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FilePrintAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.FilePrintAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class FilePrintAction
extends GuiAction
Action for the File -> Print menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
FilePrintAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
Uses the HardcopyWriter class developed by David Flanagan for the book
“Java Examples in a Nutshell”.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
FilePrintAction
public FilePrintAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Uses the HardcopyWriter class developed by David Flanagan for the book
“Java Examples in a Nutshell”. It will do basic printing of multipage
text documents. It displays a print dialog but does not act on any
changes the user may have specified there, such as number of copies.
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Parameters:
e – component triggering this call
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FileExitAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FileExitAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.FileExitAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class FileExitAction
extends GuiAction
Action for the File -> Exit menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
FileExitAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
Exit MARS, unless one or more files have unsaved edits and user cancels.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
FileExitAction
public FileExitAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Exit MARS, unless one or more files have unsaved edits and user cancels.
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
EditSelectAllAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class EditSelectAllAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.EditSelectAllAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class EditSelectAllAction
extends GuiAction
Action for the Edit -> Copy menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
EditSelectAllAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
EditSelectAllAction
public EditSelectAllAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RunToggleBreakpointsAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RunToggleBreakpointsAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.RunToggleBreakpointsAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class RunToggleBreakpointsAction
extends GuiAction
Action class for the Run menu item to clear execution breakpoints that have been set.
It is a listener and is notified whenever a breakpoint is added or removed, thus will
set its enabled status true or false depending on whether breakpoints remain after that action.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
RunToggleBreakpointsAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Create the object and register with text segment window as a listener on its table model.
Method Summary
void actionPerformed(ActionEvent e)
When this option is selected, tell text segment window to clear breakpoints in its table model.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
RunToggleBreakpointsAction
public RunToggleBreakpointsAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Create the object and register with text segment window as a listener on its table model.
The table model has not been created yet, so text segment window will hang onto this
registration info and transfer it to the table model upon creation (which happens with
each successful assembly).
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
When this option is selected, tell text segment window to clear breakpoints in its table model.
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
HelpAboutAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class HelpAboutAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.HelpAboutAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class HelpAboutAction
extends GuiAction
Action for the Help -> About menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
HelpAboutAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
HelpAboutAction
public HelpAboutAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
TextSegmentWindow
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class TextSegmentWindow
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JInternalFrame
mars.venus.TextSegmentWindow
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants
public class TextSegmentWindow
extends JInternalFrame
implements Observer
Creates the Text Segment window in the Execute tab of the UI
Author:
Team JSpim
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JInternalFrame
JInternalFrame.AccessibleJInternalFrame, JInternalFrame.JDesktopIcon
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JInternalFrame
closable, CONTENT_PANE_PROPERTY, desktopIcon, FRAME_ICON_PROPERTY, frameIcon, GLASS_PANE_PROPERTY, iconable, IS_CLOSED_PROPERTY, IS_ICON_PROPERTY, IS_MAXIMUM_PROPERTY, IS_SELECTED_PROPERTY, isClosed, isIcon, isMaximum, isSelected, LAYERED_PANE_PROPERTY, maximizable, MENU_BAR_PROPERTY, resizable, ROOT_PANE_PROPERTY, rootPane, rootPaneCheckingEnabled, title, TITLE_PROPERTY
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, EXIT_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
TextSegmentWindow()
Constructor, sets up a new JInternalFrame.
Method Summary
void addProgramArgumentsPanel()
void clearAllBreakpoints()
Clears all breakpoints that have been set since last assemble, and
updates the display of the breakpoint column.
void clearWindow()
remove all components
int getBreakpointCount()
Returns number of breakpoints currently set.
boolean getCodeHighlighting()
Get code highlighting status.
String getProgramArguments()
Get program arguments from text field in south border of text segment window.
int[] getSortedBreakPointsArray()
Returns array of current breakpoints, each represented by a MIPS program counter address.
void highlightStepAtAddress(int address)
Highlights the source code line whose address matches the given
text segment address.
void highlightStepAtAddress(int address,
boolean inDelaySlot)
Highlights the source code line whose address matches the given
text segment address.
void highlightStepAtPC()
Highlights the source code line whose address matches the current
program counter value.
void highlightStepAtPC(boolean inDelaySlot)
Highlights the source code line whose address matches the current
program counter value.
void registerTableModelListener(TableModelListener tml)
Assign listener to Table model.
void removeProgramArgumentsPanel()
void setCodeHighlighting(boolean highlightSetting)
Used to enable or disable source code highlighting.
void setupTable()
Method to be called once the user compiles the program.
void toggleBreakpoints()
Enable or disable all items in the Breakpoints column.
void unhighlightAllSteps()
If any steps are highlighted, this erases the highlighting.
void update(Observable observable,
Object obj)
Required by Observer interface.
void updateBasicStatements()
Redisplay the basic statements.
void updateCodeAddresses()
Redisplay the addresses.
Methods inherited from class javax.swing.JInternalFrame
addImpl, addInternalFrameListener, createRootPane, dispose, doDefaultCloseAction, fireInternalFrameEvent, getAccessibleContext, getContentPane, getDefaultCloseOperation, getDesktopIcon, getDesktopPane, getFocusCycleRootAncestor, getFocusOwner, getFrameIcon, getGlassPane, getInternalFrameListeners, getJMenuBar, getLastCursor, getLayer, getLayeredPane, getMenuBar, getMostRecentFocusOwner, getNormalBounds, getRootPane, getTitle, getUI, getUIClassID, getWarningString, hide, isClosable, isClosed, isFocusCycleRoot, isIcon, isIconifiable, isMaximizable, isMaximum, isResizable, isRootPaneCheckingEnabled, isSelected, moveToBack, moveToFront, pack, paintComponent, paramString, remove, removeInternalFrameListener, reshape, restoreSubcomponentFocus, setClosable, setClosed, setContentPane, setCursor, setDefaultCloseOperation, setDesktopIcon, setFocusCycleRoot, setFrameIcon, setGlassPane, setIcon, setIconifiable, setJMenuBar, setLayer, setLayer, setLayeredPane, setLayout, setMaximizable, setMaximum, setMenuBar, setNormalBounds, setResizable, setRootPane, setRootPaneCheckingEnabled, setSelected, setTitle, setUI, show, toBack, toFront, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
TextSegmentWindow
public TextSegmentWindow()
Constructor, sets up a new JInternalFrame.
Method Detail
setupTable
public void setupTable()
Method to be called once the user compiles the program.
Should convert the lines of code over to the table rows and columns.
getProgramArguments
public String getProgramArguments()
Get program arguments from text field in south border of text segment window.
Returns:
String containing program arguments
addProgramArgumentsPanel
public void addProgramArgumentsPanel()
removeProgramArgumentsPanel
public void removeProgramArgumentsPanel()
clearWindow
public void clearWindow()
remove all components
registerTableModelListener
public void registerTableModelListener(TableModelListener tml)
Assign listener to Table model. Used for breakpoints, since that is the only editable
column in the table. Since table model objects are transient (get a new one with each
successful assemble), this method will simply keep the identity of the listener then
add it as a listener each time a new table model object is created. Limit 1 listener.
updateCodeAddresses
public void updateCodeAddresses()
Redisplay the addresses. This should only be done when address display base is
modified (e.g. between base 16 hex and base 10 dec).
updateBasicStatements
public void updateBasicStatements()
Redisplay the basic statements. This should only be done when address or value display base is
modified (e.g. between base 16 hex and base 10 dec).
update
public void update(Observable observable,
Object obj)
Required by Observer interface. Called when notified by an Observable that we are registered with.
The Observable here is a delegate of the Memory object, which lets us know of memory operations.
More precisely, memory operations only in the text segment, since that is the only range of
addresses we’re registered for. And we’re only interested in write operations.
Specified by:
update in interface Observer
Parameters:
observable – The Observable object who is notifying us
obj – Auxiliary object with additional information.
getBreakpointCount
public int getBreakpointCount()
Returns number of breakpoints currently set.
Returns:
number of current breakpoints
getSortedBreakPointsArray
public int[] getSortedBreakPointsArray()
Returns array of current breakpoints, each represented by a MIPS program counter address.
These are stored in the BREAK_COLUMN of the table model.
Returns:
int array of breakpoints, sorted by PC address, or null if there are none.
clearAllBreakpoints
public void clearAllBreakpoints()
Clears all breakpoints that have been set since last assemble, and
updates the display of the breakpoint column.
highlightStepAtPC
public void highlightStepAtPC()
Highlights the source code line whose address matches the current
program counter value. This is used for stepping through code
execution and when reaching breakpoints.
highlightStepAtPC
public void highlightStepAtPC(boolean inDelaySlot)
Highlights the source code line whose address matches the current
program counter value. This is used for stepping through code
execution and when reaching breakpoints.
Parameters:
inDelaySlot – Set true if delayed branching is enabled and the
instruction at this address is executing in the delay slot, false
otherwise.
highlightStepAtAddress
public void highlightStepAtAddress(int address)
Highlights the source code line whose address matches the given
text segment address.
Parameters:
address – text segment address of instruction to be highlighted.
highlightStepAtAddress
public void highlightStepAtAddress(int address,
boolean inDelaySlot)
Highlights the source code line whose address matches the given
text segment address.
Parameters:
address – Text segment address of instruction to be highlighted.
inDelaySlot – Set true if delayed branching is enabled and the
instruction at this address is executing in the delay slot, false
otherwise.
setCodeHighlighting
public void setCodeHighlighting(boolean highlightSetting)
Used to enable or disable source code highlighting. If true (normally while
stepping through execution) then MIPS statement at current program counter
is highlighted. The code column’s cell renderer tests this variable.
Parameters:
highlightSetting – true to enable highlighting, false to disable.
getCodeHighlighting
public boolean getCodeHighlighting()
Get code highlighting status.
Returns:
true if code highlighting currently enabled, false otherwise.
unhighlightAllSteps
public void unhighlightAllSteps()
If any steps are highlighted, this erases the highlighting.
toggleBreakpoints
public void toggleBreakpoints()
Enable or disable all items in the Breakpoints column.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RunGoAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RunGoAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.RunGoAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class RunGoAction
extends GuiAction
Action class for the Run -> Go menu item (and toolbar icon)
See Also:
Serialized Form
Field Summary
static int defaultMaxSteps
static int maxSteps
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
RunGoAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
Action to take when GO is selected — run the MIPS program!
void paused(boolean done,
int pauseReason,
ProcessingException pe)
Method to be called when Pause is selected through menu/toolbar/shortcut.
static void resetMaxSteps()
Reset max steps limit to default value at termination of a simulated execution.
void stopped(ProcessingException pe,
int reason)
Method to be called when Stop is selected through menu/toolbar/shortcut.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
defaultMaxSteps
public static int defaultMaxSteps
maxSteps
public static int maxSteps
Constructor Detail
RunGoAction
public RunGoAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Action to take when GO is selected — run the MIPS program!
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
paused
public void paused(boolean done,
int pauseReason,
ProcessingException pe)
Method to be called when Pause is selected through menu/toolbar/shortcut. This should only
happen when MIPS program is running (FileStatus.RUNNING). See VenusUI.java for enabled
status of menu items based on FileStatus. Set GUI as if at breakpoint or executing
step by step.
stopped
public void stopped(ProcessingException pe,
int reason)
Method to be called when Stop is selected through menu/toolbar/shortcut. This should only
happen when MIPS program is running (FileStatus.RUNNING). See VenusUI.java for enabled
status of menu items based on FileStatus. Display finalized values as if execution
terminated due to completion or exception.
resetMaxSteps
public static void resetMaxSteps()
Reset max steps limit to default value at termination of a simulated execution.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
ToolAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class ToolAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.ToolAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class ToolAction
extends AbstractAction
Connects a MarsTool class (class that implements MarsTool interface) to
the Mars menu system by supplying the response to that tool’s menu item
selection.
Author:
Pete Sanderson
See Also:
Serialized Form
Field Summary
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
ToolAction(Class toolClass,
String toolName)
Simple constructor.
Method Summary
void actionPerformed(ActionEvent e)
Response when tool’s item selected from menu.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
ToolAction
public ToolAction(Class toolClass,
String toolName)
Simple constructor.
Parameters:
toolClass – Class object for the associated MarsTool subclass
toolName – Name of this tool, for the menu.
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Response when tool’s item selected from menu. Invokes tool’s action() method.
Parameters:
e – the ActionEvent that triggered this call
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Coprocessor1Window
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class Coprocessor1Window
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
mars.venus.Coprocessor1Window
All Implemented Interfaces:
ActionListener, ImageObserver, MenuContainer, Serializable, EventListener, Observer, Accessible
public class Coprocessor1Window
extends JPanel
implements ActionListener, Observer
Sets up a window to display Coprocessor 1 registers in the Registers pane of the UI.
Author:
Pete Sanderson 2005
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
Coprocessor1Window()
Constructor which sets up a fresh window with a table that contains the register values.
Method Summary
void actionPerformed(ActionEvent e)
Called when user clicks on a condition flag checkbox.
void clearHighlighting()
Clear highlight background color from any row currently highlighted.
void clearWindow()
Reset and redisplay registers.
void refresh()
Refresh the table, triggering re-rendering.
Object[][] setupWindow()
Sets up the data for the window.
void update(Observable observable,
Object obj)
Required by Observer interface.
void updateDoubleRegisterValue(int number,
int base)
This method handles the updating of the GUI.
void updateFloatRegisterValue(int number,
int val,
int base)
This method handles the updating of the GUI.
void updateRegisters()
Redisplay registers using current display number base (10 or 16)
void updateRegisters(int base)
Redisplay registers using specified display number base (10 or 16)
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
Coprocessor1Window
public Coprocessor1Window()
Constructor which sets up a fresh window with a table that contains the register values.
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Called when user clicks on a condition flag checkbox.
Updates both the display and the underlying Coprocessor 1 flag.
Specified by:
actionPerformed in interface ActionListener
Parameters:
e – component that triggered this call
setupWindow
public Object[][] setupWindow()
Sets up the data for the window.
Returns:
The array object with the data for the window.
clearWindow
public void clearWindow()
Reset and redisplay registers.
clearHighlighting
public void clearHighlighting()
Clear highlight background color from any row currently highlighted.
refresh
public void refresh()
Refresh the table, triggering re-rendering.
updateRegisters
public void updateRegisters()
Redisplay registers using current display number base (10 or 16)
updateRegisters
public void updateRegisters(int base)
Redisplay registers using specified display number base (10 or 16)
Parameters:
base – number base for display (10 or 16)
updateFloatRegisterValue
public void updateFloatRegisterValue(int number,
int val,
int base)
This method handles the updating of the GUI. Does not affect actual register.
Parameters:
number – The number of the float register whose display to update.
val – New value.
base – the number base for display (e.g. 10, 16)
updateDoubleRegisterValue
public void updateDoubleRegisterValue(int number,
int base)
This method handles the updating of the GUI. Does not affect actual register.
Parameters:
number – The number of the double register to update.
base – the number base for display (e.g. 10, 16)
update
public void update(Observable observable,
Object obj)
Required by Observer interface. Called when notified by an Observable that we are registered with.
Observables include:
The Simulator object, which lets us know when it starts and stops running
A register object, which lets us know of register operations
The Simulator keeps us informed of when simulated MIPS execution is active.
This is the only time we care about register operations.
Specified by:
update in interface Observer
Parameters:
observable – The Observable object who is notifying us
obj – Auxiliary object with additional information.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DataSegmentWindow
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class DataSegmentWindow
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JInternalFrame
mars.venus.DataSegmentWindow
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible, RootPaneContainer, WindowConstants
public class DataSegmentWindow
extends JInternalFrame
implements Observer
Represents the Data Segment window, which is a type of JInternalFrame.
Author:
Sanderson and Bumgarner
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JInternalFrame
JInternalFrame.AccessibleJInternalFrame, JInternalFrame.JDesktopIcon
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JInternalFrame
closable, CONTENT_PANE_PROPERTY, desktopIcon, FRAME_ICON_PROPERTY, frameIcon, GLASS_PANE_PROPERTY, iconable, IS_CLOSED_PROPERTY, IS_ICON_PROPERTY, IS_MAXIMUM_PROPERTY, IS_SELECTED_PROPERTY, isClosed, isIcon, isMaximum, isSelected, LAYERED_PANE_PROPERTY, maximizable, MENU_BAR_PROPERTY, resizable, ROOT_PANE_PROPERTY, rootPane, rootPaneCheckingEnabled, title, TITLE_PROPERTY
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, EXIT_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
DataSegmentWindow(NumberDisplayBaseChooser[] choosers)
Constructor for the Data Segment window.
Method Summary
void clearHighlighting()
Clear highlight background color from any cell currently highlighted.
void clearWindow()
Removes the table from its frame, typically done when a file is closed.
void resetMemoryRange()
Reset range of memory addresses to base address of currently selected segment and update display.
void resetValues()
Reset all data display values to 0
void setupTable()
Generates and displays fresh table, typically done upon successful assembly.
void update(Observable observable,
Object obj)
Required by Observer interface.
void updateBaseAddressComboBox()
void updateCell(int address,
int value)
Update data display to show this value (I’m not sure it is being called).
void updateDataAddresses()
Redisplay the addresses.
void updateModelForMemoryRange(int firstAddr)
Update table model with contents of new memory “chunk”.
void updateValues()
Update data display to show all values
Methods inherited from class javax.swing.JInternalFrame
addImpl, addInternalFrameListener, createRootPane, dispose, doDefaultCloseAction, fireInternalFrameEvent, getAccessibleContext, getContentPane, getDefaultCloseOperation, getDesktopIcon, getDesktopPane, getFocusCycleRootAncestor, getFocusOwner, getFrameIcon, getGlassPane, getInternalFrameListeners, getJMenuBar, getLastCursor, getLayer, getLayeredPane, getMenuBar, getMostRecentFocusOwner, getNormalBounds, getRootPane, getTitle, getUI, getUIClassID, getWarningString, hide, isClosable, isClosed, isFocusCycleRoot, isIcon, isIconifiable, isMaximizable, isMaximum, isResizable, isRootPaneCheckingEnabled, isSelected, moveToBack, moveToFront, pack, paintComponent, paramString, remove, removeInternalFrameListener, reshape, restoreSubcomponentFocus, setClosable, setClosed, setContentPane, setCursor, setDefaultCloseOperation, setDesktopIcon, setFocusCycleRoot, setFrameIcon, setGlassPane, setIcon, setIconifiable, setJMenuBar, setLayer, setLayer, setLayeredPane, setLayout, setMaximizable, setMaximum, setMenuBar, setNormalBounds, setResizable, setRootPane, setRootPaneCheckingEnabled, setSelected, setTitle, setUI, show, toBack, toFront, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
DataSegmentWindow
public DataSegmentWindow(NumberDisplayBaseChooser[] choosers)
Constructor for the Data Segment window.
Parameters:
choosers – an array of objects used by user to select number display base (10 or 16)
Method Detail
updateBaseAddressComboBox
public void updateBaseAddressComboBox()
setupTable
public void setupTable()
Generates and displays fresh table, typically done upon successful assembly.
clearWindow
public void clearWindow()
Removes the table from its frame, typically done when a file is closed.
clearHighlighting
public void clearHighlighting()
Clear highlight background color from any cell currently highlighted.
updateModelForMemoryRange
public void updateModelForMemoryRange(int firstAddr)
Update table model with contents of new memory “chunk”. Mars supports megabytes of
data segment space so we only plug a “chunk” at a time into the table.
Parameters:
firstAddr – the first address in the memory range to be placed in the model.
updateCell
public void updateCell(int address,
int value)
Update data display to show this value (I’m not sure it is being called).
updateDataAddresses
public void updateDataAddresses()
Redisplay the addresses. This should only be done when address display base is
modified (e.g. between base 16, hex, and base 10, dec).
updateValues
public void updateValues()
Update data display to show all values
resetMemoryRange
public void resetMemoryRange()
Reset range of memory addresses to base address of currently selected segment and update display.
resetValues
public void resetValues()
Reset all data display values to 0
update
public void update(Observable observable,
Object obj)
Required by Observer interface. Called when notified by an Observable that we are registered with.
Observables include:
The Simulator object, which lets us know when it starts and stops running
A delegate of the Memory object, which lets us know of memory operations
The Simulator keeps us informed of when simulated MIPS execution is active.
This is the only time we care about memory operations.
Specified by:
update in interface Observer
Parameters:
observable – The Observable object who is notifying us
obj – Auxiliary object with additional information.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FileNewAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FileNewAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.FileNewAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class FileNewAction
extends GuiAction
Action for the File -> New menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
FileNewAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
Code to create a new document.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
FileNewAction
public FileNewAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Code to create a new document. It clears the source code window.
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Parameters:
e – component triggering this call
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RunAssembleAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RunAssembleAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.RunAssembleAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class RunAssembleAction
extends GuiAction
Action class for the Run -> Assemble menu item (and toolbar icon)
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
RunAssembleAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
RunAssembleAction
public RunAssembleAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
EditRedoAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class EditRedoAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.EditRedoAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class EditRedoAction
extends GuiAction
Action for the Edit -> Redo menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
EditRedoAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
Adapted from TextComponentDemo.java in the
Java Tutorial “Text Component Features”
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
EditRedoAction
public EditRedoAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Adapted from TextComponentDemo.java in the
Java Tutorial “Text Component Features”
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsStartAtMainAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsStartAtMainAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsStartAtMainAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsStartAtMainAction
extends GuiAction
Action class for the Settings menu item to control whether or not
assembler warnings are considered errors. If so, a program generating
warnings but not errors will not assemble.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsStartAtMainAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsStartAtMainAction
public SettingsStartAtMainAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
EditTabbedPane
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class EditTabbedPane
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JTabbedPane
mars.venus.EditTabbedPane
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, SwingConstants
public class EditTabbedPane
extends JTabbedPane
Tabbed pane for the editor. Each of its tabs represents an open file.
Author:
Sanderson
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JTabbedPane
JTabbedPane.AccessibleJTabbedPane, JTabbedPane.ModelListener
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JTabbedPane
changeEvent, changeListener, model, SCROLL_TAB_LAYOUT, tabPlacement, WRAP_TAB_LAYOUT
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
EditTabbedPane(VenusUI appFrame,
Editor editor,
MainPane mainPane)
Constructor for the EditTabbedPane class.
Method Summary
boolean closeAllFiles()
Carries out all necessary operations to implement
the Close All operation from the File menu.
boolean closeCurrentFile()
Carries out all necessary operations to implement
the Close operation from the File menu.
boolean editsSavedOrAbandoned()
Check whether file has unsaved edits and, if so, check with user about saving them.
EditPane getCurrentEditTab()
The current EditPane representing a file.
EditPane getCurrentEditTabForFile(File file)
If the given file is open in the tabbed pane, make it the
current tab.
EditPane getEditPaneForFile(String pathname)
If there is an EditPane for the given file pathname, return it else return null.
void newFile()
Carries out all necessary operations to implement
the New operation from the File menu.
boolean openFile()
Carries out all necessary operations to implement
the Open operation from the File menu.
boolean openFile(File file)
Carries out all necessary operations to open the
specified file in the editor.
void remove(EditPane editPane)
Remove the pane and update menu status
boolean saveAllFiles()
Saves all files currently open in the editor.
boolean saveAsCurrentFile()
Pops up a dialog box to do “Save As” operation.
boolean saveCurrentFile()
Saves file under existing name.
void setCurrentEditTab(EditPane editPane)
Select the specified EditPane to be the current tab.
Methods inherited from class javax.swing.JTabbedPane
add, add, add, add, add, addChangeListener, addTab, addTab, addTab, createChangeListener, fireStateChanged, getAccessibleContext, getBackgroundAt, getBoundsAt, getChangeListeners, getComponentAt, getDisabledIconAt, getDisplayedMnemonicIndexAt, getForegroundAt, getIconAt, getMnemonicAt, getModel, getSelectedComponent, getSelectedIndex, getTabComponentAt, getTabCount, getTabLayoutPolicy, getTabPlacement, getTabRunCount, getTitleAt, getToolTipText, getToolTipTextAt, getUI, getUIClassID, indexAtLocation, indexOfComponent, indexOfTab, indexOfTab, indexOfTabComponent, insertTab, isEnabledAt, paramString, remove, remove, removeAll, removeChangeListener, removeTabAt, setBackgroundAt, setComponentAt, setDisabledIconAt, setDisplayedMnemonicIndexAt, setEnabledAt, setForegroundAt, setIconAt, setMnemonicAt, setModel, setSelectedComponent, setSelectedIndex, setTabComponentAt, setTabLayoutPolicy, setTabPlacement, setTitleAt, setToolTipTextAt, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
EditTabbedPane
public EditTabbedPane(VenusUI appFrame,
Editor editor,
MainPane mainPane)
Constructor for the EditTabbedPane class.
Method Detail
getCurrentEditTab
public EditPane getCurrentEditTab()
The current EditPane representing a file. Returns null if
no files open.
Returns:
the current editor pane
setCurrentEditTab
public void setCurrentEditTab(EditPane editPane)
Select the specified EditPane to be the current tab.
Parameters:
editPane – The EditPane tab to become current.
getCurrentEditTabForFile
public EditPane getCurrentEditTabForFile(File file)
If the given file is open in the tabbed pane, make it the
current tab. If not opened, open it in a new tab and make
it the current tab. If file is unable to be opened,
leave current tab as is.
Parameters:
file – File object for the desired file.
Returns:
EditPane for the specified file, or null if file is unable to be opened in an EditPane
newFile
public void newFile()
Carries out all necessary operations to implement
the New operation from the File menu.
openFile
public boolean openFile()
Carries out all necessary operations to implement
the Open operation from the File menu. This
begins with an Open File dialog.
Returns:
true if file was opened, false otherwise.
openFile
public boolean openFile(File file)
Carries out all necessary operations to open the
specified file in the editor.
Returns:
true if file was opened, false otherwise.
closeCurrentFile
public boolean closeCurrentFile()
Carries out all necessary operations to implement
the Close operation from the File menu. May return
false, for instance when file has unsaved changes
and user selects Cancel from the warning dialog.
Returns:
true if file was closed, false otherwise.
closeAllFiles
public boolean closeAllFiles()
Carries out all necessary operations to implement
the Close All operation from the File menu.
Returns:
true if files closed, false otherwise.
saveCurrentFile
public boolean saveCurrentFile()
Saves file under existing name. If no name, will invoke Save As.
Returns:
true if the file was actually saved.
saveAsCurrentFile
public boolean saveAsCurrentFile()
Pops up a dialog box to do “Save As” operation. If necessary
an additional overwrite dialog is performed.
Returns:
true if the file was actually saved.
saveAllFiles
public boolean saveAllFiles()
Saves all files currently open in the editor.
Returns:
true if operation succeeded otherwise false.
remove
public void remove(EditPane editPane)
Remove the pane and update menu status
getEditPaneForFile
public EditPane getEditPaneForFile(String pathname)
If there is an EditPane for the given file pathname, return it else return null.
Parameters:
pathname – Pathname for desired file
Returns:
the EditPane for this file if it is open in the editor, or null if not.
editsSavedOrAbandoned
public boolean editsSavedOrAbandoned()
Check whether file has unsaved edits and, if so, check with user about saving them.
Returns:
true if no unsaved edits or if user chooses to save them or not; false
if there are unsaved edits and user cancels the operation.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
HardcopyWriter
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class HardcopyWriter
java.lang.Object
java.io.Writer
mars.venus.HardcopyWriter
All Implemented Interfaces:
Closeable, Flushable, Appendable
public class HardcopyWriter
extends Writer
Nested Class Summary
static class HardcopyWriter.PrintCanceledException
This is the exception class that the HardcopyWriter constructor
throws when the user clicks “Cancel” in the print dialog box.
Field Summary
protected int charnum
protected int chars_per_line
protected int chars_per_tab
protected int charwidth
protected Font font
protected int fontsize
protected Font headerfont
protected FontMetrics headermetrics
protected int headery
protected int height
protected PrintJob job
protected String jobname
protected int lineascent
protected int lineheight
protected int linenum
protected int lines_per_page
protected FontMetrics metrics
protected Graphics page
protected int pagedpi
protected int pagenum
protected Dimension pagesize
protected static Properties printprops
protected String time
protected int width
protected int x0
protected int y0
Fields inherited from class java.io.Writer
lock
Constructor Summary
HardcopyWriter(Frame frame,
String jobname,
int fontsize,
double leftmargin,
double rightmargin,
double topmargin,
double bottommargin)
The constructor for this class has a bunch of arguments:
The frame argument is required for all printing in Java.
Method Summary
void close()
This is the close( ) method that all Writer subclasses must implement.
void flush()
This is the flush( ) method that all Writer subclasses must implement.
int getCharactersPerLine()
Return the number of columns of characters that fit on the page
int getLinesPerPage()
Return the number of lines that fit on a page
static void main(String[] args)
A program that prints the specified file using HardcopyWriter
protected void newline()
This internal method begins a new line
protected void newpage()
This internal method begins a new page and prints the header.
void pageBreak()
End the current page.
void setFontStyle(int style)
Set the font style.
void write(char[] buffer,
int index,
int len)
This is the write( ) method of the stream.
Methods inherited from class java.io.Writer
append, append, append, write, write, write, write
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
job
protected PrintJob job
page
protected Graphics page
jobname
protected String jobname
fontsize
protected int fontsize
time
protected String time
pagesize
protected Dimension pagesize
pagedpi
protected int pagedpi
font
protected Font font
headerfont
protected Font headerfont
metrics
protected FontMetrics metrics
headermetrics
protected FontMetrics headermetrics
x0
protected int x0
y0
protected int y0
width
protected int width
height
protected int height
headery
protected int headery
charwidth
protected int charwidth
lineheight
protected int lineheight
lineascent
protected int lineascent
chars_per_line
protected int chars_per_line
lines_per_page
protected int lines_per_page
chars_per_tab
protected int chars_per_tab
charnum
protected int charnum
linenum
protected int linenum
pagenum
protected int pagenum
printprops
protected static Properties printprops
Constructor Detail
HardcopyWriter
public HardcopyWriter(Frame frame,
String jobname,
int fontsize,
double leftmargin,
double rightmargin,
double topmargin,
double bottommargin)
throws HardcopyWriter.PrintCanceledException
The constructor for this class has a bunch of arguments:
The frame argument is required for all printing in Java.
The jobname appears left justified at the top of each printed page.
The font size is specified in points, as on-screen font sizes are.
The margins are specified in inches (or fractions of inches).
Throws:
HardcopyWriter.PrintCanceledException
Method Detail
write
public void write(char[] buffer,
int index,
int len)
This is the write( ) method of the stream. All Writer subclasses
implement this. All other versions of write( ) are variants of this one
Specified by:
write in class Writer
flush
public void flush()
This is the flush( ) method that all Writer subclasses must implement.
There is no way to flush a PrintJob without prematurely printing the
page, so we don’t do anything.
Specified by:
flush in interface Flushable
Specified by:
flush in class Writer
close
public void close()
This is the close( ) method that all Writer subclasses must implement.
Print the pending page (if any) and terminate the PrintJob.
Specified by:
close in interface Closeable
Specified by:
close in class Writer
setFontStyle
public void setFontStyle(int style)
Set the font style. The argument should be one of the font style
constants defined by the java.awt.Font class. All subsequent output
will be in that style. This method relies on all styles of the
Monospaced font having the same metrics.
pageBreak
public void pageBreak()
End the current page. Subsequent output will be on a new page.
getCharactersPerLine
public int getCharactersPerLine()
Return the number of columns of characters that fit on the page
getLinesPerPage
public int getLinesPerPage()
Return the number of lines that fit on a page
newline
protected void newline()
This internal method begins a new line
newpage
protected void newpage()
This internal method begins a new page and prints the header.
main
public static void main(String[] args)
A program that prints the specified file using HardcopyWriter
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsEditorAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsEditorAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsEditorAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsEditorAction
extends GuiAction
Action class for the Settings menu item for text editor settings.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsEditorAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Create a new SettingsEditorAction.
Method Summary
void actionPerformed(ActionEvent e)
When this action is triggered, launch a dialog to view and modify
editor settings.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsEditorAction
public SettingsEditorAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Create a new SettingsEditorAction. Has all the GuiAction parameters.
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
When this action is triggered, launch a dialog to view and modify
editor settings.
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsMemoryConfigurationAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsMemoryConfigurationAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsMemoryConfigurationAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsMemoryConfigurationAction
extends GuiAction
Action class for the Settings menu item for text editor settings.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsMemoryConfigurationAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Create a new SettingsEditorAction.
Method Summary
void actionPerformed(ActionEvent e)
When this action is triggered, launch a dialog to view and modify
editor settings.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsMemoryConfigurationAction
public SettingsMemoryConfigurationAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Create a new SettingsEditorAction. Has all the GuiAction parameters.
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
When this action is triggered, launch a dialog to view and modify
editor settings.
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsAddressDisplayBaseAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsAddressDisplayBaseAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsAddressDisplayBaseAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsAddressDisplayBaseAction
extends GuiAction
Action class for the Settings menu item to control number base (10 or 16) of memory addresses.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsAddressDisplayBaseAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsAddressDisplayBaseAction
public SettingsAddressDisplayBaseAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RunResetAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RunResetAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.RunResetAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class RunResetAction
extends GuiAction
Action for the Run -> Reset menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
RunResetAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
reset GUI components and MIPS resources
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
RunResetAction
public RunResetAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
reset GUI components and MIPS resources
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
EditPasteAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class EditPasteAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.EditPasteAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class EditPasteAction
extends GuiAction
Action for the Edit -> Paste menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
EditPasteAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
EditPasteAction
public EditPasteAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FileOpenAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FileOpenAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.FileOpenAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class FileOpenAction
extends GuiAction
Action for the File -> Open menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
FileOpenAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
Launch a file chooser for name of file to open
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
FileOpenAction
public FileOpenAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Launch a file chooser for name of file to open
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Parameters:
e – component triggering this call
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RunPauseAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RunPauseAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.RunPauseAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class RunPauseAction
extends GuiAction
Action class for the Run -> Pause menu item (and toolbar icon)
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
RunPauseAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
RunPauseAction
public RunPauseAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors
mars.venus.editors
Interfaces
MARSTextEditingArea
TextAreaPainter
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class TextAreaPainter
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
mars.venus.editors.jeditsyntax.TextAreaPainter
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, TabExpander
public class TextAreaPainter
extends JComponent
implements TabExpander
The text area repaint manager. It performs double buffering and paints
lines of text.
Author:
Slava Pestov
See Also:
Serialized Form
Nested Class Summary
static interface TextAreaPainter.Highlight
Highlight interface.
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
protected boolean blockCaret
protected boolean bracketHighlight
protected Color bracketHighlightColor
protected Color caretColor
protected int cols
protected Color eolMarkerColor
protected boolean eolMarkers
protected FontMetrics fm
protected TextAreaPainter.Highlight highlights
protected boolean lineHighlight
protected Color lineHighlightColor
protected boolean paintInvalid
protected int rows
protected Color selectionColor
protected SyntaxStyle[] styles
protected int tabSize
protected int tabSizeChars
protected JEditTextArea textArea
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
TextAreaPainter(JEditTextArea textArea,
TextAreaDefaults defaults)
Creates a new repaint manager.
Method Summary
void addCustomHighlight(TextAreaPainter.Highlight highlight)
Adds a custom highlight painter.
Color getBracketHighlightColor()
Returns the bracket highlight color.
Color getCaretColor()
Returns the caret color.
Color getEOLMarkerColor()
Returns the EOL marker color.
boolean getEOLMarkersPainted()
Returns true if EOL markers are drawn, false otherwise.
FontMetrics getFontMetrics()
Returns the font metrics used by this component.
boolean getInvalidLinesPainted()
Returns true if invalid lines are painted as red tildes (~),
false otherwise.
Color getLineHighlightColor()
Returns the line highlight color.
Dimension getMinimumSize()
Returns the painter’s minimum size.
Dimension getPreferredSize()
Returns the painter’s preferred size.
Color getSelectionColor()
Returns the selection color.
SyntaxStyle[] getStyles()
Returns the syntax styles used to paint colorized text.
int getTabSize()
Fetch the tab size in characters.
String getToolTipText(MouseEvent evt)
Returns the tool tip to display at the specified location.
void invalidateLine(int line)
Marks a line as needing a repaint.
void invalidateLineRange(int firstLine,
int lastLine)
Marks a range of lines as needing a repaint.
void invalidateSelectedLines()
Repaints the lines containing the selection.
boolean isBlockCaretEnabled()
Returns true if the caret should be drawn as a block, false otherwise.
boolean isBracketHighlightEnabled()
Returns true if bracket highlighting is enabled, false otherwise.
boolean isLineHighlightEnabled()
Returns true if line highlight is enabled, false otherwise.
boolean isManagingFocus()
Returns if this component can be traversed by pressing the
Tab key.
float nextTabStop(float x,
int tabOffset)
Implementation of TabExpander interface.
void paint(Graphics gfx)
Repaints the text.
protected void paintBracketHighlight(Graphics gfx,
int line,
int y)
protected void paintCaret(Graphics gfx,
int line,
int y)
protected void paintHighlight(Graphics gfx,
int line,
int y)
protected void paintLine(Graphics gfx,
TokenMarker tokenMarker,
int line,
int x)
protected void paintLineHighlight(Graphics gfx,
int line,
int y)
protected void paintPlainLine(Graphics gfx,
int line,
Font defaultFont,
Color defaultColor,
int x,
int y)
protected void paintSyntaxLine(Graphics gfx,
TokenMarker tokenMarker,
int line,
Font defaultFont,
Color defaultColor,
int x,
int y)
void setBlockCaretEnabled(boolean blockCaret)
Sets if the caret should be drawn as a block, false otherwise.
void setBracketHighlightColor(Color bracketHighlightColor)
Sets the bracket highlight color.
void setBracketHighlightEnabled(boolean bracketHighlight)
Enables or disables bracket highlighting.
void setCaretColor(Color caretColor)
Sets the caret color.
void setEOLMarkerColor(Color eolMarkerColor)
Sets the EOL marker color.
void setEOLMarkersPainted(boolean eolMarkers)
Sets if EOL markers are to be drawn.
void setFont(Font font)
Sets the font for this component.
void setInvalidLinesPainted(boolean paintInvalid)
Sets if invalid lines are to be painted as red tildes.
void setLineHighlightColor(Color lineHighlightColor)
Sets the line highlight color.
void setLineHighlightEnabled(boolean lineHighlight)
Enables or disables current line highlighting.
void setSelectionColor(Color selectionColor)
Sets the selection color.
void setStyles(SyntaxStyle[] styles)
Sets the syntax styles used to paint colorized text.
void setTabSize(int size)
Set the tab size in characters.
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getUIClassID, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, paramString, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update, updateUI
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
textArea
protected JEditTextArea textArea
styles
protected SyntaxStyle[] styles
caretColor
protected Color caretColor
selectionColor
protected Color selectionColor
lineHighlightColor
protected Color lineHighlightColor
bracketHighlightColor
protected Color bracketHighlightColor
eolMarkerColor
protected Color eolMarkerColor
blockCaret
protected boolean blockCaret
lineHighlight
protected boolean lineHighlight
bracketHighlight
protected boolean bracketHighlight
paintInvalid
protected boolean paintInvalid
eolMarkers
protected boolean eolMarkers
cols
protected int cols
rows
protected int rows
tabSize
protected int tabSize
tabSizeChars
protected int tabSizeChars
fm
protected FontMetrics fm
highlights
protected TextAreaPainter.Highlight highlights
Constructor Detail
TextAreaPainter
public TextAreaPainter(JEditTextArea textArea,
TextAreaDefaults defaults)
Creates a new repaint manager. This should be not be called
directly.
Method Detail
isManagingFocus
public final boolean isManagingFocus()
Returns if this component can be traversed by pressing the
Tab key. This returns false.
NOTE: as of Java 1.4 this method is deprecated and no longer
has the desired effect because the focus subsystem does not
call it. I’ve implemented a KeyEventDispatcher in JEditTextArea
to handle Tabs. DPS 12-May-2010
Overrides:
isManagingFocus in class JComponent
getTabSize
public int getTabSize()
Fetch the tab size in characters. DPS 12-May-2010.
Returns:
int tab size in characters
setTabSize
public void setTabSize(int size)
Set the tab size in characters. DPS 12-May-2010.
Originally it was fixed at PlainDocument property
value (8).
Parameters:
size – tab size in characters
getStyles
public final SyntaxStyle[] getStyles()
Returns the syntax styles used to paint colorized text. Entry n
will be used to paint tokens with id = n.
See Also:
org.syntax.jedit.Token
setStyles
public final void setStyles(SyntaxStyle[] styles)
Sets the syntax styles used to paint colorized text. Entry n
will be used to paint tokens with id = n.
Parameters:
styles – The syntax styles
See Also:
org.syntax.jedit.Token
getCaretColor
public final Color getCaretColor()
Returns the caret color.
setCaretColor
public final void setCaretColor(Color caretColor)
Sets the caret color.
Parameters:
caretColor – The caret color
getSelectionColor
public final Color getSelectionColor()
Returns the selection color.
setSelectionColor
public final void setSelectionColor(Color selectionColor)
Sets the selection color.
Parameters:
selectionColor – The selection color
getLineHighlightColor
public final Color getLineHighlightColor()
Returns the line highlight color.
setLineHighlightColor
public final void setLineHighlightColor(Color lineHighlightColor)
Sets the line highlight color.
Parameters:
lineHighlightColor – The line highlight color
isLineHighlightEnabled
public final boolean isLineHighlightEnabled()
Returns true if line highlight is enabled, false otherwise.
setLineHighlightEnabled
public final void setLineHighlightEnabled(boolean lineHighlight)
Enables or disables current line highlighting.
Parameters:
lineHighlight – True if current line highlight should be enabled,
false otherwise
getBracketHighlightColor
public final Color getBracketHighlightColor()
Returns the bracket highlight color.
setBracketHighlightColor
public final void setBracketHighlightColor(Color bracketHighlightColor)
Sets the bracket highlight color.
Parameters:
bracketHighlightColor – The bracket highlight color
isBracketHighlightEnabled
public final boolean isBracketHighlightEnabled()
Returns true if bracket highlighting is enabled, false otherwise.
When bracket highlighting is enabled, the bracket matching the
one before the caret (if any) is highlighted.
setBracketHighlightEnabled
public final void setBracketHighlightEnabled(boolean bracketHighlight)
Enables or disables bracket highlighting.
When bracket highlighting is enabled, the bracket matching the
one before the caret (if any) is highlighted.
Parameters:
bracketHighlight – True if bracket highlighting should be
enabled, false otherwise
isBlockCaretEnabled
public final boolean isBlockCaretEnabled()
Returns true if the caret should be drawn as a block, false otherwise.
setBlockCaretEnabled
public final void setBlockCaretEnabled(boolean blockCaret)
Sets if the caret should be drawn as a block, false otherwise.
Parameters:
blockCaret – True if the caret should be drawn as a block,
false otherwise.
getEOLMarkerColor
public final Color getEOLMarkerColor()
Returns the EOL marker color.
setEOLMarkerColor
public final void setEOLMarkerColor(Color eolMarkerColor)
Sets the EOL marker color.
Parameters:
eolMarkerColor – The EOL marker color
getEOLMarkersPainted
public final boolean getEOLMarkersPainted()
Returns true if EOL markers are drawn, false otherwise.
setEOLMarkersPainted
public final void setEOLMarkersPainted(boolean eolMarkers)
Sets if EOL markers are to be drawn.
Parameters:
eolMarkers – True if EOL markers should be drawn, false otherwise
getInvalidLinesPainted
public boolean getInvalidLinesPainted()
Returns true if invalid lines are painted as red tildes (~),
false otherwise.
setInvalidLinesPainted
public void setInvalidLinesPainted(boolean paintInvalid)
Sets if invalid lines are to be painted as red tildes.
Parameters:
paintInvalid – True if invalid lines should be drawn, false otherwise
addCustomHighlight
public void addCustomHighlight(TextAreaPainter.Highlight highlight)
Adds a custom highlight painter.
Parameters:
highlight – The highlight
getToolTipText
public String getToolTipText(MouseEvent evt)
Returns the tool tip to display at the specified location.
Overrides:
getToolTipText in class JComponent
Parameters:
evt – The mouse event
getFontMetrics
public FontMetrics getFontMetrics()
Returns the font metrics used by this component.
setFont
public void setFont(Font font)
Sets the font for this component. This is overridden to update the
cached font metrics and to recalculate which lines are visible.
Overrides:
setFont in class JComponent
Parameters:
font – The font
paint
public void paint(Graphics gfx)
Repaints the text.
Overrides:
paint in class JComponent
Parameters:
gfx – The graphics context
invalidateLine
public final void invalidateLine(int line)
Marks a line as needing a repaint.
Parameters:
line – The line to invalidate
invalidateLineRange
public final void invalidateLineRange(int firstLine,
int lastLine)
Marks a range of lines as needing a repaint.
Parameters:
firstLine – The first line to invalidate
lastLine – The last line to invalidate
invalidateSelectedLines
public final void invalidateSelectedLines()
Repaints the lines containing the selection.
nextTabStop
public float nextTabStop(float x,
int tabOffset)
Implementation of TabExpander interface. Returns next tab stop after
a specified point.
Specified by:
nextTabStop in interface TabExpander
Parameters:
x – The x co-ordinate
tabOffset – Ignored
Returns:
The next tab stop after x
getPreferredSize
public Dimension getPreferredSize()
Returns the painter’s preferred size.
Overrides:
getPreferredSize in class JComponent
getMinimumSize
public Dimension getMinimumSize()
Returns the painter’s minimum size.
Overrides:
getMinimumSize in class JComponent
paintLine
protected void paintLine(Graphics gfx,
TokenMarker tokenMarker,
int line,
int x)
paintPlainLine
protected void paintPlainLine(Graphics gfx,
int line,
Font defaultFont,
Color defaultColor,
int x,
int y)
paintSyntaxLine
protected void paintSyntaxLine(Graphics gfx,
TokenMarker tokenMarker,
int line,
Font defaultFont,
Color defaultColor,
int x,
int y)
paintHighlight
protected void paintHighlight(Graphics gfx,
int line,
int y)
paintLineHighlight
protected void paintLineHighlight(Graphics gfx,
int line,
int y)
paintBracketHighlight
protected void paintBracketHighlight(Graphics gfx,
int line,
int y)
paintCaret
protected void paintCaret(Graphics gfx,
int line,
int y)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.next_line
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.next_line
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.next_line
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.next_line
extends Object
implements ActionListener
Constructor Summary
InputHandler.next_line(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.next_line
public InputHandler.next_line(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.overwrite
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.overwrite
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.overwrite
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.overwrite
extends Object
implements ActionListener
Constructor Summary
InputHandler.overwrite()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.overwrite
public InputHandler.overwrite()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyntaxDocument
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class SyntaxDocument
java.lang.Object
javax.swing.text.AbstractDocument
javax.swing.text.PlainDocument
mars.venus.editors.jeditsyntax.SyntaxDocument
All Implemented Interfaces:
Serializable, Document
public class SyntaxDocument
extends PlainDocument
A document implementation that can be tokenized by the syntax highlighting
system.
Author:
Slava Pestov
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.text.AbstractDocument
AbstractDocument.AbstractElement, AbstractDocument.AttributeContext, AbstractDocument.BranchElement, AbstractDocument.Content, AbstractDocument.DefaultDocumentEvent, AbstractDocument.ElementEdit, AbstractDocument.LeafElement
Field Summary
protected TokenMarker tokenMarker
Fields inherited from class javax.swing.text.PlainDocument
lineLimitAttribute, tabSizeAttribute
Fields inherited from class javax.swing.text.AbstractDocument
BAD_LOCATION, BidiElementName, ContentElementName, ElementNameAttribute, listenerList, ParagraphElementName, SectionElementName
Fields inherited from interface javax.swing.text.Document
StreamDescriptionProperty, TitleProperty
Constructor Summary
SyntaxDocument()
Method Summary
void addUndoableEdit(UndoableEdit edit)
Adds an undoable edit to this document’s undo list.
void beginCompoundEdit()
Starts a compound edit that can be undone in one operation.
void endCompoundEdit()
Ends a compound edit that can be undone in one operation.
protected void fireInsertUpdate(DocumentEvent evt)
We overwrite this method to update the token marker
state immediately so that any event listeners get a
consistent token marker.
protected void fireRemoveUpdate(DocumentEvent evt)
We overwrite this method to update the token marker
state immediately so that any event listeners get a
consistent token marker.
TokenMarker getTokenMarker()
Returns the token marker that is to be used to split lines
of this document up into tokens.
void setTokenMarker(TokenMarker tm)
Sets the token marker that is to be used to split lines of
this document up into tokens.
void tokenizeLines()
Reparses the document, by passing all lines to the token
marker.
void tokenizeLines(int start,
int len)
Reparses the document, by passing the specified lines to the
token marker.
Methods inherited from class javax.swing.text.PlainDocument
createDefaultRoot, getDefaultRootElement, getParagraphElement, insertString, insertUpdate, removeUpdate
Methods inherited from class javax.swing.text.AbstractDocument
addDocumentListener, addUndoableEditListener, createBranchElement, createLeafElement, createPosition, dump, fireChangedUpdate, fireUndoableEditUpdate, getAsynchronousLoadPriority, getAttributeContext, getBidiRootElement, getContent, getCurrentWriter, getDocumentFilter, getDocumentListeners, getDocumentProperties, getEndPosition, getLength, getListeners, getProperty, getRootElements, getStartPosition, getText, getText, getUndoableEditListeners, postRemoveUpdate, putProperty, readLock, readUnlock, remove, removeDocumentListener, removeUndoableEditListener, render, replace, setAsynchronousLoadPriority, setDocumentFilter, setDocumentProperties, writeLock, writeUnlock
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
tokenMarker
protected TokenMarker tokenMarker
Constructor Detail
SyntaxDocument
public SyntaxDocument()
Method Detail
getTokenMarker
public TokenMarker getTokenMarker()
Returns the token marker that is to be used to split lines
of this document up into tokens. May return null if this
document is not to be colorized.
setTokenMarker
public void setTokenMarker(TokenMarker tm)
Sets the token marker that is to be used to split lines of
this document up into tokens. May throw an exception if
this is not supported for this type of document.
Parameters:
tm – The new token marker
tokenizeLines
public void tokenizeLines()
Reparses the document, by passing all lines to the token
marker. This should be called after the document is first
loaded.
tokenizeLines
public void tokenizeLines(int start,
int len)
Reparses the document, by passing the specified lines to the
token marker. This should be called after a large quantity of
text is first inserted.
Parameters:
start – The first line to parse
len – The number of lines, after the first one to parse
beginCompoundEdit
public void beginCompoundEdit()
Starts a compound edit that can be undone in one operation.
Subclasses that implement undo should override this method;
this class has no undo functionality so this method is
empty.
endCompoundEdit
public void endCompoundEdit()
Ends a compound edit that can be undone in one operation.
Subclasses that implement undo should override this method;
this class has no undo functionality so this method is
empty.
addUndoableEdit
public void addUndoableEdit(UndoableEdit edit)
Adds an undoable edit to this document’s undo list. The edit
should be ignored if something is currently being undone.
Parameters:
edit – The undoable edit
Since:
jEdit 2.2pre1
fireInsertUpdate
protected void fireInsertUpdate(DocumentEvent evt)
We overwrite this method to update the token marker
state immediately so that any event listeners get a
consistent token marker.
Overrides:
fireInsertUpdate in class AbstractDocument
fireRemoveUpdate
protected void fireRemoveUpdate(DocumentEvent evt)
We overwrite this method to update the token marker
state immediately so that any event listeners get a
consistent token marker.
Overrides:
fireRemoveUpdate in class AbstractDocument
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.backspace_word
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.backspace_word
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.backspace_word
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.backspace_word
extends Object
implements ActionListener
Constructor Summary
InputHandler.backspace_word()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.backspace_word
public InputHandler.backspace_word()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
KeywordMap
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class KeywordMap
java.lang.Object
mars.venus.editors.jeditsyntax.KeywordMap
public class KeywordMap
extends Object
A KeywordMap is similar to a hashtable in that it maps keys
to values. However, the `keys’ are Swing segments. This allows lookups of
text substrings without the overhead of creating a new string object.
This class is used by CTokenMarker to map keywords to ids.
Author:
Slava Pestov, Mike Dillon
Field Summary
protected int mapLength
Constructor Summary
KeywordMap(boolean ignoreCase)
Creates a new KeywordMap.
KeywordMap(boolean ignoreCase,
int mapLength)
Creates a new KeywordMap.
Method Summary
void add(String keyword,
byte id)
Adds a key-value mapping.
boolean getIgnoreCase()
Returns true if the keyword map is set to be case insensitive,
false otherwise.
protected int getSegmentMapKey(Segment s,
int off,
int len)
protected int getStringMapKey(String s)
byte lookup(Segment text,
int offset,
int length)
Looks up a key.
void setIgnoreCase(boolean ignoreCase)
Sets if the keyword map should be case insensitive.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
mapLength
protected int mapLength
Constructor Detail
KeywordMap
public KeywordMap(boolean ignoreCase)
Creates a new KeywordMap.
Parameters:
ignoreCase – True if keys are case insensitive
KeywordMap
public KeywordMap(boolean ignoreCase,
int mapLength)
Creates a new KeywordMap.
Parameters:
ignoreCase – True if the keys are case insensitive
mapLength – The number of `buckets’ to create.
A value of 52 will give good performance for most maps.
Method Detail
lookup
public byte lookup(Segment text,
int offset,
int length)
Looks up a key.
Parameters:
text – The text segment
offset – The offset of the substring within the text segment
length – The length of the substring
add
public void add(String keyword,
byte id)
Adds a key-value mapping.
Parameters:
keyword – The key
getIgnoreCase
public boolean getIgnoreCase()
Returns true if the keyword map is set to be case insensitive,
false otherwise.
setIgnoreCase
public void setIgnoreCase(boolean ignoreCase)
Sets if the keyword map should be case insensitive.
Parameters:
ignoreCase – True if the keyword map should be case
insensitive, false otherwise
getStringMapKey
protected int getStringMapKey(String s)
getSegmentMapKey
protected int getSegmentMapKey(Segment s,
int off,
int len)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.prev_page
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.prev_page
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.prev_page
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.prev_page
extends Object
implements ActionListener
Constructor Summary
InputHandler.prev_page(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.prev_page
public InputHandler.prev_page(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.insert_tab
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.insert_tab
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.insert_tab
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.insert_tab
extends Object
implements ActionListener
Constructor Summary
InputHandler.insert_tab()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.insert_tab
public InputHandler.insert_tab()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
JEditTextArea
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class JEditTextArea
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
mars.venus.editors.jeditsyntax.JEditTextArea
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable
Direct Known Subclasses:
JEditBasedTextArea
public class JEditTextArea
extends JComponent
jEdit’s text area component. It is more suited for editing program
source code than JEditorPane, because it drops the unnecessary features
(images, variable-width lines, and so on) and adds a whole bunch of
useful goodies such as:
More flexible key binding scheme
Supports macro recorders
Rectangular selection
Bracket highlighting
Syntax highlighting
Command repetition
Block caret can be enabled
It is also faster and doesn’t have as many problems. It can be used
in other applications; the only other part of jEdit it depends on is
the syntax package.
To use it in your app, treat it like any other component, for example:
JEditTextArea ta = new JEditTextArea();
ta.setTokenMarker(new JavaTokenMarker());
ta.setText(“public class Test {\n”
+ ” public static void main(String[] args) {\n”
+ ” System.out.println(\”Hello World\”);\n”
+ ” }\n”
+ “}”);
Author:
Slava Pestov
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
protected boolean biasLeft
protected boolean blink
protected static String BOTTOM
protected int bracketLine
protected int bracketPosition
protected int caretBlinkRate
protected boolean caretBlinks
protected mars.venus.editors.jeditsyntax.JEditTextArea.MutableCaretEvent caretEvent
protected static Timer caretTimer
protected boolean caretVisible
protected static String CENTER
protected SyntaxDocument document
protected mars.venus.editors.jeditsyntax.JEditTextArea.DocumentHandler documentHandler
protected boolean editable
protected int electricScroll
protected int firstLine
protected static JEditTextArea focusedComponent
protected JScrollBar horizontal
protected int horizontalOffset
protected InputHandler inputHandler
static String LEFT_OF_SCROLLBAR
Adding components with this name to the text area will place
them left of the horizontal scroll bar.
protected Segment lineSegment
protected EventListenerList listenerList
protected int magicCaret
protected boolean overwrite
protected TextAreaPainter painter
protected JPopupMenu popup
protected boolean rectSelect
protected static String RIGHT
protected boolean scrollBarsInitialized
protected int selectionEnd
protected int selectionEndLine
protected int selectionStart
protected int selectionStartLine
protected boolean unredoing
protected JScrollBar vertical
protected int visibleLines
Fields inherited from class javax.swing.JComponent
accessibleContext, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
JEditTextArea(JComponent lineNumbers)
Creates a new JEditTextArea with the default settings.
JEditTextArea(TextAreaDefaults defaults,
JComponent lineNumbers)
Method Summary
int _offsetToX(int line,
int offset)
Converts an offset in a line into an x co-ordinate.
void addCaretListener(CaretListener listener)
Adds a caret change listener to this text area.
void blinkCaret()
Blinks the caret.
void copy()
Places the selected text into the clipboard.
void cut()
Deletes the selected text from the text area and places it
into the clipboard.
protected void documentChanged(DocumentEvent evt)
protected void fireCaretEvent()
String getAutoIndent()
Constructs string for auto-indent feature.
int getBracketLine()
Returns the line of the highlighted bracket (the bracket
matching the one before the caret)
int getBracketPosition()
Returns the position of the highlighted bracket (the bracket
matching the one before the caret)
int getCaretLine()
Returns the caret line.
int getCaretPosition()
Returns the caret position.
Document getDocument()
Returns the document this text area is editing.
int getDocumentLength()
Returns the length of the document.
int getElectricScroll()
Returns the number of lines from the top and button of the
text area that are always visible.
int getFirstLine()
Returns the line displayed at the text area’s origin.
int getHorizontalOffset()
Returns the horizontal offset of drawn lines.
InputHandler getInputHandler()
Returns the input handler.
String getLeadingWhiteSpace()
Makes a copy of leading white space (tab or space) from the current line and
returns it.
int getLineCount()
Returns the number of lines in the document.
int getLineEndOffset(int line)
Returns the end offset of the specified line.
int getLineLength(int line)
Returns the length of the specified line.
int getLineOfOffset(int offset)
Returns the line containing the specified offset.
int getLineStartOffset(int line)
Returns the start offset of the specified line.
String getLineText(int lineIndex)
Returns the text on the specified line.
void getLineText(int lineIndex,
Segment segment)
Copies the text on the specified line into a segment.
int getMagicCaretPosition()
Returns the `magic’ caret position.
int getMarkLine()
Returns the mark line.
int getMarkPosition()
Returns the mark position.
TextAreaPainter getPainter()
Returns the object responsible for painting this text area.
JPopupMenu getRightClickPopup()
Returns the right click popup menu.
String getSelectedText()
Returns the selected text, or null if no selection is active.
int getSelectionEnd()
Returns the selection end offset.
int getSelectionEnd(int line)
Returns the offset where the selection ends on the specified
line.
int getSelectionEndLine()
Returns the selection end line.
int getSelectionStart()
Returns the selection start offset.
int getSelectionStart(int line)
Returns the offset where the selection starts on the specified
line.
int getSelectionStartLine()
Returns the selection start line.
String getSyntaxSensitiveToolTipText(int x,
int y)
Return any relevant tool tip text for token at specified position.
String getText()
Returns the entire text of this text area.
String getText(int start,
int len)
Returns the specified substring of the document.
void getText(int start,
int len,
Segment segment)
Copies the specified substring of the document into a segment.
TokenMarker getTokenMarker()
Returns the document’s token marker.
int getVisibleLines()
Returns the number of lines visible in this text area.
boolean isCaretBlinkEnabled()
Returns true if the caret is blinking, false otherwise.
boolean isCaretVisible()
Returns true if the caret is visible, false otherwise.
boolean isEditable()
Returns true if this text area is editable, false otherwise.
boolean isOverwriteEnabled()
Returns true if overwrite mode is enabled, false otherwise.
boolean isSelectionRectangular()
Returns true if the selection is rectangular, false otherwise.
int lineToY(int line)
Converts a line index to a y co-ordinate.
int offsetToX(int line,
int offset)
Converts an offset in a line into an x co-ordinate.
void overwriteSetSelectedText(String str)
Similar to setSelectedText(), but overstrikes the
appropriate number of characters if overwrite mode is enabled.
void paste()
Inserts the clipboard contents into the text.
void processKeyEvent(KeyEvent evt)
Forwards key events directly to the input handler.
void recalculateVisibleLines()
Recalculates the number of visible lines.
void removeCaretListener(CaretListener listener)
Removes a caret change listener from this text area.
void removeNotify()
Called by the AWT when this component is removed from it’s parent.
boolean scrollTo(int line,
int offset)
Ensures that the specified line and offset is visible by scrolling
the text area if necessary.
boolean scrollToCaret()
Ensures that the caret is visible by scrolling the text area if
necessary.
void select(int start,
int end)
Selects from the start offset to the end offset.
void selectAll()
Selects all text in the document.
void selectNone()
Moves the mark to the caret position.
void setCaretBlinkEnabled(boolean caretBlinks)
Toggles caret blinking.
void setCaretPosition(int caret)
Sets the caret position.
void setCaretVisible(boolean caretVisible)
Sets if the caret should be visible.
void setDocument(SyntaxDocument document)
Sets the document this text area is editing.
void setEditable(boolean editable)
Sets if this component is editable.
void setElectricScroll(int electricScroll)
Sets the number of lines from the top and bottom of the text
area that are always visible
void setFirstLine(int firstLine)
Sets the line displayed at the text area’s origin and
updates the scroll bars.
void setHorizontalOffset(int horizontalOffset)
Sets the horizontal offset of drawn lines.
void setInputHandler(InputHandler inputHandler)
Sets the input handler.
void setMagicCaretPosition(int magicCaret)
Sets the `magic’ caret position.
boolean setOrigin(int firstLine,
int horizontalOffset)
A fast way of changing both the first line and horizontal
offset.
void setOverwriteEnabled(boolean overwrite)
Sets if overwrite mode should be enabled.
void setRightClickPopup(JPopupMenu popup)
Sets the right click popup menu.
void setSelectedText(String selectedText)
Replaces the selection with the specified text.
void setSelectionEnd(int selectionEnd)
Sets the selection end.
void setSelectionRectangular(boolean rectSelect)
Sets if the selection should be rectangular.
void setSelectionStart(int selectionStart)
Sets the selection start.
void setText(String text)
Sets the entire text of this text area.
void setTokenMarker(TokenMarker tokenMarker)
Sets the document’s token marker.
protected void updateBracketHighlight(int newCaretPosition)
void updateScrollBars()
Updates the state of the scroll bars.
int xToOffset(int line,
int x)
Converts an x co-ordinate to an offset within a line.
int xyToOffset(int x,
int y)
Converts a point to an offset, from the start of the text.
int yToLine(int y)
Converts a y co-ordinate to a line index.
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getUIClassID, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, paramString, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update, updateUI
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
LEFT_OF_SCROLLBAR
public static String LEFT_OF_SCROLLBAR
Adding components with this name to the text area will place
them left of the horizontal scroll bar. In jEdit, the status
bar is added this way.
CENTER
protected static String CENTER
RIGHT
protected static String RIGHT
BOTTOM
protected static String BOTTOM
focusedComponent
protected static JEditTextArea focusedComponent
caretTimer
protected static Timer caretTimer
painter
protected TextAreaPainter painter
popup
protected JPopupMenu popup
listenerList
protected EventListenerList listenerList
caretEvent
protected mars.venus.editors.jeditsyntax.JEditTextArea.MutableCaretEvent caretEvent
caretBlinks
protected boolean caretBlinks
caretVisible
protected boolean caretVisible
blink
protected boolean blink
editable
protected boolean editable
caretBlinkRate
protected int caretBlinkRate
firstLine
protected int firstLine
visibleLines
protected int visibleLines
electricScroll
protected int electricScroll
horizontalOffset
protected int horizontalOffset
vertical
protected JScrollBar vertical
horizontal
protected JScrollBar horizontal
scrollBarsInitialized
protected boolean scrollBarsInitialized
inputHandler
protected InputHandler inputHandler
document
protected SyntaxDocument document
documentHandler
protected mars.venus.editors.jeditsyntax.JEditTextArea.DocumentHandler documentHandler
lineSegment
protected Segment lineSegment
selectionStart
protected int selectionStart
selectionStartLine
protected int selectionStartLine
selectionEnd
protected int selectionEnd
selectionEndLine
protected int selectionEndLine
biasLeft
protected boolean biasLeft
bracketPosition
protected int bracketPosition
bracketLine
protected int bracketLine
magicCaret
protected int magicCaret
overwrite
protected boolean overwrite
rectSelect
protected boolean rectSelect
unredoing
protected boolean unredoing
Constructor Detail
JEditTextArea
public JEditTextArea(JComponent lineNumbers)
Creates a new JEditTextArea with the default settings.
JEditTextArea
public JEditTextArea(TextAreaDefaults defaults,
JComponent lineNumbers)
Method Detail
getPainter
public final TextAreaPainter getPainter()
Returns the object responsible for painting this text area.
getInputHandler
public final InputHandler getInputHandler()
Returns the input handler.
setInputHandler
public void setInputHandler(InputHandler inputHandler)
Sets the input handler.
Parameters:
inputHandler – The new input handler
isCaretBlinkEnabled
public final boolean isCaretBlinkEnabled()
Returns true if the caret is blinking, false otherwise.
setCaretBlinkEnabled
public void setCaretBlinkEnabled(boolean caretBlinks)
Toggles caret blinking.
Parameters:
caretBlinks – True if the caret should blink, false otherwise
isCaretVisible
public final boolean isCaretVisible()
Returns true if the caret is visible, false otherwise.
setCaretVisible
public void setCaretVisible(boolean caretVisible)
Sets if the caret should be visible.
Parameters:
caretVisible – True if the caret should be visible, false
otherwise
blinkCaret
public final void blinkCaret()
Blinks the caret.
getElectricScroll
public final int getElectricScroll()
Returns the number of lines from the top and button of the
text area that are always visible.
setElectricScroll
public final void setElectricScroll(int electricScroll)
Sets the number of lines from the top and bottom of the text
area that are always visible
Parameters:
electricScroll – The number of lines always visible from
the top or bottom
updateScrollBars
public void updateScrollBars()
Updates the state of the scroll bars. This should be called
if the number of lines in the document changes, or when the
size of the text are changes.
getFirstLine
public final int getFirstLine()
Returns the line displayed at the text area’s origin.
setFirstLine
public void setFirstLine(int firstLine)
Sets the line displayed at the text area’s origin and
updates the scroll bars.
getVisibleLines
public final int getVisibleLines()
Returns the number of lines visible in this text area.
recalculateVisibleLines
public final void recalculateVisibleLines()
Recalculates the number of visible lines. This should not
be called directly.
getHorizontalOffset
public final int getHorizontalOffset()
Returns the horizontal offset of drawn lines.
setHorizontalOffset
public void setHorizontalOffset(int horizontalOffset)
Sets the horizontal offset of drawn lines. This can be used to
implement horizontal scrolling.
Parameters:
horizontalOffset – offset The new horizontal offset
setOrigin
public boolean setOrigin(int firstLine,
int horizontalOffset)
A fast way of changing both the first line and horizontal
offset.
Parameters:
firstLine – The new first line
horizontalOffset – The new horizontal offset
Returns:
True if any of the values were changed, false otherwise
scrollToCaret
public boolean scrollToCaret()
Ensures that the caret is visible by scrolling the text area if
necessary.
Returns:
True if scrolling was actually performed, false if the
caret was already visible
scrollTo
public boolean scrollTo(int line,
int offset)
Ensures that the specified line and offset is visible by scrolling
the text area if necessary.
Parameters:
line – The line to scroll to
offset – The offset in the line to scroll to
Returns:
True if scrolling was actually performed, false if the
line and offset was already visible
lineToY
public int lineToY(int line)
Converts a line index to a y co-ordinate.
Parameters:
line – The line
yToLine
public int yToLine(int y)
Converts a y co-ordinate to a line index.
Parameters:
y – The y co-ordinate
offsetToX
public final int offsetToX(int line,
int offset)
Converts an offset in a line into an x co-ordinate. This is a
slow version that can be used any time.
Parameters:
line – The line
offset – The offset, from the start of the line
_offsetToX
public int _offsetToX(int line,
int offset)
Converts an offset in a line into an x co-ordinate. This is a
fast version that should only be used if no changes were made
to the text since the last repaint.
Parameters:
line – The line
offset – The offset, from the start of the line
xToOffset
public int xToOffset(int line,
int x)
Converts an x co-ordinate to an offset within a line.
Parameters:
line – The line
x – The x co-ordinate
xyToOffset
public int xyToOffset(int x,
int y)
Converts a point to an offset, from the start of the text.
Parameters:
x – The x co-ordinate of the point
y – The y co-ordinate of the point
getDocument
public final Document getDocument()
Returns the document this text area is editing.
setDocument
public void setDocument(SyntaxDocument document)
Sets the document this text area is editing.
Parameters:
document – The document
getTokenMarker
public final TokenMarker getTokenMarker()
Returns the document’s token marker. Equivalent to calling
getDocument().getTokenMarker().
setTokenMarker
public final void setTokenMarker(TokenMarker tokenMarker)
Sets the document’s token marker. Equivalent to caling
getDocument().setTokenMarker().
Parameters:
tokenMarker – The token marker
getDocumentLength
public final int getDocumentLength()
Returns the length of the document. Equivalent to calling
getDocument().getLength().
getLineCount
public final int getLineCount()
Returns the number of lines in the document.
getLineOfOffset
public final int getLineOfOffset(int offset)
Returns the line containing the specified offset.
Parameters:
offset – The offset
getLineStartOffset
public int getLineStartOffset(int line)
Returns the start offset of the specified line.
Parameters:
line – The line
Returns:
The start offset of the specified line, or -1 if the line is
invalid
getLineEndOffset
public int getLineEndOffset(int line)
Returns the end offset of the specified line.
Parameters:
line – The line
Returns:
The end offset of the specified line, or -1 if the line is
invalid.
getLineLength
public int getLineLength(int line)
Returns the length of the specified line.
Parameters:
line – The line
getText
public String getText()
Returns the entire text of this text area.
setText
public void setText(String text)
Sets the entire text of this text area.
getText
public final String getText(int start,
int len)
Returns the specified substring of the document.
Parameters:
start – The start offset
len – The length of the substring
Returns:
The substring, or null if the offsets are invalid
getText
public final void getText(int start,
int len,
Segment segment)
Copies the specified substring of the document into a segment.
If the offsets are invalid, the segment will contain a null string.
Parameters:
start – The start offset
len – The length of the substring
segment – The segment
getLineText
public final String getLineText(int lineIndex)
Returns the text on the specified line.
Parameters:
lineIndex – The line
Returns:
The text, or null if the line is invalid
getLineText
public final void getLineText(int lineIndex,
Segment segment)
Copies the text on the specified line into a segment. If the line
is invalid, the segment will contain a null string.
Parameters:
lineIndex – The line
getSelectionStart
public final int getSelectionStart()
Returns the selection start offset.
getSelectionStart
public int getSelectionStart(int line)
Returns the offset where the selection starts on the specified
line.
getSelectionStartLine
public final int getSelectionStartLine()
Returns the selection start line.
setSelectionStart
public final void setSelectionStart(int selectionStart)
Sets the selection start. The new selection will be the new
selection start and the old selection end.
Parameters:
selectionStart – The selection start
See Also:
select(int,int)
getSelectionEnd
public final int getSelectionEnd()
Returns the selection end offset.
getSelectionEnd
public int getSelectionEnd(int line)
Returns the offset where the selection ends on the specified
line.
getSelectionEndLine
public final int getSelectionEndLine()
Returns the selection end line.
setSelectionEnd
public final void setSelectionEnd(int selectionEnd)
Sets the selection end. The new selection will be the old
selection start and the new selection end.
Parameters:
selectionEnd – The selection end
See Also:
select(int,int)
getCaretPosition
public final int getCaretPosition()
Returns the caret position. This will either be the selection
start or the selection end, depending on which direction the
selection was made in.
getCaretLine
public final int getCaretLine()
Returns the caret line.
getMarkPosition
public final int getMarkPosition()
Returns the mark position. This will be the opposite selection
bound to the caret position.
See Also:
getCaretPosition()
getMarkLine
public final int getMarkLine()
Returns the mark line.
setCaretPosition
public final void setCaretPosition(int caret)
Sets the caret position. The new selection will consist of the
caret position only (hence no text will be selected)
Parameters:
caret – The caret position
See Also:
select(int,int)
selectAll
public final void selectAll()
Selects all text in the document.
selectNone
public final void selectNone()
Moves the mark to the caret position.
select
public void select(int start,
int end)
Selects from the start offset to the end offset. This is the
general selection method used by all other selecting methods.
The caret position will be start if start < end, and end
if end > start.
Parameters:
start – The start offset
end – The end offset
getSelectedText
public final String getSelectedText()
Returns the selected text, or null if no selection is active.
setSelectedText
public void setSelectedText(String selectedText)
Replaces the selection with the specified text.
Parameters:
selectedText – The replacement text for the selection
isEditable
public final boolean isEditable()
Returns true if this text area is editable, false otherwise.
setEditable
public final void setEditable(boolean editable)
Sets if this component is editable.
Parameters:
editable – True if this text area should be editable,
false otherwise
getRightClickPopup
public final JPopupMenu getRightClickPopup()
Returns the right click popup menu.
setRightClickPopup
public final void setRightClickPopup(JPopupMenu popup)
Sets the right click popup menu.
Parameters:
popup – The popup
getMagicCaretPosition
public final int getMagicCaretPosition()
Returns the `magic’ caret position. This can be used to preserve
the column position when moving up and down lines.
setMagicCaretPosition
public final void setMagicCaretPosition(int magicCaret)
Sets the `magic’ caret position. This can be used to preserve
the column position when moving up and down lines.
Parameters:
magicCaret – The magic caret position
overwriteSetSelectedText
public void overwriteSetSelectedText(String str)
Similar to setSelectedText(), but overstrikes the
appropriate number of characters if overwrite mode is enabled.
Parameters:
str – The string
See Also:
setSelectedText(String),
isOverwriteEnabled()
isOverwriteEnabled
public final boolean isOverwriteEnabled()
Returns true if overwrite mode is enabled, false otherwise.
setOverwriteEnabled
public final void setOverwriteEnabled(boolean overwrite)
Sets if overwrite mode should be enabled.
Parameters:
overwrite – True if overwrite mode should be enabled,
false otherwise.
isSelectionRectangular
public final boolean isSelectionRectangular()
Returns true if the selection is rectangular, false otherwise.
setSelectionRectangular
public final void setSelectionRectangular(boolean rectSelect)
Sets if the selection should be rectangular.
Parameters:
overwrite – True if the selection should be rectangular,
false otherwise.
getBracketPosition
public final int getBracketPosition()
Returns the position of the highlighted bracket (the bracket
matching the one before the caret)
getBracketLine
public final int getBracketLine()
Returns the line of the highlighted bracket (the bracket
matching the one before the caret)
addCaretListener
public final void addCaretListener(CaretListener listener)
Adds a caret change listener to this text area.
Parameters:
listener – The listener
removeCaretListener
public final void removeCaretListener(CaretListener listener)
Removes a caret change listener from this text area.
Parameters:
listener – The listener
cut
public void cut()
Deletes the selected text from the text area and places it
into the clipboard.
copy
public void copy()
Places the selected text into the clipboard.
paste
public void paste()
Inserts the clipboard contents into the text.
removeNotify
public void removeNotify()
Called by the AWT when this component is removed from it’s parent.
This stops clears the currently focused component.
Overrides:
removeNotify in class JComponent
processKeyEvent
public void processKeyEvent(KeyEvent evt)
Forwards key events directly to the input handler.
This is slightly faster than using a KeyListener
because some Swing overhead is avoided.
Overrides:
processKeyEvent in class JComponent
fireCaretEvent
protected void fireCaretEvent()
updateBracketHighlight
protected void updateBracketHighlight(int newCaretPosition)
documentChanged
protected void documentChanged(DocumentEvent evt)
getSyntaxSensitiveToolTipText
public String getSyntaxSensitiveToolTipText(int x,
int y)
Return any relevant tool tip text for token at specified position. Keyword match
must be exact. DPS 24-May-2010
Parameters:
x – x-coordinate of current position
y – y-coordinate of current position
Returns:
String containing appropriate tool tip text. Possibly HTML-encoded.
getAutoIndent
public String getAutoIndent()
Constructs string for auto-indent feature. Returns empty string
if auto-intent is disabled or if line has no leading white space.
Uses getLeadingWhiteSpace(). Is used by InputHandler when processing
key press for Enter key. DPS 31-Dec-2010
Returns:
String containing auto-indent characters to be inserted into text
getLeadingWhiteSpace
public String getLeadingWhiteSpace()
Makes a copy of leading white space (tab or space) from the current line and
returns it. DPS 31-Dec-2010
Returns:
String containing leading white space of current line. Empty string if none.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.repeat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.repeat
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.repeat
All Implemented Interfaces:
ActionListener, EventListener, InputHandler.NonRecordable
Enclosing class:
InputHandler
public static class InputHandler.repeat
extends Object
implements ActionListener, InputHandler.NonRecordable
Constructor Summary
InputHandler.repeat()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.repeat
public InputHandler.repeat()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.end
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.end
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.end
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.end
extends Object
implements ActionListener
Constructor Summary
InputHandler.end(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.end
public InputHandler.end(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.prev_word
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.prev_word
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.prev_word
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.prev_word
extends Object
implements ActionListener
Constructor Summary
InputHandler.prev_word(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.prev_word
public InputHandler.prev_word(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
TextAreaPainter.Highlight
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Interface TextAreaPainter.Highlight
Enclosing class:
TextAreaPainter
public static interface TextAreaPainter.Highlight
Highlight interface.
Method Summary
String getToolTipText(MouseEvent evt)
Returns the tool tip to display at the specified
location.
void init(JEditTextArea textArea,
TextAreaPainter.Highlight next)
Called after the highlight painter has been added.
void paintHighlight(Graphics gfx,
int line,
int y)
This should paint the highlight and delgate to the
next highlight painter.
Method Detail
init
void init(JEditTextArea textArea,
TextAreaPainter.Highlight next)
Called after the highlight painter has been added.
Parameters:
textArea – The text area
next – The painter this one should delegate to
paintHighlight
void paintHighlight(Graphics gfx,
int line,
int y)
This should paint the highlight and delgate to the
next highlight painter.
Parameters:
gfx – The graphics context
line – The line number
y – The y co-ordinate of the line
getToolTipText
String getToolTipText(MouseEvent evt)
Returns the tool tip to display at the specified
location. If this highlighter doesn’t know what to
display, it should delegate to the next highlight
painter.
Parameters:
evt – The mouse event
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.backspace
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.backspace
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.backspace
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.backspace
extends Object
implements ActionListener
Constructor Summary
InputHandler.backspace()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.backspace
public InputHandler.backspace()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
JEditBasedTextArea
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class JEditBasedTextArea
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
mars.venus.editors.jeditsyntax.JEditTextArea
mars.venus.editors.jeditsyntax.JEditBasedTextArea
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, EventListener, CaretListener, MARSTextEditingArea
public class JEditBasedTextArea
extends JEditTextArea
implements MARSTextEditingArea, CaretListener
Adaptor subclass for JEditTextArea
Provides those methods required by the MARSTextEditingArea interface
that are not defined by JEditTextArea. This permits JEditTextArea
to be used within MARS largely without modification. DPS 4-20-2010
Since:
4.0
Author:
Pete Sanderson
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class mars.venus.editors.jeditsyntax.JEditTextArea
biasLeft, blink, BOTTOM, bracketLine, bracketPosition, caretBlinkRate, caretBlinks, caretEvent, caretTimer, caretVisible, CENTER, document, documentHandler, editable, electricScroll, firstLine, focusedComponent, horizontal, horizontalOffset, inputHandler, LEFT_OF_SCROLLBAR, lineSegment, listenerList, magicCaret, overwrite, painter, popup, rectSelect, RIGHT, scrollBarsInitialized, selectionEnd, selectionEndLine, selectionStart, selectionStartLine, unredoing, vertical, visibleLines
Fields inherited from class javax.swing.JComponent
accessibleContext, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface mars.venus.editors.MARSTextEditingArea
TEXT_FOUND, TEXT_NOT_FOUND, TEXT_REPLACED_FOUND_NEXT, TEXT_REPLACED_NOT_FOUND_NEXT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
JEditBasedTextArea(EditPane editPain,
JComponent lineNumbers)
Method Summary
void caretUpdate(CaretEvent e)
Display caret position on the edit pane.
void discardAllUndoableEdits()
Get rid of any accumulated undoable edits.
int doFindText(String find,
boolean caseSensitive)
Finds next occurrence of text in a forward search of a string.
int doReplace(String find,
String replace,
boolean caseSensitive)
Finds and replaces next occurrence of text in a string in a forward search.
int doReplaceAll(String find,
String replace,
boolean caseSensitive)
Finds and replaces ALL occurrences of text in a string in a forward search.
Font getFont()
Component getOuterComponent()
UndoManager getUndoManager()
Returns the undo manager for this editing area
int nextIndex(String input,
String find,
int start,
boolean caseSensitive)
Returns next posn of word in text – forward search.
void redo()
Redo previous edit
void replaceSelection(String replacementText)
Same as setSelectedText but named for compatibility with
JTextComponent method replaceSelection.
void setCaretBlinkRate(int rate)
Set the caret blinking rate in milliseconds.
void setFont(Font f)
void setLineHighlightEnabled(boolean highlight)
Use for highlighting the line currently being edited.
void setSelectionVisible(boolean vis)
void setSourceCode(String s,
boolean editable)
void setTabSize(int chars)
Set the number of characters a tab will expand to.
void undo()
Undo previous edit
void updateSyntaxStyles()
Update the syntax style table, which is obtained from
SyntaxUtilities.
Methods inherited from class mars.venus.editors.jeditsyntax.JEditTextArea
_offsetToX, addCaretListener, blinkCaret, copy, cut, documentChanged, fireCaretEvent, getAutoIndent, getBracketLine, getBracketPosition, getCaretLine, getCaretPosition, getDocument, getDocumentLength, getElectricScroll, getFirstLine, getHorizontalOffset, getInputHandler, getLeadingWhiteSpace, getLineCount, getLineEndOffset, getLineLength, getLineOfOffset, getLineStartOffset, getLineText, getLineText, getMagicCaretPosition, getMarkLine, getMarkPosition, getPainter, getRightClickPopup, getSelectedText, getSelectionEnd, getSelectionEnd, getSelectionEndLine, getSelectionStart, getSelectionStart, getSelectionStartLine, getSyntaxSensitiveToolTipText, getText, getText, getText, getTokenMarker, getVisibleLines, isCaretBlinkEnabled, isCaretVisible, isEditable, isOverwriteEnabled, isSelectionRectangular, lineToY, offsetToX, overwriteSetSelectedText, paste, processKeyEvent, recalculateVisibleLines, removeCaretListener, removeNotify, scrollTo, scrollToCaret, select, selectAll, selectNone, setCaretBlinkEnabled, setCaretPosition, setCaretVisible, setDocument, setEditable, setElectricScroll, setFirstLine, setHorizontalOffset, setInputHandler, setMagicCaretPosition, setOrigin, setOverwriteEnabled, setRightClickPopup, setSelectedText, setSelectionEnd, setSelectionRectangular, setSelectionStart, setText, setTokenMarker, updateBracketHighlight, updateScrollBars, xToOffset, xyToOffset, yToLine
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getUIClassID, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, paramString, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update, updateUI
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface mars.venus.editors.MARSTextEditingArea
copy, cut, getCaretPosition, getDocument, getFontMetrics, getSelectedText, getSelectionEnd, getSelectionStart, getText, grabFocus, paste, requestFocusInWindow, revalidate, select, selectAll, setBackground, setCaretPosition, setCaretVisible, setEditable, setEnabled, setSelectionEnd, setSelectionStart, setText
Constructor Detail
JEditBasedTextArea
public JEditBasedTextArea(EditPane editPain,
JComponent lineNumbers)
Method Detail
setFont
public void setFont(Font f)
Specified by:
setFont in interface MARSTextEditingArea
Overrides:
setFont in class JComponent
getFont
public Font getFont()
Specified by:
getFont in interface MenuContainer
Specified by:
getFont in interface MARSTextEditingArea
Overrides:
getFont in class Component
setLineHighlightEnabled
public void setLineHighlightEnabled(boolean highlight)
Use for highlighting the line currently being edited.
Specified by:
setLineHighlightEnabled in interface MARSTextEditingArea
Parameters:
highlight – true to enable line highlighting, false to disable.
setCaretBlinkRate
public void setCaretBlinkRate(int rate)
Set the caret blinking rate in milliseconds. If rate is 0
will disable blinking. If negative, do nothing.
Specified by:
setCaretBlinkRate in interface MARSTextEditingArea
Parameters:
rate – blinking rate in milliseconds
setTabSize
public void setTabSize(int chars)
Set the number of characters a tab will expand to.
Specified by:
setTabSize in interface MARSTextEditingArea
Parameters:
chars – number of characters
updateSyntaxStyles
public void updateSyntaxStyles()
Update the syntax style table, which is obtained from
SyntaxUtilities.
Specified by:
updateSyntaxStyles in interface MARSTextEditingArea
getOuterComponent
public Component getOuterComponent()
Specified by:
getOuterComponent in interface MARSTextEditingArea
discardAllUndoableEdits
public void discardAllUndoableEdits()
Get rid of any accumulated undoable edits. It is useful to call
this method after opening a file into the text area. The
act of setting its text content upon reading the file will generate
an undoable edit. Normally you don’t want a freshly-opened file
to appear with its Undo action enabled. But it will unless you
call this after setting the text.
Specified by:
discardAllUndoableEdits in interface MARSTextEditingArea
caretUpdate
public void caretUpdate(CaretEvent e)
Display caret position on the edit pane.
Specified by:
caretUpdate in interface CaretListener
Parameters:
e – A CaretEvent
replaceSelection
public void replaceSelection(String replacementText)
Same as setSelectedText but named for compatibility with
JTextComponent method replaceSelection.
DPS, 14 Apr 2010
Specified by:
replaceSelection in interface MARSTextEditingArea
Parameters:
replacementText – The replacement text for the selection
setSelectionVisible
public void setSelectionVisible(boolean vis)
Specified by:
setSelectionVisible in interface MARSTextEditingArea
setSourceCode
public void setSourceCode(String s,
boolean editable)
Specified by:
setSourceCode in interface MARSTextEditingArea
getUndoManager
public UndoManager getUndoManager()
Returns the undo manager for this editing area
Specified by:
getUndoManager in interface MARSTextEditingArea
Returns:
the undo manager
undo
public void undo()
Undo previous edit
Specified by:
undo in interface MARSTextEditingArea
redo
public void redo()
Redo previous edit
Specified by:
redo in interface MARSTextEditingArea
doFindText
public int doFindText(String find,
boolean caseSensitive)
Finds next occurrence of text in a forward search of a string. Search begins
at the current cursor location, and wraps around when the end of the string
is reached.
Specified by:
doFindText in interface MARSTextEditingArea
Parameters:
find – the text to locate in the string
caseSensitive – true if search is to be case-sensitive, false otherwise
Returns:
TEXT_FOUND or TEXT_NOT_FOUND, depending on the result.
nextIndex
public int nextIndex(String input,
String find,
int start,
boolean caseSensitive)
Returns next posn of word in text – forward search. If end of string is
reached during the search, will wrap around to the beginning one time.
Parameters:
input – the string to search
find – the string to find
start – the character position to start the search
caseSensitive – true for case sensitive. false to ignore case
Returns:
next indexed position of found text or -1 if not found
doReplace
public int doReplace(String find,
String replace,
boolean caseSensitive)
Finds and replaces next occurrence of text in a string in a forward search.
If cursor is initially at end
of matching selection, will immediately replace then find and select the
next occurrence if any. Otherwise it performs a find operation. The replace
can be undone with one undo operation.
Specified by:
doReplace in interface MARSTextEditingArea
Parameters:
find – the text to locate in the string
replace – the text to replace the find text with – if the find text exists
caseSensitive – true for case sensitive. false to ignore case
Returns:
Returns TEXT_FOUND if not initially at end of selected match and matching
occurrence is found. Returns TEXT_NOT_FOUND if the text is not matched.
Returns TEXT_REPLACED_NOT_FOUND_NEXT if replacement is successful but there are
no additional matches. Returns TEXT_REPLACED_FOUND_NEXT if reaplacement is
successful and there is at least one additional match.
doReplaceAll
public int doReplaceAll(String find,
String replace,
boolean caseSensitive)
Finds and replaces ALL occurrences of text in a string in a forward search.
All replacements are bundled into one CompoundEdit, so one Undo operation will
undo all of them.
Specified by:
doReplaceAll in interface MARSTextEditingArea
Parameters:
find – the text to locate in the string
replace – the text to replace the find text with – if the find text exists
caseSensitive – true for case sensitive. false to ignore case
Returns:
the number of occurrences that were matched and replaced.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
PopupHelpItem
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class PopupHelpItem
java.lang.Object
mars.venus.editors.jeditsyntax.PopupHelpItem
public class PopupHelpItem
extends Object
Handly little class to contain help information for a popupMenu or
tool tip item.
Constructor Summary
PopupHelpItem(String tokenText,
String example,
String description)
Create popup help item, where match is result of an exact-match search.
PopupHelpItem(String tokenText,
String example,
String description,
boolean exact)
Create popup help item.
Method Summary
String getDescription()
boolean getExact()
Determines whether match occurred in an exact-match or prefix-match search.
String getExample()
int getExampleLength()
String getExamplePaddedToLength(int length)
String getTokenText()
The document text that mached this item
static int maxExampleLength(ArrayList matches)
void setDescription(String description)
void setExample(String example)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
PopupHelpItem
public PopupHelpItem(String tokenText,
String example,
String description,
boolean exact)
Create popup help item. This is created as result of either an exact-match or
prefix-match search. Note that prefix-match search includes exact as well as partial matches.
Parameters:
tokenText – The document text that matched
example – An example instruction
description – A textual description of the instruction
exact – True if match occurred as result of exact-match search, false otherwise.
PopupHelpItem
public PopupHelpItem(String tokenText,
String example,
String description)
Create popup help item, where match is result of an exact-match search.
Parameters:
tokenText – The document text that matched
example – An example instruction
description – A textual description of the instruction
Method Detail
getTokenText
public String getTokenText()
The document text that mached this item
getExample
public String getExample()
getDescription
public String getDescription()
getExact
public boolean getExact()
Determines whether match occurred in an exact-match or prefix-match search.
Note this can return false even if the match is exact because prefix-match also
includes exact match results. E.g. prefix match on “lw” will match both “lwl” and “lw”.
Returns:
True if exact-match search, false otherwise.
getExampleLength
public int getExampleLength()
getExamplePaddedToLength
public String getExamplePaddedToLength(int length)
setExample
public void setExample(String example)
setDescription
public void setDescription(String description)
maxExampleLength
public static int maxExampleLength(ArrayList matches)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DefaultInputHandler
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class DefaultInputHandler
java.lang.Object
java.awt.event.KeyAdapter
mars.venus.editors.jeditsyntax.InputHandler
mars.venus.editors.jeditsyntax.DefaultInputHandler
All Implemented Interfaces:
KeyListener, EventListener
public class DefaultInputHandler
extends InputHandler
The default input handler. It maps sequences of keystrokes into actions
and inserts key typed events into the text area.
Author:
Slava Pestov
Nested Class Summary
Nested classes/interfaces inherited from class mars.venus.editors.jeditsyntax.InputHandler
InputHandler.backspace, InputHandler.backspace_word, InputHandler.clip_copy, InputHandler.clip_cut, InputHandler.clip_paste, InputHandler.delete, InputHandler.delete_word, InputHandler.document_end, InputHandler.document_home, InputHandler.end, InputHandler.home, InputHandler.insert_break, InputHandler.insert_char, InputHandler.insert_tab, InputHandler.MacroRecorder, InputHandler.next_char, InputHandler.next_line, InputHandler.next_page, InputHandler.next_word, InputHandler.NonRecordable, InputHandler.NonRepeatable, InputHandler.overwrite, InputHandler.prev_char, InputHandler.prev_line, InputHandler.prev_page, InputHandler.prev_word, InputHandler.repeat, InputHandler.select_all, InputHandler.toggle_rect, InputHandler.Wrapper
Field Summary
Fields inherited from class mars.venus.editors.jeditsyntax.InputHandler
BACKSPACE, BACKSPACE_WORD, CLIP_COPY, CLIP_CUT, CLIP_PASTE, DELETE, DELETE_WORD, DOCUMENT_END, DOCUMENT_HOME, END, grabAction, HOME, INSERT_BREAK, INSERT_CHAR, INSERT_TAB, NEXT_CHAR, NEXT_LINE, NEXT_PAGE, NEXT_WORD, OVERWRITE, PREV_CHAR, PREV_LINE, PREV_PAGE, PREV_WORD, recorder, repeat, REPEAT, repeatCount, SELECT_ALL, SELECT_DOC_END, SELECT_DOC_HOME, SELECT_END, SELECT_HOME, SELECT_NEXT_CHAR, SELECT_NEXT_LINE, SELECT_NEXT_PAGE, SELECT_NEXT_WORD, SELECT_PREV_CHAR, SELECT_PREV_LINE, SELECT_PREV_PAGE, SELECT_PREV_WORD, SMART_HOME_END_PROPERTY, TOGGLE_RECT
Constructor Summary
DefaultInputHandler()
Creates a new input handler with no key bindings defined.
Method Summary
void addDefaultKeyBindings()
Sets up the default key bindings.
void addKeyBinding(String keyBinding,
ActionListener action)
Adds a key binding to this input handler.
InputHandler copy()
Returns a copy of this input handler that shares the same
key bindings.
void keyPressed(KeyEvent evt)
Handle a key pressed event.
void keyTyped(KeyEvent evt)
Handle a key typed event.
static KeyStroke parseKeyStroke(String keyStroke)
Converts a string to a keystroke.
void removeAllKeyBindings()
Removes all key bindings from this input handler.
void removeKeyBinding(String keyBinding)
Removes a key binding from this input handler.
Methods inherited from class mars.venus.editors.jeditsyntax.InputHandler
executeAction, getAction, getActionName, getActions, getMacroRecorder, getRepeatCount, getTextArea, grabNextKeyStroke, handleGrabAction, isRepeatEnabled, setMacroRecorder, setRepeatCount, setRepeatEnabled
Methods inherited from class java.awt.event.KeyAdapter
keyReleased
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
DefaultInputHandler
public DefaultInputHandler()
Creates a new input handler with no key bindings defined.
Method Detail
addDefaultKeyBindings
public void addDefaultKeyBindings()
Sets up the default key bindings.
Specified by:
addDefaultKeyBindings in class InputHandler
addKeyBinding
public void addKeyBinding(String keyBinding,
ActionListener action)
Adds a key binding to this input handler. The key binding is
a list of white space separated key strokes of the form
[modifiers+]key where modifier is C for Control, A for Alt,
or S for Shift, and key is either a character (a-z) or a field
name in the KeyEvent class prefixed with VK_ (e.g., BACK_SPACE)
Specified by:
addKeyBinding in class InputHandler
Parameters:
keyBinding – The key binding
action – The action
removeKeyBinding
public void removeKeyBinding(String keyBinding)
Removes a key binding from this input handler. This is not yet
implemented.
Specified by:
removeKeyBinding in class InputHandler
Parameters:
keyBinding – The key binding
removeAllKeyBindings
public void removeAllKeyBindings()
Removes all key bindings from this input handler.
Specified by:
removeAllKeyBindings in class InputHandler
copy
public InputHandler copy()
Returns a copy of this input handler that shares the same
key bindings. Setting key bindings in the copy will also
set them in the original.
Specified by:
copy in class InputHandler
keyPressed
public void keyPressed(KeyEvent evt)
Handle a key pressed event. This will look up the binding for
the key stroke and execute it.
Specified by:
keyPressed in interface KeyListener
Overrides:
keyPressed in class KeyAdapter
keyTyped
public void keyTyped(KeyEvent evt)
Handle a key typed event. This inserts the key into the text area.
Specified by:
keyTyped in interface KeyListener
Overrides:
keyTyped in class KeyAdapter
parseKeyStroke
public static KeyStroke parseKeyStroke(String keyStroke)
Converts a string to a keystroke. The string should be of the
form modifiers+shortcut where modifiers
is any combination of A for Alt, C for Control, S for Shift
or M for Meta, and shortcut is either a single character,
or a keycode name from the KeyEvent class, without
the VK_ prefix.
Parameters:
keyStroke – A string description of the key stroke
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
TokenMarker
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax.tokenmarker
Class TokenMarker
java.lang.Object
mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
Direct Known Subclasses:
MIPSTokenMarker
public abstract class TokenMarker
extends Object
A token marker that splits lines of text into tokens. Each token carries
a length field and an indentification tag that can be mapped to a color
for painting that token.
For performance reasons, the linked list of tokens is reused after each
line is tokenized. Therefore, the return value of markTokens
should only be used for immediate painting. Notably, it cannot be
cached.
Author:
Slava Pestov
See Also:
org.syntax.jedit.Token
Nested Class Summary
class TokenMarker.LineInfo
Inner class for storing information about tokenized lines.
Field Summary
protected Token firstToken
The first token in the list.
protected int lastLine
The last tokenized line.
protected Token lastToken
The last token in the list.
protected int length
The number of lines in the model being tokenized.
protected TokenMarker.LineInfo[] lineInfo
An array for storing information about lines.
protected boolean nextLineRequested
True if the next line should be painted.
Constructor Summary
protected TokenMarker()
Creates a new TokenMarker.
Method Summary
protected void addToken(int length,
byte id)
Adds a token to the token list.
void deleteLines(int index,
int lines)
Informs the token marker that line have been deleted from
the document.
protected void ensureCapacity(int index)
Ensures that the lineInfo array can contain the
specified index.
int getLineCount()
Returns the number of lines in this token marker.
ArrayList getTokenExactMatchHelp(Token token,
String tokenText)
Construct and return any appropriate help information for
the given token.
ArrayList getTokenPrefixMatchHelp(String line,
Token tokenList,
Token tokenAtOffset,
String tokenText)
Construct and return any appropriate help information for
the given token or “token prefix”.
void insertLines(int index,
int lines)
Informs the token marker that lines have been inserted into
the document.
boolean isNextLineRequested()
Returns true if the next line should be repainted.
Token markTokens(Segment line,
int lineIndex)
A wrapper for the lower-level markTokensImpl method
that is called to split a line up into tokens.
protected abstract byte markTokensImpl(byte token,
Segment line,
int lineIndex)
An abstract method that splits a line up into tokens.
boolean supportsMultilineTokens()
Returns if the token marker supports tokens that span multiple
lines.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
firstToken
protected Token firstToken
The first token in the list. This should be used as the return
value from markTokens().
lastToken
protected Token lastToken
The last token in the list. New tokens are added here.
This should be set to null before a new line is to be tokenized.
lineInfo
protected TokenMarker.LineInfo[] lineInfo
An array for storing information about lines. It is enlarged and
shrunk automatically by the insertLines() and
deleteLines() methods.
length
protected int length
The number of lines in the model being tokenized. This can be
less than the length of the lineInfo array.
lastLine
protected int lastLine
The last tokenized line.
nextLineRequested
protected boolean nextLineRequested
True if the next line should be painted.
Constructor Detail
TokenMarker
protected TokenMarker()
Creates a new TokenMarker. This DOES NOT create
a lineInfo array; an initial call to insertLines()
does that.
Method Detail
markTokens
public Token markTokens(Segment line,
int lineIndex)
A wrapper for the lower-level markTokensImpl method
that is called to split a line up into tokens.
Parameters:
line – The line
lineIndex – The line number
markTokensImpl
protected abstract byte markTokensImpl(byte token,
Segment line,
int lineIndex)
An abstract method that splits a line up into tokens. It
should parse the line, and call addToken() to
add syntax tokens to the token list. Then, it should return
the initial token type for the next line.
For example if the current line contains the start of a
multiline comment that doesn’t end on that line, this method
should return the comment token type so that it continues on
the next line.
Parameters:
token – The initial token type for this line
line – The line to be tokenized
lineIndex – The index of the line in the document, starting at 0
Returns:
The initial token type for the next line
supportsMultilineTokens
public boolean supportsMultilineTokens()
Returns if the token marker supports tokens that span multiple
lines. If this is true, the object using this token marker is
required to pass all lines in the document to the
markTokens() method (in turn).
The default implementation returns true; it should be overridden
to return false on simpler token markers for increased speed.
insertLines
public void insertLines(int index,
int lines)
Informs the token marker that lines have been inserted into
the document. This inserts a gap in the lineInfo
array.
Parameters:
index – The first line number
lines – The number of lines
deleteLines
public void deleteLines(int index,
int lines)
Informs the token marker that line have been deleted from
the document. This removes the lines in question from the
lineInfo array.
Parameters:
index – The first line number
lines – The number of lines
getLineCount
public int getLineCount()
Returns the number of lines in this token marker.
isNextLineRequested
public boolean isNextLineRequested()
Returns true if the next line should be repainted. This
will return true after a line has been tokenized that starts
a multiline token that continues onto the next line.
getTokenExactMatchHelp
public ArrayList getTokenExactMatchHelp(Token token,
String tokenText)
Construct and return any appropriate help information for
the given token. This default definition returns null;
override it in language-specific subclasses.
Parameters:
token – the pertinent Token object
tokenText – the source String that matched to the token
Returns:
ArrayList containing PopupHelpItem objects, one per match.
getTokenPrefixMatchHelp
public ArrayList getTokenPrefixMatchHelp(String line,
Token tokenList,
Token tokenAtOffset,
String tokenText)
Construct and return any appropriate help information for
the given token or “token prefix”. Will match instruction prefixes, e.g. “s” matches “sw”.
This default definition returns null;
override it in language-specific subclasses.
Parameters:
line – String containing current line
tokenList – first Token on the current line
token – the pertinent Token object
tokenText – the source String that matched to the token
Returns:
ArrayList containing PopupHelpItem objects, one per match.
ensureCapacity
protected void ensureCapacity(int index)
Ensures that the lineInfo array can contain the
specified index. This enlarges it if necessary. No action is
taken if the array is large enough already.
It should be unnecessary to call this under normal
circumstances; insertLine() should take care of
enlarging the line info array automatically.
Parameters:
index – The array index
addToken
protected void addToken(int length,
byte id)
Adds a token to the token list.
Parameters:
length – The length of the token
id – The id of the token
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MIPSTokenMarker
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax.tokenmarker
Class MIPSTokenMarker
java.lang.Object
mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
public class MIPSTokenMarker
extends TokenMarker
MIPS token marker.
Author:
Pete Sanderson (2010) and Slava Pestov (1999)
Nested Class Summary
Nested classes/interfaces inherited from class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
TokenMarker.LineInfo
Field Summary
Fields inherited from class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
firstToken, lastLine, lastToken, length, lineInfo, nextLineRequested
Constructor Summary
MIPSTokenMarker()
MIPSTokenMarker(KeywordMap keywords)
Method Summary
static KeywordMap getKeywords()
Get KeywordMap containing all MIPS key words.
static String[] getMIPSTokenExamples()
static String[] getMIPSTokenLabels()
ArrayList getTokenExactMatchHelp(Token token,
String tokenText)
Construct and return any appropriate help information for
the given token.
ArrayList getTokenPrefixMatchHelp(String line,
Token tokenList,
Token token,
String tokenText)
Construct and return any appropriate help information for
prefix match based on current line’s token list.
byte markTokensImpl(byte token,
Segment line,
int lineIndex)
An abstract method that splits a line up into tokens.
Methods inherited from class mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker
addToken, deleteLines, ensureCapacity, getLineCount, insertLines, isNextLineRequested, markTokens, supportsMultilineTokens
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
MIPSTokenMarker
public MIPSTokenMarker()
MIPSTokenMarker
public MIPSTokenMarker(KeywordMap keywords)
Method Detail
getMIPSTokenLabels
public static String[] getMIPSTokenLabels()
getMIPSTokenExamples
public static String[] getMIPSTokenExamples()
markTokensImpl
public byte markTokensImpl(byte token,
Segment line,
int lineIndex)
Description copied from class: TokenMarker
An abstract method that splits a line up into tokens. It
should parse the line, and call addToken() to
add syntax tokens to the token list. Then, it should return
the initial token type for the next line.
For example if the current line contains the start of a
multiline comment that doesn’t end on that line, this method
should return the comment token type so that it continues on
the next line.
Specified by:
markTokensImpl in class TokenMarker
Parameters:
token – The initial token type for this line
line – The line to be tokenized
lineIndex – The index of the line in the document, starting at 0
Returns:
The initial token type for the next line
getTokenExactMatchHelp
public ArrayList getTokenExactMatchHelp(Token token,
String tokenText)
Construct and return any appropriate help information for
the given token.
Overrides:
getTokenExactMatchHelp in class TokenMarker
Parameters:
token – the pertinent Token object
tokenText – the source String that matched to the token
Returns:
ArrayList of PopupHelpItem objects, one per match.
getTokenPrefixMatchHelp
public ArrayList getTokenPrefixMatchHelp(String line,
Token tokenList,
Token token,
String tokenText)
Construct and return any appropriate help information for
prefix match based on current line’s token list.
Overrides:
getTokenPrefixMatchHelp in class TokenMarker
Parameters:
line – String containing current line
tokenList – first Token on current line (head of linked list)
token – the pertinent Token object
tokenText – the source String that matched to the token in previous parameter
Returns:
ArrayList of PopupHelpItem objects, one per match.
getKeywords
public static KeywordMap getKeywords()
Get KeywordMap containing all MIPS key words. This includes all instruction mnemonics,
assembler directives, and register names.
Returns:
KeywordMap where key is the keyword and associated value is the token type (e.g. Token.KEYWORD1).
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax.tokenmarker
mars.venus.editors.jeditsyntax.tokenmarker
Classes
MIPSTokenMarker
Token
TokenMarker
mars.venus.editors.jeditsyntax.tokenmarker
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.venus.editors.jeditsyntax.tokenmarker
Class Summary
MIPSTokenMarker MIPS token marker.
Token A linked list of tokens.
TokenMarker A token marker that splits lines of text into tokens.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
TokenMarker.LineInfo
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax.tokenmarker
Class TokenMarker.LineInfo
java.lang.Object
mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker.LineInfo
Enclosing class:
TokenMarker
public class TokenMarker.LineInfo
extends Object
Inner class for storing information about tokenized lines.
Field Summary
Object obj
This is for use by the token marker implementations
themselves.
byte token
The id of the last token of the line.
Constructor Summary
TokenMarker.LineInfo()
Creates a new LineInfo object with token = Token.NULL
and obj = null.
TokenMarker.LineInfo(byte token,
Object obj)
Creates a new LineInfo object with the specified
parameters.
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
token
public byte token
The id of the last token of the line.
obj
public Object obj
This is for use by the token marker implementations
themselves. It can be used to store anything that
is an object and that needs to exist on a per-line
basis.
Constructor Detail
TokenMarker.LineInfo
public TokenMarker.LineInfo()
Creates a new LineInfo object with token = Token.NULL
and obj = null.
TokenMarker.LineInfo
public TokenMarker.LineInfo(byte token,
Object obj)
Creates a new LineInfo object with the specified
parameters.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax.tokenmarker Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.venus.editors.jeditsyntax.tokenmarker
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object mars.venus.editors.jeditsyntax.tokenmarker.Token
mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker mars.venus.editors.jeditsyntax.tokenmarker.MIPSTokenMarker
mars.venus.editors.jeditsyntax.tokenmarker.TokenMarker.LineInfo
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Token
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax.tokenmarker
Class Token
java.lang.Object
mars.venus.editors.jeditsyntax.tokenmarker.Token
public class Token
extends Object
A linked list of tokens. Each token has three fields – a token
identifier, which is a byte value that can be looked up in the
array returned by SyntaxDocument.getColors()
to get a color value, a length value which is the length of the
token in the text, and a pointer to the next token in the list.
Author:
Slava Pestov
Field Summary
static byte COMMENT1
Comment 1 token id.
static byte COMMENT2
Comment 2 token id.
static byte END
The token type, that along with a length of 0
marks the end of the token list.
byte id
The id of this token.
static byte ID_COUNT
The total number of defined token ids.
static byte INTERNAL_FIRST
The first id that can be used for internal state
in a token marker.
static byte INTERNAL_LAST
The last id that can be used for internal state
in a token marker.
static byte INVALID
Invalid token id.
static byte KEYWORD1
Keyword 1 token id.
static byte KEYWORD2
Keyword 2 token id.
static byte KEYWORD3
Keyword 3 token id.
static byte LABEL
Label token id.
int length
The length of this token.
static byte LITERAL1
Literal 1 token id.
static byte LITERAL2
Literal 2 token id.
static byte MACRO_ARG
Macro parameter token.
Token next
The next token in the linked list.
static byte NULL
Normal text token id.
static byte OPERATOR
Operator token id.
Constructor Summary
Token(int length,
byte id)
Creates a new token.
Method Summary
String toString()
Returns a string representation of this token.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
NULL
public static final byte NULL
Normal text token id. This should be used to mark
normal text.
See Also:
Constant Field Values
COMMENT1
public static final byte COMMENT1
Comment 1 token id. This can be used to mark a comment.
See Also:
Constant Field Values
COMMENT2
public static final byte COMMENT2
Comment 2 token id. This can be used to mark a comment.
See Also:
Constant Field Values
LITERAL1
public static final byte LITERAL1
Literal 1 token id. This can be used to mark a string
literal (eg, C mode uses this to mark “…” literals)
See Also:
Constant Field Values
LITERAL2
public static final byte LITERAL2
Literal 2 token id. This can be used to mark an object
literal (eg, Java mode uses this to mark true, false, etc)
See Also:
Constant Field Values
LABEL
public static final byte LABEL
Label token id. This can be used to mark labels
(eg, C mode uses this to mark …: sequences)
See Also:
Constant Field Values
KEYWORD1
public static final byte KEYWORD1
Keyword 1 token id. This can be used to mark a
keyword. This should be used for general language
constructs.
See Also:
Constant Field Values
KEYWORD2
public static final byte KEYWORD2
Keyword 2 token id. This can be used to mark a
keyword. This should be used for preprocessor
commands, or variables.
See Also:
Constant Field Values
KEYWORD3
public static final byte KEYWORD3
Keyword 3 token id. This can be used to mark a
keyword. This should be used for data types.
See Also:
Constant Field Values
OPERATOR
public static final byte OPERATOR
Operator token id. This can be used to mark an
operator. (eg, SQL mode marks +, -, etc with this
token type)
See Also:
Constant Field Values
INVALID
public static final byte INVALID
Invalid token id. This can be used to mark invalid
or incomplete tokens, so the user can easily spot
syntax errors.
See Also:
Constant Field Values
MACRO_ARG
public static final byte MACRO_ARG
Macro parameter token. Added for MARS 4.3.
See Also:
Constant Field Values
ID_COUNT
public static final byte ID_COUNT
The total number of defined token ids.
See Also:
Constant Field Values
INTERNAL_FIRST
public static final byte INTERNAL_FIRST
The first id that can be used for internal state
in a token marker.
See Also:
Constant Field Values
INTERNAL_LAST
public static final byte INTERNAL_LAST
The last id that can be used for internal state
in a token marker.
See Also:
Constant Field Values
END
public static final byte END
The token type, that along with a length of 0
marks the end of the token list.
See Also:
Constant Field Values
length
public int length
The length of this token.
id
public byte id
The id of this token.
next
public Token next
The next token in the linked list.
Constructor Detail
Token
public Token(int length,
byte id)
Creates a new token.
Parameters:
length – The length of the token
id – The id of the token
Method Detail
toString
public String toString()
Returns a string representation of this token.
Overrides:
toString in class Object
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.NonRepeatable
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Interface InputHandler.NonRepeatable
All Known Implementing Classes:
InputHandler.insert_char
Enclosing class:
InputHandler
public static interface InputHandler.NonRepeatable
If an action implements this interface, it should not be repeated.
Instead, it will handle the repetition itself.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.next_char
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.next_char
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.next_char
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.next_char
extends Object
implements ActionListener
Constructor Summary
InputHandler.next_char(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.next_char
public InputHandler.next_char(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.prev_char
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.prev_char
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.prev_char
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.prev_char
extends Object
implements ActionListener
Constructor Summary
InputHandler.prev_char(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.prev_char
public InputHandler.prev_char(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.clip_paste
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.clip_paste
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.clip_paste
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.clip_paste
extends Object
implements ActionListener
Constructor Summary
InputHandler.clip_paste()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.clip_paste
public InputHandler.clip_paste()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler
java.lang.Object
java.awt.event.KeyAdapter
mars.venus.editors.jeditsyntax.InputHandler
All Implemented Interfaces:
KeyListener, EventListener
Direct Known Subclasses:
DefaultInputHandler
public abstract class InputHandler
extends KeyAdapter
An input handler converts the user’s key strokes into concrete actions.
It also takes care of macro recording and action repetition.
This class provides all the necessary support code for an input
handler, but doesn’t actually do any key binding logic. It is up
to the implementations of this class to do so.
Author:
Slava Pestov
See Also:
08/12/2002 Clipboard actions (Oliver Henning)
Nested Class Summary
static class InputHandler.backspace
static class InputHandler.backspace_word
static class InputHandler.clip_copy
static class InputHandler.clip_cut
static class InputHandler.clip_paste
static class InputHandler.delete
static class InputHandler.delete_word
static class InputHandler.document_end
static class InputHandler.document_home
static class InputHandler.end
static class InputHandler.home
static class InputHandler.insert_break
static class InputHandler.insert_char
static class InputHandler.insert_tab
static interface InputHandler.MacroRecorder
Macro recorder.
static class InputHandler.next_char
static class InputHandler.next_line
static class InputHandler.next_page
static class InputHandler.next_word
static interface InputHandler.NonRecordable
If an action implements this interface, it should not be recorded
by the macro recorder.
static interface InputHandler.NonRepeatable
If an action implements this interface, it should not be repeated.
static class InputHandler.overwrite
static class InputHandler.prev_char
static class InputHandler.prev_line
static class InputHandler.prev_page
static class InputHandler.prev_word
static class InputHandler.repeat
static class InputHandler.select_all
static class InputHandler.toggle_rect
static interface InputHandler.Wrapper
For use by EditAction.Wrapper only.
Field Summary
static ActionListener BACKSPACE
static ActionListener BACKSPACE_WORD
static ActionListener CLIP_COPY
static ActionListener CLIP_CUT
static ActionListener CLIP_PASTE
static ActionListener DELETE
static ActionListener DELETE_WORD
static ActionListener DOCUMENT_END
static ActionListener DOCUMENT_HOME
static ActionListener END
protected ActionListener grabAction
static ActionListener HOME
static ActionListener INSERT_BREAK
static ActionListener INSERT_CHAR
static ActionListener INSERT_TAB
static ActionListener NEXT_CHAR
static ActionListener NEXT_LINE
static ActionListener NEXT_PAGE
static ActionListener NEXT_WORD
static ActionListener OVERWRITE
static ActionListener PREV_CHAR
static ActionListener PREV_LINE
static ActionListener PREV_PAGE
static ActionListener PREV_WORD
protected InputHandler.MacroRecorder recorder
protected boolean repeat
static ActionListener REPEAT
protected int repeatCount
static ActionListener SELECT_ALL
static ActionListener SELECT_DOC_END
static ActionListener SELECT_DOC_HOME
static ActionListener SELECT_END
static ActionListener SELECT_HOME
static ActionListener SELECT_NEXT_CHAR
static ActionListener SELECT_NEXT_LINE
static ActionListener SELECT_NEXT_PAGE
static ActionListener SELECT_NEXT_WORD
static ActionListener SELECT_PREV_CHAR
static ActionListener SELECT_PREV_LINE
static ActionListener SELECT_PREV_PAGE
static ActionListener SELECT_PREV_WORD
static String SMART_HOME_END_PROPERTY
If this client property is set to Boolean.TRUE on the text area,
the home/end keys will support ‘smart’ BRIEF-like behaviour
(one press = start/end of line, two presses = start/end of
viewscreen, three presses = start/end of document).
static ActionListener TOGGLE_RECT
Constructor Summary
InputHandler()
Method Summary
abstract void addDefaultKeyBindings()
Adds the default key bindings to this input handler.
abstract void addKeyBinding(String keyBinding,
ActionListener action)
Adds a key binding to this input handler.
abstract InputHandler copy()
Returns a copy of this input handler that shares the same
key bindings.
void executeAction(ActionListener listener,
Object source,
String actionCommand)
Executes the specified action, repeating and recording it as
necessary.
static ActionListener getAction(String name)
Returns a named text area action.
static String getActionName(ActionListener listener)
Returns the name of the specified text area action.
static Enumeration getActions()
Returns an enumeration of all available actions.
InputHandler.MacroRecorder getMacroRecorder()
Returns the macro recorder.
int getRepeatCount()
Returns the number of times the next action will be repeated.
static JEditTextArea getTextArea(EventObject evt)
Returns the text area that fired the specified event.
void grabNextKeyStroke(ActionListener listener)
Grabs the next key typed event and invokes the specified
action with the key as a the action command.
protected void handleGrabAction(KeyEvent evt)
If a key is being grabbed, this method should be called with
the appropriate key event.
boolean isRepeatEnabled()
Returns if repeating is enabled.
abstract void removeAllKeyBindings()
Removes all key bindings from this input handler.
abstract void removeKeyBinding(String keyBinding)
Removes a key binding from this input handler.
void setMacroRecorder(InputHandler.MacroRecorder recorder)
Sets the macro recorder.
void setRepeatCount(int repeatCount)
Sets the number of times the next action will be repeated.
void setRepeatEnabled(boolean repeat)
Enables repeating.
Methods inherited from class java.awt.event.KeyAdapter
keyPressed, keyReleased, keyTyped
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
SMART_HOME_END_PROPERTY
public static final String SMART_HOME_END_PROPERTY
If this client property is set to Boolean.TRUE on the text area,
the home/end keys will support ‘smart’ BRIEF-like behaviour
(one press = start/end of line, two presses = start/end of
viewscreen, three presses = start/end of document). By default,
this property is not set.
See Also:
Constant Field Values
BACKSPACE
public static final ActionListener BACKSPACE
BACKSPACE_WORD
public static final ActionListener BACKSPACE_WORD
DELETE
public static final ActionListener DELETE
DELETE_WORD
public static final ActionListener DELETE_WORD
END
public static final ActionListener END
DOCUMENT_END
public static final ActionListener DOCUMENT_END
SELECT_ALL
public static final ActionListener SELECT_ALL
SELECT_END
public static final ActionListener SELECT_END
SELECT_DOC_END
public static final ActionListener SELECT_DOC_END
INSERT_BREAK
public static final ActionListener INSERT_BREAK
INSERT_TAB
public static final ActionListener INSERT_TAB
HOME
public static final ActionListener HOME
DOCUMENT_HOME
public static final ActionListener DOCUMENT_HOME
SELECT_HOME
public static final ActionListener SELECT_HOME
SELECT_DOC_HOME
public static final ActionListener SELECT_DOC_HOME
NEXT_CHAR
public static final ActionListener NEXT_CHAR
NEXT_LINE
public static final ActionListener NEXT_LINE
NEXT_PAGE
public static final ActionListener NEXT_PAGE
NEXT_WORD
public static final ActionListener NEXT_WORD
SELECT_NEXT_CHAR
public static final ActionListener SELECT_NEXT_CHAR
SELECT_NEXT_LINE
public static final ActionListener SELECT_NEXT_LINE
SELECT_NEXT_PAGE
public static final ActionListener SELECT_NEXT_PAGE
SELECT_NEXT_WORD
public static final ActionListener SELECT_NEXT_WORD
OVERWRITE
public static final ActionListener OVERWRITE
PREV_CHAR
public static final ActionListener PREV_CHAR
PREV_LINE
public static final ActionListener PREV_LINE
PREV_PAGE
public static final ActionListener PREV_PAGE
PREV_WORD
public static final ActionListener PREV_WORD
SELECT_PREV_CHAR
public static final ActionListener SELECT_PREV_CHAR
SELECT_PREV_LINE
public static final ActionListener SELECT_PREV_LINE
SELECT_PREV_PAGE
public static final ActionListener SELECT_PREV_PAGE
SELECT_PREV_WORD
public static final ActionListener SELECT_PREV_WORD
REPEAT
public static final ActionListener REPEAT
TOGGLE_RECT
public static final ActionListener TOGGLE_RECT
CLIP_COPY
public static final ActionListener CLIP_COPY
CLIP_PASTE
public static final ActionListener CLIP_PASTE
CLIP_CUT
public static final ActionListener CLIP_CUT
INSERT_CHAR
public static final ActionListener INSERT_CHAR
grabAction
protected ActionListener grabAction
repeat
protected boolean repeat
repeatCount
protected int repeatCount
recorder
protected InputHandler.MacroRecorder recorder
Constructor Detail
InputHandler
public InputHandler()
Method Detail
getAction
public static ActionListener getAction(String name)
Returns a named text area action.
Parameters:
name – The action name
getActionName
public static String getActionName(ActionListener listener)
Returns the name of the specified text area action.
Parameters:
listener – The action
getActions
public static Enumeration getActions()
Returns an enumeration of all available actions.
addDefaultKeyBindings
public abstract void addDefaultKeyBindings()
Adds the default key bindings to this input handler.
This should not be called in the constructor of this
input handler, because applications might load the
key bindings from a file, etc.
addKeyBinding
public abstract void addKeyBinding(String keyBinding,
ActionListener action)
Adds a key binding to this input handler.
Parameters:
keyBinding – The key binding (the format of this is
input-handler specific)
action – The action
removeKeyBinding
public abstract void removeKeyBinding(String keyBinding)
Removes a key binding from this input handler.
Parameters:
keyBinding – The key binding
removeAllKeyBindings
public abstract void removeAllKeyBindings()
Removes all key bindings from this input handler.
grabNextKeyStroke
public void grabNextKeyStroke(ActionListener listener)
Grabs the next key typed event and invokes the specified
action with the key as a the action command.
Parameters:
action – The action
isRepeatEnabled
public boolean isRepeatEnabled()
Returns if repeating is enabled. When repeating is enabled,
actions will be executed multiple times. This is usually
invoked with a special key stroke in the input handler.
setRepeatEnabled
public void setRepeatEnabled(boolean repeat)
Enables repeating. When repeating is enabled, actions will be
executed multiple times. Once repeating is enabled, the input
handler should read a number from the keyboard.
getRepeatCount
public int getRepeatCount()
Returns the number of times the next action will be repeated.
setRepeatCount
public void setRepeatCount(int repeatCount)
Sets the number of times the next action will be repeated.
Parameters:
repeatCount – The repeat count
getMacroRecorder
public InputHandler.MacroRecorder getMacroRecorder()
Returns the macro recorder. If this is non-null, all executed
actions should be forwarded to the recorder.
setMacroRecorder
public void setMacroRecorder(InputHandler.MacroRecorder recorder)
Sets the macro recorder. If this is non-null, all executed
actions should be forwarded to the recorder.
Parameters:
recorder – The macro recorder
copy
public abstract InputHandler copy()
Returns a copy of this input handler that shares the same
key bindings. Setting key bindings in the copy will also
set them in the original.
executeAction
public void executeAction(ActionListener listener,
Object source,
String actionCommand)
Executes the specified action, repeating and recording it as
necessary.
Parameters:
listener – The action listener
source – The event source
actionCommand – The action command
getTextArea
public static JEditTextArea getTextArea(EventObject evt)
Returns the text area that fired the specified event.
Parameters:
evt – The event
handleGrabAction
protected void handleGrabAction(KeyEvent evt)
If a key is being grabbed, this method should be called with
the appropriate key event. It executes the grab action with
the typed character as the parameter.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.clip_copy
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.clip_copy
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.clip_copy
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.clip_copy
extends Object
implements ActionListener
Constructor Summary
InputHandler.clip_copy()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.clip_copy
public InputHandler.clip_copy()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
TextAreaDefaults
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class TextAreaDefaults
java.lang.Object
mars.venus.editors.jeditsyntax.TextAreaDefaults
public class TextAreaDefaults
extends Object
Encapsulates default settings for a text area. This can be passed
to the constructor once the necessary fields have been filled out.
The advantage of doing this over calling lots of set() methods after
creating the text area is that this method is faster.
Field Summary
boolean blockCaret
boolean bracketHighlight
Color bracketHighlightColor
int caretBlinkRate
boolean caretBlinks
Color caretColor
boolean caretVisible
int cols
SyntaxDocument document
boolean editable
int electricScroll
Color eolMarkerColor
boolean eolMarkers
InputHandler inputHandler
boolean lineHighlight
Color lineHighlightColor
boolean paintInvalid
JPopupMenu popup
int rows
Color selectionColor
SyntaxStyle[] styles
int tabSize
Constructor Summary
TextAreaDefaults()
Method Summary
static TextAreaDefaults getDefaults()
Returns a new TextAreaDefaults object with the default values filled
in.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
inputHandler
public InputHandler inputHandler
document
public SyntaxDocument document
editable
public boolean editable
caretVisible
public boolean caretVisible
caretBlinks
public boolean caretBlinks
blockCaret
public boolean blockCaret
caretBlinkRate
public int caretBlinkRate
electricScroll
public int electricScroll
tabSize
public int tabSize
cols
public int cols
rows
public int rows
styles
public SyntaxStyle[] styles
caretColor
public Color caretColor
selectionColor
public Color selectionColor
lineHighlightColor
public Color lineHighlightColor
lineHighlight
public boolean lineHighlight
bracketHighlightColor
public Color bracketHighlightColor
bracketHighlight
public boolean bracketHighlight
eolMarkerColor
public Color eolMarkerColor
eolMarkers
public boolean eolMarkers
paintInvalid
public boolean paintInvalid
popup
public JPopupMenu popup
Constructor Detail
TextAreaDefaults
public TextAreaDefaults()
Method Detail
getDefaults
public static TextAreaDefaults getDefaults()
Returns a new TextAreaDefaults object with the default values filled
in.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
mars.venus.editors.jeditsyntax
Interfaces
InputHandler.MacroRecorder
InputHandler.NonRecordable
InputHandler.NonRepeatable
InputHandler.Wrapper
TextAreaPainter.Highlight
Classes
DefaultInputHandler
InputHandler
InputHandler.backspace
InputHandler.backspace_word
InputHandler.clip_copy
InputHandler.clip_cut
InputHandler.clip_paste
InputHandler.delete
InputHandler.delete_word
InputHandler.document_end
InputHandler.document_home
InputHandler.end
InputHandler.home
InputHandler.insert_break
InputHandler.insert_char
InputHandler.insert_tab
InputHandler.next_char
InputHandler.next_line
InputHandler.next_page
InputHandler.next_word
InputHandler.overwrite
InputHandler.prev_char
InputHandler.prev_line
InputHandler.prev_page
InputHandler.prev_word
InputHandler.repeat
InputHandler.select_all
InputHandler.toggle_rect
JEditBasedTextArea
JEditTextArea
KeywordMap
PopupHelpItem
SyntaxDocument
SyntaxStyle
SyntaxUtilities
TextAreaDefaults
TextAreaPainter
TextUtilities
SyntaxStyle
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class SyntaxStyle
java.lang.Object
mars.venus.editors.jeditsyntax.SyntaxStyle
public class SyntaxStyle
extends Object
A simple text style class. It can specify the color, italic flag,
and bold flag of a run of text.
Author:
Slava Pestov
Constructor Summary
SyntaxStyle(Color color,
boolean italic,
boolean bold)
Creates a new SyntaxStyle.
Method Summary
Color getColor()
Returns the color specified in this style.
String getColorAsHexString()
Returns the color coded as Stringified 32-bit hex with
Red in bits 16-23, Green in bits 8-15, Blue in bits 0-7
e.g.
FontMetrics getFontMetrics(Font font)
Returns the font metrics for the styled font.
Font getStyledFont(Font font)
Returns the specified font, but with the style’s bold and
italic flags applied.
boolean isBold()
Returns true if boldface is enabled for this style.
boolean isItalic()
Returns true if italics is enabled for this style.
boolean isPlain()
Returns true if no font styles are enabled.
void setGraphicsFlags(Graphics gfx,
Font font)
Sets the foreground color and font of the specified graphics
context to that specified in this style.
String toString()
Returns a string representation of this object.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
SyntaxStyle
public SyntaxStyle(Color color,
boolean italic,
boolean bold)
Creates a new SyntaxStyle.
Parameters:
color – The text color
italic – True if the text should be italics
bold – True if the text should be bold
Method Detail
getColor
public Color getColor()
Returns the color specified in this style.
getColorAsHexString
public String getColorAsHexString()
Returns the color coded as Stringified 32-bit hex with
Red in bits 16-23, Green in bits 8-15, Blue in bits 0-7
e.g. “0x00FF3366” where Red is FF, Green is 33, Blue is 66.
This is used by Settings initialization to avoid direct
use of Color class. Long story. DPS 13-May-2010
Returns:
String containing hex-coded color value.
isPlain
public boolean isPlain()
Returns true if no font styles are enabled.
isItalic
public boolean isItalic()
Returns true if italics is enabled for this style.
isBold
public boolean isBold()
Returns true if boldface is enabled for this style.
getStyledFont
public Font getStyledFont(Font font)
Returns the specified font, but with the style’s bold and
italic flags applied.
getFontMetrics
public FontMetrics getFontMetrics(Font font)
Returns the font metrics for the styled font.
setGraphicsFlags
public void setGraphicsFlags(Graphics gfx,
Font font)
Sets the foreground color and font of the specified graphics
context to that specified in this style.
Parameters:
gfx – The graphics context
font – The font to add the styles to
toString
public String toString()
Returns a string representation of this object.
Overrides:
toString in class Object
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.insert_break
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.insert_break
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.insert_break
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.insert_break
extends Object
implements ActionListener
Constructor Summary
InputHandler.insert_break()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.insert_break
public InputHandler.insert_break()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.venus.editors.jeditsyntax
Interface Summary
InputHandler.MacroRecorder Macro recorder.
InputHandler.NonRecordable If an action implements this interface, it should not be recorded
by the macro recorder.
InputHandler.NonRepeatable If an action implements this interface, it should not be repeated.
InputHandler.Wrapper For use by EditAction.Wrapper only.
TextAreaPainter.Highlight Highlight interface.
Class Summary
DefaultInputHandler The default input handler.
InputHandler An input handler converts the user’s key strokes into concrete actions.
InputHandler.backspace
InputHandler.backspace_word
InputHandler.clip_copy
InputHandler.clip_cut
InputHandler.clip_paste
InputHandler.delete
InputHandler.delete_word
InputHandler.document_end
InputHandler.document_home
InputHandler.end
InputHandler.home
InputHandler.insert_break
InputHandler.insert_char
InputHandler.insert_tab
InputHandler.next_char
InputHandler.next_line
InputHandler.next_page
InputHandler.next_word
InputHandler.overwrite
InputHandler.prev_char
InputHandler.prev_line
InputHandler.prev_page
InputHandler.prev_word
InputHandler.repeat
InputHandler.select_all
InputHandler.toggle_rect
JEditBasedTextArea Adaptor subclass for JEditTextArea
Provides those methods required by the MARSTextEditingArea interface
that are not defined by JEditTextArea.
JEditTextArea jEdit’s text area component.
KeywordMap A KeywordMap is similar to a hashtable in that it maps keys
to values.
PopupHelpItem Handly little class to contain help information for a popupMenu or
tool tip item.
SyntaxDocument A document implementation that can be tokenized by the syntax highlighting
system.
SyntaxStyle A simple text style class.
SyntaxUtilities Class with several utility functions used by jEdit’s syntax colorizing
subsystem.
TextAreaDefaults Encapsulates default settings for a text area.
TextAreaPainter The text area repaint manager.
TextUtilities Class with several utility functions used by the text area component.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
InputHandler.select_all
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.select_all
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.select_all
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.select_all
extends Object
implements ActionListener
Constructor Summary
InputHandler.select_all()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.select_all
public InputHandler.select_all()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.delete_word
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.delete_word
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.delete_word
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.delete_word
extends Object
implements ActionListener
Constructor Summary
InputHandler.delete_word()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.delete_word
public InputHandler.delete_word()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
TextUtilities
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class TextUtilities
java.lang.Object
mars.venus.editors.jeditsyntax.TextUtilities
public class TextUtilities
extends Object
Class with several utility functions used by the text area component.
Author:
Slava Pestov
Constructor Summary
TextUtilities()
Method Summary
static int findMatchingBracket(Document doc,
int offset)
Returns the offset of the bracket matching the one at the
specified offset of the document, or -1 if the bracket is
unmatched (or if the character is not a bracket).
static int findWordEnd(String line,
int pos,
String noWordSep)
Locates the end of the word at the specified position.
static int findWordStart(String line,
int pos,
String noWordSep)
Locates the start of the word at the specified position.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
TextUtilities
public TextUtilities()
Method Detail
findMatchingBracket
public static int findMatchingBracket(Document doc,
int offset)
throws BadLocationException
Returns the offset of the bracket matching the one at the
specified offset of the document, or -1 if the bracket is
unmatched (or if the character is not a bracket).
Parameters:
doc – The document
offset – The offset
Throws:
BadLocationException – If an out-of-bounds access
was attempted on the document text
findWordStart
public static int findWordStart(String line,
int pos,
String noWordSep)
Locates the start of the word at the specified position.
Parameters:
line – The text
pos – The position
findWordEnd
public static int findWordEnd(String line,
int pos,
String noWordSep)
Locates the end of the word at the specified position.
Parameters:
line – The text
pos – The position
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.next_word
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.next_word
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.next_word
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.next_word
extends Object
implements ActionListener
Constructor Summary
InputHandler.next_word(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.next_word
public InputHandler.next_word(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.venus.editors.jeditsyntax
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object javax.swing.text.AbstractDocument (implements javax.swing.text.Document, java.io.Serializable)
javax.swing.text.PlainDocument mars.venus.editors.jeditsyntax.SyntaxDocument
java.awt.Component (implements java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable)
java.awt.Container javax.swing.JComponent (implements java.io.Serializable)
mars.venus.editors.jeditsyntax.JEditTextArea mars.venus.editors.jeditsyntax.JEditBasedTextArea (implements javax.swing.event.CaretListener, mars.venus.editors.MARSTextEditingArea)
mars.venus.editors.jeditsyntax.TextAreaPainter (implements javax.swing.text.TabExpander)
mars.venus.editors.jeditsyntax.InputHandler.backspace (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.backspace_word (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.clip_copy (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.clip_cut (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.clip_paste (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.delete (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.delete_word (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.document_end (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.document_home (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.end (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.home (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.insert_break (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.insert_char (implements java.awt.event.ActionListener, mars.venus.editors.jeditsyntax.InputHandler.NonRepeatable)
mars.venus.editors.jeditsyntax.InputHandler.insert_tab (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.next_char (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.next_line (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.next_page (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.next_word (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.overwrite (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.prev_char (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.prev_line (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.prev_page (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.prev_word (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.repeat (implements java.awt.event.ActionListener, mars.venus.editors.jeditsyntax.InputHandler.NonRecordable)
mars.venus.editors.jeditsyntax.InputHandler.select_all (implements java.awt.event.ActionListener)
mars.venus.editors.jeditsyntax.InputHandler.toggle_rect (implements java.awt.event.ActionListener)
java.awt.event.KeyAdapter (implements java.awt.event.KeyListener)
mars.venus.editors.jeditsyntax.InputHandler mars.venus.editors.jeditsyntax.DefaultInputHandler
mars.venus.editors.jeditsyntax.KeywordMap
mars.venus.editors.jeditsyntax.PopupHelpItem
mars.venus.editors.jeditsyntax.SyntaxStyle
mars.venus.editors.jeditsyntax.SyntaxUtilities
mars.venus.editors.jeditsyntax.TextAreaDefaults
mars.venus.editors.jeditsyntax.TextUtilities
Interface Hierarchy
mars.venus.editors.jeditsyntax.InputHandler.MacroRecorder
mars.venus.editors.jeditsyntax.InputHandler.NonRecordable
mars.venus.editors.jeditsyntax.InputHandler.NonRepeatable
mars.venus.editors.jeditsyntax.InputHandler.Wrapper
mars.venus.editors.jeditsyntax.TextAreaPainter.Highlight
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
SyntaxUtilities
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class SyntaxUtilities
java.lang.Object
mars.venus.editors.jeditsyntax.SyntaxUtilities
public class SyntaxUtilities
extends Object
Class with several utility functions used by jEdit’s syntax colorizing
subsystem.
Author:
Slava Pestov
Field Summary
static Popup popup
static boolean popupShowing
Paints the specified line onto the graphics context.
Method Summary
static SyntaxStyle[] getCurrentSyntaxStyles()
Returns the CURRENT style table.
static SyntaxStyle[] getDefaultSyntaxStyles()
Returns the default style table.
static int paintSyntaxLine(Segment line,
Token tokens,
SyntaxStyle[] styles,
TabExpander expander,
Graphics gfx,
int x,
int y)
static boolean regionMatches(boolean ignoreCase,
Segment text,
int offset,
char[] match)
Checks if a subregion of a Segment is equal to a
character array.
static boolean regionMatches(boolean ignoreCase,
Segment text,
int offset,
String match)
Checks if a subregion of a Segment is equal to a
string.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
popupShowing
public static boolean popupShowing
Paints the specified line onto the graphics context. Note that this
method munges the offset and count values of the segment.
popup
public static Popup popup
Method Detail
regionMatches
public static boolean regionMatches(boolean ignoreCase,
Segment text,
int offset,
String match)
Checks if a subregion of a Segment is equal to a
string.
Parameters:
ignoreCase – True if case should be ignored, false otherwise
text – The segment
offset – The offset into the segment
match – The string to match
regionMatches
public static boolean regionMatches(boolean ignoreCase,
Segment text,
int offset,
char[] match)
Checks if a subregion of a Segment is equal to a
character array.
Parameters:
ignoreCase – True if case should be ignored, false otherwise
text – The segment
offset – The offset into the segment
match – The character array to match
getDefaultSyntaxStyles
public static SyntaxStyle[] getDefaultSyntaxStyles()
Returns the default style table. This can be passed to the
setStyles() method of SyntaxDocument
to use the default syntax styles.
getCurrentSyntaxStyles
public static SyntaxStyle[] getCurrentSyntaxStyles()
Returns the CURRENT style table. This can be passed to the
setStyles() method of SyntaxDocument
to use the current syntax styles. If changes have been made
via MARS Settings menu, the current settings will not be the
same as the default settings.
paintSyntaxLine
public static int paintSyntaxLine(Segment line,
Token tokens,
SyntaxStyle[] styles,
TabExpander expander,
Graphics gfx,
int x,
int y)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.Wrapper
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Interface InputHandler.Wrapper
Enclosing class:
InputHandler
public static interface InputHandler.Wrapper
For use by EditAction.Wrapper only.
Since:
jEdit 2.2final
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.next_page
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.next_page
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.next_page
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.next_page
extends Object
implements ActionListener
Constructor Summary
InputHandler.next_page(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.next_page
public InputHandler.next_page(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.prev_line
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.prev_line
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.prev_line
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.prev_line
extends Object
implements ActionListener
Constructor Summary
InputHandler.prev_line(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.prev_line
public InputHandler.prev_line(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.MacroRecorder
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Interface InputHandler.MacroRecorder
Enclosing class:
InputHandler
public static interface InputHandler.MacroRecorder
Macro recorder.
Method Summary
void actionPerformed(ActionListener listener,
String actionCommand)
Method Detail
actionPerformed
void actionPerformed(ActionListener listener,
String actionCommand)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.document_home
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.document_home
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.document_home
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.document_home
extends Object
implements ActionListener
Constructor Summary
InputHandler.document_home(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.document_home
public InputHandler.document_home(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.delete
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.delete
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.delete
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.delete
extends Object
implements ActionListener
Constructor Summary
InputHandler.delete()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.delete
public InputHandler.delete()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.home
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.home
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.home
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.home
extends Object
implements ActionListener
Constructor Summary
InputHandler.home(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.home
public InputHandler.home(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.insert_char
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.insert_char
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.insert_char
All Implemented Interfaces:
ActionListener, EventListener, InputHandler.NonRepeatable
Enclosing class:
InputHandler
public static class InputHandler.insert_char
extends Object
implements ActionListener, InputHandler.NonRepeatable
Constructor Summary
InputHandler.insert_char()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.insert_char
public InputHandler.insert_char()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.clip_cut
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.clip_cut
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.clip_cut
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.clip_cut
extends Object
implements ActionListener
Constructor Summary
InputHandler.clip_cut()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.clip_cut
public InputHandler.clip_cut()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.NonRecordable
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Interface InputHandler.NonRecordable
All Known Implementing Classes:
InputHandler.repeat
Enclosing class:
InputHandler
public static interface InputHandler.NonRecordable
If an action implements this interface, it should not be recorded
by the macro recorder. Instead, it will do its own recording.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.toggle_rect
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.toggle_rect
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.toggle_rect
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.toggle_rect
extends Object
implements ActionListener
Constructor Summary
InputHandler.toggle_rect()
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.toggle_rect
public InputHandler.toggle_rect()
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InputHandler.document_end
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.jeditsyntax
Class InputHandler.document_end
java.lang.Object
mars.venus.editors.jeditsyntax.InputHandler.document_end
All Implemented Interfaces:
ActionListener, EventListener
Enclosing class:
InputHandler
public static class InputHandler.document_end
extends Object
implements ActionListener
Constructor Summary
InputHandler.document_end(boolean select)
Method Summary
void actionPerformed(ActionEvent evt)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InputHandler.document_end
public InputHandler.document_end(boolean select)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent evt)
Specified by:
actionPerformed in interface ActionListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.venus.editors
Interface Summary
MARSTextEditingArea Specifies capabilities that any test editor used in MARS must have.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
mars.venus.editors.generic
mars.venus.editors.generic
Classes
GenericTextArea
mars.venus.editors.generic
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.venus.editors.generic
Class Summary
GenericTextArea
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
mars.venus.editors.generic Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.venus.editors.generic
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object java.awt.Component (implements java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable)
java.awt.Container javax.swing.JComponent (implements java.io.Serializable)
javax.swing.text.JTextComponent (implements javax.accessibility.Accessible, javax.swing.Scrollable)
javax.swing.JTextArea mars.venus.editors.generic.GenericTextArea (implements mars.venus.editors.MARSTextEditingArea)
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
GenericTextArea
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors.generic
Class GenericTextArea
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.text.JTextComponent
javax.swing.JTextArea
mars.venus.editors.generic.GenericTextArea
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, Scrollable, MARSTextEditingArea
public class GenericTextArea
extends JTextArea
implements MARSTextEditingArea
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JTextArea
JTextArea.AccessibleJTextArea
Nested classes/interfaces inherited from class javax.swing.text.JTextComponent
JTextComponent.AccessibleJTextComponent, JTextComponent.DropLocation, JTextComponent.KeyBinding
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.text.JTextComponent
DEFAULT_KEYMAP, FOCUS_ACCELERATOR_KEY
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface mars.venus.editors.MARSTextEditingArea
TEXT_FOUND, TEXT_NOT_FOUND, TEXT_REPLACED_FOUND_NEXT, TEXT_REPLACED_NOT_FOUND_NEXT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
GenericTextArea(EditPane editPain,
JComponent lineNumbers)
Method Summary
void discardAllUndoableEdits()
Tell UndoManager to discard all its collected undoable edits.
int doFindText(String find,
boolean caseSensitive)
Finds next occurrence of text in a forward search of a string.
int doReplace(String find,
String replace,
boolean caseSensitive)
Finds and replaces next occurrence of text in a string in a forward search.
int doReplaceAll(String find,
String replace,
boolean caseSensitive)
Finds and replaces ALL occurrences of text in a string in a forward search.
Component getOuterComponent()
UndoManager getUndoManager()
Returns the undo manager for this editing area
int nextIndex(String input,
String find,
int start,
boolean caseSensitive)
Returns next posn of word in text – forward search.
void redo()
Redo previous edit
void setCaretBlinkRate(int rate)
Set the caret blinking rate in milliseconds.
void setCaretVisible(boolean vis)
Control caret visibility
void setLineHighlightEnabled(boolean highlight)
Does nothing, but required by the interface.
void setSelectionVisible(boolean vis)
Control selection visibility
void setSourceCode(String s,
boolean editable)
For initalizing the source code when opening an ASM file
void setText(String s)
Override inherited setText to temporarily remove UndoableEditListener because this
operation is not undoable.
void undo()
Undo previous edit
void updateSyntaxStyles()
Does nothing, but required by the interface.
Methods inherited from class javax.swing.JTextArea
append, createDefaultModel, getAccessibleContext, getColumns, getColumnWidth, getLineCount, getLineEndOffset, getLineOfOffset, getLineStartOffset, getLineWrap, getPreferredScrollableViewportSize, getPreferredSize, getRowHeight, getRows, getScrollableTracksViewportWidth, getScrollableUnitIncrement, getTabSize, getUIClassID, getWrapStyleWord, insert, paramString, replaceRange, setColumns, setFont, setLineWrap, setRows, setTabSize, setWrapStyleWord
Methods inherited from class javax.swing.text.JTextComponent
addCaretListener, addInputMethodListener, addKeymap, copy, cut, fireCaretUpdate, getActions, getCaret, getCaretColor, getCaretListeners, getCaretPosition, getDisabledTextColor, getDocument, getDragEnabled, getDropLocation, getDropMode, getFocusAccelerator, getHighlighter, getInputMethodRequests, getKeymap, getKeymap, getMargin, getNavigationFilter, getPrintable, getScrollableBlockIncrement, getScrollableTracksViewportHeight, getSelectedText, getSelectedTextColor, getSelectionColor, getSelectionEnd, getSelectionStart, getText, getText, getToolTipText, getUI, isEditable, loadKeymap, modelToView, moveCaretPosition, paste, print, print, print, processInputMethodEvent, read, removeCaretListener, removeKeymap, removeNotify, replaceSelection, select, selectAll, setCaret, setCaretColor, setCaretPosition, setComponentOrientation, setDisabledTextColor, setDocument, setDragEnabled, setDropMode, setEditable, setFocusAccelerator, setHighlighter, setKeymap, setMargin, setNavigationFilter, setSelectedTextColor, setSelectionColor, setSelectionEnd, setSelectionStart, setUI, updateUI, viewToModel, write
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface mars.venus.editors.MARSTextEditingArea
copy, cut, getCaretPosition, getDocument, getFont, getFontMetrics, getSelectedText, getSelectionEnd, getSelectionStart, getText, grabFocus, paste, replaceSelection, requestFocusInWindow, revalidate, select, selectAll, setBackground, setCaretPosition, setEditable, setEnabled, setFont, setSelectionEnd, setSelectionStart, setTabSize
Constructor Detail
GenericTextArea
public GenericTextArea(EditPane editPain,
JComponent lineNumbers)
Method Detail
setLineHighlightEnabled
public void setLineHighlightEnabled(boolean highlight)
Does nothing, but required by the interface. This editor does not support
highlighting of the line currently being edited.
Specified by:
setLineHighlightEnabled in interface MARSTextEditingArea
updateSyntaxStyles
public void updateSyntaxStyles()
Does nothing, but required by the interface. This editor does not support
syntax styling (colors, bold/italic).
Specified by:
updateSyntaxStyles in interface MARSTextEditingArea
setCaretBlinkRate
public void setCaretBlinkRate(int rate)
Set the caret blinking rate in milliseconds. If rate is 0
it will not blink. If negative, do nothing.
Specified by:
setCaretBlinkRate in interface MARSTextEditingArea
Parameters:
rate – blinking rate in milliseconds
getOuterComponent
public Component getOuterComponent()
Specified by:
getOuterComponent in interface MARSTextEditingArea
setSourceCode
public void setSourceCode(String s,
boolean editable)
For initalizing the source code when opening an ASM file
Specified by:
setSourceCode in interface MARSTextEditingArea
Parameters:
s – String containing text
editable – set true if code is editable else false
discardAllUndoableEdits
public void discardAllUndoableEdits()
Tell UndoManager to discard all its collected undoable edits.
Specified by:
discardAllUndoableEdits in interface MARSTextEditingArea
setText
public void setText(String s)
Override inherited setText to temporarily remove UndoableEditListener because this
operation is not undoable.
Specified by:
setText in interface MARSTextEditingArea
Overrides:
setText in class JTextComponent
Parameters:
s – String with new contents for the editing area. Replaces current content.
setCaretVisible
public void setCaretVisible(boolean vis)
Control caret visibility
Specified by:
setCaretVisible in interface MARSTextEditingArea
Parameters:
vis – true to display caret, false to hide it
setSelectionVisible
public void setSelectionVisible(boolean vis)
Control selection visibility
Specified by:
setSelectionVisible in interface MARSTextEditingArea
Parameters:
vis – true to display selection, false to hide it
getUndoManager
public UndoManager getUndoManager()
Returns the undo manager for this editing area
Specified by:
getUndoManager in interface MARSTextEditingArea
Returns:
the undo manager
undo
public void undo()
Undo previous edit
Specified by:
undo in interface MARSTextEditingArea
redo
public void redo()
Redo previous edit
Specified by:
redo in interface MARSTextEditingArea
doFindText
public int doFindText(String find,
boolean caseSensitive)
Finds next occurrence of text in a forward search of a string. Search begins
at the current cursor location, and wraps around when the end of the string
is reached.
Specified by:
doFindText in interface MARSTextEditingArea
Parameters:
find – the text to locate in the string
caseSensitive – true if search is to be case-sensitive, false otherwise
Returns:
TEXT_FOUND or TEXT_NOT_FOUND, depending on the result.
nextIndex
public int nextIndex(String input,
String find,
int start,
boolean caseSensitive)
Returns next posn of word in text – forward search. If end of string is
reached during the search, will wrap around to the beginning one time.
Parameters:
input – the string to search
find – the string to find
start – the character position to start the search
caseSensitive – true for case sensitive. false to ignore case
Returns:
next indexed position of found text or -1 if not found
doReplace
public int doReplace(String find,
String replace,
boolean caseSensitive)
Finds and replaces next occurrence of text in a string in a forward search.
If cursor is initially at end
of matching selection, will immediately replace then find and select the
next occurrence if any. Otherwise it performs a find operation. The replace
can be undone with one undo operation.
Specified by:
doReplace in interface MARSTextEditingArea
Parameters:
find – the text to locate in the string
replace – the text to replace the find text with – if the find text exists
caseSensitive – true for case sensitive. false to ignore case
Returns:
Returns TEXT_FOUND if not initially at end of selected match and matching
occurrence is found. Returns TEXT_NOT_FOUND if the text is not matched.
Returns TEXT_REPLACED_NOT_FOUND_NEXT if replacement is successful but there are
no additional matches. Returns TEXT_REPLACED_FOUND_NEXT if reaplacement is
successful and there is at least one additional match.
doReplaceAll
public int doReplaceAll(String find,
String replace,
boolean caseSensitive)
Finds and replaces ALL occurrences of text in a string in a forward search.
All replacements are bundled into one CompoundEdit, so one Undo operation will
undo all of them.
Specified by:
doReplaceAll in interface MARSTextEditingArea
Parameters:
find – the text to locate in the string
replace – the text to replace the find text with – if the find text exists
caseSensitive – true for case sensitive. false to ignore case
Returns:
the number of occurrences that were matched and replaced.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.venus.editors
Package Hierarchies:
All Packages
Interface Hierarchy
mars.venus.editors.MARSTextEditingArea
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
MARSTextEditingArea
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus.editors
Interface MARSTextEditingArea
All Known Implementing Classes:
GenericTextArea, JEditBasedTextArea
public interface MARSTextEditingArea
Specifies capabilities that any test editor used in MARS must have.
Field Summary
static int TEXT_FOUND
static int TEXT_NOT_FOUND
static int TEXT_REPLACED_FOUND_NEXT
static int TEXT_REPLACED_NOT_FOUND_NEXT
Method Summary
void copy()
void cut()
void discardAllUndoableEdits()
int doFindText(String find,
boolean caseSensitive)
int doReplace(String find,
String replace,
boolean caseSensitive)
int doReplaceAll(String find,
String replace,
boolean caseSensitive)
int getCaretPosition()
Document getDocument()
Font getFont()
FontMetrics getFontMetrics(Font f)
Component getOuterComponent()
String getSelectedText()
int getSelectionEnd()
int getSelectionStart()
String getText()
UndoManager getUndoManager()
void grabFocus()
void paste()
void redo()
void replaceSelection(String str)
boolean requestFocusInWindow()
void revalidate()
void select(int selectionStart,
int selectionEnd)
void selectAll()
void setBackground(Color c)
void setCaretBlinkRate(int rate)
void setCaretPosition(int position)
void setCaretVisible(boolean vis)
void setEditable(boolean editable)
void setEnabled(boolean enabled)
void setFont(Font f)
void setLineHighlightEnabled(boolean highlight)
void setSelectionEnd(int pos)
void setSelectionStart(int pos)
void setSelectionVisible(boolean vis)
void setSourceCode(String code,
boolean editable)
void setTabSize(int chars)
void setText(String text)
void undo()
void updateSyntaxStyles()
Field Detail
TEXT_NOT_FOUND
static final int TEXT_NOT_FOUND
See Also:
Constant Field Values
TEXT_FOUND
static final int TEXT_FOUND
See Also:
Constant Field Values
TEXT_REPLACED_FOUND_NEXT
static final int TEXT_REPLACED_FOUND_NEXT
See Also:
Constant Field Values
TEXT_REPLACED_NOT_FOUND_NEXT
static final int TEXT_REPLACED_NOT_FOUND_NEXT
See Also:
Constant Field Values
Method Detail
copy
void copy()
cut
void cut()
doFindText
int doFindText(String find,
boolean caseSensitive)
doReplace
int doReplace(String find,
String replace,
boolean caseSensitive)
doReplaceAll
int doReplaceAll(String find,
String replace,
boolean caseSensitive)
getCaretPosition
int getCaretPosition()
getDocument
Document getDocument()
getSelectedText
String getSelectedText()
getSelectionEnd
int getSelectionEnd()
getSelectionStart
int getSelectionStart()
select
void select(int selectionStart,
int selectionEnd)
selectAll
void selectAll()
getText
String getText()
getUndoManager
UndoManager getUndoManager()
paste
void paste()
replaceSelection
void replaceSelection(String str)
setCaretPosition
void setCaretPosition(int position)
setEditable
void setEditable(boolean editable)
setSelectionEnd
void setSelectionEnd(int pos)
setSelectionStart
void setSelectionStart(int pos)
setText
void setText(String text)
setFont
void setFont(Font f)
getFont
Font getFont()
requestFocusInWindow
boolean requestFocusInWindow()
getFontMetrics
FontMetrics getFontMetrics(Font f)
setBackground
void setBackground(Color c)
setEnabled
void setEnabled(boolean enabled)
grabFocus
void grabFocus()
redo
void redo()
revalidate
void revalidate()
setSourceCode
void setSourceCode(String code,
boolean editable)
setCaretVisible
void setCaretVisible(boolean vis)
setSelectionVisible
void setSelectionVisible(boolean vis)
undo
void undo()
discardAllUndoableEdits
void discardAllUndoableEdits()
setLineHighlightEnabled
void setLineHighlightEnabled(boolean highlight)
setCaretBlinkRate
void setCaretBlinkRate(int rate)
setTabSize
void setTabSize(int chars)
updateSyntaxStyles
void updateSyntaxStyles()
getOuterComponent
Component getOuterComponent()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RegistersWindow
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RegistersWindow
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
mars.venus.RegistersWindow
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible
public class RegistersWindow
extends JPanel
implements Observer
Sets up a window to display registers in the UI.
Author:
Sanderson, Bumgarner
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
RegistersWindow()
Constructor which sets up a fresh window with a table that contains the register values.
Method Summary
void clearHighlighting()
Clear highlight background color from any cell currently highlighted.
void clearWindow()
clear and redisplay registers
void refresh()
Refresh the table, triggering re-rendering.
Object[][] setupWindow()
Sets up the data for the window.
void update(Observable observable,
Object obj)
Required by Observer interface.
void updateRegisters()
update register display using current number base (10 or 16)
void updateRegisters(int base)
update register display using specified number base (10 or 16)
void updateRegisterValue(int number,
int val,
int base)
This method handles the updating of the GUI.
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
RegistersWindow
public RegistersWindow()
Constructor which sets up a fresh window with a table that contains the register values.
Method Detail
setupWindow
public Object[][] setupWindow()
Sets up the data for the window.
Returns:
The array object with the data for the window.
clearWindow
public void clearWindow()
clear and redisplay registers
clearHighlighting
public void clearHighlighting()
Clear highlight background color from any cell currently highlighted.
refresh
public void refresh()
Refresh the table, triggering re-rendering.
updateRegisters
public void updateRegisters()
update register display using current number base (10 or 16)
updateRegisters
public void updateRegisters(int base)
update register display using specified number base (10 or 16)
Parameters:
base – desired number base
updateRegisterValue
public void updateRegisterValue(int number,
int val,
int base)
This method handles the updating of the GUI.
Parameters:
number – The number of the register to update.
val – New value.
update
public void update(Observable observable,
Object obj)
Required by Observer interface. Called when notified by an Observable that we are registered with.
Observables include:
The Simulator object, which lets us know when it starts and stops running
A register object, which lets us know of register operations
The Simulator keeps us informed of when simulated MIPS execution is active.
This is the only time we care about register operations.
Specified by:
update in interface Observer
Parameters:
observable – The Observable object who is notifying us
obj – Auxiliary object with additional information.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
EditUndoAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class EditUndoAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.EditUndoAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class EditUndoAction
extends GuiAction
Action for the Edit -> Undo menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
EditUndoAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
Adapted from TextComponentDemo.java in the
Java Tutorial “Text Component Features”
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
EditUndoAction
public EditUndoAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Adapted from TextComponentDemo.java in the
Java Tutorial “Text Component Features”
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FileSaveAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FileSaveAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.FileSaveAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class FileSaveAction
extends GuiAction
Action for the File -> Save menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
FileSaveAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
saves the file, if not alredy saved it will do a saveAs
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
FileSaveAction
public FileSaveAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
saves the file, if not alredy saved it will do a saveAs
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
PopupListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class PopupListener
java.lang.Object
java.awt.event.MouseAdapter
mars.venus.PopupListener
All Implemented Interfaces:
MouseListener, MouseMotionListener, MouseWheelListener, EventListener
public class PopupListener
extends MouseAdapter
Constructor Summary
PopupListener(JPopupMenu p)
Method Summary
void mousePressed(MouseEvent e)
void mouseReleased(MouseEvent e)
Methods inherited from class java.awt.event.MouseAdapter
mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mouseWheelMoved
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
PopupListener
public PopupListener(JPopupMenu p)
Method Detail
mousePressed
public void mousePressed(MouseEvent e)
Specified by:
mousePressed in interface MouseListener
Overrides:
mousePressed in class MouseAdapter
mouseReleased
public void mouseReleased(MouseEvent e)
Specified by:
mouseReleased in interface MouseListener
Overrides:
mouseReleased in class MouseAdapter
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsExtendedAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsExtendedAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsExtendedAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsExtendedAction
extends GuiAction
Action class for the Settings menu item to control use of extended (pseudo) instructions or formats.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsExtendedAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsExtendedAction
public SettingsExtendedAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
EditFindReplaceAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class EditFindReplaceAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.EditFindReplaceAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class EditFindReplaceAction
extends GuiAction
Action for the Edit -> Find/Replace menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
EditFindReplaceAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
EditFindReplaceAction
public EditFindReplaceAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Editor
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class Editor
java.lang.Object
mars.venus.Editor
public class Editor
extends Object
Manage the file being edited.
Currently only manages one file at a time, but can be expanded.
Field Summary
static int MAX_BLINK_RATE
static int MAX_TAB_SIZE
static int MIN_BLINK_RATE
static int MIN_TAB_SIZE
Constructor Summary
Editor(VenusUI ui)
Create editor.
Method Summary
boolean close()
Perform “close” operation on current tab’s file.
boolean closeAll()
Close all currently open files.
boolean editsSavedOrAbandoned()
Called by several of the Action objects when there is potential
loss of editing changes.
String getCurrentOpenDirectory()
Get name of current directory for Open operation.
String getCurrentSaveDirectory()
Get name of current directory for Save or Save As operation.
String getNextDefaultFilename()
Generates a default file name
void newFile()
Perform “new” operation to create an empty tab.
boolean open()
Open file in a new tab.
boolean save()
Perform “save” operation on current tab’s file.
boolean saveAll()
Perform save operation on all open files (tabs).
boolean saveAs()
Perform “save as” operation on current tab’s file.
void setEditTabbedPane(EditTabbedPane editTabbedPane)
Set associated EditTabbedPane.
void setTitle(String path,
String name,
int status)
Places name of file currently being edited into its edit tab and
the application’s title bar.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
MIN_TAB_SIZE
public static final int MIN_TAB_SIZE
See Also:
Constant Field Values
MAX_TAB_SIZE
public static final int MAX_TAB_SIZE
See Also:
Constant Field Values
MIN_BLINK_RATE
public static final int MIN_BLINK_RATE
See Also:
Constant Field Values
MAX_BLINK_RATE
public static final int MAX_BLINK_RATE
See Also:
Constant Field Values
Constructor Detail
Editor
public Editor(VenusUI ui)
Create editor.
Parameters:
ui – the GUI that owns this editor
Method Detail
setEditTabbedPane
public void setEditTabbedPane(EditTabbedPane editTabbedPane)
Set associated EditTabbedPane. This is container for any/all open files.
Parameters:
editTabbedPane – an existing editTabbedPane object
getCurrentOpenDirectory
public String getCurrentOpenDirectory()
Get name of current directory for Open operation.
Returns:
String containing directory pathname. Returns null if there is
no EditTabbedPane. Returns default, directory MARS is launched from, if
no Opens have been performed.
getCurrentSaveDirectory
public String getCurrentSaveDirectory()
Get name of current directory for Save or Save As operation.
Returns:
String containing directory pathname. Returns null if there is
no EditTabbedPane. Returns default, directory MARS is launched from, if
no Save or Save As operations have been performed.
getNextDefaultFilename
public String getNextDefaultFilename()
Generates a default file name
Returns:
returns string mipsN.asm, where N is 1,2,3,…
setTitle
public void setTitle(String path,
String name,
int status)
Places name of file currently being edited into its edit tab and
the application’s title bar. The edit tab will contain only
the filename, the title bar will contain full pathname.
If file has been modified since created, opened or saved, as
indicated by value of the status parameter, the name and path
will be followed with an ‘*’. If newly-created file has not
yet been saved, the title bar will show (temporary) file name
but not path.
Parameters:
path – Full pathname for file
name – Name of file (last component of path)
status – Edit status of file. See FileStatus static constants.
newFile
public void newFile()
Perform “new” operation to create an empty tab.
close
public boolean close()
Perform “close” operation on current tab’s file.
Returns:
true if succeeded, else false.
closeAll
public boolean closeAll()
Close all currently open files.
Returns:
true if succeeded, else false.
save
public boolean save()
Perform “save” operation on current tab’s file.
Returns:
true if succeeded, else false.
saveAs
public boolean saveAs()
Perform “save as” operation on current tab’s file.
Returns:
true if succeeded, else false.
saveAll
public boolean saveAll()
Perform save operation on all open files (tabs).
Returns:
true if succeeded, else false.
open
public boolean open()
Open file in a new tab.
Returns:
true if succeeded, else false.
editsSavedOrAbandoned
public boolean editsSavedOrAbandoned()
Called by several of the Action objects when there is potential
loss of editing changes. Specifically: if there is a current
file open for editing and its modify flag is true, then give user
a dialog box with choice to save, discard edits, or cancel and
carry out the decision. This applies to File->New, File->Open,
File->Close, and File->Exit.
Returns:
false means user selected Cancel so caller should do that.
Return of true means caller can proceed (edits were saved or discarded).
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FileCloseAllAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FileCloseAllAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.FileCloseAllAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class FileCloseAllAction
extends GuiAction
Action for the File -> Close All menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
FileCloseAllAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
FileCloseAllAction
public FileCloseAllAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsLabelAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsLabelAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsLabelAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsLabelAction
extends GuiAction
Action class for the Settings menu item to control display of Labels window (symbol table).
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsLabelAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsLabelAction
public SettingsLabelAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsDelayedBranchingAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsDelayedBranchingAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsDelayedBranchingAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsDelayedBranchingAction
extends GuiAction
Action class for the Settings menu item to control delayed branching.
Note: Changing this setting while the current program is runnable
(assembled, or stepped execution) or terminated triggers a re-assembly.
This is necessary to maintain consistency because the machine
code assembled for branch instructions differs depending on
this setting — would branch to incorrect address if setting
were changed between assembly and execution.
Note: This action is disabled while the MIPS program is running.
The user need only pause or stop execution to re-enable it.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsDelayedBranchingAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsDelayedBranchingAction
public SettingsDelayedBranchingAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
HardcopyWriter.PrintCanceledException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class HardcopyWriter.PrintCanceledException
java.lang.Object
java.lang.Throwable
java.lang.Exception
mars.venus.HardcopyWriter.PrintCanceledException
All Implemented Interfaces:
Serializable
Enclosing class:
HardcopyWriter
public static class HardcopyWriter.PrintCanceledException
extends Exception
This is the exception class that the HardcopyWriter constructor
throws when the user clicks “Cancel” in the print dialog box.
See Also:
Serialized Form
Constructor Summary
HardcopyWriter.PrintCanceledException(String msg)
Method Summary
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
HardcopyWriter.PrintCanceledException
public HardcopyWriter.PrintCanceledException(String msg)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
ExecutePane
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class ExecutePane
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JLayeredPane
javax.swing.JDesktopPane
mars.venus.ExecutePane
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible
public class ExecutePane
extends JDesktopPane
Container for the execution-related windows. Currently displayed as a tabbed pane.
Author:
Sanderson and Team JSpim
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JDesktopPane
JDesktopPane.AccessibleJDesktopPane
Nested classes/interfaces inherited from class javax.swing.JLayeredPane
JLayeredPane.AccessibleJLayeredPane
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JDesktopPane
LIVE_DRAG_MODE, OUTLINE_DRAG_MODE
Fields inherited from class javax.swing.JLayeredPane
DEFAULT_LAYER, DRAG_LAYER, FRAME_CONTENT_LAYER, LAYER_PROPERTY, MODAL_LAYER, PALETTE_LAYER, POPUP_LAYER
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
ExecutePane(VenusUI mainUI,
RegistersWindow regs,
Coprocessor1Window cop1Regs,
Coprocessor0Window cop0Regs)
initialize the Execute pane with major components
Method Summary
void clearPane()
Clears out all components of the Execute tab: text segment
display, data segment display, label display and register display.
int getAddressDisplayBase()
Retrieve the number system base for displaying memory addresses
NumberDisplayBaseChooser getAddressDisplayBaseChooser()
Retrieve component used to set numerical base (10 or 16) of address display.
Coprocessor0Window getCoprocessor0Window()
Access the coprocessor0 values window.
Coprocessor1Window getCoprocessor1Window()
Access the coprocessor1 values window.
DataSegmentWindow getDataSegmentWindow()
Access the data segment window.
LabelsWindow getLabelsWindow()
Access the label values window.
RegistersWindow getRegistersWindow()
Access the register values window.
TextSegmentWindow getTextSegmentWindow()
Access the text segment window.
int getValueDisplayBase()
Retrieve the number system base for displaying values (mem/register contents)
NumberDisplayBaseChooser getValueDisplayBaseChooser()
Retrieve component used to set numerical base (10 or 16) of data value display.
void numberDisplayBaseChanged(NumberDisplayBaseChooser chooser)
Update display of columns based on state of given chooser.
void setLabelWindowVisibility(boolean visibility)
Show or hide the label window (symbol table).
void setWindowBounds()
This method will set the bounds of this JDesktopPane’s internal windows
relative to the current size of this JDesktopPane.
Methods inherited from class javax.swing.JDesktopPane
addImpl, getAccessibleContext, getAllFrames, getAllFramesInLayer, getDesktopManager, getDragMode, getSelectedFrame, getUI, getUIClassID, paramString, remove, removeAll, selectFrame, setComponentZOrder, setDesktopManager, setDragMode, setSelectedFrame, setUI, updateUI
Methods inherited from class javax.swing.JLayeredPane
getComponentCountInLayer, getComponentsInLayer, getComponentToLayer, getIndexOf, getLayer, getLayer, getLayeredPaneAbove, getObjectForLayer, getPosition, highestLayer, insertIndexForLayer, isOptimizedDrawingEnabled, lowestLayer, moveToBack, moveToFront, paint, putLayer, setLayer, setLayer, setPosition
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, removeContainerListener, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
ExecutePane
public ExecutePane(VenusUI mainUI,
RegistersWindow regs,
Coprocessor1Window cop1Regs,
Coprocessor0Window cop0Regs)
initialize the Execute pane with major components
Parameters:
mainUI – the parent GUI
regs – window containing integer register set
cop1Regs – window containing Coprocessor 1 register set
cop0Regs – window containing Coprocessor 0 register set
Method Detail
setWindowBounds
public void setWindowBounds()
This method will set the bounds of this JDesktopPane’s internal windows
relative to the current size of this JDesktopPane. Such an operation
cannot be adequately done at constructor time because the actual
size of the desktop pane window is not yet established. Layout manager
is not a good option here because JDesktopPane does not work well with
them (the whole idea of using JDesktopPane with internal frames is to
have mini-frames that you can resize, move around, minimize, etc). This
method should be invoked only once: the first time the Execute tab is
selected (a change listener invokes it). We do not want it invoked
on subsequent tab selections; otherwise, user manipulations of the
internal frames would be lost the next time execute tab is selected.
setLabelWindowVisibility
public void setLabelWindowVisibility(boolean visibility)
Show or hide the label window (symbol table). If visible, it is displayed
to the right of the text segment and the latter is shrunk accordingly.
Parameters:
visibility – set to true or false
clearPane
public void clearPane()
Clears out all components of the Execute tab: text segment
display, data segment display, label display and register display.
This will typically be done upon File->Close, Open, New.
getTextSegmentWindow
public TextSegmentWindow getTextSegmentWindow()
Access the text segment window.
getDataSegmentWindow
public DataSegmentWindow getDataSegmentWindow()
Access the data segment window.
getRegistersWindow
public RegistersWindow getRegistersWindow()
Access the register values window.
getCoprocessor1Window
public Coprocessor1Window getCoprocessor1Window()
Access the coprocessor1 values window.
getCoprocessor0Window
public Coprocessor0Window getCoprocessor0Window()
Access the coprocessor0 values window.
getLabelsWindow
public LabelsWindow getLabelsWindow()
Access the label values window.
getValueDisplayBase
public int getValueDisplayBase()
Retrieve the number system base for displaying values (mem/register contents)
getAddressDisplayBase
public int getAddressDisplayBase()
Retrieve the number system base for displaying memory addresses
getValueDisplayBaseChooser
public NumberDisplayBaseChooser getValueDisplayBaseChooser()
Retrieve component used to set numerical base (10 or 16) of data value display.
Returns:
the chooser
getAddressDisplayBaseChooser
public NumberDisplayBaseChooser getAddressDisplayBaseChooser()
Retrieve component used to set numerical base (10 or 16) of address display.
Returns:
the chooser
numberDisplayBaseChanged
public void numberDisplayBaseChanged(NumberDisplayBaseChooser chooser)
Update display of columns based on state of given chooser. Normally
called only by the chooser’s ItemListener.
Parameters:
chooser – the GUI object manipulated by the user to change number base
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RunClearBreakpointsAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RunClearBreakpointsAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.RunClearBreakpointsAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action, TableModelListener
public class RunClearBreakpointsAction
extends GuiAction
implements TableModelListener
Action class for the Run menu item to clear execution breakpoints that have been set.
It is a listener and is notified whenever a breakpoint is added or removed, thus will
set its enabled status true or false depending on whether breakpoints remain after that action.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
RunClearBreakpointsAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Create the object and register with text segment window as a listener on its table model.
Method Summary
void actionPerformed(ActionEvent e)
When this option is selected, tell text segment window to clear breakpoints in its table model.
void tableChanged(TableModelEvent e)
Required TableModelListener method.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
RunClearBreakpointsAction
public RunClearBreakpointsAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Create the object and register with text segment window as a listener on its table model.
The table model has not been created yet, so text segment window will hang onto this
registration info and transfer it to the table model upon creation (which happens with
each successful assembly).
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
When this option is selected, tell text segment window to clear breakpoints in its table model.
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
tableChanged
public void tableChanged(TableModelEvent e)
Required TableModelListener method. This is response upon editing of text segment table
model. The only editable column is breakpoints so this method is called only when user
adds or removes a breakpoint. Gets new breakpoint count and sets enabled status
accordingly.
Specified by:
tableChanged in interface TableModelListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Coprocessor0Window
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class Coprocessor0Window
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
mars.venus.Coprocessor0Window
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible
public class Coprocessor0Window
extends JPanel
implements Observer
Sets up a window to display registers in the UI.
Author:
Sanderson, Bumgarner
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
Coprocessor0Window()
Constructor which sets up a fresh window with a table that contains the register values.
Method Summary
void clearHighlighting()
Clear highlight background color from any row currently highlighted.
void clearWindow()
Reset and redisplay registers
void refresh()
Refresh the table, triggering re-rendering.
Object[][] setupWindow()
Sets up the data for the window.
void update(Observable observable,
Object obj)
Required by Observer interface.
void updateRegisters()
Update register display using current display base (10 or 16)
void updateRegisters(int base)
Update register display using specified display base
void updateRegisterValue(int number,
int val,
int base)
This method handles the updating of the GUI.
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
Coprocessor0Window
public Coprocessor0Window()
Constructor which sets up a fresh window with a table that contains the register values.
Method Detail
setupWindow
public Object[][] setupWindow()
Sets up the data for the window.
Returns:
The array object with the data for the window.
clearWindow
public void clearWindow()
Reset and redisplay registers
clearHighlighting
public void clearHighlighting()
Clear highlight background color from any row currently highlighted.
refresh
public void refresh()
Refresh the table, triggering re-rendering.
updateRegisters
public void updateRegisters()
Update register display using current display base (10 or 16)
updateRegisters
public void updateRegisters(int base)
Update register display using specified display base
Parameters:
base – number base for display (10 or 16)
updateRegisterValue
public void updateRegisterValue(int number,
int val,
int base)
This method handles the updating of the GUI.
Parameters:
number – The number of the register to update.
val – New value.
update
public void update(Observable observable,
Object obj)
Required by Observer interface. Called when notified by an Observable that we are registered with.
Observables include:
The Simulator object, which lets us know when it starts and stops running
A register object, which lets us know of register operations
The Simulator keeps us informed of when simulated MIPS execution is active.
This is the only time we care about register operations.
Specified by:
update in interface Observer
Parameters:
observable – The Observable object who is notifying us
obj – Auxiliary object with additional information.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RegistersPane
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RegistersPane
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JTabbedPane
mars.venus.RegistersPane
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, SwingConstants
public class RegistersPane
extends JTabbedPane
Contains tabbed areas in the UI to display register contents
Author:
Sanderson
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JTabbedPane
JTabbedPane.AccessibleJTabbedPane, JTabbedPane.ModelListener
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JTabbedPane
changeEvent, changeListener, model, SCROLL_TAB_LAYOUT, tabPlacement, WRAP_TAB_LAYOUT
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
RegistersPane(VenusUI appFrame,
RegistersWindow regs,
Coprocessor1Window cop1,
Coprocessor0Window cop0)
Constructor for the RegistersPane class.
Method Summary
Coprocessor0Window getCoprocessor0Window()
Return component containing coprocessor 0 (exceptions) register set.
Coprocessor1Window getCoprocessor1Window()
Return component containing coprocessor 1 (floating point) register set.
RegistersWindow getRegistersWindow()
Return component containing integer register set.
Methods inherited from class javax.swing.JTabbedPane
add, add, add, add, add, addChangeListener, addTab, addTab, addTab, createChangeListener, fireStateChanged, getAccessibleContext, getBackgroundAt, getBoundsAt, getChangeListeners, getComponentAt, getDisabledIconAt, getDisplayedMnemonicIndexAt, getForegroundAt, getIconAt, getMnemonicAt, getModel, getSelectedComponent, getSelectedIndex, getTabComponentAt, getTabCount, getTabLayoutPolicy, getTabPlacement, getTabRunCount, getTitleAt, getToolTipText, getToolTipTextAt, getUI, getUIClassID, indexAtLocation, indexOfComponent, indexOfTab, indexOfTab, indexOfTabComponent, insertTab, isEnabledAt, paramString, remove, remove, removeAll, removeChangeListener, removeTabAt, setBackgroundAt, setComponentAt, setDisabledIconAt, setDisplayedMnemonicIndexAt, setEnabledAt, setForegroundAt, setIconAt, setMnemonicAt, setModel, setSelectedComponent, setSelectedIndex, setTabComponentAt, setTabLayoutPolicy, setTabPlacement, setTitleAt, setToolTipTextAt, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
RegistersPane
public RegistersPane(VenusUI appFrame,
RegistersWindow regs,
Coprocessor1Window cop1,
Coprocessor0Window cop0)
Constructor for the RegistersPane class.
Method Detail
getRegistersWindow
public RegistersWindow getRegistersWindow()
Return component containing integer register set.
Returns:
integer register window
getCoprocessor1Window
public Coprocessor1Window getCoprocessor1Window()
Return component containing coprocessor 1 (floating point) register set.
Returns:
floating point register window
getCoprocessor0Window
public Coprocessor0Window getCoprocessor0Window()
Return component containing coprocessor 0 (exceptions) register set.
Returns:
exceptions register window
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
mars.venus
Classes
AbstractFontSettingDialog
Coprocessor0Window
Coprocessor1Window
DataSegmentWindow
EditCopyAction
EditCutAction
EditFindReplaceAction
Editor
EditPane
EditPasteAction
EditRedoAction
EditSelectAllAction
EditTabbedPane
EditUndoAction
ExecutePane
FileCloseAction
FileCloseAllAction
FileDumpMemoryAction
FileExitAction
FileNewAction
FileOpenAction
FilePrintAction
FileSaveAction
FileSaveAllAction
FileSaveAsAction
FileStatus
GuiAction
HardcopyWriter
HelpAboutAction
HelpHelpAction
LabelsWindow
MainPane
MessagesPane
NumberDisplayBaseChooser
PopupListener
RegistersPane
RegistersWindow
RepeatButton
RunAssembleAction
RunBackstepAction
RunClearBreakpointsAction
RunGoAction
RunPauseAction
RunResetAction
RunSpeedPanel
RunStepAction
RunStopAction
RunToggleBreakpointsAction
SettingsAddressDisplayBaseAction
SettingsAssembleAllAction
SettingsAssembleOnOpenAction
SettingsDelayedBranchingAction
SettingsEditorAction
SettingsExceptionHandlerAction
SettingsExtendedAction
SettingsHighlightingAction
SettingsLabelAction
SettingsMemoryConfigurationAction
SettingsPopupInputAction
SettingsProgramArgumentsAction
SettingsSelfModifyingCodeAction
SettingsStartAtMainAction
SettingsValueDisplayBaseAction
SettingsWarningsAreErrorsAction
TextSegmentWindow
ToolAction
ToolLoader
VenusUI
Exceptions
HardcopyWriter.PrintCanceledException
HelpHelpAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class HelpHelpAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.HelpHelpAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class HelpHelpAction
extends GuiAction
Action for the Help -> Help menu item
See Also:
Serialized Form
Field Summary
static String descriptionDetailSeparator
Separates Instruction name descriptor from detailed (operation) description
in help string.
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
HelpHelpAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
Displays tabs with categories of information
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
descriptionDetailSeparator
public static final String descriptionDetailSeparator
Separates Instruction name descriptor from detailed (operation) description
in help string.
See Also:
Constant Field Values
Constructor Detail
HelpHelpAction
public HelpHelpAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Displays tabs with categories of information
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
EditCutAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class EditCutAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.EditCutAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class EditCutAction
extends GuiAction
Action for the Edit -> Cut menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
EditCutAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
EditCutAction
public EditCutAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FileDumpMemoryAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FileDumpMemoryAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.FileDumpMemoryAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class FileDumpMemoryAction
extends GuiAction
Action for the File -> Save For Dump Memory menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
FileDumpMemoryAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
FileDumpMemoryAction
public FileDumpMemoryAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsSelfModifyingCodeAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsSelfModifyingCodeAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsSelfModifyingCodeAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsSelfModifyingCodeAction
extends GuiAction
Action class for the Settings menu item to control whether
the running MIPS program can write to the text segment or
branch to the data segment. This actions permit the program
to generate and execute binary code at runtime. In other
words, modify itself.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsSelfModifyingCodeAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsSelfModifyingCodeAction
public SettingsSelfModifyingCodeAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.venus
Class Summary
AbstractFontSettingDialog Abstract class for a font selection dialog.
Coprocessor0Window Sets up a window to display registers in the UI.
Coprocessor1Window Sets up a window to display Coprocessor 1 registers in the Registers pane of the UI.
DataSegmentWindow Represents the Data Segment window, which is a type of JInternalFrame.
EditCopyAction Action for the Edit -> Copy menu item
EditCutAction Action for the Edit -> Cut menu item
EditFindReplaceAction Action for the Edit -> Find/Replace menu item
Editor Manage the file being edited.
EditPane Represents one file opened for editing.
EditPasteAction Action for the Edit -> Paste menu item
EditRedoAction Action for the Edit -> Redo menu item
EditSelectAllAction Action for the Edit -> Copy menu item
EditTabbedPane Tabbed pane for the editor.
EditUndoAction Action for the Edit -> Undo menu item
ExecutePane Container for the execution-related windows.
FileCloseAction Action for the File -> Close menu item
FileCloseAllAction Action for the File -> Close All menu item
FileDumpMemoryAction Action for the File -> Save For Dump Memory menu item
FileExitAction Action for the File -> Exit menu item
FileNewAction Action for the File -> New menu item
FileOpenAction Action for the File -> Open menu item
FilePrintAction Action for the File -> Print menu item
FileSaveAction Action for the File -> Save menu item
FileSaveAllAction Action for the File -> Close All menu item
FileSaveAsAction Action for the File -> Save As menu item
FileStatus Used to store and return information on the status of the current ASM file that
is being edited in the program.
GuiAction parent class for Action subclasses to be defined for every menu/toolbar
option.
HardcopyWriter
HelpAboutAction Action for the Help -> About menu item
HelpHelpAction Action for the Help -> Help menu item
LabelsWindow Represents the Labels window, which is a type of JInternalFrame.
MainPane Creates the tabbed areas in the UI and also created the internal windows that
exist in them.
MessagesPane Creates the message window at the bottom of the UI.
NumberDisplayBaseChooser Use to select base for displaying numbers.
PopupListener
RegistersPane Contains tabbed areas in the UI to display register contents
RegistersWindow Sets up a window to display registers in the UI.
RepeatButton RepeatButton is a JButton which contains a timer
for firing events while the button is held down.
RunAssembleAction Action class for the Run -> Assemble menu item (and toolbar icon)
RunBackstepAction Action for the Run -> Backstep menu item
RunClearBreakpointsAction Action class for the Run menu item to clear execution breakpoints that have been set.
RunGoAction Action class for the Run -> Go menu item (and toolbar icon)
RunPauseAction Action class for the Run -> Pause menu item (and toolbar icon)
RunResetAction Action for the Run -> Reset menu item
RunSpeedPanel Class for the Run speed slider control.
RunStepAction Action for the Run -> Step menu item
RunStopAction Action class for the Run -> Stop menu item (and toolbar icon)
RunToggleBreakpointsAction Action class for the Run menu item to clear execution breakpoints that have been set.
SettingsAddressDisplayBaseAction Action class for the Settings menu item to control number base (10 or 16) of memory addresses.
SettingsAssembleAllAction Action class for the Settings menu item to determine whether assemble operation applies
only to current file or to all files in its directory.
SettingsAssembleOnOpenAction Action class for the Settings menu item to control automatic assemble of file upon opening.
SettingsDelayedBranchingAction Action class for the Settings menu item to control delayed branching.
SettingsEditorAction Action class for the Settings menu item for text editor settings.
SettingsExceptionHandlerAction Action class for the Settings menu item for optionally loading a MIPS exception handler.
SettingsExtendedAction Action class for the Settings menu item to control use of extended (pseudo) instructions or formats.
SettingsHighlightingAction Action class for the Settings menu item for text editor settings.
SettingsLabelAction Action class for the Settings menu item to control display of Labels window (symbol table).
SettingsMemoryConfigurationAction Action class for the Settings menu item for text editor settings.
SettingsPopupInputAction Action class for the Settings menu item to control use of popup dialog for input syscalls.
SettingsProgramArgumentsAction Action class for the Settings menu item to control whether or not
program arguments can be entered and used.
SettingsSelfModifyingCodeAction Action class for the Settings menu item to control whether
the running MIPS program can write to the text segment or
branch to the data segment.
SettingsStartAtMainAction Action class for the Settings menu item to control whether or not
assembler warnings are considered errors.
SettingsValueDisplayBaseAction Action class for the Settings menu item to control number base (10 or 16) of memory/register contents.
SettingsWarningsAreErrorsAction Action class for the Settings menu item to control whether or not
assembler warnings are considered errors.
TextSegmentWindow Creates the Text Segment window in the Execute tab of the UI
ToolAction Connects a MarsTool class (class that implements MarsTool interface) to
the Mars menu system by supplying the response to that tool’s menu item
selection.
ToolLoader This class provides functionality to bring external Mars tools into the Mars
system by adding them to its Tools menu.
VenusUI Top level container for Venus GUI.
Exception Summary
HardcopyWriter.PrintCanceledException This is the exception class that the HardcopyWriter constructor
throws when the user clicks “Cancel” in the print dialog box.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
RepeatButton
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RepeatButton
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.AbstractButton
javax.swing.JButton
mars.venus.RepeatButton
All Implemented Interfaces:
ActionListener, MouseListener, ImageObserver, ItemSelectable, MenuContainer, Serializable, EventListener, Accessible, SwingConstants
public class RepeatButton
extends JButton
implements ActionListener, MouseListener
RepeatButton is a JButton which contains a timer
for firing events while the button is held down. There is a default
initial delay of 300ms before the first event is fired and a 60ms delay
between subsequent events. When the user holds the button down and moves
the mouse out from over the button, the timer stops, but if the user moves
the mouse back over the button without having released the mouse button,
the timer starts up again at the same delay rate. If the enabled state is
changed while the timer is active, it will be stopped.
NOTE: The normal button behavior is that the action event is fired after
the button is released. It may be important to konw then that this is
still the case. So in effect, listeners will get 1 more event then what
the internal timer fires. It’s not a “bug”, per se, just something to be
aware of. There seems to be no way to suppress the final event from
firing anyway, except to process all ActionListeners internally. But
realistically, it probably doesn’t matter.
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JButton
JButton.AccessibleJButton
Nested classes/interfaces inherited from class javax.swing.AbstractButton
AbstractButton.AccessibleAbstractButton, AbstractButton.ButtonChangeListener
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.AbstractButton
actionListener, BORDER_PAINTED_CHANGED_PROPERTY, changeEvent, changeListener, CONTENT_AREA_FILLED_CHANGED_PROPERTY, DISABLED_ICON_CHANGED_PROPERTY, DISABLED_SELECTED_ICON_CHANGED_PROPERTY, FOCUS_PAINTED_CHANGED_PROPERTY, HORIZONTAL_ALIGNMENT_CHANGED_PROPERTY, HORIZONTAL_TEXT_POSITION_CHANGED_PROPERTY, ICON_CHANGED_PROPERTY, itemListener, MARGIN_CHANGED_PROPERTY, MNEMONIC_CHANGED_PROPERTY, model, MODEL_CHANGED_PROPERTY, PRESSED_ICON_CHANGED_PROPERTY, ROLLOVER_ENABLED_CHANGED_PROPERTY, ROLLOVER_ICON_CHANGED_PROPERTY, ROLLOVER_SELECTED_ICON_CHANGED_PROPERTY, SELECTED_ICON_CHANGED_PROPERTY, TEXT_CHANGED_PROPERTY, VERTICAL_ALIGNMENT_CHANGED_PROPERTY, VERTICAL_TEXT_POSITION_CHANGED_PROPERTY
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
RepeatButton()
Creates a button with no set text or icon.
RepeatButton(Action a)
Creates a button where properties are taken from the Action supplied.
RepeatButton(Icon icon)
Creates a button with an icon.
RepeatButton(String text)
Creates a button with text.
RepeatButton(String text,
Icon icon)
Creates a button with initial text and an icon.
Method Summary
void actionPerformed(ActionEvent ae)
Handle action events.
int getDelay()
Gets the delay for the timer of this button.
int getInitialDelay()
Gets the initial delay for the timer of this button.
boolean isRepeatEnabled()
Checks if the button should fire events when held.
static void main(String[] args)
Main method, for testing.
void mouseClicked(MouseEvent me)
Handle mouse clicked events.
void mouseEntered(MouseEvent me)
Handle mouse entered events.
void mouseExited(MouseEvent me)
Handle mouse exited events.
void mousePressed(MouseEvent me)
Handle mouse pressed events.
void mouseReleased(MouseEvent me)
Handle mouse released events.
void setDelay(int d)
Set the delay for the timer of this button.
void setEnabled(boolean en)
Sets the enabled state of this button.
void setInitialDelay(int d)
Sets the initial delay for the timer of this button.
void setRepeatEnabled(boolean en)
Sets if the button should fire events when held.
Methods inherited from class javax.swing.JButton
getAccessibleContext, getUIClassID, isDefaultButton, isDefaultCapable, paramString, removeNotify, setDefaultCapable, updateUI
Methods inherited from class javax.swing.AbstractButton
actionPropertyChanged, addActionListener, addChangeListener, addImpl, addItemListener, checkHorizontalKey, checkVerticalKey, configurePropertiesFromAction, createActionListener, createActionPropertyChangeListener, createChangeListener, createItemListener, doClick, doClick, fireActionPerformed, fireItemStateChanged, fireStateChanged, getAction, getActionCommand, getActionListeners, getChangeListeners, getDisabledIcon, getDisabledSelectedIcon, getDisplayedMnemonicIndex, getHideActionText, getHorizontalAlignment, getHorizontalTextPosition, getIcon, getIconTextGap, getItemListeners, getLabel, getMargin, getMnemonic, getModel, getMultiClickThreshhold, getPressedIcon, getRolloverIcon, getRolloverSelectedIcon, getSelectedIcon, getSelectedObjects, getText, getUI, getVerticalAlignment, getVerticalTextPosition, imageUpdate, init, isBorderPainted, isContentAreaFilled, isFocusPainted, isRolloverEnabled, isSelected, paintBorder, removeActionListener, removeChangeListener, removeItemListener, setAction, setActionCommand, setBorderPainted, setContentAreaFilled, setDisabledIcon, setDisabledSelectedIcon, setDisplayedMnemonicIndex, setFocusPainted, setHideActionText, setHorizontalAlignment, setHorizontalTextPosition, setIcon, setIconTextGap, setLabel, setLayout, setMargin, setMnemonic, setMnemonic, setModel, setMultiClickThreshhold, setPressedIcon, setRolloverEnabled, setRolloverIcon, setRolloverSelectedIcon, setSelected, setSelectedIcon, setText, setUI, setVerticalAlignment, setVerticalTextPosition
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
RepeatButton
public RepeatButton()
Creates a button with no set text or icon.
RepeatButton
public RepeatButton(Action a)
Creates a button where properties are taken from the Action supplied.
Parameters:
a – the button action
RepeatButton
public RepeatButton(Icon icon)
Creates a button with an icon.
Parameters:
icon – the button icon
RepeatButton
public RepeatButton(String text)
Creates a button with text.
Parameters:
text – the button text
RepeatButton
public RepeatButton(String text,
Icon icon)
Creates a button with initial text and an icon.
Parameters:
text – the button text
icon – the button icon
Method Detail
getDelay
public int getDelay()
Gets the delay for the timer of this button.
Returns:
the delay
setDelay
public void setDelay(int d)
Set the delay for the timer of this button.
Parameters:
d – the delay
getInitialDelay
public int getInitialDelay()
Gets the initial delay for the timer of this button.
Returns:
the initial delay
setInitialDelay
public void setInitialDelay(int d)
Sets the initial delay for the timer of this button.
Parameters:
d – the initial delay
isRepeatEnabled
public boolean isRepeatEnabled()
Checks if the button should fire events when held. If false, the
button is effectively a plain old JButton, but there may be times
when this feature might wish to be disabled.
Returns:
if true, the button should fire events when held
setRepeatEnabled
public void setRepeatEnabled(boolean en)
Sets if the button should fire events when held. If false, the
button is effectively a plain old JButton, but there may be times
when this feature might wish to be disabled. If false, it will
also stop the timer if it’s running.
Parameters:
en – if true, the button should fire events when held
setEnabled
public void setEnabled(boolean en)
Sets the enabled state of this button. Overridden to stop the timer
if it’s running.
Overrides:
setEnabled in class AbstractButton
Parameters:
en – if true, enables the button
actionPerformed
public void actionPerformed(ActionEvent ae)
Handle action events. OVERRIDE THIS IN SUBCLASS!
Specified by:
actionPerformed in interface ActionListener
Parameters:
ae – the action event
mouseClicked
public void mouseClicked(MouseEvent me)
Handle mouse clicked events.
Specified by:
mouseClicked in interface MouseListener
Parameters:
me – the mouse event
mousePressed
public void mousePressed(MouseEvent me)
Handle mouse pressed events.
Specified by:
mousePressed in interface MouseListener
Parameters:
me – the mouse event
mouseReleased
public void mouseReleased(MouseEvent me)
Handle mouse released events.
Specified by:
mouseReleased in interface MouseListener
Parameters:
me – the mouse event
mouseEntered
public void mouseEntered(MouseEvent me)
Handle mouse entered events.
Specified by:
mouseEntered in interface MouseListener
Parameters:
me – the mouse event
mouseExited
public void mouseExited(MouseEvent me)
Handle mouse exited events.
Specified by:
mouseExited in interface MouseListener
Parameters:
me – the mouse event
main
public static void main(String[] args)
Main method, for testing. Creates a frame with both styles of menu.
Parameters:
args – the command-line arguments
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
EditCopyAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class EditCopyAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.EditCopyAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class EditCopyAction
extends GuiAction
Action for the Edit -> Copy menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
EditCopyAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
EditCopyAction
public EditCopyAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FileSaveAllAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FileSaveAllAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.FileSaveAllAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class FileSaveAllAction
extends GuiAction
Action for the File -> Close All menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
FileSaveAllAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
FileSaveAllAction
public FileSaveAllAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MessagesPane
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class MessagesPane
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JTabbedPane
mars.venus.MessagesPane
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, SwingConstants
public class MessagesPane
extends JTabbedPane
Creates the message window at the bottom of the UI.
Author:
Team JSpim
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JTabbedPane
JTabbedPane.AccessibleJTabbedPane, JTabbedPane.ModelListener
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
static int MAXIMUM_SCROLLED_CHARACTERS
static int NUMBER_OF_CHARACTERS_TO_CUT
Fields inherited from class javax.swing.JTabbedPane
changeEvent, changeListener, model, SCROLL_TAB_LAYOUT, tabPlacement, WRAP_TAB_LAYOUT
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
MessagesPane()
Constructor for the class, sets up two fresh tabbed text areas for program feedback.
Method Summary
JTextArea getAssembleTextArea()
Returns component used to display assembler messages
String getInputString(int maxLen)
Method used by the SystemIO class to get interactive user input
requested by a running MIPS program (e.g.
String getInputString(String prompt)
Method used by the SystemIO class to get interactive user input
requested by a running MIPS program (e.g.
JTextArea getRunTextArea()
Returns component used to display runtime messages
void postMarsMessage(String message)
Post a message to the assembler display
void postRunMessage(String message)
Post a message to the runtime display
void selectEditorTextLine(String fileName,
int line,
int column)
Will select the specified line in an editor tab.
void selectErrorMessage(String fileName,
int line,
int column)
Will select the Mars Messages tab error message that matches the given
specifications, if it is found.
void selectMarsMessageTab()
Make the assembler message tab current (up front)
void selectRunMessageTab()
Make the runtime message tab current (up front)
Methods inherited from class javax.swing.JTabbedPane
add, add, add, add, add, addChangeListener, addTab, addTab, addTab, createChangeListener, fireStateChanged, getAccessibleContext, getBackgroundAt, getBoundsAt, getChangeListeners, getComponentAt, getDisabledIconAt, getDisplayedMnemonicIndexAt, getForegroundAt, getIconAt, getMnemonicAt, getModel, getSelectedComponent, getSelectedIndex, getTabComponentAt, getTabCount, getTabLayoutPolicy, getTabPlacement, getTabRunCount, getTitleAt, getToolTipText, getToolTipTextAt, getUI, getUIClassID, indexAtLocation, indexOfComponent, indexOfTab, indexOfTab, indexOfTabComponent, insertTab, isEnabledAt, paramString, remove, remove, removeAll, removeChangeListener, removeTabAt, setBackgroundAt, setComponentAt, setDisabledIconAt, setDisplayedMnemonicIndexAt, setEnabledAt, setForegroundAt, setIconAt, setMnemonicAt, setModel, setSelectedComponent, setSelectedIndex, setTabComponentAt, setTabLayoutPolicy, setTabPlacement, setTitleAt, setToolTipTextAt, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
MAXIMUM_SCROLLED_CHARACTERS
public static final int MAXIMUM_SCROLLED_CHARACTERS
NUMBER_OF_CHARACTERS_TO_CUT
public static final int NUMBER_OF_CHARACTERS_TO_CUT
Constructor Detail
MessagesPane
public MessagesPane()
Constructor for the class, sets up two fresh tabbed text areas for program feedback.
Method Detail
selectErrorMessage
public void selectErrorMessage(String fileName,
int line,
int column)
Will select the Mars Messages tab error message that matches the given
specifications, if it is found. Matching is done by constructing
a string using the parameter values and searching the text area for the last
occurrance of that string.
Parameters:
fileName – A String containing the file path name.
line – Line number for error message
column – Column number for error message
selectEditorTextLine
public void selectEditorTextLine(String fileName,
int line,
int column)
Will select the specified line in an editor tab. If the file is open
but not current, its tab will be made current. If the file is not open,
it will be opened in a new tab and made current, however the line will
not be selected (apparent apparent problem with JEditTextArea).
Parameters:
fileName – A String containing the file path name.
line – Line number for error message
column – Column number for error message
getAssembleTextArea
public JTextArea getAssembleTextArea()
Returns component used to display assembler messages
Returns:
assembler message text component
getRunTextArea
public JTextArea getRunTextArea()
Returns component used to display runtime messages
Returns:
runtime message text component
postMarsMessage
public void postMarsMessage(String message)
Post a message to the assembler display
Parameters:
message – String to append to assembler display text
postRunMessage
public void postRunMessage(String message)
Post a message to the runtime display
Parameters:
message – String to append to runtime display text
selectMarsMessageTab
public void selectMarsMessageTab()
Make the assembler message tab current (up front)
selectRunMessageTab
public void selectRunMessageTab()
Make the runtime message tab current (up front)
getInputString
public String getInputString(String prompt)
Method used by the SystemIO class to get interactive user input
requested by a running MIPS program (e.g. syscall #5 to read an
integer). SystemIO knows whether simulator is being run at
command line by the user, or by the GUI. If run at command line,
it gets input from System.in rather than here.
This is an overloaded method. This version, with the String parameter,
is used to get input from a popup dialog.
Parameters:
prompt – Prompt to display to the user.
Returns:
User input.
getInputString
public String getInputString(int maxLen)
Method used by the SystemIO class to get interactive user input
requested by a running MIPS program (e.g. syscall #5 to read an
integer). SystemIO knows whether simulator is being run at
command line by the user, or by the GUI. If run at command line,
it gets input from System.in rather than here.
This is an overloaded method. This version, with the int parameter,
is used to get input from the MARS Run I/O window.
Parameters:
maxLen: – maximum length of input. This method returns when maxLen characters have been read. Use -1 for no length restrictions.
Returns:
User input.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsWarningsAreErrorsAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsWarningsAreErrorsAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsWarningsAreErrorsAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsWarningsAreErrorsAction
extends GuiAction
Action class for the Settings menu item to control whether or not
assembler warnings are considered errors. If so, a program generating
warnings but not errors will not assemble.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsWarningsAreErrorsAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsWarningsAreErrorsAction
public SettingsWarningsAreErrorsAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
NumberDisplayBaseChooser
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class NumberDisplayBaseChooser
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.AbstractButton
javax.swing.JToggleButton
javax.swing.JCheckBox
mars.venus.NumberDisplayBaseChooser
All Implemented Interfaces:
ImageObserver, ItemSelectable, MenuContainer, Serializable, Accessible, SwingConstants
public class NumberDisplayBaseChooser
extends JCheckBox
Use to select base for displaying numbers. Initially the
choices are only 10 (decimal) and 16 (hex), so I’m using
a check box where checked means hex. If base 8 (octal)
is added later, the Component will need to change.
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JCheckBox
JCheckBox.AccessibleJCheckBox
Nested classes/interfaces inherited from class javax.swing.JToggleButton
JToggleButton.AccessibleJToggleButton, JToggleButton.ToggleButtonModel
Nested classes/interfaces inherited from class javax.swing.AbstractButton
AbstractButton.AccessibleAbstractButton, AbstractButton.ButtonChangeListener
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
static int ASCII
static int DECIMAL
static int HEXADECIMAL
Fields inherited from class javax.swing.JCheckBox
BORDER_PAINTED_FLAT_CHANGED_PROPERTY
Fields inherited from class javax.swing.AbstractButton
actionListener, BORDER_PAINTED_CHANGED_PROPERTY, changeEvent, changeListener, CONTENT_AREA_FILLED_CHANGED_PROPERTY, DISABLED_ICON_CHANGED_PROPERTY, DISABLED_SELECTED_ICON_CHANGED_PROPERTY, FOCUS_PAINTED_CHANGED_PROPERTY, HORIZONTAL_ALIGNMENT_CHANGED_PROPERTY, HORIZONTAL_TEXT_POSITION_CHANGED_PROPERTY, ICON_CHANGED_PROPERTY, itemListener, MARGIN_CHANGED_PROPERTY, MNEMONIC_CHANGED_PROPERTY, model, MODEL_CHANGED_PROPERTY, PRESSED_ICON_CHANGED_PROPERTY, ROLLOVER_ENABLED_CHANGED_PROPERTY, ROLLOVER_ICON_CHANGED_PROPERTY, ROLLOVER_SELECTED_ICON_CHANGED_PROPERTY, SELECTED_ICON_CHANGED_PROPERTY, TEXT_CHANGED_PROPERTY, VERTICAL_ALIGNMENT_CHANGED_PROPERTY, VERTICAL_TEXT_POSITION_CHANGED_PROPERTY
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
NumberDisplayBaseChooser(String text,
boolean displayInHex)
constructor.
Method Summary
static String formatDoubleNumber(long value,
int base)
Produces a string form of a double given a long containing
the 64 bit pattern and the numerical base to use (10 or 16).
static String formatFloatNumber(int value,
int base)
Produces a string form of a float given an integer containing
the 32 bit pattern and the numerical base to use (10 or 16).
static String formatNumber(double value,
int base)
Produces a string form of a double given the value and the
numerical base to convert it to.
static String formatNumber(float value,
int base)
Produces a string form of a float given the value and the
numerical base to convert it to.
String formatNumber(int value)
Produces a string form of a number given the value.
static String formatNumber(int value,
int base)
Produces a string form of an integer given the value and the
numerical base to convert it to.
String formatUnsignedInteger(int value)
Produces a string form of an unsigned integer given the value.
static String formatUnsignedInteger(int value,
int base)
Produces a string form of an unsigned given the value and the
numerical base to convert it to.
int getBase()
Retrieve the current number base.
static int getBase(boolean setting)
Return the number base corresponding to the specified setting.
void setBase(int newBase)
Set the current number base.
void setSettingsMenuItem(JCheckBoxMenuItem setter)
Set the menu item from Settings menu that corresponds to this chooser.
Methods inherited from class javax.swing.JCheckBox
getAccessibleContext, getUIClassID, isBorderPaintedFlat, paramString, setBorderPaintedFlat, updateUI
Methods inherited from class javax.swing.AbstractButton
actionPropertyChanged, addActionListener, addChangeListener, addImpl, addItemListener, checkHorizontalKey, checkVerticalKey, configurePropertiesFromAction, createActionListener, createActionPropertyChangeListener, createChangeListener, createItemListener, doClick, doClick, fireActionPerformed, fireItemStateChanged, fireStateChanged, getAction, getActionCommand, getActionListeners, getChangeListeners, getDisabledIcon, getDisabledSelectedIcon, getDisplayedMnemonicIndex, getHideActionText, getHorizontalAlignment, getHorizontalTextPosition, getIcon, getIconTextGap, getItemListeners, getLabel, getMargin, getMnemonic, getModel, getMultiClickThreshhold, getPressedIcon, getRolloverIcon, getRolloverSelectedIcon, getSelectedIcon, getSelectedObjects, getText, getUI, getVerticalAlignment, getVerticalTextPosition, imageUpdate, init, isBorderPainted, isContentAreaFilled, isFocusPainted, isRolloverEnabled, isSelected, paintBorder, removeActionListener, removeChangeListener, removeItemListener, removeNotify, setAction, setActionCommand, setBorderPainted, setContentAreaFilled, setDisabledIcon, setDisabledSelectedIcon, setDisplayedMnemonicIndex, setEnabled, setFocusPainted, setHideActionText, setHorizontalAlignment, setHorizontalTextPosition, setIcon, setIconTextGap, setLabel, setLayout, setMargin, setMnemonic, setMnemonic, setModel, setMultiClickThreshhold, setPressedIcon, setRolloverEnabled, setRolloverIcon, setRolloverSelectedIcon, setSelected, setSelectedIcon, setText, setUI, setVerticalAlignment, setVerticalTextPosition
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
DECIMAL
public static final int DECIMAL
See Also:
Constant Field Values
HEXADECIMAL
public static final int HEXADECIMAL
See Also:
Constant Field Values
ASCII
public static final int ASCII
See Also:
Constant Field Values
Constructor Detail
NumberDisplayBaseChooser
public NumberDisplayBaseChooser(String text,
boolean displayInHex)
constructor. It assumes the text will be worded
so that a checked box means hexadecimal!
Parameters:
text – Text to accompany the check box.
defaultBase – Currently either DECIMAL or HEXADECIMAL
Method Detail
getBase
public int getBase()
Retrieve the current number base.
Returns:
current number base, currently DECIMAL or HEXADECIMAL
setBase
public void setBase(int newBase)
Set the current number base.
Parameters:
newBase – The new number base. Currently, if it is
neither DECIMAL nor HEXADECIMAL, the base will not be changed.
formatUnsignedInteger
public static String formatUnsignedInteger(int value,
int base)
Produces a string form of an unsigned given the value and the
numerical base to convert it to. This class
method can be used by anyone anytime. If base is 16, result
is same as for formatNumber(). If base is 10, will produce
string version of unsigned value. E.g. 0xffffffff will produce
“4294967295” instead of “-1”.
Parameters:
value – the number to be converted
base – the numerical base to use (currently 10 or 16)
Returns:
a String equivalent of the value rendered appropriately.
formatNumber
public static String formatNumber(int value,
int base)
Produces a string form of an integer given the value and the
numerical base to convert it to. There is an instance
method that uses the internally stored base. This class
method can be used by anyone anytime.
Parameters:
value – the number to be converted
base – the numerical base to use (currently 10 or 16)
Returns:
a String equivalent of the value rendered appropriately.
formatNumber
public static String formatNumber(float value,
int base)
Produces a string form of a float given the value and the
numerical base to convert it to. There is an instance
method that uses the internally stored base. This class
method can be used by anyone anytime.
Parameters:
value – the number to be converted
base – the numerical base to use (currently 10 or 16)
Returns:
a String equivalent of the value rendered appropriately.
formatNumber
public static String formatNumber(double value,
int base)
Produces a string form of a double given the value and the
numerical base to convert it to. There is an instance
method that uses the internally stored base. This class
method can be used by anyone anytime.
Parameters:
value – the number to be converted
base – the numerical base to use (currently 10 or 16)
Returns:
a String equivalent of the value rendered appropriately.
formatNumber
public String formatNumber(int value)
Produces a string form of a number given the value. There
is also an class (static method) that uses a specified
base.
Parameters:
value – the number to be converted
Returns:
a String equivalent of the value rendered appropriately.
formatUnsignedInteger
public String formatUnsignedInteger(int value)
Produces a string form of an unsigned integer given the value. There
is also an class (static method) that uses a specified base.
If the current base is 16, this produces the same result as formatNumber().
Parameters:
value – the number to be converted
Returns:
a String equivalent of the value rendered appropriately.
formatFloatNumber
public static String formatFloatNumber(int value,
int base)
Produces a string form of a float given an integer containing
the 32 bit pattern and the numerical base to use (10 or 16). If the
base is 16, the string will be built from the 32 bits. If the
base is 10, the int bits will be converted to float and the
string constructed from that. Seems an odd distinction to make,
except that contents of floating point registers are stored
internally as int bits. If the int bits represent a NaN value
(of which there are many!), converting them to float then calling
formatNumber(float, int) above, causes the float value to become
the canonical NaN value 0x7fc00000. It does not preserve the bit
pattern! Then converting it to hex string yields the canonical NaN.
Not an issue if display base is 10 since result string will be NaN
no matter what the internal NaN value is.
Parameters:
value – the int bits to be converted to string of corresponding float.
base – the numerical base to use (currently 10 or 16)
Returns:
a String equivalent of the value rendered appropriately.
formatDoubleNumber
public static String formatDoubleNumber(long value,
int base)
Produces a string form of a double given a long containing
the 64 bit pattern and the numerical base to use (10 or 16). If the
base is 16, the string will be built from the 64 bits. If the
base is 10, the long bits will be converted to double and the
string constructed from that. Seems an odd distinction to make,
except that contents of floating point registers are stored
internally as int bits. If the int bits represent a NaN value
(of which there are many!), converting them to double then calling
formatNumber(double, int) above, causes the double value to become
the canonical NaN value. It does not preserve the bit
pattern! Then converting it to hex string yields the canonical NaN.
Not an issue if display base is 10 since result string will be NaN
no matter what the internal NaN value is.
Parameters:
value – the long bits to be converted to string of corresponding double.
base – the numerical base to use (currently 10 or 16)
Returns:
a String equivalent of the value rendered appropriately.
setSettingsMenuItem
public void setSettingsMenuItem(JCheckBoxMenuItem setter)
Set the menu item from Settings menu that corresponds to this chooser.
It is the responsibility of that item to register here, because this
one is created first (before the menu item). They need to communicate
with each other so that whenever one changes, so does the other. They
cannot be the same object (one is JCheckBox, the other is JCheckBoxMenuItem).
getBase
public static int getBase(boolean setting)
Return the number base corresponding to the specified setting.
Returns:
HEXADECIMAL if setting is true, DECIMAL otherwise.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RunStepAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RunStepAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.RunStepAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class RunStepAction
extends GuiAction
Action for the Run -> Step menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
RunStepAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
perform next simulated instruction step.
void stepped(boolean done,
int reason,
ProcessingException pe)
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
RunStepAction
public RunStepAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
perform next simulated instruction step.
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
stepped
public void stepped(boolean done,
int reason,
ProcessingException pe)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsHighlightingAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsHighlightingAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsHighlightingAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsHighlightingAction
extends GuiAction
Action class for the Settings menu item for text editor settings.
See Also:
Serialized Form
Field Summary
static String APPLY_TOOL_TIP_TEXT
static String CANCEL_TOOL_TIP_TEXT
static String CLOSE_TOOL_TIP_TEXT
static String RESET_TOOL_TIP_TEXT
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsHighlightingAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Create a new SettingsEditorAction.
Method Summary
void actionPerformed(ActionEvent e)
When this action is triggered, launch a dialog to view and modify
editor settings.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
CLOSE_TOOL_TIP_TEXT
public static final String CLOSE_TOOL_TIP_TEXT
See Also:
Constant Field Values
APPLY_TOOL_TIP_TEXT
public static final String APPLY_TOOL_TIP_TEXT
See Also:
Constant Field Values
RESET_TOOL_TIP_TEXT
public static final String RESET_TOOL_TIP_TEXT
See Also:
Constant Field Values
CANCEL_TOOL_TIP_TEXT
public static final String CANCEL_TOOL_TIP_TEXT
See Also:
Constant Field Values
Constructor Detail
SettingsHighlightingAction
public SettingsHighlightingAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Create a new SettingsEditorAction. Has all the GuiAction parameters.
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
When this action is triggered, launch a dialog to view and modify
editor settings.
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
EditPane
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class EditPane
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
mars.venus.EditPane
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Observer, Accessible
public class EditPane
extends JPanel
implements Observer
Represents one file opened for editing. Maintains required internal structures.
Before Mars 4.0, there was only one editor pane, a tab, and only one file could
be open at a time. With 4.0 came the multifile (pane, tab) editor, and existing
duties were split between EditPane and the new EditTabbedPane class.
Author:
Sanderson and Bumgarner
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
EditPane(VenusUI appFrame)
Constructor for the EditPane class.
Method Summary
int convertLineColumnToStreamPosition(int line,
int column)
Given line and column (position in the line) numbers, calculate
its byte stream position in text being edited.
Point convertStreamPositionToLineColumn(int position)
void copyText()
copy currently-selected text into clipboard
void cutText()
cut currently-selected text into clipboard
void discardAllUndoableEdits()
Get rid of any accumulated undoable edits.
void displayCaretPosition(int pos)
Update the caret position label on the editor’s border to
display the current line and column.
void displayCaretPosition(Point p)
Display cursor coordinates
int doFindText(String find,
boolean caseSensitive)
Finds next occurrence of text in a forward search of a string.
int doReplace(String find,
String replace,
boolean caseSensitive)
Finds and replaces next occurrence of text in a string in a forward search.
int doReplaceAll(String find,
String replace,
boolean caseSensitive)
Finds and replaces ALL occurrences of text in a string in a forward search.
String getFilename()
Delegates to corresponding FileStatus method
int getFileStatus()
Get the editing status for this EditPane’s associated document.
String getLineNumbersList(Document doc)
String getPathname()
Delegates to corresponding FileStatus method
String getSource()
Get source code text
int getSourceLineCount()
Calculate and return number of lines in source code text.
UndoManager getUndoManager()
get the manager in charge of Undo and Redo operations
boolean hasUnsavedEdits()
Delegates to corresponding FileStatus method
boolean isNew()
Delegates to corresponding FileStatus method
void pasteText()
paste clipboard contents at cursor position
void redo()
Redo previous edit
void selectAllText()
select all text
void selectLine(int line)
Select the specified editor text line.
void selectLine(int line,
int column)
Select the specified editor text line.
void setFileStatus(int fileStatus)
Set the editing status for this EditPane’s associated document.
void setPathname(String pathname)
Delegates to corresponding FileStatus method
void setShowLineNumbersEnabled(boolean enabled)
enable or disable checkbox that controls display of line numbers
void setSourceCode(String s,
boolean editable)
For initalizing the source code when opening an ASM file
boolean showingLineNumbers()
get editor’s line number display status
void tellEditingComponentToRequestFocusInWindow()
Delegates to text area’s requestFocusInWindow method.
void undo()
Undo previous edit
void update(Observable fontChanger,
Object arg)
Update, if source code is visible, when Font setting changes.
void updateRedoState()
Update state of Edit menu’s Redo menu item.
void updateStaticFileStatus()
Delegates to corresponding FileStatus method
void updateUndoState()
Update state of Edit menu’s Undo menu item.
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
EditPane
public EditPane(VenusUI appFrame)
Constructor for the EditPane class.
Method Detail
setSourceCode
public void setSourceCode(String s,
boolean editable)
For initalizing the source code when opening an ASM file
Parameters:
s – String containing text
editable – set true if code is editable else false
discardAllUndoableEdits
public void discardAllUndoableEdits()
Get rid of any accumulated undoable edits. It is useful to call
this method after opening a file into the text area. The
act of setting its text content upon reading the file will generate
an undoable edit. Normally you don’t want a freshly-opened file
to appear with its Undo action enabled. But it will unless you
call this after setting the text.
getLineNumbersList
public String getLineNumbersList(Document doc)
getSourceLineCount
public int getSourceLineCount()
Calculate and return number of lines in source code text.
Do this by counting newline characters then adding one if last line does
not end with newline character.
getSource
public String getSource()
Get source code text
Returns:
Sting containing source code
setFileStatus
public void setFileStatus(int fileStatus)
Set the editing status for this EditPane’s associated document.
For the argument, use one of the constants from class FileStatus.
Parameters:
FileStatus – the status constant from class FileStatus
getFileStatus
public int getFileStatus()
Get the editing status for this EditPane’s associated document.
This will be one of the constants from class FileStatus.
getFilename
public String getFilename()
Delegates to corresponding FileStatus method
getPathname
public String getPathname()
Delegates to corresponding FileStatus method
setPathname
public void setPathname(String pathname)
Delegates to corresponding FileStatus method
hasUnsavedEdits
public boolean hasUnsavedEdits()
Delegates to corresponding FileStatus method
isNew
public boolean isNew()
Delegates to corresponding FileStatus method
tellEditingComponentToRequestFocusInWindow
public void tellEditingComponentToRequestFocusInWindow()
Delegates to text area’s requestFocusInWindow method.
updateStaticFileStatus
public void updateStaticFileStatus()
Delegates to corresponding FileStatus method
getUndoManager
public UndoManager getUndoManager()
get the manager in charge of Undo and Redo operations
Returns:
the UnDo manager
copyText
public void copyText()
copy currently-selected text into clipboard
cutText
public void cutText()
cut currently-selected text into clipboard
pasteText
public void pasteText()
paste clipboard contents at cursor position
selectAllText
public void selectAllText()
select all text
undo
public void undo()
Undo previous edit
redo
public void redo()
Redo previous edit
updateUndoState
public void updateUndoState()
Update state of Edit menu’s Undo menu item.
updateRedoState
public void updateRedoState()
Update state of Edit menu’s Redo menu item.
showingLineNumbers
public boolean showingLineNumbers()
get editor’s line number display status
Returns:
true if editor is current displaying line numbers, false otherwise.
setShowLineNumbersEnabled
public void setShowLineNumbersEnabled(boolean enabled)
enable or disable checkbox that controls display of line numbers
Parameters:
enable – True to enable box, false to disable.
displayCaretPosition
public void displayCaretPosition(int pos)
Update the caret position label on the editor’s border to
display the current line and column. The position is given
as text stream offset and will be converted into line and column.
Parameters:
pos – Offset into the text stream of caret.
displayCaretPosition
public void displayCaretPosition(Point p)
Display cursor coordinates
Parameters:
p – Point object with x-y (column, line number) coordinates of cursor
convertStreamPositionToLineColumn
public Point convertStreamPositionToLineColumn(int position)
convertLineColumnToStreamPosition
public int convertLineColumnToStreamPosition(int line,
int column)
Given line and column (position in the line) numbers, calculate
its byte stream position in text being edited.
Parameters:
line – Line number in file (starts with 1)
column – Position within that line (starts with 1)
Returns:
corresponding stream position. Returns -1 if there is no corresponding position.
selectLine
public void selectLine(int line)
Select the specified editor text line. Lines are numbered starting with 1, consistent
with line numbers displayed by the editor.
Parameters:
line – The desired line number of this TextPane’s text. Numbering starts at 1, and
nothing will happen if the parameter value is less than 1
selectLine
public void selectLine(int line,
int column)
Select the specified editor text line. Lines are numbered starting with 1, consistent
with line numbers displayed by the editor.
Parameters:
line – The desired line number of this TextPane’s text. Numbering starts at 1, and
nothing will happen if the parameter value is less than 1
column – Desired column at which to place the cursor.
doFindText
public int doFindText(String find,
boolean caseSensitive)
Finds next occurrence of text in a forward search of a string. Search begins
at the current cursor location, and wraps around when the end of the string
is reached.
Parameters:
find – the text to locate in the string
caseSensitive – true if search is to be case-sensitive, false otherwise
Returns:
TEXT_FOUND or TEXT_NOT_FOUND, depending on the result.
doReplace
public int doReplace(String find,
String replace,
boolean caseSensitive)
Finds and replaces next occurrence of text in a string in a forward search.
If cursor is initially at end
of matching selection, will immediately replace then find and select the
next occurrence if any. Otherwise it performs a find operation. The replace
can be undone with one undo operation.
Parameters:
find – the text to locate in the string
replace – the text to replace the find text with – if the find text exists
caseSensitive – true for case sensitive. false to ignore case
Returns:
Returns TEXT_FOUND if not initially at end of selected match and matching
occurrence is found. Returns TEXT_NOT_FOUND if the text is not matched.
Returns TEXT_REPLACED_NOT_FOUND_NEXT if replacement is successful but there are
no additional matches. Returns TEXT_REPLACED_FOUND_NEXT if reaplacement is
successful and there is at least one additional match.
doReplaceAll
public int doReplaceAll(String find,
String replace,
boolean caseSensitive)
Finds and replaces ALL occurrences of text in a string in a forward search.
All replacements are bundled into one CompoundEdit, so one Undo operation will
undo all of them.
Parameters:
find – the text to locate in the string
replace – the text to replace the find text with – if the find text exists
caseSensitive – true for case sensitive. false to ignore case
Returns:
the number of occurrences that were matched and replaced.
update
public void update(Observable fontChanger,
Object arg)
Update, if source code is visible, when Font setting changes.
This method is specified by the Observer interface.
Specified by:
update in interface Observer
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
ToolLoader
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class ToolLoader
java.lang.Object
mars.venus.ToolLoader
public class ToolLoader
extends Object
This class provides functionality to bring external Mars tools into the Mars
system by adding them to its Tools menu. This permits anyone with knowledge
of the Mars public interfaces, in particular of the Memory and Register
classes, to write applications which can interact with a MIPS program
executing under Mars. The execution is of course simulated. The
private method for loading tool classes is adapted from Bret Barker’s
GameServer class from the book “Developing Games In Java”.
Author:
Pete Sanderson with help from Bret Barker
Constructor Summary
ToolLoader()
Method Summary
JMenu buildToolsMenu()
Called in VenusUI to build its Tools menu.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
ToolLoader
public ToolLoader()
Method Detail
buildToolsMenu
public JMenu buildToolsMenu()
Called in VenusUI to build its Tools menu. If there are no qualifying tools
or any problems accessing those tools, it returns null. A qualifying tool
must be a class in the Tools package that implements MarsTool, must be compiled
into a .class file, and its .class file must be in the same Tools folder as
MarsTool.class.
Returns:
a Tools JMenu if qualifying tool classes are found, otherwise null
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsProgramArgumentsAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsProgramArgumentsAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsProgramArgumentsAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsProgramArgumentsAction
extends GuiAction
Action class for the Settings menu item to control whether or not
program arguments can be entered and used. If so, a text field
will be displayed where they can be interactively entered.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsProgramArgumentsAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsProgramArgumentsAction
public SettingsProgramArgumentsAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.venus
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object javax.swing.AbstractAction (implements javax.swing.Action, java.lang.Cloneable, java.io.Serializable)
mars.venus.GuiAction mars.venus.EditCopyAction
mars.venus.EditCutAction
mars.venus.EditFindReplaceAction
mars.venus.EditPasteAction
mars.venus.EditRedoAction
mars.venus.EditSelectAllAction
mars.venus.EditUndoAction
mars.venus.FileCloseAction
mars.venus.FileCloseAllAction
mars.venus.FileDumpMemoryAction
mars.venus.FileExitAction
mars.venus.FileNewAction
mars.venus.FileOpenAction
mars.venus.FilePrintAction
mars.venus.FileSaveAction
mars.venus.FileSaveAllAction
mars.venus.FileSaveAsAction
mars.venus.HelpAboutAction
mars.venus.HelpHelpAction
mars.venus.RunAssembleAction
mars.venus.RunBackstepAction
mars.venus.RunClearBreakpointsAction (implements javax.swing.event.TableModelListener)
mars.venus.RunGoAction
mars.venus.RunPauseAction
mars.venus.RunResetAction
mars.venus.RunStepAction
mars.venus.RunStopAction
mars.venus.RunToggleBreakpointsAction
mars.venus.SettingsAddressDisplayBaseAction
mars.venus.SettingsAssembleAllAction
mars.venus.SettingsAssembleOnOpenAction
mars.venus.SettingsDelayedBranchingAction
mars.venus.SettingsEditorAction
mars.venus.SettingsExceptionHandlerAction
mars.venus.SettingsExtendedAction
mars.venus.SettingsHighlightingAction
mars.venus.SettingsLabelAction
mars.venus.SettingsMemoryConfigurationAction
mars.venus.SettingsPopupInputAction
mars.venus.SettingsProgramArgumentsAction
mars.venus.SettingsSelfModifyingCodeAction
mars.venus.SettingsStartAtMainAction
mars.venus.SettingsValueDisplayBaseAction
mars.venus.SettingsWarningsAreErrorsAction
mars.venus.ToolAction
java.awt.Component (implements java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable)
java.awt.Container javax.swing.JComponent (implements java.io.Serializable)
javax.swing.AbstractButton (implements java.awt.ItemSelectable, javax.swing.SwingConstants)
javax.swing.JButton (implements javax.accessibility.Accessible)
mars.venus.RepeatButton (implements java.awt.event.ActionListener, java.awt.event.MouseListener)
javax.swing.JToggleButton (implements javax.accessibility.Accessible)
javax.swing.JCheckBox (implements javax.accessibility.Accessible)
mars.venus.NumberDisplayBaseChooser
javax.swing.JInternalFrame (implements javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants)
mars.venus.DataSegmentWindow (implements java.util.Observer)
mars.venus.LabelsWindow
mars.venus.TextSegmentWindow (implements java.util.Observer)
javax.swing.JLayeredPane (implements javax.accessibility.Accessible)
javax.swing.JDesktopPane (implements javax.accessibility.Accessible)
mars.venus.ExecutePane
javax.swing.JPanel (implements javax.accessibility.Accessible)
mars.venus.Coprocessor0Window (implements java.util.Observer)
mars.venus.Coprocessor1Window (implements java.awt.event.ActionListener, java.util.Observer)
mars.venus.EditPane (implements java.util.Observer)
mars.venus.RegistersWindow (implements java.util.Observer)
mars.venus.RunSpeedPanel
javax.swing.JTabbedPane (implements javax.accessibility.Accessible, java.io.Serializable, javax.swing.SwingConstants)
mars.venus.EditTabbedPane
mars.venus.MainPane
mars.venus.MessagesPane
mars.venus.RegistersPane
java.awt.Window (implements javax.accessibility.Accessible)
java.awt.Dialog javax.swing.JDialog (implements javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants)
mars.venus.AbstractFontSettingDialog
java.awt.Frame (implements java.awt.MenuContainer)
javax.swing.JFrame (implements javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants)
mars.venus.VenusUI
mars.venus.Editor
mars.venus.FileStatus
java.awt.event.MouseAdapter (implements java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.awt.event.MouseWheelListener)
mars.venus.PopupListener
java.lang.Throwable (implements java.io.Serializable)
java.lang.Exception mars.venus.HardcopyWriter.PrintCanceledException
mars.venus.ToolLoader
java.io.Writer (implements java.lang.Appendable, java.io.Closeable, java.io.Flushable)
mars.venus.HardcopyWriter
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
RunSpeedPanel
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RunSpeedPanel
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
mars.venus.RunSpeedPanel
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible
public class RunSpeedPanel
extends JPanel
Class for the Run speed slider control. One is created and can be obtained using
getInstance().
Author:
Pete Sanderson
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
static double UNLIMITED_SPEED
Constant that represents unlimited run speed.
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Method Summary
static RunSpeedPanel getInstance()
Retrieve the run speed panel object
double getRunSpeed()
returns current run speed setting, in instructions/second.
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
UNLIMITED_SPEED
public static final double UNLIMITED_SPEED
Constant that represents unlimited run speed. Compare with return value of
getRunSpeed() to determine if set to unlimited. At the unlimited setting, the GUI
will not attempt to update register and memory contents as each instruction
is executed. This is the only possible value for command-line use of Mars.
See Also:
Constant Field Values
Method Detail
getInstance
public static RunSpeedPanel getInstance()
Retrieve the run speed panel object
Returns:
the run speed panel
getRunSpeed
public double getRunSpeed()
returns current run speed setting, in instructions/second. Unlimited speed
setting is equal to RunSpeedPanel.UNLIMITED_SPEED
Returns:
run speed setting in instructions/second.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class GuiAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
Direct Known Subclasses:
EditCopyAction, EditCutAction, EditFindReplaceAction, EditPasteAction, EditRedoAction, EditSelectAllAction, EditUndoAction, FileCloseAction, FileCloseAllAction, FileDumpMemoryAction, FileExitAction, FileNewAction, FileOpenAction, FilePrintAction, FileSaveAction, FileSaveAllAction, FileSaveAsAction, HelpAboutAction, HelpHelpAction, RunAssembleAction, RunBackstepAction, RunClearBreakpointsAction, RunGoAction, RunPauseAction, RunResetAction, RunStepAction, RunStopAction, RunToggleBreakpointsAction, SettingsAddressDisplayBaseAction, SettingsAssembleAllAction, SettingsAssembleOnOpenAction, SettingsDelayedBranchingAction, SettingsEditorAction, SettingsExceptionHandlerAction, SettingsExtendedAction, SettingsHighlightingAction, SettingsLabelAction, SettingsMemoryConfigurationAction, SettingsPopupInputAction, SettingsProgramArgumentsAction, SettingsSelfModifyingCodeAction, SettingsStartAtMainAction, SettingsValueDisplayBaseAction, SettingsWarningsAreErrorsAction
public class GuiAction
extends AbstractAction
parent class for Action subclasses to be defined for every menu/toolbar
option.
See Also:
Serialized Form
Field Summary
protected VenusUI mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
protected GuiAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
mainUI
protected VenusUI mainUI
Constructor Detail
GuiAction
protected GuiAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
does nothing by default. Should be over-ridden by subclass
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FileSaveAsAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FileSaveAsAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.FileSaveAsAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class FileSaveAsAction
extends GuiAction
Action for the File -> Save As menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
FileSaveAsAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
FileSaveAsAction
public FileSaveAsAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
VenusUI
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class VenusUI
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
mars.venus.VenusUI
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, RootPaneContainer, WindowConstants
public class VenusUI
extends JFrame
Top level container for Venus GUI.
Author:
Sanderson and Team JSpim
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JFrame
JFrame.AccessibleJFrame
Nested classes/interfaces inherited from class java.awt.Frame
Frame.AccessibleAWTFrame
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
JMenuBar menu
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
VenusUI(String s)
Constructor for the Class.
Method Summary
void dispatchEventToMenu(KeyEvent evt)
Send keyboard event to menu for possible processing.
JCheckBoxMenuItem getAddressDisplayBaseMenuItem()
Get reference to settings menu item for display base of memory/register values.
Editor getEditor()
Get reference to Editor object associated with this GUI.
MainPane getMainPane()
Get reference to messages pane associated with this GUI.
static int getMenuState()
Get current menu state.
MessagesPane getMessagesPane()
Get reference to messages pane associated with this GUI.
RegistersPane getRegistersPane()
Get reference to registers pane associated with this GUI.
static boolean getReset()
To find out whether the register values are reset.
Action getRunAssembleAction()
Return reference tothe Run->Assemble item’s action.
static boolean getStarted()
To find out whether MIPS program is currently executing.
JCheckBoxMenuItem getValueDisplayBaseMenuItem()
Get reference to settings menu item for display base of memory/register values.
void haveMenuRequestFocus()
Have the menu request keyboard focus.
static void setReset(boolean b)
To set whether the register values are reset.
static void setStarted(boolean b)
To set whether MIPS program execution has started.
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
Field Detail
menu
public JMenuBar menu
Constructor Detail
VenusUI
public VenusUI(String s)
Constructor for the Class. Sets up a window object for the UI
Parameters:
s – Name of the window to be created.
Method Detail
getMenuState
public static int getMenuState()
Get current menu state. State values are constants in FileStatus class. DPS 23 July 2008
Returns:
current menu state.
setReset
public static void setReset(boolean b)
To set whether the register values are reset.
Parameters:
b – Boolean true if the register values have been reset.
setStarted
public static void setStarted(boolean b)
To set whether MIPS program execution has started.
Parameters:
b – true if the MIPS program execution has started.
getReset
public static boolean getReset()
To find out whether the register values are reset.
Returns:
Boolean true if the register values have been reset.
getStarted
public static boolean getStarted()
To find out whether MIPS program is currently executing.
Returns:
true if MIPS program is currently executing.
getEditor
public Editor getEditor()
Get reference to Editor object associated with this GUI.
Returns:
Editor for the GUI.
getMainPane
public MainPane getMainPane()
Get reference to messages pane associated with this GUI.
Returns:
MessagesPane object associated with the GUI.
getMessagesPane
public MessagesPane getMessagesPane()
Get reference to messages pane associated with this GUI.
Returns:
MessagesPane object associated with the GUI.
getRegistersPane
public RegistersPane getRegistersPane()
Get reference to registers pane associated with this GUI.
Returns:
RegistersPane object associated with the GUI.
getValueDisplayBaseMenuItem
public JCheckBoxMenuItem getValueDisplayBaseMenuItem()
Get reference to settings menu item for display base of memory/register values.
Returns:
the menu item
getAddressDisplayBaseMenuItem
public JCheckBoxMenuItem getAddressDisplayBaseMenuItem()
Get reference to settings menu item for display base of memory/register values.
Returns:
the menu item
getRunAssembleAction
public Action getRunAssembleAction()
Return reference tothe Run->Assemble item’s action. Needed by File->Open in case
assemble-upon-open flag is set.
Returns:
the Action object for the Run->Assemble operation.
haveMenuRequestFocus
public void haveMenuRequestFocus()
Have the menu request keyboard focus. DPS 5-4-10
dispatchEventToMenu
public void dispatchEventToMenu(KeyEvent evt)
Send keyboard event to menu for possible processing. DPS 5-4-10
Parameters:
evt – KeyEvent for menu component to consider for processing.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MainPane
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class MainPane
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JTabbedPane
mars.venus.MainPane
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, SwingConstants
public class MainPane
extends JTabbedPane
Creates the tabbed areas in the UI and also created the internal windows that
exist in them.
Author:
Sanderson and Bumgarner
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JTabbedPane
JTabbedPane.AccessibleJTabbedPane, JTabbedPane.ModelListener
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JTabbedPane
changeEvent, changeListener, model, SCROLL_TAB_LAYOUT, tabPlacement, WRAP_TAB_LAYOUT
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
MainPane(VenusUI appFrame,
Editor editor,
RegistersWindow regs,
Coprocessor1Window cop1Regs,
Coprocessor0Window cop0Regs)
Constructor for the MainPane class.
Method Summary
EditPane getEditPane()
Returns current edit pane.
JComponent getEditTabbedPane()
Returns component containing editor display
ExecutePane getExecutePane()
returns component containing execution-time display
ExecutePane getExecuteTab()
returns component containing execution-time display.
Methods inherited from class javax.swing.JTabbedPane
add, add, add, add, add, addChangeListener, addTab, addTab, addTab, createChangeListener, fireStateChanged, getAccessibleContext, getBackgroundAt, getBoundsAt, getChangeListeners, getComponentAt, getDisabledIconAt, getDisplayedMnemonicIndexAt, getForegroundAt, getIconAt, getMnemonicAt, getModel, getSelectedComponent, getSelectedIndex, getTabComponentAt, getTabCount, getTabLayoutPolicy, getTabPlacement, getTabRunCount, getTitleAt, getToolTipText, getToolTipTextAt, getUI, getUIClassID, indexAtLocation, indexOfComponent, indexOfTab, indexOfTab, indexOfTabComponent, insertTab, isEnabledAt, paramString, remove, remove, removeAll, removeChangeListener, removeTabAt, setBackgroundAt, setComponentAt, setDisabledIconAt, setDisplayedMnemonicIndexAt, setEnabledAt, setForegroundAt, setIconAt, setMnemonicAt, setModel, setSelectedComponent, setSelectedIndex, setTabComponentAt, setTabLayoutPolicy, setTabPlacement, setTitleAt, setToolTipTextAt, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
MainPane
public MainPane(VenusUI appFrame,
Editor editor,
RegistersWindow regs,
Coprocessor1Window cop1Regs,
Coprocessor0Window cop0Regs)
Constructor for the MainPane class.
Method Detail
getEditPane
public EditPane getEditPane()
Returns current edit pane. Implementation changed for MARS 4.0 support
for multiple panes, but specification is same.
Returns:
the editor pane
getEditTabbedPane
public JComponent getEditTabbedPane()
Returns component containing editor display
Returns:
the editor tabbed pane
getExecutePane
public ExecutePane getExecutePane()
returns component containing execution-time display
Returns:
the execute pane
getExecuteTab
public ExecutePane getExecuteTab()
returns component containing execution-time display.
Same as getExecutePane().
Returns:
the execute pane
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RunBackstepAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RunBackstepAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.RunBackstepAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class RunBackstepAction
extends GuiAction
Action for the Run -> Backstep menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
RunBackstepAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
perform next simulated instruction step.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
RunBackstepAction
public RunBackstepAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
perform next simulated instruction step.
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
FileCloseAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class FileCloseAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.FileCloseAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class FileCloseAction
extends GuiAction
Action for the File -> Close menu item
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
FileCloseAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
FileCloseAction
public FileCloseAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsPopupInputAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsPopupInputAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsPopupInputAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsPopupInputAction
extends GuiAction
Action class for the Settings menu item to control use of popup dialog for input syscalls.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsPopupInputAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsPopupInputAction
public SettingsPopupInputAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RunStopAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class RunStopAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.RunStopAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class RunStopAction
extends GuiAction
Action class for the Run -> Stop menu item (and toolbar icon)
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
RunStopAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
RunStopAction
public RunStopAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsAssembleOnOpenAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsAssembleOnOpenAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsAssembleOnOpenAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsAssembleOnOpenAction
extends GuiAction
Action class for the Settings menu item to control automatic assemble of file upon opening.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsAssembleOnOpenAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsAssembleOnOpenAction
public SettingsAssembleOnOpenAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsExceptionHandlerAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsExceptionHandlerAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsExceptionHandlerAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsExceptionHandlerAction
extends GuiAction
Action class for the Settings menu item for optionally loading a MIPS exception handler.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsExceptionHandlerAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsExceptionHandlerAction
public SettingsExceptionHandlerAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SettingsValueDisplayBaseAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class SettingsValueDisplayBaseAction
java.lang.Object
javax.swing.AbstractAction
mars.venus.GuiAction
mars.venus.SettingsValueDisplayBaseAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action
public class SettingsValueDisplayBaseAction
extends GuiAction
Action class for the Settings menu item to control number base (10 or 16) of memory/register contents.
See Also:
Serialized Form
Field Summary
Fields inherited from class mars.venus.GuiAction
mainUI
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
Constructor Summary
SettingsValueDisplayBaseAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Summary
void actionPerformed(ActionEvent e)
does nothing by default.
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SettingsValueDisplayBaseAction
public SettingsValueDisplayBaseAction(String name,
Icon icon,
String descrip,
Integer mnemonic,
KeyStroke accel,
VenusUI gui)
Method Detail
actionPerformed
public void actionPerformed(ActionEvent e)
Description copied from class: GuiAction
does nothing by default. Should be over-ridden by subclass
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class GuiAction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
AbstractFontSettingDialog
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class AbstractFontSettingDialog
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Dialog
javax.swing.JDialog
mars.venus.AbstractFontSettingDialog
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, RootPaneContainer, WindowConstants
public abstract class AbstractFontSettingDialog
extends JDialog
Abstract class for a font selection dialog.
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JDialog
JDialog.AccessibleJDialog
Nested classes/interfaces inherited from class java.awt.Dialog
Dialog.AccessibleAWTDialog, Dialog.ModalExclusionType, Dialog.ModalityType
Nested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
protected Font currentFont
Fields inherited from class javax.swing.JDialog
accessibleContext, rootPane, rootPaneCheckingEnabled
Fields inherited from class java.awt.Dialog
DEFAULT_MODALITY_TYPE
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, EXIT_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
AbstractFontSettingDialog(Frame owner,
String title,
boolean modality,
Font currentFont)
Create a new font chooser.
Method Summary
protected abstract void apply(Font font)
Apply the given font.
protected abstract Component buildControlPanel()
protected JPanel buildDialogPanel()
protected void closeDialog()
Font getFont()
protected void performApply()
protected void reset()
Methods inherited from class javax.swing.JDialog
addImpl, createRootPane, dialogInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
Methods inherited from class java.awt.Dialog
addNotify, getModalityType, getTitle, hide, isModal, isResizable, isUndecorated, setModal, setModalityType, setResizable, setTitle, setUndecorated, setVisible, show, toBack
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeNotify, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImage, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, toFront
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
currentFont
protected Font currentFont
Constructor Detail
AbstractFontSettingDialog
public AbstractFontSettingDialog(Frame owner,
String title,
boolean modality,
Font currentFont)
Create a new font chooser. Has pertinent JDialog parameters.
Will do everything except make it visible.
Method Detail
buildDialogPanel
protected JPanel buildDialogPanel()
buildControlPanel
protected abstract Component buildControlPanel()
getFont
public Font getFont()
Specified by:
getFont in interface MenuContainer
Overrides:
getFont in class Component
performApply
protected void performApply()
closeDialog
protected void closeDialog()
reset
protected void reset()
apply
protected abstract void apply(Font font)
Apply the given font. Left for the client to define.
Parameters:
font – a font to be applied by the client.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
LabelsWindow
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.venus
Class LabelsWindow
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JInternalFrame
mars.venus.LabelsWindow
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, RootPaneContainer, WindowConstants
public class LabelsWindow
extends JInternalFrame
Represents the Labels window, which is a type of JInternalFrame. Venus user
can view MIPS program labels.
Author:
Sanderson and Team JSpim
See Also:
Serialized Form
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JInternalFrame
JInternalFrame.AccessibleJInternalFrame, JInternalFrame.JDesktopIcon
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
Field Summary
Fields inherited from class javax.swing.JInternalFrame
closable, CONTENT_PANE_PROPERTY, desktopIcon, FRAME_ICON_PROPERTY, frameIcon, GLASS_PANE_PROPERTY, iconable, IS_CLOSED_PROPERTY, IS_ICON_PROPERTY, IS_MAXIMUM_PROPERTY, IS_SELECTED_PROPERTY, isClosed, isIcon, isMaximum, isSelected, LAYERED_PANE_PROPERTY, maximizable, MENU_BAR_PROPERTY, resizable, ROOT_PANE_PROPERTY, rootPane, rootPaneCheckingEnabled, title, TITLE_PROPERTY
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, EXIT_ON_CLOSE, HIDE_ON_CLOSE
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor Summary
LabelsWindow()
Constructor for the Labels (symbol table) window.
Method Summary
void clearWindow()
Clear the window
void setupTable()
Initialize table of labels (symbol table)
void updateLabelAddresses()
Method to update display of label addresses.
Methods inherited from class javax.swing.JInternalFrame
addImpl, addInternalFrameListener, createRootPane, dispose, doDefaultCloseAction, fireInternalFrameEvent, getAccessibleContext, getContentPane, getDefaultCloseOperation, getDesktopIcon, getDesktopPane, getFocusCycleRootAncestor, getFocusOwner, getFrameIcon, getGlassPane, getInternalFrameListeners, getJMenuBar, getLastCursor, getLayer, getLayeredPane, getMenuBar, getMostRecentFocusOwner, getNormalBounds, getRootPane, getTitle, getUI, getUIClassID, getWarningString, hide, isClosable, isClosed, isFocusCycleRoot, isIcon, isIconifiable, isMaximizable, isMaximum, isResizable, isRootPaneCheckingEnabled, isSelected, moveToBack, moveToFront, pack, paintComponent, paramString, remove, removeInternalFrameListener, reshape, restoreSubcomponentFocus, setClosable, setClosed, setContentPane, setCursor, setDefaultCloseOperation, setDesktopIcon, setFocusCycleRoot, setFrameIcon, setGlassPane, setIcon, setIconifiable, setJMenuBar, setLayer, setLayer, setLayeredPane, setLayout, setMaximizable, setMaximum, setMenuBar, setNormalBounds, setResizable, setRootPane, setRootPaneCheckingEnabled, setSelected, setTitle, setUI, show, toBack, toFront, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, transferFocusBackward, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, size, toString, transferFocus, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
LabelsWindow
public LabelsWindow()
Constructor for the Labels (symbol table) window.
Method Detail
setupTable
public void setupTable()
Initialize table of labels (symbol table)
clearWindow
public void clearWindow()
Clear the window
updateLabelAddresses
public void updateLabelAddresses()
Method to update display of label addresses. Since label information doesn’t change,
this should only be done when address base is changed.
(e.g. between base 16 hex and base 10 dec).
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
Class ProcessingException
java.lang.Object
java.lang.Throwable
java.lang.Exception
mars.ProcessingException
All Implemented Interfaces:
Serializable
public class ProcessingException
extends Exception
Class to represent error that occurs while assembling or running a MIPS program.
Author:
Pete Sanderson
See Also:
Serialized Form
Constructor Summary
ProcessingException()
Constructor for ProcessingException.
ProcessingException(ErrorList e)
Constructor for ProcessingException.
ProcessingException(ErrorList e,
AddressErrorException aee)
Constructor for ProcessingException.
ProcessingException(ProgramStatement ps,
AddressErrorException aee)
Constructor for ProcessingException to handle address runtime exceptions
ProcessingException(ProgramStatement ps,
String m)
Constructor for ProcessingException to handle runtime exceptions
ProcessingException(ProgramStatement ps,
String m,
int cause)
Constructor for ProcessingException to handle runtime exceptions
Method Summary
ErrorList errors()
Produce the list of error messages.
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
ProcessingException
public ProcessingException(ErrorList e)
Constructor for ProcessingException.
Parameters:
e – An ErrorList which is an ArrayList of ErrorMessage objects. Each ErrorMessage
represents one processing error.
ProcessingException
public ProcessingException(ErrorList e,
AddressErrorException aee)
Constructor for ProcessingException.
Parameters:
e – An ErrorList which is an ArrayList of ErrorMessage objects. Each ErrorMessage
represents one processing error.
aee – AddressErrorException object containing specialized error message, cause, address
ProcessingException
public ProcessingException(ProgramStatement ps,
String m)
Constructor for ProcessingException to handle runtime exceptions
Parameters:
ps – a ProgramStatement of statement causing runtime exception
m – a String containing specialized error message
ProcessingException
public ProcessingException(ProgramStatement ps,
String m,
int cause)
Constructor for ProcessingException to handle runtime exceptions
Parameters:
ps – a ProgramStatement of statement causing runtime exception
m – a String containing specialized error message
cause – exception cause (see Exceptions class for list)
ProcessingException
public ProcessingException(ProgramStatement ps,
AddressErrorException aee)
Constructor for ProcessingException to handle address runtime exceptions
Parameters:
ps – a ProgramStatement of statement causing runtime exception
aee – AddressErrorException object containing specialized error message, cause, address
ProcessingException
public ProcessingException()
Constructor for ProcessingException.
No parameter and thus no error list. Use this for normal MIPS
program termination (e.g. syscall 10 for exit).
Method Detail
errors
public ErrorList errors()
Produce the list of error messages.
Returns:
Returns ErrorList of error messages.
See Also:
ErrorList,
ErrorMessage
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
ErrorList
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
Class ErrorList
java.lang.Object
mars.ErrorList
public class ErrorList
extends Object
Maintains list of generated error messages, regardless of source (tokenizing, parsing,
assembly, execution).
Author:
Pete Sanderson
Field Summary
static String ERROR_MESSAGE_PREFIX
static String FILENAME_PREFIX
static String LINE_PREFIX
static String MESSAGE_SEPARATOR
static String POSITION_PREFIX
static String WARNING_MESSAGE_PREFIX
Constructor Summary
ErrorList()
Constructor for ErrorList
Method Summary
void add(ErrorMessage mess)
Add new error message to end of list.
void add(ErrorMessage mess,
int index)
Add new error message at specified index position.
int errorCount()
Count of number of error messages in list.
boolean errorLimitExceeded()
Check to see if error limit has been exceeded.
boolean errorsOccurred()
Determine whether error has occured or not.
String generateErrorAndWarningReport()
Produce report containing both warnings and errors, warnings first.
String generateErrorReport()
Produce error report.
String generateWarningReport()
Produce warning report.
int getErrorLimit()
Get limit on number of error messages to be generated
by one assemble operation.
ArrayList getErrorMessages()
Get ArrayList of error messages.
int warningCount()
Count of number of warning messages in list.
boolean warningsOccurred()
Determine whether warning has occured or not.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
ERROR_MESSAGE_PREFIX
public static final String ERROR_MESSAGE_PREFIX
See Also:
Constant Field Values
WARNING_MESSAGE_PREFIX
public static final String WARNING_MESSAGE_PREFIX
See Also:
Constant Field Values
FILENAME_PREFIX
public static final String FILENAME_PREFIX
See Also:
Constant Field Values
LINE_PREFIX
public static final String LINE_PREFIX
See Also:
Constant Field Values
POSITION_PREFIX
public static final String POSITION_PREFIX
See Also:
Constant Field Values
MESSAGE_SEPARATOR
public static final String MESSAGE_SEPARATOR
See Also:
Constant Field Values
Constructor Detail
ErrorList
public ErrorList()
Constructor for ErrorList
Method Detail
getErrorMessages
public ArrayList getErrorMessages()
Get ArrayList of error messages.
Returns:
ArrayList of ErrorMessage objects
errorsOccurred
public boolean errorsOccurred()
Determine whether error has occured or not.
Returns:
true if an error has occurred (does not include warnings), false otherwise.
warningsOccurred
public boolean warningsOccurred()
Determine whether warning has occured or not.
Returns:
true if an warning has occurred, false otherwise.
add
public void add(ErrorMessage mess)
Add new error message to end of list.
Parameters:
mess – ErrorMessage object to be added to end of error list.
add
public void add(ErrorMessage mess,
int index)
Add new error message at specified index position.
Parameters:
mess – ErrorMessage object to be added to end of error list.
index – position in error list
errorCount
public int errorCount()
Count of number of error messages in list.
Returns:
Number of error messages in list.
warningCount
public int warningCount()
Count of number of warning messages in list.
Returns:
Number of warning messages in list.
errorLimitExceeded
public boolean errorLimitExceeded()
Check to see if error limit has been exceeded.
Returns:
True if error limit exceeded, false otherwise.
getErrorLimit
public int getErrorLimit()
Get limit on number of error messages to be generated
by one assemble operation.
Returns:
error limit.
generateErrorReport
public String generateErrorReport()
Produce error report.
Returns:
String containing report.
generateWarningReport
public String generateWarningReport()
Produce warning report.
Returns:
String containing report.
generateErrorAndWarningReport
public String generateErrorAndWarningReport()
Produce report containing both warnings and errors, warnings first.
Returns:
String containing report.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SimulationCode
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions
Interface SimulationCode
public interface SimulationCode
Interface to represent the method for simulating the execution of a specific MIPS basic
instruction. It will be implemented by the anonymous class created in the last
argument to the BasicInstruction constructor.
Author:
Pete Sanderson
Method Summary
void simulate(ProgramStatement statement)
Method to simulate the execution of a specific MIPS basic instruction.
Method Detail
simulate
void simulate(ProgramStatement statement)
throws ProcessingException
Method to simulate the execution of a specific MIPS basic instruction.
Parameters:
statement – A ProgramStatement representing the MIPS instruction to simulate.
Throws:
ProcessingException – This is a run-time exception generated during simulation.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
ExtendedInstruction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions
Class ExtendedInstruction
java.lang.Object
mars.mips.instructions.Instruction
mars.mips.instructions.ExtendedInstruction
public class ExtendedInstruction
extends Instruction
ExtendedInstruction represents a MIPS extended (a.k.a pseudo) instruction. This
assembly language instruction does not have a corresponding machine instruction. Instead
it is translated by the extended assembler into one or more basic instructions (operations
that have a corresponding machine instruction). The TranslationCode object is
responsible for performing the translation.
Author:
Pete Sanderson
Field Summary
Fields inherited from class mars.mips.instructions.Instruction
description, exampleFormat, INSTRUCTION_LENGTH, INSTRUCTION_LENGTH_BITS, mnemonic, operandMask, tokenList
Constructor Summary
ExtendedInstruction(String example,
String translation)
Constructor for ExtendedInstruction, where no instruction description or
compact translation is provided.
ExtendedInstruction(String example,
String translation,
String description)
Constructor for ExtendedInstruction.
ExtendedInstruction(String example,
String translation,
String compactTranslation,
String description)
Constructor for ExtendedInstruction.
Method Summary
ArrayList getBasicIntructionTemplateList()
Get ArrayList of Strings that represent list of templates for
basic instructions generated by this extended instruction.
ArrayList getCompactBasicIntructionTemplateList()
Get ArrayList of Strings that represent list of templates for
basic instructions generated by the “compact” or 16-bit version
of this extended instruction.
int getCompactInstructionLength()
Get length in bytes that this extended instruction requires in its
binary form if it includes an alternative expansion for compact
memory (16 bit addressing) configuration.
int getInstructionLength()
Get length in bytes that this extended instruction requires in its
binary form.
boolean hasCompactTranslation()
Determine whether or not this pseudo-instruction has a second
translation optimized for 16 bit address space: a compact version.
static String makeTemplateSubstitutions(MIPSprogram program,
String template,
TokenList theTokenList)
Given a basic instruction template and the list of tokens from an extended
instruction statement, substitute operands from the token list appropriately into the
template to generate the basic statement.
Methods inherited from class mars.mips.instructions.Instruction
createExampleTokenList, extractOperator, getDescription, getExampleFormat, getName, getTokenList
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
ExtendedInstruction
public ExtendedInstruction(String example,
String translation,
String compactTranslation,
String description)
Constructor for ExtendedInstruction.
Parameters:
example – A String containing example use of the MIPS extended instruction.
translation – Specifications for translating this instruction into a sequence
of one or more MIPS basic instructions.
compactTranslation – Alternative translation that can be used if running under
a compact (16 bit) memory configuration.
description – a helpful description to be included on help requests
The presence of an alternative “compact translation” can optimize code generation
by assuming that data label addresses are 16 bits instead of 32
ExtendedInstruction
public ExtendedInstruction(String example,
String translation,
String description)
Constructor for ExtendedInstruction. No compact translation is provided.
Parameters:
example – A String containing example use of the MIPS extended instruction.
translation – Specifications for translating this instruction into a sequence
of one or more MIPS basic instructions.
description – a helpful description to be included on help requests
ExtendedInstruction
public ExtendedInstruction(String example,
String translation)
Constructor for ExtendedInstruction, where no instruction description or
compact translation is provided.
Parameters:
example – A String containing example use of the MIPS extended instruction.
translation – Specifications for translating this instruction into a sequence
of one or more MIPS basic instructions.
Method Detail
getInstructionLength
public int getInstructionLength()
Get length in bytes that this extended instruction requires in its
binary form. The answer depends on how many basic instructions it
expands to. This may vary, if expansion includes a nop, depending on
whether or not delayed branches are enabled. Each requires 4 bytes.
Overrides:
getInstructionLength in class Instruction
Returns:
int length in bytes of corresponding binary instruction(s).
getBasicIntructionTemplateList
public ArrayList getBasicIntructionTemplateList()
Get ArrayList of Strings that represent list of templates for
basic instructions generated by this extended instruction.
Returns:
ArrayList of Strings.
getCompactInstructionLength
public int getCompactInstructionLength()
Get length in bytes that this extended instruction requires in its
binary form if it includes an alternative expansion for compact
memory (16 bit addressing) configuration. The answer depends on
how many basic instructions it expands to. This may vary, if
expansion includes a nop, depending on whether or not delayed
branches are enabled. Each requires 4 bytes.
Returns:
int length in bytes of corresponding binary instruction(s).
Returns 0 if an alternative expansion is not defined for this
instruction.
hasCompactTranslation
public boolean hasCompactTranslation()
Determine whether or not this pseudo-instruction has a second
translation optimized for 16 bit address space: a compact version.
getCompactBasicIntructionTemplateList
public ArrayList getCompactBasicIntructionTemplateList()
Get ArrayList of Strings that represent list of templates for
basic instructions generated by the “compact” or 16-bit version
of this extended instruction.
Returns:
ArrayList of Strings. Returns null if the instruction does not
have a compact alternative.
makeTemplateSubstitutions
public static String makeTemplateSubstitutions(MIPSprogram program,
String template,
TokenList theTokenList)
Given a basic instruction template and the list of tokens from an extended
instruction statement, substitute operands from the token list appropriately into the
template to generate the basic statement. Assumes the extended instruction statement has
been translated from source form to basic assembly form (e.g. register mnemonics
translated to corresponding register numbers).
Operand format of source statement is already verified correct.
Assume the template has correct number and positions of operands.
Template is String with special markers. In the list below, n represents token position (1,2,3,etc)
in source statement (operator is token 0, parentheses count but commas don’t):
RGn means substitute register found in n’th token of source statement
NRn means substitute next higher register than the one in n’th token of source code
OPn means substitute n’th token of source code as is
LLn means substitute low order 16 bits from label address in source token n.
LLnU means substitute low order 16 bits (unsigned) from label address in source token n.
LLnPm (m=1,2,3,4) means substitute low order 16 bits from label address in source token n, after adding m.
LHn means substitute high order 16 bits from label address in source token n. Must add 1 if address bit 15 is 1.
LHnPm (m=1,2,3,4) means substitute high order 16 bits from label address in source token n, after adding m. Must then add 1 if bit 15 is 1.
VLn means substitute low order 16 bits from 32 bit value in source token n.
VLnU means substitute low order 16 bits (unsigned) from 32 bit value in source token n.
VLnPm (m=1,2,3,4) means substitute low order 16 bits from 32 bit value in source token n, after adding m to value.
VLnPmU (m=1,2,3,4) means substitute low order 16 bits (unsigned) from 32 bit value in source token n, after adding m to value.
VHLn means substitute high order 16 bits from 32 bit value in source token n. Use this if later combined with low order 16 bits using “ori $1,$1,VLn”. See logical and branch operations.
VHn means substitute high order 16 bits from 32 bit value in source token n, then add 1 if value’s bit 15 is 1. Use this only if later instruction uses VLn($1) to calculate 32 bit address. See loads and stores.
VHLnPm (m=1,2,3,4) means substitute high order 16 bits from 32 bit value in source token n, after adding m. See VHLn.
VHnPm (m=1,2,3,4) means substitute high order 16 bits from 32 bit value in source token n, after adding m. Must then add 1 if bit 15 is 1. See VHn.
LLP is similar to LLn, but is needed for “label+100000” address offset. Immediate is added before taking low order 16.
LLPU is similar to LLnU, but is needed for “label+100000” address offset. Immediate is added before taking low order 16 (unsigned).
LLPPm (m=1,2,3,4) is similar to LLP except m is added along with mmediate before taking low order 16.
LHPA is similar to LHn, but is needed for “label+100000” address offset. Immediate is added before taking high order 16.
LHPN is similar to LHPA, used only by “la” instruction. Address resolved by “ori” so do not add 1 if bit 15 is 1.
LHPAPm (m=1,2,3,4) is similar to LHPA except value m is added along with immediate before taking high order 16.
LHL means substitute high order 16 bits from label address in token 2 of “la” (load address) source statement.
LAB means substitute textual label from last token of source statement. Used for various branches.
S32 means substitute the result of subtracting the constant value in last token from 32. Used by “ror”, “rol”.
DBNOP means Delayed Branching NOP – generate a “nop” instruction but only if delayed branching is enabled. Added in 3.4.1 release.
BROFFnm means substitute n if delayed branching is NOT enabled otherwise substitute m. n and m are single digit numbers indicating constant branch offset (in words). Added in 3.4.1 release.
Parameters:
template – a String containing template for basic statement.
tokenList – a TokenList containing tokens from extended instruction.
Returns:
String representing basic assembler statement.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions
mars.mips.instructions
Interfaces
SimulationCode
Classes
BasicInstruction
BasicInstructionFormat
ExtendedInstruction
Instruction
InstructionSet
BasicInstructionFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions
Class BasicInstructionFormat
java.lang.Object
mars.mips.instructions.BasicInstructionFormat
public class BasicInstructionFormat
extends Object
These are the MIPS-defined formats of basic machine instructions. The R-format indicates
the instruction works only with registers. The I-format indicates the instruction
works with an immediate value (e.g. constant). The J-format indicates this is a Jump
instruction. The I-branch-format is defined by me, not MIPS, to to indicate this is
a Branch instruction, specifically to distinguish immediate
values used as target addresses.
Author:
Pete Sanderson
Field Summary
static BasicInstructionFormat I_BRANCH_FORMAT
static BasicInstructionFormat I_FORMAT
static BasicInstructionFormat J_FORMAT
static BasicInstructionFormat R_FORMAT
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
R_FORMAT
public static final BasicInstructionFormat R_FORMAT
I_FORMAT
public static final BasicInstructionFormat I_FORMAT
I_BRANCH_FORMAT
public static final BasicInstructionFormat I_BRANCH_FORMAT
J_FORMAT
public static final BasicInstructionFormat J_FORMAT
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.mips.instructions
Interface Summary
SimulationCode Interface to represent the method for simulating the execution of a specific MIPS basic
instruction.
Class Summary
BasicInstruction Class to represent a basic instruction in the MIPS instruction set.
BasicInstructionFormat These are the MIPS-defined formats of basic machine instructions.
ExtendedInstruction ExtendedInstruction represents a MIPS extended (a.k.a pseudo) instruction.
Instruction Base class to represent member of MIPS instruction set.
InstructionSet The list of Instruction objects, each of which represents a MIPS instruction.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
mars.mips.instructions Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.mips.instructions
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object mars.mips.instructions.BasicInstructionFormat
mars.mips.instructions.Instruction mars.mips.instructions.BasicInstruction
mars.mips.instructions.ExtendedInstruction
mars.mips.instructions.InstructionSet
Interface Hierarchy
mars.mips.instructions.SimulationCode
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Instruction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions
Class Instruction
java.lang.Object
mars.mips.instructions.Instruction
Direct Known Subclasses:
BasicInstruction, ExtendedInstruction
public abstract class Instruction
extends Object
Base class to represent member of MIPS instruction set.
Author:
Pete Sanderson and Ken Vollmar
Field Summary
protected String description
Description of instruction for display to user
protected String exampleFormat
Example usage of this instruction.
static int INSTRUCTION_LENGTH
Length in bytes of a machine instruction.
static int INSTRUCTION_LENGTH_BITS
protected String mnemonic
The instruction name.
static char[] operandMask
Characters used in instruction mask to indicate bit positions
for ‘f’irst, ‘s’econd, and ‘t’hird operands.
protected TokenList tokenList
List of tokens generated by tokenizing example usage (see exampleFormat).
Constructor Summary
Instruction()
Method Summary
protected void createExampleTokenList()
Used to build a token list from the example instruction
provided as constructor argument.
protected String extractOperator(String example)
Used by subclass constructors to extract operator mnemonic from the
instruction example.
String getDescription()
Get string describing the instruction.
String getExampleFormat()
Get string descriptor of instruction’s format.
int getInstructionLength()
Get length in bytes that this instruction requires in its binary form.
String getName()
Get operation mnemonic
TokenList getTokenList()
Get TokenList corresponding to correct instruction syntax.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
INSTRUCTION_LENGTH
public static final int INSTRUCTION_LENGTH
Length in bytes of a machine instruction. MIPS is a RISC architecture
so all instructions are the same length. Currently set to 4.
See Also:
Constant Field Values
INSTRUCTION_LENGTH_BITS
public static final int INSTRUCTION_LENGTH_BITS
See Also:
Constant Field Values
operandMask
public static char[] operandMask
Characters used in instruction mask to indicate bit positions
for ‘f’irst, ‘s’econd, and ‘t’hird operands.
mnemonic
protected String mnemonic
The instruction name.
exampleFormat
protected String exampleFormat
Example usage of this instruction. Is provided as subclass constructor argument.
description
protected String description
Description of instruction for display to user
tokenList
protected TokenList tokenList
List of tokens generated by tokenizing example usage (see exampleFormat).
Constructor Detail
Instruction
public Instruction()
Method Detail
getName
public String getName()
Get operation mnemonic
Returns:
operation mnemonic (e.g. addi, sw)
getExampleFormat
public String getExampleFormat()
Get string descriptor of instruction’s format. This is an example MIPS
assembler instruction usage which contains the operator and all operands.
Operands are separated by commas, an operand that begins with a ‘$’
represents a register, and an integer operand represents an immediate value
or address. Here are two examples: “nor $1,$2,$3” and “sw $1,100($2)”
Returns:
String representing example instruction format.
getDescription
public String getDescription()
Get string describing the instruction. This is not used internally by
MARS, but is for display to the user.
Returns:
String describing the instruction.
getTokenList
public TokenList getTokenList()
Get TokenList corresponding to correct instruction syntax.
For example, the instruction with format “sw $1,100($2)” yields token list
Returns:
TokenList object representing correct instruction usage.
getInstructionLength
public int getInstructionLength()
Get length in bytes that this instruction requires in its binary form.
Default is 4 (holds for all basic instructions), but can be overridden
in subclass.
Returns:
int length in bytes of corresponding binary instruction(s).
extractOperator
protected String extractOperator(String example)
Used by subclass constructors to extract operator mnemonic from the
instruction example.
createExampleTokenList
protected void createExampleTokenList()
Used to build a token list from the example instruction
provided as constructor argument. Parser uses this for syntax checking.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
InstructionSet
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions
Class InstructionSet
java.lang.Object
mars.mips.instructions.InstructionSet
public class InstructionSet
extends Object
The list of Instruction objects, each of which represents a MIPS instruction.
The instruction may either be basic (translates into binary machine code) or
extended (translates into sequence of one or more basic instructions).
Author:
Pete Sanderson and Ken Vollmar
Constructor Summary
InstructionSet()
Creates a new InstructionSet object.
Method Summary
BasicInstruction findByBinaryCode(int binaryInstr)
ArrayList getInstructionList()
Retrieve the current instruction set.
ArrayList matchOperator(String name)
Given an operator mnemonic, will return the corresponding Instruction object(s)
from the instruction set.
void populate()
Adds all instructions to the set.
ArrayList prefixMatchOperator(String name)
Given a string, will return the Instruction object(s) from the instruction
set whose operator mnemonic prefix matches it.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
InstructionSet
public InstructionSet()
Creates a new InstructionSet object.
Method Detail
getInstructionList
public ArrayList getInstructionList()
Retrieve the current instruction set.
populate
public void populate()
Adds all instructions to the set. A given extended instruction may have
more than one Instruction object, depending on how many formats it can have.
See Also:
Instruction,
BasicInstruction,
ExtendedInstruction
findByBinaryCode
public BasicInstruction findByBinaryCode(int binaryInstr)
matchOperator
public ArrayList matchOperator(String name)
Given an operator mnemonic, will return the corresponding Instruction object(s)
from the instruction set. Uses straight linear search technique.
Parameters:
name – operator mnemonic (e.g. addi, sw,…)
Returns:
list of corresponding Instruction object(s), or null if not found.
prefixMatchOperator
public ArrayList prefixMatchOperator(String name)
Given a string, will return the Instruction object(s) from the instruction
set whose operator mnemonic prefix matches it. Case-insensitive. For example
“s” will match “sw”, “sh”, “sb”, etc. Uses straight linear search technique.
Parameters:
name – a string
Returns:
list of matching Instruction object(s), or null if none match.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallPrintString
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallPrintString
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallPrintString
All Implemented Interfaces:
Syscall
public class SyscallPrintString
extends AbstractSyscall
Service to display string stored starting at address in $a0 onto the console.
Constructor Summary
SyscallPrintString()
Build an instance of the Print String syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to print string stored starting at address in $a0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallPrintString
public SyscallPrintString()
Build an instance of the Print String syscall. Default service number
is 4 and name is “PrintString”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to print string stored starting at address in $a0.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallPrintIntBinary
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallPrintIntBinary
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallPrintIntBinary
All Implemented Interfaces:
Syscall
public class SyscallPrintIntBinary
extends AbstractSyscall
Service to display integer stored in $a0 on the console.
Constructor Summary
SyscallPrintIntBinary()
Build an instance of the Print Integer syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to print on the console the integer stored in $a0, in hexadecimal format.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallPrintIntBinary
public SyscallPrintIntBinary()
Build an instance of the Print Integer syscall. Default service number
is 1 and name is “PrintInt”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to print on the console the integer stored in $a0, in hexadecimal format.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallMidiOut
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallMidiOut
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallMidiOut
All Implemented Interfaces:
Syscall
public class SyscallMidiOut
extends AbstractSyscall
Service to output simulated MIDI tone to sound card. The call returns
immediately upon generating the tone. By contrast, syscall 33
(MidiOutSync) does not return until tone duration has elapsed.
Constructor Summary
SyscallMidiOut()
Build an instance of the MIDI (simulated) out syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to send MIDI output to sound card.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallMidiOut
public SyscallMidiOut()
Build an instance of the MIDI (simulated) out syscall. Default service number
is 31 and name is “MidiOut”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to send MIDI output to sound card. This requires
four arguments in registers $a0 through $a3.
$a0 – pitch (note). Integer value from 0 to 127, with 60 being middle-C on a piano.
$a1 – duration. Integer value in milliseconds.
$a2 – instrument. Integer value from 0 to 127, with 0 being acoustic grand piano.
$a3 – volume. Integer value from 0 to 127.
Default values, in case any parameters are outside the above ranges, are $a0=60, $a1=1000,
$a2=0, $a3=100.
See MARS documentation elsewhere or www.midi.org for more information. Note that the pitch,
instrument and volume value ranges 0-127 are from javax.sound.midi; actual MIDI instruments
use the range 1-128.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallMessageDialogInt
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallMessageDialogInt
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallMessageDialogInt
All Implemented Interfaces:
Syscall
public class SyscallMessageDialogInt
extends AbstractSyscall
Service to display a message to user.
Constructor Summary
SyscallMessageDialogInt()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to display a message to user.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallMessageDialogInt
public SyscallMessageDialogInt()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to display a message to user.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallExit
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallExit
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallExit
All Implemented Interfaces:
Syscall
public class SyscallExit
extends AbstractSyscall
Service to exit the MIPS program.
Constructor Summary
SyscallExit()
Build an instance of the Exit syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to exit the MIPS program.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallExit
public SyscallExit()
Build an instance of the Exit syscall. Default service number
is 10 and name is “Exit”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to exit the MIPS program.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallInputDialogInt
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallInputDialogInt
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallInputDialogInt
All Implemented Interfaces:
Syscall
public class SyscallInputDialogInt
extends AbstractSyscall
Service to input data.
Constructor Summary
SyscallInputDialogInt()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to input data.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallInputDialogInt
public SyscallInputDialogInt()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to input data.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallReadFloat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallReadFloat
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallReadFloat
All Implemented Interfaces:
Syscall
public class SyscallReadFloat
extends AbstractSyscall
Service to read the bits of input float into $f0
Constructor Summary
SyscallReadFloat()
Build an instance of the Read Float syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to read the bits of input float into $f0
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallReadFloat
public SyscallReadFloat()
Build an instance of the Read Float syscall. Default service number
is 6 and name is “ReadFloat”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to read the bits of input float into $f0
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallOpen
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallOpen
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallOpen
All Implemented Interfaces:
Syscall
public class SyscallOpen
extends AbstractSyscall
Service to open file name specified by $a0. File descriptor returned in $v0.
(this was changed from $a0 in MARS 3.7 for SPIM compatibility. The table
in COD erroneously shows $a0).
Constructor Summary
SyscallOpen()
Build an instance of the Open file syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to open file name specified by $a0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallOpen
public SyscallOpen()
Build an instance of the Open file syscall. Default service number
is 13 and name is “Open”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to open file name specified by $a0. File descriptor returned
in $v0. Only supported flags ($a1) are read-only (0), write-only (1) and
write-append (9). write-only flag creates file if it does not exist, so it is technically
write-create. write-append will start writing at end of existing file.
Mode ($a2) is ignored.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallReadChar
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallReadChar
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallReadChar
All Implemented Interfaces:
Syscall
public class SyscallReadChar
extends AbstractSyscall
Service to read a character from input console into $a0.
Constructor Summary
SyscallReadChar()
Build an instance of the Read Char syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to read a character from input console into $a0
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallReadChar
public SyscallReadChar()
Build an instance of the Read Char syscall. Default service number
is 12 and name is “ReadChar”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to read a character from input console into $a0
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallMessageDialog
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallMessageDialog
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallMessageDialog
All Implemented Interfaces:
Syscall
public class SyscallMessageDialog
extends AbstractSyscall
Service to display a message to user.
Constructor Summary
SyscallMessageDialog()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to display a message to user.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallMessageDialog
public SyscallMessageDialog()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to display a message to user.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallPrintFloat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallPrintFloat
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallPrintFloat
All Implemented Interfaces:
Syscall
public class SyscallPrintFloat
extends AbstractSyscall
Service to display on the console float whose bits are stored in $f12
Constructor Summary
SyscallPrintFloat()
Build an instance of the Print Float syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to display float whose bits are stored in $f12
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallPrintFloat
public SyscallPrintFloat()
Build an instance of the Print Float syscall. Default service number
is 2 and name is “PrintFloat”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to display float whose bits are stored in $f12
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallSbrk
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallSbrk
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallSbrk
All Implemented Interfaces:
Syscall
public class SyscallSbrk
extends AbstractSyscall
Service to allocate amount of heap memory specified in $a0, putting address into $v0.
Constructor Summary
SyscallSbrk()
Build an instance of the Sbrk syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to allocate amount of heap memory specified in $a0, putting address into $v0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallSbrk
public SyscallSbrk()
Build an instance of the Sbrk syscall. Default service number
is 9 and name is “Sbrk”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to allocate amount of heap memory specified in $a0, putting address into $v0.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallRandDouble
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallRandDouble
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallRandDouble
All Implemented Interfaces:
Syscall
public class SyscallRandDouble
extends AbstractSyscall
Service to return a random floating point value.
Constructor Summary
SyscallRandDouble()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to the random number generator.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallRandDouble
public SyscallRandDouble()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to the random number generator.
Return in $f0 the next pseudorandom, uniformly distributed double value between 0.0 and 1.0
from this random number generator’s sequence.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallPrintIntUnsigned
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallPrintIntUnsigned
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallPrintIntUnsigned
All Implemented Interfaces:
Syscall
public class SyscallPrintIntUnsigned
extends AbstractSyscall
Service to display integer stored in $a0 on the console as unsigned decimal.
Constructor Summary
SyscallPrintIntUnsigned()
Build an instance of the Print Integer Unsigned syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to print on the console the integer stored in $a0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallPrintIntUnsigned
public SyscallPrintIntUnsigned()
Build an instance of the Print Integer Unsigned syscall. Default service number
is 36 and name is “PrintIntUnsigned”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to print on the console the integer stored in $a0.
The value is treated as unsigned.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallMessageDialogString
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallMessageDialogString
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallMessageDialogString
All Implemented Interfaces:
Syscall
public class SyscallMessageDialogString
extends AbstractSyscall
Service to display a message to user.
Constructor Summary
SyscallMessageDialogString()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to display a message to user.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallMessageDialogString
public SyscallMessageDialogString()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to display a message to user.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
AbstractSyscall
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class AbstractSyscall
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
All Implemented Interfaces:
Syscall
Direct Known Subclasses:
SyscallClose, SyscallConfirmDialog, SyscallExit, SyscallExit2, SyscallInputDialogDouble, SyscallInputDialogFloat, SyscallInputDialogInt, SyscallInputDialogString, SyscallMessageDialog, SyscallMessageDialogDouble, SyscallMessageDialogFloat, SyscallMessageDialogInt, SyscallMessageDialogString, SyscallMidiOut, SyscallMidiOutSync, SyscallOpen, SyscallPrintChar, SyscallPrintDouble, SyscallPrintFloat, SyscallPrintInt, SyscallPrintIntBinary, SyscallPrintIntHex, SyscallPrintIntUnsigned, SyscallPrintString, SyscallRandDouble, SyscallRandFloat, SyscallRandInt, SyscallRandIntRange, SyscallRandSeed, SyscallRead, SyscallReadChar, SyscallReadDouble, SyscallReadFloat, SyscallReadInt, SyscallReadString, SyscallSbrk, SyscallSleep, SyscallTime, SyscallWrite
public abstract class AbstractSyscall
extends Object
implements Syscall
Abstract class that a MIPS syscall system service may extend. A qualifying service
must be a class in the mars.mips.instructions.syscalls package that
implements the Syscall interface, must be compiled into a .class file,
and its .class file must be in the same folder as Syscall.class.
Mars will detect a qualifying syscall upon startup, create an instance
using its no-argument constructor and add it to its syscall list.
When its service is invoked at runtime (“syscall” instruction
with its service number stored in register $v0), its simulate()
method will be invoked.
Constructor Summary
AbstractSyscall(int number,
String name)
Constructor is provided so subclass may initialize instance variables.
Method Summary
String getName()
Return the name you have chosen for this syscall.
int getNumber()
Return the assigned service number.
void setNumber(int num)
Set the service number.
abstract void simulate(ProgramStatement statement)
Performs syscall function.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
AbstractSyscall
public AbstractSyscall(int number,
String name)
Constructor is provided so subclass may initialize instance variables.
Parameters:
number – default assigned service number
name – service name which may be used for reference independent of number
Method Detail
getName
public String getName()
Return the name you have chosen for this syscall. This can be used by a MARS
user to refer to the service when choosing to override its default service
number in the configuration file.
Specified by:
getName in interface Syscall
Returns:
service name as a string
setNumber
public void setNumber(int num)
Set the service number. This is provided to allow MARS implementer or user
to override the default service number.
Specified by:
setNumber in interface Syscall
Parameters:
num – specified service number to override the default.
getNumber
public int getNumber()
Return the assigned service number. This is the number the MIPS programmer
must store into $v0 before issuing the SYSCALL instruction.
Specified by:
getNumber in interface Syscall
Returns:
assigned service number
simulate
public abstract void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function. It will be invoked when the service is invoked
at simulation time. Service is identified by value stored in $v0.
Specified by:
simulate in interface Syscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallInputDialogFloat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallInputDialogFloat
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallInputDialogFloat
All Implemented Interfaces:
Syscall
public class SyscallInputDialogFloat
extends AbstractSyscall
Service to input data.
Constructor Summary
SyscallInputDialogFloat()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to input data.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallInputDialogFloat
public SyscallInputDialogFloat()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to input data.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RandomStreams
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class RandomStreams
java.lang.Object
mars.mips.instructions.syscalls.RandomStreams
public class RandomStreams
extends Object
This small class serves only to hold a static HashMap for storing
random number generators for use by all the random number generator
syscalls.
Constructor Summary
RandomStreams()
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
RandomStreams
public RandomStreams()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallInputDialogString
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallInputDialogString
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallInputDialogString
All Implemented Interfaces:
Syscall
public class SyscallInputDialogString
extends AbstractSyscall
Service to input data.
Constructor Summary
SyscallInputDialogString()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to input data.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallInputDialogString
public SyscallInputDialogString()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to input data.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallReadString
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallReadString
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallReadString
All Implemented Interfaces:
Syscall
public class SyscallReadString
extends AbstractSyscall
Service to read console input string into buffer starting at address in $a0.
Constructor Summary
SyscallReadString()
Build an instance of the Read String syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to read console input string into buffer starting at address in $a0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallReadString
public SyscallReadString()
Build an instance of the Read String syscall. Default service number
is 8 and name is “ReadString”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to read console input string into buffer starting at address in $a0.
Follows semantics of UNIX ‘fgets’. For specified length n,
string can be no longer than n-1. If less than that, add
newline to end. In either case, then pad with null byte.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallPrintChar
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallPrintChar
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallPrintChar
All Implemented Interfaces:
Syscall
public class SyscallPrintChar
extends AbstractSyscall
Service to display character stored in $a0 on the console.
Constructor Summary
SyscallPrintChar()
Build an instance of the Print Char syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to print on the console the character stored in $a0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallPrintChar
public SyscallPrintChar()
Build an instance of the Print Char syscall. Default service number
is 11 and name is “PrintChar”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to print on the console the character stored in $a0.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallRandIntRange
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallRandIntRange
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallRandIntRange
All Implemented Interfaces:
Syscall
public class SyscallRandIntRange
extends AbstractSyscall
Service to return a random integer in a specified range.
Constructor Summary
SyscallRandIntRange()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to the random number generator, with an upper range specified.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallRandIntRange
public SyscallRandIntRange()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to the random number generator, with an upper range specified.
Return in $a0 the next pseudorandom, uniformly distributed int value between 0 (inclusive)
and the specified value (exclusive), drawn from this random number generator’s sequence.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Syscall
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Interface Syscall
All Known Implementing Classes:
AbstractSyscall, SyscallClose, SyscallConfirmDialog, SyscallExit, SyscallExit2, SyscallInputDialogDouble, SyscallInputDialogFloat, SyscallInputDialogInt, SyscallInputDialogString, SyscallMessageDialog, SyscallMessageDialogDouble, SyscallMessageDialogFloat, SyscallMessageDialogInt, SyscallMessageDialogString, SyscallMidiOut, SyscallMidiOutSync, SyscallOpen, SyscallPrintChar, SyscallPrintDouble, SyscallPrintFloat, SyscallPrintInt, SyscallPrintIntBinary, SyscallPrintIntHex, SyscallPrintIntUnsigned, SyscallPrintString, SyscallRandDouble, SyscallRandFloat, SyscallRandInt, SyscallRandIntRange, SyscallRandSeed, SyscallRead, SyscallReadChar, SyscallReadDouble, SyscallReadFloat, SyscallReadInt, SyscallReadString, SyscallSbrk, SyscallSleep, SyscallTime, SyscallWrite
public interface Syscall
Interface for any MIPS syscall system service. A qualifying service
must be a class in the mars.mips.instructions.syscalls package that
implements the Syscall interface, must be compiled into a .class file,
and its .class file must be in the same folder as Syscall.class.
Mars will detect a qualifying syscall upon startup, create an instance
using its no-argument constructor and add it to its syscall list.
When its service is invoked at runtime (“syscall” instruction
with its service number stored in register $v0), its simulate()
method will be invoked.
Method Summary
String getName()
Return a name you have chosen for this syscall.
int getNumber()
Return the assigned service number.
void setNumber(int num)
Set the service number.
void simulate(ProgramStatement statement)
Performs syscall function.
Method Detail
getName
String getName()
Return a name you have chosen for this syscall. This can be used by a MARS
user to refer to the service when choosing to override its default service
number in the configuration file.
Returns:
service name as a string
setNumber
void setNumber(int num)
Set the service number. This is provided to allow MARS implementer or user
to override the default service number.
Parameters:
num – specified service number to override the default.
getNumber
int getNumber()
Return the assigned service number. This is the number the MIPS programmer
must store into $v0 before issuing the SYSCALL instruction.
Returns:
assigned service number
simulate
void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function. It will be invoked when the service is invoked
at simulation time. Service is identified by value stored in $v0.
Parameters:
statement – ProgramStatement for this syscall statement.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallTime
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallTime
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallTime
All Implemented Interfaces:
Syscall
public class SyscallTime
extends AbstractSyscall
Service to read a character from input console into $a0.
Constructor Summary
SyscallTime()
Build an instance of the Read Char syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to place current system time into $a0 (low order 32 bits)
and $a1 (high order 32 bits).
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallTime
public SyscallTime()
Build an instance of the Read Char syscall. Default service number
is 12 and name is “ReadChar”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to place current system time into $a0 (low order 32 bits)
and $a1 (high order 32 bits).
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallRandSeed
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallRandSeed
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallRandSeed
All Implemented Interfaces:
Syscall
public class SyscallRandSeed
extends AbstractSyscall
Service to set seed for the underlying Java pseudorandom number generator. No values are returned.
Constructor Summary
SyscallRandSeed()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
Set the seed of the underlying Java pseudorandom number generator.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallRandSeed
public SyscallRandSeed()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Set the seed of the underlying Java pseudorandom number generator.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallPrintIntHex
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallPrintIntHex
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallPrintIntHex
All Implemented Interfaces:
Syscall
public class SyscallPrintIntHex
extends AbstractSyscall
Service to display integer stored in $a0 on the console.
Constructor Summary
SyscallPrintIntHex()
Build an instance of the Print Integer syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to print on the console the integer stored in $a0, in hexadecimal format.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallPrintIntHex
public SyscallPrintIntHex()
Build an instance of the Print Integer syscall. Default service number
is 1 and name is “PrintInt”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to print on the console the integer stored in $a0, in hexadecimal format.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
mars.mips.instructions.syscalls
Interfaces
Syscall
Classes
AbstractSyscall
RandomStreams
SyscallClose
SyscallConfirmDialog
SyscallExit
SyscallExit2
SyscallInputDialogDouble
SyscallInputDialogFloat
SyscallInputDialogInt
SyscallInputDialogString
SyscallMessageDialog
SyscallMessageDialogDouble
SyscallMessageDialogFloat
SyscallMessageDialogInt
SyscallMessageDialogString
SyscallMidiOut
SyscallMidiOutSync
SyscallNumberOverride
SyscallOpen
SyscallPrintChar
SyscallPrintDouble
SyscallPrintFloat
SyscallPrintInt
SyscallPrintIntBinary
SyscallPrintIntHex
SyscallPrintIntUnsigned
SyscallPrintString
SyscallRandDouble
SyscallRandFloat
SyscallRandInt
SyscallRandIntRange
SyscallRandSeed
SyscallRead
SyscallReadChar
SyscallReadDouble
SyscallReadFloat
SyscallReadInt
SyscallReadString
SyscallSbrk
SyscallSleep
SyscallTime
SyscallWrite
SyscallPrintInt
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallPrintInt
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallPrintInt
All Implemented Interfaces:
Syscall
public class SyscallPrintInt
extends AbstractSyscall
Service to display integer stored in $a0 on the console.
Constructor Summary
SyscallPrintInt()
Build an instance of the Print Integer syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to print on the console the integer stored in $a0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallPrintInt
public SyscallPrintInt()
Build an instance of the Print Integer syscall. Default service number
is 1 and name is “PrintInt”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to print on the console the integer stored in $a0.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallMessageDialogDouble
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallMessageDialogDouble
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallMessageDialogDouble
All Implemented Interfaces:
Syscall
public class SyscallMessageDialogDouble
extends AbstractSyscall
Service to display a message to user.
Constructor Summary
SyscallMessageDialogDouble()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to display a message to user.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallMessageDialogDouble
public SyscallMessageDialogDouble()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to display a message to user.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallConfirmDialog
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallConfirmDialog
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallConfirmDialog
All Implemented Interfaces:
Syscall
public class SyscallConfirmDialog
extends AbstractSyscall
Service to display a message to user.
Constructor Summary
SyscallConfirmDialog()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to display a message to user.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallConfirmDialog
public SyscallConfirmDialog()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to display a message to user.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.mips.instructions.syscalls
Interface Summary
Syscall Interface for any MIPS syscall system service.
Class Summary
AbstractSyscall Abstract class that a MIPS syscall system service may extend.
RandomStreams This small class serves only to hold a static HashMap for storing
random number generators for use by all the random number generator
syscalls.
SyscallClose Service to close file descriptor given in $a0.
SyscallConfirmDialog Service to display a message to user.
SyscallExit Service to exit the MIPS program.
SyscallExit2 Service to exit the MIPS program with return value given in $a0.
SyscallInputDialogDouble Service to input data.
SyscallInputDialogFloat Service to input data.
SyscallInputDialogInt Service to input data.
SyscallInputDialogString Service to input data.
SyscallMessageDialog Service to display a message to user.
SyscallMessageDialogDouble Service to display a message to user.
SyscallMessageDialogFloat Service to display a message to user.
SyscallMessageDialogInt Service to display a message to user.
SyscallMessageDialogString Service to display a message to user.
SyscallMidiOut Service to output simulated MIDI tone to sound card.
SyscallMidiOutSync Service to output simulated MIDI tone to sound card.
SyscallNumberOverride Represents User override of default syscall number assignment.
SyscallOpen Service to open file name specified by $a0.
SyscallPrintChar Service to display character stored in $a0 on the console.
SyscallPrintDouble Service to display double whose bits are stored in $f12 & $f13 onto the console.
SyscallPrintFloat Service to display on the console float whose bits are stored in $f12
SyscallPrintInt Service to display integer stored in $a0 on the console.
SyscallPrintIntBinary Service to display integer stored in $a0 on the console.
SyscallPrintIntHex Service to display integer stored in $a0 on the console.
SyscallPrintIntUnsigned Service to display integer stored in $a0 on the console as unsigned decimal.
SyscallPrintString Service to display string stored starting at address in $a0 onto the console.
SyscallRandDouble Service to return a random floating point value.
SyscallRandFloat Service to return a random floating point value.
SyscallRandInt Service to return a random integer.
SyscallRandIntRange Service to return a random integer in a specified range.
SyscallRandSeed Service to set seed for the underlying Java pseudorandom number generator.
SyscallRead Service to read from file descriptor given in $a0.
SyscallReadChar Service to read a character from input console into $a0.
SyscallReadDouble Service to read the bits of console input double into $f0 and $f1.
SyscallReadFloat Service to read the bits of input float into $f0
SyscallReadInt Service to read an integer from input console into $v0.
SyscallReadString Service to read console input string into buffer starting at address in $a0.
SyscallSbrk Service to allocate amount of heap memory specified in $a0, putting address into $v0.
SyscallSleep Service to cause the MARS Java thread to sleep for (at least) the specified number of milliseconds.
SyscallTime Service to read a character from input console into $a0.
SyscallWrite Service to write to file descriptor given in $a0.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
SyscallReadInt
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallReadInt
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallReadInt
All Implemented Interfaces:
Syscall
public class SyscallReadInt
extends AbstractSyscall
Service to read an integer from input console into $v0.
Constructor Summary
SyscallReadInt()
Build an instance of the Read Integer syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to read an integer from input console into $v0
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallReadInt
public SyscallReadInt()
Build an instance of the Read Integer syscall. Default service number
is 5 and name is “ReadInt”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to read an integer from input console into $v0
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallExit2
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallExit2
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallExit2
All Implemented Interfaces:
Syscall
public class SyscallExit2
extends AbstractSyscall
Service to exit the MIPS program with return value given in $a0. Ignored if running from GUI.
Constructor Summary
SyscallExit2()
Build an instance of the Exit2 syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to exit the MIPS program with return value given in $a0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallExit2
public SyscallExit2()
Build an instance of the Exit2 syscall. Default service number
is 17 and name is “Exit2”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to exit the MIPS program with return value given in $a0.
If running in command mode, MARS will exit with that value. If running under GUI,
return value is ignored.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallReadDouble
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallReadDouble
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallReadDouble
All Implemented Interfaces:
Syscall
public class SyscallReadDouble
extends AbstractSyscall
Service to read the bits of console input double into $f0 and $f1.
$f1 contains high order word of the double.
Constructor Summary
SyscallReadDouble()
Build an instance of the Read Double syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to read the bits of input double into $f0 and $f1.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallReadDouble
public SyscallReadDouble()
Build an instance of the Read Double syscall. Default service number
is 7 and name is “ReadDouble”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to read the bits of input double into $f0 and $f1.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallInputDialogDouble
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallInputDialogDouble
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallInputDialogDouble
All Implemented Interfaces:
Syscall
public class SyscallInputDialogDouble
extends AbstractSyscall
Service to input data.
Constructor Summary
SyscallInputDialogDouble()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to input data.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallInputDialogDouble
public SyscallInputDialogDouble()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to input data.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallMessageDialogFloat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallMessageDialogFloat
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallMessageDialogFloat
All Implemented Interfaces:
Syscall
public class SyscallMessageDialogFloat
extends AbstractSyscall
Service to display a message to user.
Constructor Summary
SyscallMessageDialogFloat()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to display a message to user.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallMessageDialogFloat
public SyscallMessageDialogFloat()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to display a message to user.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallWrite
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallWrite
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallWrite
All Implemented Interfaces:
Syscall
public class SyscallWrite
extends AbstractSyscall
Service to write to file descriptor given in $a0. $a1 specifies buffer
and $a2 specifies length. Number of characters written is returned in $v0
(this was changed from $a0 in MARS 3.7 for SPIM compatibility. The table
in COD erroneously shows $a0).
Constructor Summary
SyscallWrite()
Build an instance of the Write file syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to write to file descriptor given in $a0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallWrite
public SyscallWrite()
Build an instance of the Write file syscall. Default service number
is 15 and name is “Write”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to write to file descriptor given in $a0. $a1 specifies buffer
and $a2 specifies length. Number of characters written is returned in $v0, starting in MARS 3.7.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.mips.instructions.syscalls
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object mars.mips.instructions.syscalls.AbstractSyscall (implements mars.mips.instructions.syscalls.Syscall)
mars.mips.instructions.syscalls.SyscallClose
mars.mips.instructions.syscalls.SyscallConfirmDialog
mars.mips.instructions.syscalls.SyscallExit
mars.mips.instructions.syscalls.SyscallExit2
mars.mips.instructions.syscalls.SyscallInputDialogDouble
mars.mips.instructions.syscalls.SyscallInputDialogFloat
mars.mips.instructions.syscalls.SyscallInputDialogInt
mars.mips.instructions.syscalls.SyscallInputDialogString
mars.mips.instructions.syscalls.SyscallMessageDialog
mars.mips.instructions.syscalls.SyscallMessageDialogDouble
mars.mips.instructions.syscalls.SyscallMessageDialogFloat
mars.mips.instructions.syscalls.SyscallMessageDialogInt
mars.mips.instructions.syscalls.SyscallMessageDialogString
mars.mips.instructions.syscalls.SyscallMidiOut
mars.mips.instructions.syscalls.SyscallMidiOutSync
mars.mips.instructions.syscalls.SyscallOpen
mars.mips.instructions.syscalls.SyscallPrintChar
mars.mips.instructions.syscalls.SyscallPrintDouble
mars.mips.instructions.syscalls.SyscallPrintFloat
mars.mips.instructions.syscalls.SyscallPrintInt
mars.mips.instructions.syscalls.SyscallPrintIntBinary
mars.mips.instructions.syscalls.SyscallPrintIntHex
mars.mips.instructions.syscalls.SyscallPrintIntUnsigned
mars.mips.instructions.syscalls.SyscallPrintString
mars.mips.instructions.syscalls.SyscallRandDouble
mars.mips.instructions.syscalls.SyscallRandFloat
mars.mips.instructions.syscalls.SyscallRandInt
mars.mips.instructions.syscalls.SyscallRandIntRange
mars.mips.instructions.syscalls.SyscallRandSeed
mars.mips.instructions.syscalls.SyscallRead
mars.mips.instructions.syscalls.SyscallReadChar
mars.mips.instructions.syscalls.SyscallReadDouble
mars.mips.instructions.syscalls.SyscallReadFloat
mars.mips.instructions.syscalls.SyscallReadInt
mars.mips.instructions.syscalls.SyscallReadString
mars.mips.instructions.syscalls.SyscallSbrk
mars.mips.instructions.syscalls.SyscallSleep
mars.mips.instructions.syscalls.SyscallTime
mars.mips.instructions.syscalls.SyscallWrite
mars.mips.instructions.syscalls.RandomStreams
mars.mips.instructions.syscalls.SyscallNumberOverride
Interface Hierarchy
mars.mips.instructions.syscalls.Syscall
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
SyscallSleep
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallSleep
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallSleep
All Implemented Interfaces:
Syscall
public class SyscallSleep
extends AbstractSyscall
Service to cause the MARS Java thread to sleep for (at least) the specified number of milliseconds.
This timing will not be precise as the Java implementation will add some overhead.
Constructor Summary
SyscallSleep()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to cause the MARS Java thread to sleep for (at least) the specified number of milliseconds.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallSleep
public SyscallSleep()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to cause the MARS Java thread to sleep for (at least) the specified number of milliseconds.
This timing will not be precise as the Java implementation will add some overhead.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallClose
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallClose
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallClose
All Implemented Interfaces:
Syscall
public class SyscallClose
extends AbstractSyscall
Service to close file descriptor given in $a0.
Constructor Summary
SyscallClose()
Build an instance of the Close syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to close file descriptor given in $a0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallClose
public SyscallClose()
Build an instance of the Close syscall. Default service number
is 16 and name is “Close”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to close file descriptor given in $a0.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallRandInt
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallRandInt
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallRandInt
All Implemented Interfaces:
Syscall
public class SyscallRandInt
extends AbstractSyscall
Service to return a random integer.
Constructor Summary
SyscallRandInt()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to the random number generator.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallRandInt
public SyscallRandInt()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to the random number generator.
Return in $a0 the next pseudorandom, uniformly distributed int value from this random number generator’s sequence.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallPrintDouble
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallPrintDouble
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallPrintDouble
All Implemented Interfaces:
Syscall
public class SyscallPrintDouble
extends AbstractSyscall
Service to display double whose bits are stored in $f12 & $f13 onto the console.
$f13 contains high order word of the double.
Constructor Summary
SyscallPrintDouble()
Build an instance of the Print Double syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to print double whose bits are stored in $f12 & $f13.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallPrintDouble
public SyscallPrintDouble()
Build an instance of the Print Double syscall. Default service number
is 3 and name is “PrintDouble”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to print double whose bits are stored in $f12 & $f13.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallRead
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallRead
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallRead
All Implemented Interfaces:
Syscall
public class SyscallRead
extends AbstractSyscall
Service to read from file descriptor given in $a0. $a1 specifies buffer
and $a2 specifies length. Number of characters read is returned in $v0.
(this was changed from $a0 in MARS 3.7 for SPIM compatibility. The table
in COD erroneously shows $a0). *
Constructor Summary
SyscallRead()
Build an instance of the Read file syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to read from file descriptor given in $a0.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallRead
public SyscallRead()
Build an instance of the Read file syscall. Default service number
is 14 and name is “Read”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to read from file descriptor given in $a0. $a1 specifies buffer
and $a2 specifies length. Number of characters read is returned in $v0 (starting MARS 3.7).
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallRandFloat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallRandFloat
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallRandFloat
All Implemented Interfaces:
Syscall
public class SyscallRandFloat
extends AbstractSyscall
Service to return a random floating point value.
Constructor Summary
SyscallRandFloat()
Build an instance of the syscall with its default service number and name.
Method Summary
void simulate(ProgramStatement statement)
System call to the random number generator.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallRandFloat
public SyscallRandFloat()
Build an instance of the syscall with its default service number and name.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
System call to the random number generator.
Return in $f0 the next pseudorandom, uniformly distributed float value between 0.0 and 1.0
from this random number generator’s sequence.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallNumberOverride
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallNumberOverride
java.lang.Object
mars.mips.instructions.syscalls.SyscallNumberOverride
public class SyscallNumberOverride
extends Object
Represents User override of default syscall number assignment.
Such overrides are specified in the config.txt file read when
MARS starts up.
Constructor Summary
SyscallNumberOverride(String serviceName,
String value)
Constructor is called with two strings: service name and desired
number.
Method Summary
String getName()
Get the service name as a String.
int getNumber()
Get the new service number as an int.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallNumberOverride
public SyscallNumberOverride(String serviceName,
String value)
Constructor is called with two strings: service name and desired
number. Will throw an exception is number is malformed, but does
not check validity of the service name or number.
Parameters:
serviceName – a String containing syscall service mnemonic.
value – a String containing its reassigned syscall service number.
If this number is previously assigned to a different syscall which does not
also receive a new number, then an error for duplicate numbers will
be issued at MARS launch.
Method Detail
getName
public String getName()
Get the service name as a String.
Returns:
the service name
getNumber
public int getNumber()
Get the new service number as an int.
Returns:
the service number
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SyscallMidiOutSync
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions.syscalls
Class SyscallMidiOutSync
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallMidiOutSync
All Implemented Interfaces:
Syscall
public class SyscallMidiOutSync
extends AbstractSyscall
Service to output simulated MIDI tone to sound card. The call does
not return until the tone duration has elapsed. By contrast, syscall 31
(MidiOut) returns immediately upon generating the tone.
Constructor Summary
SyscallMidiOutSync()
Build an instance of the MIDI (simulated) out syscall.
Method Summary
void simulate(ProgramStatement statement)
Performs syscall function to send MIDI output to sound card.
Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SyscallMidiOutSync
public SyscallMidiOutSync()
Build an instance of the MIDI (simulated) out syscall. Default service number
is 33 and name is “MidiOutSync”.
Method Detail
simulate
public void simulate(ProgramStatement statement)
throws ProcessingException
Performs syscall function to send MIDI output to sound card. The syscall does not
return until after the duration period ($a1) has elapsed. This requires
four arguments in registers $a0 through $a3.
$a0 – pitch (note). Integer value from 0 to 127, with 60 being middle-C on a piano.
$a1 – duration. Integer value in milliseconds.
$a2 – instrument. Integer value from 0 to 127, with 0 being acoustic grand piano.
$a3 – volume. Integer value from 0 to 127.
Default values, in case any parameters are outside the above ranges, are $a0=60, $a1=1000,
$a2=0, $a3=100.
See MARS documentation elsewhere or www.midi.org for more information. Note that the pitch,
instrument and volume value ranges 0-127 are from javax.sound.midi; actual MIDI instruments
use the range 1-128.
Specified by:
simulate in interface Syscall
Specified by:
simulate in class AbstractSyscall
Parameters:
statement – ProgramStatement object for this syscall instruction.
Throws:
ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
BasicInstruction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.instructions
Class BasicInstruction
java.lang.Object
mars.mips.instructions.Instruction
mars.mips.instructions.BasicInstruction
public class BasicInstruction
extends Instruction
Class to represent a basic instruction in the MIPS instruction set.
Basic instruction means it translates directly to a 32-bit binary machine
instruction.
Author:
Pete Sanderson and Ken Vollmar
Field Summary
Fields inherited from class mars.mips.instructions.Instruction
description, exampleFormat, INSTRUCTION_LENGTH, INSTRUCTION_LENGTH_BITS, mnemonic, operandMask, tokenList
Constructor Summary
BasicInstruction(String example,
BasicInstructionFormat instrFormat,
String operMask,
SimulationCode simCode)
BasicInstruction(String example,
String description,
BasicInstructionFormat instrFormat,
String operMask,
SimulationCode simCode)
BasicInstruction constructor.
Method Summary
BasicInstructionFormat getInstructionFormat()
Gets the operand format of the instruction.
int getOpcodeMask()
int getOpcodeMatch()
String getOperationMask()
Gets the 32-character operation mask.
SimulationCode getSimulationCode()
Gets the SimulationCode object.
Methods inherited from class mars.mips.instructions.Instruction
createExampleTokenList, extractOperator, getDescription, getExampleFormat, getInstructionLength, getName, getTokenList
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
BasicInstruction
public BasicInstruction(String example,
String description,
BasicInstructionFormat instrFormat,
String operMask,
SimulationCode simCode)
BasicInstruction constructor.
Parameters:
example – An example usage of the instruction, as a String.
instrFormat – The format is R, I, I-branch or J.
operMask – The opcode mask is a 32 character string that contains the opcode in binary in the appropriate bit positions and codes for operand positions (‘f’, ‘s’, ‘t’) in the remainding positions.
simCode – The inline definition of an object and class which anonymously implements the SimulationCode interface.
See Also:
SimulationCode
BasicInstruction
public BasicInstruction(String example,
BasicInstructionFormat instrFormat,
String operMask,
SimulationCode simCode)
Method Detail
getOperationMask
public String getOperationMask()
Gets the 32-character operation mask. Each mask position represents a
bit position in the 32-bit machine instruction. Operation codes and
unused bits are represented in the mask by 1’s and 0’s. Operand codes
are represented by ‘f’, ‘s’, and ‘t’ for bits occupied by first, secon
and third operand, respectively.
Returns:
The 32 bit mask, as a String
getInstructionFormat
public BasicInstructionFormat getInstructionFormat()
Gets the operand format of the instruction. MIPS defines 3 of these
R-format, I-format, and J-format. R-format is all registers. I-format
is address formed from register base with immediate offset. J-format
is for jump destination addresses. I have added one more:
I-branch-format, for branch destination addresses. These are a variation
of the I-format in that the computed value is address relative to the
Program Counter. All four formats are represented by static objects.
Returns:
The machine instruction format, R, I, J or I-branch.
getSimulationCode
public SimulationCode getSimulationCode()
Gets the SimulationCode object. It is really an object of an anonymous
class that implements the SimulationCode interface. Such an object has but one
method: Simulate().
Returns:
the SimulationCode object for this instruction.
See Also:
SimulationCode
getOpcodeMask
public int getOpcodeMask()
getOpcodeMatch
public int getOpcodeMatch()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Coprocessor0
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class Coprocessor0
java.lang.Object
mars.mips.hardware.Coprocessor0
public class Coprocessor0
extends Object
Represents Coprocessor 0. We will use only its interrupt/exception registers.
Author:
Pete Sanderson
Field Summary
static int CAUSE
static int DEFAULT_STATUS_VALUE
static int EPC
static int EXCEPTION_LEVEL
static int STATUS
static int VADDR
Coprocessor register names
Constructor Summary
Coprocessor0()
Method Summary
static void addRegistersObserver(Observer observer)
Each individual register is a separate object and Observable.
static void deleteRegistersObserver(Observer observer)
Each individual register is a separate object and Observable.
static int getNumber(String n)
For getting the number representation of the register.
static Register getRegister(String rname)
Get register object corresponding to given name.
static int getRegisterPosition(Register r)
Coprocessor0 implements only selected registers, so the register number
(8, 12, 13, 14) does not correspond to its position in the list of registers
(0, 1, 2, 3).
static Register[] getRegisters()
For returning the set of registers.
static int getValue(int num)
Returns the value of the register who’s number is num.
static void resetRegisters()
Method to reinitialize the values of the registers.
static void showRegisters()
Method for displaying the register values for debugging.
static int updateRegister(int num,
int val)
This method updates the register value who’s number is num.
static int updateRegister(String n,
int val)
Sets the value of the register given to the value given.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
VADDR
public static final int VADDR
Coprocessor register names
See Also:
Constant Field Values
STATUS
public static final int STATUS
See Also:
Constant Field Values
CAUSE
public static final int CAUSE
See Also:
Constant Field Values
EPC
public static final int EPC
See Also:
Constant Field Values
EXCEPTION_LEVEL
public static final int EXCEPTION_LEVEL
See Also:
Constant Field Values
DEFAULT_STATUS_VALUE
public static final int DEFAULT_STATUS_VALUE
See Also:
Constant Field Values
Constructor Detail
Coprocessor0
public Coprocessor0()
Method Detail
showRegisters
public static void showRegisters()
Method for displaying the register values for debugging.
updateRegister
public static int updateRegister(String n,
int val)
Sets the value of the register given to the value given.
Parameters:
n – name of register to set the value of ($n, where n is reg number).
val – The desired value for the register.
Returns:
old value in register prior to update
updateRegister
public static int updateRegister(int num,
int val)
This method updates the register value who’s number is num.
Parameters:
num – Number of register to set the value of.
val – The desired value for the register.
Returns:
old value in register prior to update
getValue
public static int getValue(int num)
Returns the value of the register who’s number is num.
Parameters:
num – The register number.
Returns:
The value of the given register. 0 for non-implemented registers
getNumber
public static int getNumber(String n)
For getting the number representation of the register.
Parameters:
n – The string formatted register name to look for.
Returns:
The number of the register represented by the string. -1 if no match.
getRegisters
public static Register[] getRegisters()
For returning the set of registers.
Returns:
The set of registers.
getRegisterPosition
public static int getRegisterPosition(Register r)
Coprocessor0 implements only selected registers, so the register number
(8, 12, 13, 14) does not correspond to its position in the list of registers
(0, 1, 2, 3).
Parameters:
r – A coprocessor0 Register
Returns:
the list position of given register, -1 if not found.
getRegister
public static Register getRegister(String rname)
Get register object corresponding to given name. If no match, return null.
Parameters:
rname – The register name, in $0 format.
Returns:
The register object,or null if not found.
resetRegisters
public static void resetRegisters()
Method to reinitialize the values of the registers.
addRegistersObserver
public static void addRegistersObserver(Observer observer)
Each individual register is a separate object and Observable. This handy method
will add the given Observer to each one.
deleteRegistersObserver
public static void deleteRegistersObserver(Observer observer)
Each individual register is a separate object and Observable. This handy method
will delete the given Observer from each one.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Coprocessor1
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class Coprocessor1
java.lang.Object
mars.mips.hardware.Coprocessor1
public class Coprocessor1
extends Object
Represents Coprocessor 1, the Floating Point Unit (FPU)
Author:
Pete Sanderson
Constructor Summary
Coprocessor1()
Method Summary
static void addRegistersObserver(Observer observer)
Each individual register is a separate object and Observable.
static int clearConditionFlag(int flag)
Set condition flag to 0 (false).
static void clearConditionFlags()
Clear all condition flags (0-7).
static void deleteRegistersObserver(Observer observer)
Each individual register is a separate object and Observable.
static int getConditionFlag(int flag)
Get value of specified condition flag (0-7).
static int getConditionFlagCount()
Get count of condition flags.
static int getConditionFlags()
Get array of condition flags (0-7).
static double getDoubleFromRegisterPair(int reg)
Gets the double value stored in the given FPU register.
static double getDoubleFromRegisterPair(String reg)
Gets the double value stored in the given FPU register.
static float getFloatFromRegister(int reg)
Gets the float value stored in the given FPU register.
static float getFloatFromRegister(String reg)
Gets the float value stored in the given FPU register.
static int getIntFromRegister(int reg)
Gets the 32-bit int bit pattern stored in the given FPU register.
static int getIntFromRegister(String reg)
Gets the 32-bit int bit pattern stored in the given FPU register.
static long getLongFromRegisterPair(int reg)
Gets a long representing the double value stored in the given double
precision FPU register.
static long getLongFromRegisterPair(String reg)
Gets the double value stored in the given FPU register.
static Register getRegister(String rName)
Get register object corresponding to given name.
static int getRegisterNumber(String n)
For getting the number representation of the FPU register.
static Register[] getRegisters()
For returning the set of registers.
static int getValue(int num)
Returns the value of the FPU register who’s number is num.
static void resetRegisters()
Method to reinitialize the values of the registers.
static int setConditionFlag(int flag)
Set condition flag to 1 (true).
static void setConditionFlags()
Set all condition flags (0-7).
static void setRegisterPairToDouble(int reg,
double val)
Sets the value of the FPU register given to the double value given.
static void setRegisterPairToDouble(String reg,
double val)
Sets the value of the FPU register given to the double value given.
static void setRegisterPairToLong(int reg,
long val)
Sets the value of the FPU register pair given to the long value containing 64 bit pattern
given.
static void setRegisterPairToLong(String reg,
long val)
Sets the value of the FPU register pair given to the long value containing 64 bit pattern
given.
static void setRegisterToFloat(int reg,
float val)
Sets the value of the FPU register given to the value given.
static void setRegisterToFloat(String reg,
float val)
Sets the value of the FPU register given to the value given.
static void setRegisterToInt(int reg,
int val)
Sets the value of the FPU register given to the 32-bit
pattern given by the int parameter.
static void setRegisterToInt(String reg,
int val)
Sets the value of the FPU register given to the 32-bit
pattern given by the int parameter.
static void showRegisters()
Method for displaying the register values for debugging.
static int updateRegister(int num,
int val)
This method updates the FPU register value who’s number is num.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
Coprocessor1
public Coprocessor1()
Method Detail
showRegisters
public static void showRegisters()
Method for displaying the register values for debugging.
setRegisterToFloat
public static void setRegisterToFloat(String reg,
float val)
Sets the value of the FPU register given to the value given.
Parameters:
reg – Register to set the value of.
val – The desired float value for the register.
setRegisterToFloat
public static void setRegisterToFloat(int reg,
float val)
Sets the value of the FPU register given to the value given.
Parameters:
reg – Register to set the value of.
val – The desired float value for the register.
setRegisterToInt
public static void setRegisterToInt(String reg,
int val)
Sets the value of the FPU register given to the 32-bit
pattern given by the int parameter.
Parameters:
reg – Register to set the value of.
val – The desired int bit pattern for the register.
setRegisterToInt
public static void setRegisterToInt(int reg,
int val)
Sets the value of the FPU register given to the 32-bit
pattern given by the int parameter.
Parameters:
reg – Register to set the value of.
val – The desired int bit pattern for the register.
setRegisterPairToDouble
public static void setRegisterPairToDouble(int reg,
double val)
throws InvalidRegisterAccessException
Sets the value of the FPU register given to the double value given. The register
must be even-numbered, and the low order 32 bits are placed in it. The high order
32 bits are placed in the (odd numbered) register that follows it.
Parameters:
reg – Register to set the value of.
val – The desired double value for the register.
Throws:
InvalidRegisterAccessException – if register ID is invalid or odd-numbered.
setRegisterPairToDouble
public static void setRegisterPairToDouble(String reg,
double val)
throws InvalidRegisterAccessException
Sets the value of the FPU register given to the double value given. The register
must be even-numbered, and the low order 32 bits are placed in it. The high order
32 bits are placed in the (odd numbered) register that follows it.
Parameters:
reg – Register to set the value of.
val – The desired double value for the register.
Throws:
InvalidRegisterAccessException – if register ID is invalid or odd-numbered.
setRegisterPairToLong
public static void setRegisterPairToLong(int reg,
long val)
throws InvalidRegisterAccessException
Sets the value of the FPU register pair given to the long value containing 64 bit pattern
given. The register
must be even-numbered, and the low order 32 bits from the long are placed in it. The high order
32 bits from the long are placed in the (odd numbered) register that follows it.
Parameters:
reg – Register to set the value of. Must be even register of even/odd pair.
val – The desired double value for the register.
Throws:
InvalidRegisterAccessException – if register ID is invalid or odd-numbered.
setRegisterPairToLong
public static void setRegisterPairToLong(String reg,
long val)
throws InvalidRegisterAccessException
Sets the value of the FPU register pair given to the long value containing 64 bit pattern
given. The register
must be even-numbered, and the low order 32 bits from the long are placed in it. The high order
32 bits from the long are placed in the (odd numbered) register that follows it.
Parameters:
reg – Register to set the value of. Must be even register of even/odd pair.
val – The desired long value containing the 64 bits for the register pair.
Throws:
InvalidRegisterAccessException – if register ID is invalid or odd-numbered.
getFloatFromRegister
public static float getFloatFromRegister(int reg)
Gets the float value stored in the given FPU register.
Parameters:
reg – Register to get the value of.
Returns:
The float value stored by that register.
getFloatFromRegister
public static float getFloatFromRegister(String reg)
Gets the float value stored in the given FPU register.
Parameters:
reg – Register to get the value of.
Returns:
The float value stored by that register.
getIntFromRegister
public static int getIntFromRegister(int reg)
Gets the 32-bit int bit pattern stored in the given FPU register.
Parameters:
reg – Register to get the value of.
Returns:
The int bit pattern stored by that register.
getIntFromRegister
public static int getIntFromRegister(String reg)
Gets the 32-bit int bit pattern stored in the given FPU register.
Parameters:
reg – Register to get the value of.
Returns:
The int bit pattern stored by that register.
getDoubleFromRegisterPair
public static double getDoubleFromRegisterPair(int reg)
throws InvalidRegisterAccessException
Gets the double value stored in the given FPU register. The register
must be even-numbered.
Parameters:
reg – Register to get the value of. Must be even number of even/odd pair.
Throws:
InvalidRegisterAccessException – if register ID is invalid or odd-numbered.
getDoubleFromRegisterPair
public static double getDoubleFromRegisterPair(String reg)
throws InvalidRegisterAccessException
Gets the double value stored in the given FPU register. The register
must be even-numbered.
Parameters:
reg – Register to get the value of. Must be even number of even/odd pair.
Throws:
InvalidRegisterAccessException – if register ID is invalid or odd-numbered.
getLongFromRegisterPair
public static long getLongFromRegisterPair(int reg)
throws InvalidRegisterAccessException
Gets a long representing the double value stored in the given double
precision FPU register.
The register must be even-numbered.
Parameters:
reg – Register to get the value of. Must be even number of even/odd pair.
Throws:
InvalidRegisterAccessException – if register ID is invalid or odd-numbered.
getLongFromRegisterPair
public static long getLongFromRegisterPair(String reg)
throws InvalidRegisterAccessException
Gets the double value stored in the given FPU register. The register
must be even-numbered.
Parameters:
reg – Register to get the value of. Must be even number of even/odd pair.
Throws:
InvalidRegisterAccessException – if register ID is invalid or odd-numbered.
updateRegister
public static int updateRegister(int num,
int val)
This method updates the FPU register value who’s number is num. Note the
registers themselves hold an int value. There are helper methods available
to which you can give a float or double to store.
Parameters:
num – FPU register to set the value of.
val – The desired int value for the register.
getValue
public static int getValue(int num)
Returns the value of the FPU register who’s number is num. Returns the
raw int value actually stored there. If you need a float, use
Float.intBitsToFloat() to get the equivent float.
Parameters:
num – The FPU register number.
Returns:
The int value of the given register.
getRegisterNumber
public static int getRegisterNumber(String n)
For getting the number representation of the FPU register.
Parameters:
n – The string formatted register name to look for.
Returns:
The number of the register represented by the string.
getRegisters
public static Register[] getRegisters()
For returning the set of registers.
Returns:
The set of registers.
getRegister
public static Register getRegister(String rName)
Get register object corresponding to given name. If no match, return null.
Parameters:
rName – The FPU register name, must be “$f0” through “$f31”.
Returns:
The register object,or null if not found.
resetRegisters
public static void resetRegisters()
Method to reinitialize the values of the registers.
addRegistersObserver
public static void addRegistersObserver(Observer observer)
Each individual register is a separate object and Observable. This handy method
will add the given Observer to each one.
deleteRegistersObserver
public static void deleteRegistersObserver(Observer observer)
Each individual register is a separate object and Observable. This handy method
will delete the given Observer from each one.
setConditionFlag
public static int setConditionFlag(int flag)
Set condition flag to 1 (true).
Parameters:
flag – condition flag number (0-7)
Returns:
previous flag setting (0 or 1)
clearConditionFlag
public static int clearConditionFlag(int flag)
Set condition flag to 0 (false).
Parameters:
flag – condition flag number (0-7)
Returns:
previous flag setting (0 or 1)
getConditionFlag
public static int getConditionFlag(int flag)
Get value of specified condition flag (0-7).
Parameters:
flag – condition flag number (0-7)
Returns:
0 if condition is false, 1 if condition is true
getConditionFlags
public static int getConditionFlags()
Get array of condition flags (0-7).
Returns:
array of int condition flags
clearConditionFlags
public static void clearConditionFlags()
Clear all condition flags (0-7).
setConditionFlags
public static void setConditionFlags()
Set all condition flags (0-7).
getConditionFlagCount
public static int getConditionFlagCount()
Get count of condition flags.
Returns:
number of condition flags
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
AccessNotice
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class AccessNotice
java.lang.Object
mars.mips.hardware.AccessNotice
Direct Known Subclasses:
MemoryAccessNotice, RegisterAccessNotice
public abstract class AccessNotice
extends Object
Object provided to Observers of runtime access to MIPS memory or registers.
The access types READ and WRITE defined here; use subclasses defined for
MemoryAccessNotice and RegisterAccessNotice. This is abstract class.
Author:
Pete Sanderson
Field Summary
static int READ
Indicates the purpose of access was to read.
static int WRITE
Indicates the purpose of access was to write.
Constructor Summary
protected AccessNotice(int type)
Method Summary
boolean accessIsFromGUI()
Query whether the access originated from MARS GUI (AWT event queue)
boolean accessIsFromMIPS()
Query whether the access originated from executing MIPS program
int getAccessType()
Get the access type: READ or WRITE.
Thread getThread()
Get reference to thread that created this notice
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
READ
public static final int READ
Indicates the purpose of access was to read.
See Also:
Constant Field Values
WRITE
public static final int WRITE
Indicates the purpose of access was to write.
See Also:
Constant Field Values
Constructor Detail
AccessNotice
protected AccessNotice(int type)
Method Detail
getAccessType
public int getAccessType()
Get the access type: READ or WRITE.
Returns:
Access type, either AccessNotice.READ or AccessNotice.WRITE
getThread
public Thread getThread()
Get reference to thread that created this notice
Returns:
Return reference to the thread that created this notice.
accessIsFromGUI
public boolean accessIsFromGUI()
Query whether the access originated from MARS GUI (AWT event queue)
Returns:
true if this access originated from MARS GUI, false otherwise
accessIsFromMIPS
public boolean accessIsFromMIPS()
Query whether the access originated from executing MIPS program
Returns:
true if this access originated from executing MIPS program, false otherwise
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MemoryConfiguration
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class MemoryConfiguration
java.lang.Object
mars.mips.hardware.MemoryConfiguration
public class MemoryConfiguration
extends Object
Models the memory configuration for the simulated MIPS machine.
“configuration” refers to the starting memory addresses for
the various memory segments.
The default configuration is based on SPIM. Starting with MARS 3.7,
the configuration can be changed.
Author:
Pete Sanderson
Constructor Summary
MemoryConfiguration(String ident,
String name,
String[] items,
int[] values)
Method Summary
String getConfigurationIdentifier()
String[] getConfigurationItemNames()
int[] getConfigurationItemValues()
String getConfigurationName()
int getDataBaseAddress()
int getDataSegmentBaseAddress()
int getDataSegmentLimitAddress()
int getExceptionHandlerAddress()
int getExternBaseAddress()
int getGlobalPointer()
int getHeapBaseAddress()
int getKernelBaseAddress()
int getKernelDataBaseAddress()
int getKernelDataSegmentLimitAddress()
int getKernelHighAddress()
int getKernelTextBaseAddress()
int getKernelTextLimitAddress()
int getMemoryMapBaseAddress()
int getMemoryMapLimitAddress()
int getStackBaseAddress()
int getStackLimitAddress()
int getStackPointer()
int getTextBaseAddress()
int getTextLimitAddress()
int getUserHighAddress()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
MemoryConfiguration
public MemoryConfiguration(String ident,
String name,
String[] items,
int[] values)
Method Detail
getConfigurationIdentifier
public String getConfigurationIdentifier()
getConfigurationName
public String getConfigurationName()
getConfigurationItemValues
public int[] getConfigurationItemValues()
getConfigurationItemNames
public String[] getConfigurationItemNames()
getTextBaseAddress
public int getTextBaseAddress()
getDataSegmentBaseAddress
public int getDataSegmentBaseAddress()
getExternBaseAddress
public int getExternBaseAddress()
getGlobalPointer
public int getGlobalPointer()
getDataBaseAddress
public int getDataBaseAddress()
getHeapBaseAddress
public int getHeapBaseAddress()
getStackPointer
public int getStackPointer()
getStackBaseAddress
public int getStackBaseAddress()
getUserHighAddress
public int getUserHighAddress()
getKernelBaseAddress
public int getKernelBaseAddress()
getKernelTextBaseAddress
public int getKernelTextBaseAddress()
getExceptionHandlerAddress
public int getExceptionHandlerAddress()
getKernelDataBaseAddress
public int getKernelDataBaseAddress()
getMemoryMapBaseAddress
public int getMemoryMapBaseAddress()
getKernelHighAddress
public int getKernelHighAddress()
getDataSegmentLimitAddress
public int getDataSegmentLimitAddress()
getTextLimitAddress
public int getTextLimitAddress()
getKernelDataSegmentLimitAddress
public int getKernelDataSegmentLimitAddress()
getKernelTextLimitAddress
public int getKernelTextLimitAddress()
getStackLimitAddress
public int getStackLimitAddress()
getMemoryMapLimitAddress
public int getMemoryMapLimitAddress()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Register
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class Register
java.lang.Object
java.util.Observable
mars.mips.hardware.Register
public class Register
extends Observable
Abstraction to represent a register of a MIPS Assembler.
Author:
Jason Bumgarner, Jason Shrewsbury, Ben Sherman
Constructor Summary
Register(String n,
int num,
int val)
Creates a new register with specified name, number, and value.
Method Summary
void changeResetValue(int reset)
Change the register’s reset value; the value to which it will be
set when resetValue() is called.
String getName()
Returns the name of the Register.
int getNumber()
Returns the number of the Register.
int getResetValue()
Returns the reset value of the Register.
int getValue()
Returns the value of the Register.
int getValueNoNotify()
Returns the value of the Register.
void resetValue()
Resets the value of the register to the value it was constructed with.
int setValue(int val)
Sets the value of the register to the val passed to it.
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
Register
public Register(String n,
int num,
int val)
Creates a new register with specified name, number, and value.
Parameters:
n – The name of the register.
num – The number of the register.
val – The inital (and reset) value of the register.
Method Detail
getName
public String getName()
Returns the name of the Register.
Returns:
name The name of the Register.
getValue
public int getValue()
Returns the value of the Register. Observers are notified
of the READ operation.
Returns:
value The value of the Register.
getValueNoNotify
public int getValueNoNotify()
Returns the value of the Register. Observers are not notified.
Added for release 3.8.
Returns:
value The value of the Register.
getResetValue
public int getResetValue()
Returns the reset value of the Register.
Returns:
The reset (initial) value of the Register.
getNumber
public int getNumber()
Returns the number of the Register.
Returns:
number The number of the Register.
setValue
public int setValue(int val)
Sets the value of the register to the val passed to it.
Observers are notified of the WRITE operation.
Parameters:
val – Value to set the Register to.
Returns:
previous value of register
resetValue
public void resetValue()
Resets the value of the register to the value it was constructed with.
Observers are not notified.
changeResetValue
public void changeResetValue(int reset)
Change the register’s reset value; the value to which it will be
set when resetValue() is called.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MemoryAccessNotice
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class MemoryAccessNotice
java.lang.Object
mars.mips.hardware.AccessNotice
mars.mips.hardware.MemoryAccessNotice
public class MemoryAccessNotice
extends AccessNotice
Object provided to Observers of runtime access to MIPS memory.
Observer can get the access type (R/W), address and length in bytes (4,2,1).
Author:
Pete Sanderson
Field Summary
Fields inherited from class mars.mips.hardware.AccessNotice
READ, WRITE
Constructor Summary
MemoryAccessNotice(int type,
int address,
int value)
Constructor will be called only within this package, so assume
address is in valid range.
Method Summary
int getAddress()
Fetch the memory address that was accessed.
int getLength()
Fetch the length in bytes of the access operation (4,2,1).
int getValue()
Fetch the value of the access operation (the value read or written).
String toString()
String representation indicates access type, address and length in bytes
Methods inherited from class mars.mips.hardware.AccessNotice
accessIsFromGUI, accessIsFromMIPS, getAccessType, getThread
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
MemoryAccessNotice
public MemoryAccessNotice(int type,
int address,
int value)
Constructor will be called only within this package, so assume
address is in valid range.
Method Detail
getAddress
public int getAddress()
Fetch the memory address that was accessed.
getLength
public int getLength()
Fetch the length in bytes of the access operation (4,2,1).
getValue
public int getValue()
Fetch the value of the access operation (the value read or written).
toString
public String toString()
String representation indicates access type, address and length in bytes
Overrides:
toString in class Object
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MemoryConfigurations
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class MemoryConfigurations
java.lang.Object
mars.mips.hardware.MemoryConfigurations
public class MemoryConfigurations
extends Object
Models the collection of MIPS memory configurations.
The default configuration is based on SPIM. Starting with MARS 3.7,
the configuration can be changed.
Author:
Pete Sanderson
Constructor Summary
MemoryConfigurations()
Method Summary
static void buildConfigurationCollection()
static MemoryConfiguration getConfigurationByName(String name)
static Iterator getConfigurationsIterator()
static MemoryConfiguration getCurrentConfiguration()
static MemoryConfiguration getDefaultConfiguration()
static int getDefaultDataBaseAddress()
static int getDefaultDataSegmentBaseAddress()
int getDefaultDataSegmentLimitAddress()
static int getDefaultExceptionHandlerAddress()
static int getDefaultExternBaseAddress()
static int getDefaultGlobalPointer()
static int getDefaultHeapBaseAddress()
static int getDefaultKernelBaseAddress()
static int getDefaultKernelDataBaseAddress()
int getDefaultKernelDataSegmentLimitAddress()
static int getDefaultKernelHighAddress()
static int getDefaultKernelTextBaseAddress()
int getDefaultKernelTextLimitAddress()
static int getDefaultMemoryMapBaseAddress()
static int getDefaultStackBaseAddress()
int getDefaultStackLimitAddress()
static int getDefaultStackPointer()
static int getDefaultTextBaseAddress()
int getDefaultTextLimitAddress()
static int getDefaultUserHighAddress()
int getMemoryMapLimitAddress()
static boolean setCurrentConfiguration(MemoryConfiguration config)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
MemoryConfigurations
public MemoryConfigurations()
Method Detail
buildConfigurationCollection
public static void buildConfigurationCollection()
getConfigurationsIterator
public static Iterator getConfigurationsIterator()
getConfigurationByName
public static MemoryConfiguration getConfigurationByName(String name)
getDefaultConfiguration
public static MemoryConfiguration getDefaultConfiguration()
getCurrentConfiguration
public static MemoryConfiguration getCurrentConfiguration()
setCurrentConfiguration
public static boolean setCurrentConfiguration(MemoryConfiguration config)
getDefaultTextBaseAddress
public static int getDefaultTextBaseAddress()
getDefaultDataSegmentBaseAddress
public static int getDefaultDataSegmentBaseAddress()
getDefaultExternBaseAddress
public static int getDefaultExternBaseAddress()
getDefaultGlobalPointer
public static int getDefaultGlobalPointer()
getDefaultDataBaseAddress
public static int getDefaultDataBaseAddress()
getDefaultHeapBaseAddress
public static int getDefaultHeapBaseAddress()
getDefaultStackPointer
public static int getDefaultStackPointer()
getDefaultStackBaseAddress
public static int getDefaultStackBaseAddress()
getDefaultUserHighAddress
public static int getDefaultUserHighAddress()
getDefaultKernelBaseAddress
public static int getDefaultKernelBaseAddress()
getDefaultKernelTextBaseAddress
public static int getDefaultKernelTextBaseAddress()
getDefaultExceptionHandlerAddress
public static int getDefaultExceptionHandlerAddress()
getDefaultKernelDataBaseAddress
public static int getDefaultKernelDataBaseAddress()
getDefaultMemoryMapBaseAddress
public static int getDefaultMemoryMapBaseAddress()
getDefaultKernelHighAddress
public static int getDefaultKernelHighAddress()
getDefaultDataSegmentLimitAddress
public int getDefaultDataSegmentLimitAddress()
getDefaultTextLimitAddress
public int getDefaultTextLimitAddress()
getDefaultKernelDataSegmentLimitAddress
public int getDefaultKernelDataSegmentLimitAddress()
getDefaultKernelTextLimitAddress
public int getDefaultKernelTextLimitAddress()
getDefaultStackLimitAddress
public int getDefaultStackLimitAddress()
getMemoryMapLimitAddress
public int getMemoryMapLimitAddress()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
AddressErrorException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class AddressErrorException
java.lang.Object
java.lang.Throwable
java.lang.Exception
mars.mips.hardware.AddressErrorException
All Implemented Interfaces:
Serializable
public class AddressErrorException
extends Exception
Represents MIPS AddressErrorException. This is generated by the assembler when the
source code references a memory address not valid for the context.
Author:
Pete Sanderson
See Also:
Serialized Form
Constructor Summary
AddressErrorException(String message,
int exceptType,
int addr)
Constructor for the AddressErrorException class
Method Summary
int getAddress()
Get the erroneous memory address.
int getType()
Get the exception type (load or store).
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
AddressErrorException
public AddressErrorException(String message,
int exceptType,
int addr)
Constructor for the AddressErrorException class
Parameters:
addr – The erroneous memory address.
Method Detail
getAddress
public int getAddress()
Get the erroneous memory address.
Returns:
The erroneous memory address.
getType
public int getType()
Get the exception type (load or store).
Returns:
Exception type: Exceptions.ADDRESS_EXCEPTION_LOAD, Exceptions.ADDRESS_EXCEPTION_STORE
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
mars.mips.hardware
Classes
AccessNotice
Coprocessor0
Coprocessor1
Memory
MemoryAccessNotice
MemoryConfiguration
MemoryConfigurations
Register
RegisterAccessNotice
RegisterFile
Exceptions
AddressErrorException
InvalidRegisterAccessException
InvalidRegisterAccessException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class InvalidRegisterAccessException
java.lang.Object
java.lang.Throwable
java.lang.Exception
mars.mips.hardware.InvalidRegisterAccessException
All Implemented Interfaces:
Serializable
public class InvalidRegisterAccessException
extends Exception
Represents attempt to access double precision register using an odd
(e.g. $f1, $f23) register name.
Author:
Pete Sanderson
See Also:
Serialized Form
Constructor Summary
InvalidRegisterAccessException()
Constructor for IllegalRegisterException.
Method Summary
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
InvalidRegisterAccessException
public InvalidRegisterAccessException()
Constructor for IllegalRegisterException.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.mips.hardware
Class Summary
AccessNotice Object provided to Observers of runtime access to MIPS memory or registers.
Coprocessor0 Represents Coprocessor 0.
Coprocessor1 Represents Coprocessor 1, the Floating Point Unit (FPU)
Memory Represents MIPS memory.
MemoryAccessNotice Object provided to Observers of runtime access to MIPS memory.
MemoryConfiguration Models the memory configuration for the simulated MIPS machine.
MemoryConfigurations Models the collection of MIPS memory configurations.
Register Abstraction to represent a register of a MIPS Assembler.
RegisterAccessNotice Object provided to Observers of runtime access to MIPS register.
RegisterFile Represents the collection of MIPS registers.
Exception Summary
AddressErrorException Represents MIPS AddressErrorException.
InvalidRegisterAccessException Represents attempt to access double precision register using an odd
(e.g.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Memory
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class Memory
java.lang.Object
java.util.Observable
mars.mips.hardware.Memory
public class Memory
extends Observable
Represents MIPS memory. Different segments are represented by different data structs.
Author:
Pete Sanderson
Field Summary
static boolean BIG_ENDIAN
Constant representing byte order of each memory word.
static int dataBaseAddress
base address for storage of non-global static data in data segment: 0x10010000 (from SPIM)
static int dataSegmentBaseAddress
base address for (user) data segment: 0x10000000
static int dataSegmentLimitAddress
static int exceptionHandlerAddress
starting address for exception handlers: 0x80000180
static int externBaseAddress
base address for .extern directive: 0x10000000
static int globalPointer
base address for storing globals
static int heapAddress
static int heapBaseAddress
base address for heap: 0x10040000 (I think from SPIM not MIPS)
static int kernelBaseAddress
kernel boundary.
static int kernelDataBaseAddress
base address for kernel data segment: 0x90000000
static int kernelDataSegmentLimitAddress
static int kernelHighAddress
highest address acessible in kernel mode.
static int kernelTextBaseAddress
base address for kernel text segment: 0x80000000
static int kernelTextLimitAddress
static boolean LITTLE_ENDIAN
Constant representing byte order of each memory word.
static int memoryMapBaseAddress
starting address for memory mapped I/O: 0xffff0000 (-65536)
static int memoryMapLimitAddress
static int stackBaseAddress
base address for stack: 0x7ffffffc (this is mine – start of highest word below kernel space)
static int stackLimitAddress
static int stackPointer
starting address for stack: 0x7fffeffc (this is from SPIM not MIPS)
static int textBaseAddress
base address for (user) text segment: 0x00400000
static int textLimitAddress
static int userHighAddress
highest address accessible in user (not kernel) mode.
static int WORD_LENGTH_BYTES
MIPS word length in bytes.
Method Summary
void addObserver(Observer obs)
Method to accept registration from observer for any memory address.
void addObserver(Observer obs,
int addr)
Method to accept registration from observer for specific address.
void addObserver(Observer obs,
int startAddr,
int endAddr)
Method to accept registration from observer for specific address range.
static int alignToWordBoundary(int address)
Utility method to align given address to next full word boundary, if not already
aligned.
int allocateBytesFromHeap(int numBytes)
Returns the next available word-aligned heap address.
void clear()
Explicitly clear the contents of memory.
int countObservers()
Return number of observers
void deleteObserver(Observer obs)
Remove specified memory observers
void deleteObservers()
Remove all memory observers
static boolean doublewordAligned(int address)
Utility to determine if given address is doubleword-aligned.
int get(int address,
int length)
Starting at the given word address, read the given number of bytes (max 4).
int getAddressOfFirstNull(int baseAddress,
int limitAddress)
Look for first “null” memory value in an address range.
int getByte(int address)
Reads specified Memory byte into low order 8 bits of int.
boolean getByteOrder()
Retrieve memory byte order.
int getHalf(int address)
Starting at the given word address, read a 2 byte word into lower 16 bits of int.
static Memory getInstance()
Returns the unique Memory instance, which becomes in essence global.
int getRawWord(int address)
Starting at the given word address, read a 4 byte word as an int.
Integer getRawWordOrNull(int address)
Starting at the given word address, read a 4 byte word as an int and return Integer.
ProgramStatement getStatement(int address)
Gets ProgramStatement from Text Segment.
ProgramStatement getStatementNoNotify(int address)
Gets ProgramStatement from Text Segment without notifying observers.
int getWord(int address)
Starting at the given word address, read a 4 byte word as an int.
int getWordNoNotify(int address)
Starting at the given word address, read a 4 byte word as an int.
static boolean inDataSegment(int address)
Handy little utility to find out if given address is in MARS data
segment (starts at Memory.dataSegmentBaseAddress).
static boolean inKernelDataSegment(int address)
Handy little utility to find out if given address is in MARS kernel data
segment (starts at Memory.kernelDataSegmentBaseAddress).
static boolean inKernelTextSegment(int address)
Handy little utility to find out if given address is in MARS kernel
text segment (starts at Memory.kernelTextBaseAddress).
static boolean inMemoryMapSegment(int address)
Handy little utility to find out if given address is in the Memory Map area
starts at Memory.memoryMapBaseAddress, range 0xffff0000 to 0xffffffff.
static boolean inTextSegment(int address)
Handy little utility to find out if given address is in MARS text
segment (starts at Memory.textBaseAddress).
void notifyObservers()
Overridden to be unavailable.
void notifyObservers(Object obj)
Overridden to be unavailable.
int set(int address,
int value,
int length)
Starting at the given address, write the given value over the given number of bytes.
int setByte(int address,
int value)
Writes low order 8 bits of given value into specified Memory byte.
void setByteOrder(boolean order)
Set byte order to either LITTLE_ENDIAN or BIG_ENDIAN.
static void setConfiguration()
Sets current memory configuration for simulated MIPS.
double setDouble(int address,
double value)
Writes 64 bit double value starting at specified Memory address.
int setHalf(int address,
int value)
Starting at the given halfword address, write the lower 16 bits of given value
into 2 bytes (a halfword).
int setRawWord(int address,
int value)
Starting at the given word address, write the given value over 4 bytes (a word).
void setStatement(int address,
ProgramStatement statement)
Stores ProgramStatement in Text Segment.
int setWord(int address,
int value)
Starting at the given word address, write the given value over 4 bytes (a word).
boolean usingCompactMemoryConfiguration()
Determine whether the current memory configuration has a maximum address that can be stored
in 16 bits.
static boolean wordAligned(int address)
Utility to determine if given address is word-aligned.
Methods inherited from class java.util.Observable
clearChanged, hasChanged, setChanged
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
textBaseAddress
public static int textBaseAddress
base address for (user) text segment: 0x00400000
dataSegmentBaseAddress
public static int dataSegmentBaseAddress
base address for (user) data segment: 0x10000000
externBaseAddress
public static int externBaseAddress
base address for .extern directive: 0x10000000
globalPointer
public static int globalPointer
base address for storing globals
dataBaseAddress
public static int dataBaseAddress
base address for storage of non-global static data in data segment: 0x10010000 (from SPIM)
heapBaseAddress
public static int heapBaseAddress
base address for heap: 0x10040000 (I think from SPIM not MIPS)
stackPointer
public static int stackPointer
starting address for stack: 0x7fffeffc (this is from SPIM not MIPS)
stackBaseAddress
public static int stackBaseAddress
base address for stack: 0x7ffffffc (this is mine – start of highest word below kernel space)
userHighAddress
public static int userHighAddress
highest address accessible in user (not kernel) mode.
kernelBaseAddress
public static int kernelBaseAddress
kernel boundary. Only OS can access this or higher address
kernelTextBaseAddress
public static int kernelTextBaseAddress
base address for kernel text segment: 0x80000000
exceptionHandlerAddress
public static int exceptionHandlerAddress
starting address for exception handlers: 0x80000180
kernelDataBaseAddress
public static int kernelDataBaseAddress
base address for kernel data segment: 0x90000000
memoryMapBaseAddress
public static int memoryMapBaseAddress
starting address for memory mapped I/O: 0xffff0000 (-65536)
kernelHighAddress
public static int kernelHighAddress
highest address acessible in kernel mode.
WORD_LENGTH_BYTES
public static final int WORD_LENGTH_BYTES
MIPS word length in bytes.
See Also:
Constant Field Values
LITTLE_ENDIAN
public static final boolean LITTLE_ENDIAN
Constant representing byte order of each memory word. Little-endian means lowest
numbered byte is right most [3][2][1][0].
See Also:
Constant Field Values
BIG_ENDIAN
public static final boolean BIG_ENDIAN
Constant representing byte order of each memory word. Big-endian means lowest
numbered byte is left most [0][1][2][3].
See Also:
Constant Field Values
heapAddress
public static int heapAddress
dataSegmentLimitAddress
public static int dataSegmentLimitAddress
textLimitAddress
public static int textLimitAddress
kernelDataSegmentLimitAddress
public static int kernelDataSegmentLimitAddress
kernelTextLimitAddress
public static int kernelTextLimitAddress
stackLimitAddress
public static int stackLimitAddress
memoryMapLimitAddress
public static int memoryMapLimitAddress
Method Detail
getInstance
public static Memory getInstance()
Returns the unique Memory instance, which becomes in essence global.
clear
public void clear()
Explicitly clear the contents of memory. Typically done at start of assembly.
setConfiguration
public static void setConfiguration()
Sets current memory configuration for simulated MIPS. Configuration is
collection of memory segment addresses. e.g. text segment starting at
address 0x00400000. Configuration can be modified starting with MARS 3.7.
usingCompactMemoryConfiguration
public boolean usingCompactMemoryConfiguration()
Determine whether the current memory configuration has a maximum address that can be stored
in 16 bits.
Returns:
true if maximum address can be stored in 16 bits or less, false otherwise
allocateBytesFromHeap
public int allocateBytesFromHeap(int numBytes)
throws IllegalArgumentException
Returns the next available word-aligned heap address. There is no recycling and
no heap management! There is however nearly 4MB of heap space available in Mars.
Parameters:
numBytes – Number of bytes requested. Should be multiple of 4, otherwise next higher multiple of 4 allocated.
Returns:
address of allocated heap storage.
Throws:
IllegalArgumentException – if number of requested bytes is negative or exceeds available heap storage
setByteOrder
public void setByteOrder(boolean order)
Set byte order to either LITTLE_ENDIAN or BIG_ENDIAN. Default is LITTLE_ENDIAN.
Parameters:
order – either LITTLE_ENDIAN or BIG_ENDIAN
getByteOrder
public boolean getByteOrder()
Retrieve memory byte order. Default is LITTLE_ENDIAN (like PCs).
Returns:
either LITTLE_ENDIAN or BIG_ENDIAN
set
public int set(int address,
int value,
int length)
throws AddressErrorException
Starting at the given address, write the given value over the given number of bytes.
This one does not check for word boundaries, and copies one byte at a time.
If length == 1, takes value from low order byte. If 2, takes from low order half-word.
Parameters:
address – Starting address of Memory address to be set.
value – Value to be stored starting at that address.
length – Number of bytes to be written.
Returns:
old value that was replaced by the set operation
Throws:
AddressErrorException
setRawWord
public int setRawWord(int address,
int value)
throws AddressErrorException
Starting at the given word address, write the given value over 4 bytes (a word).
It must be written as is, without adjusting for byte order (little vs big endian).
Address must be word-aligned.
Parameters:
address – Starting address of Memory address to be set.
value – Value to be stored starting at that address.
Returns:
old value that was replaced by the set operation.
Throws:
AddressErrorException – If address is not on word boundary.
setWord
public int setWord(int address,
int value)
throws AddressErrorException
Starting at the given word address, write the given value over 4 bytes (a word).
The address must be word-aligned.
Parameters:
address – Starting address of Memory address to be set.
value – Value to be stored starting at that address.
Returns:
old value that was replaced by setWord operation.
Throws:
AddressErrorException – If address is not on word boundary.
setHalf
public int setHalf(int address,
int value)
throws AddressErrorException
Starting at the given halfword address, write the lower 16 bits of given value
into 2 bytes (a halfword).
Parameters:
address – Starting address of Memory address to be set.
value – Value to be stored starting at that address. Only low order 16 bits used.
Returns:
old value that was replaced by setHalf operation.
Throws:
AddressErrorException – If address is not on halfword boundary.
setByte
public int setByte(int address,
int value)
throws AddressErrorException
Writes low order 8 bits of given value into specified Memory byte.
Parameters:
address – Address of Memory byte to be set.
value – Value to be stored at that address. Only low order 8 bits used.
Returns:
old value that was replaced by setByte operation.
Throws:
AddressErrorException
setDouble
public double setDouble(int address,
double value)
throws AddressErrorException
Writes 64 bit double value starting at specified Memory address. Note that
high-order 32 bits are stored in higher (second) memory word regardless
of “endianness”.
Parameters:
address – Starting address of Memory address to be set.
value – Value to be stored at that address.
Returns:
old value that was replaced by setDouble operation.
Throws:
AddressErrorException
setStatement
public void setStatement(int address,
ProgramStatement statement)
throws AddressErrorException
Stores ProgramStatement in Text Segment.
Parameters:
address – Starting address of Memory address to be set. Must be word boundary.
statement – Machine code to be stored starting at that address — for simulation
purposes, actually stores reference to ProgramStatement instead of 32-bit machine code.
Throws:
AddressErrorException – If address is not on word boundary or is outside Text Segment.
See Also:
ProgramStatement
get
public int get(int address,
int length)
throws AddressErrorException
Starting at the given word address, read the given number of bytes (max 4).
This one does not check for word boundaries, and copies one byte at a time.
If length == 1, puts value in low order byte. If 2, puts into low order half-word.
Parameters:
address – Starting address of Memory address to be read.
length – Number of bytes to be read.
Returns:
Value stored starting at that address.
Throws:
AddressErrorException
getRawWord
public int getRawWord(int address)
throws AddressErrorException
Starting at the given word address, read a 4 byte word as an int.
It transfers the 32 bit value “raw” as stored in memory, and does not adjust
for byte order (big or little endian). Address must be word-aligned.
Parameters:
address – Starting address of word to be read.
Returns:
Word (4-byte value) stored starting at that address.
Throws:
AddressErrorException – If address is not on word boundary.
getRawWordOrNull
public Integer getRawWordOrNull(int address)
throws AddressErrorException
Starting at the given word address, read a 4 byte word as an int and return Integer.
It transfers the 32 bit value “raw” as stored in memory, and does not adjust
for byte order (big or little endian). Address must be word-aligned.
Returns null if reading from text segment and there is no instruction at the
requested address. Returns null if reading from data segment and this is the
first reference to the MARS 4K memory allocation block (i.e., an array to
hold the memory has not been allocated).
This method was developed by Greg Giberling of UC Berkeley to support the memory
dump feature that he implemented in Fall 2007.
Parameters:
address – Starting address of word to be read.
Returns:
Word (4-byte value) stored starting at that address as an Integer. Conditions
that cause return value null are described above.
Throws:
AddressErrorException – If address is not on word boundary.
getAddressOfFirstNull
public int getAddressOfFirstNull(int baseAddress,
int limitAddress)
throws AddressErrorException
Look for first “null” memory value in an address range. For text segment (binary code), this
represents a word that does not contain an instruction. Normally use this to find the end of
the program. For data segment, this represents the first block of simulated memory (block length
currently 4K words) that has not been referenced by an assembled/executing program.
Parameters:
baseAddress – lowest MIPS address to be searched; the starting point
limitAddress – highest MIPS address to be searched
Returns:
lowest address within specified range that contains “null” value as described above.
Throws:
AddressErrorException – if the base address is not on a word boundary
getWord
public int getWord(int address)
throws AddressErrorException
Starting at the given word address, read a 4 byte word as an int.
Does not use “get()”; we can do it faster here knowing we’re working only
with full words.
Parameters:
address – Starting address of word to be read.
Returns:
Word (4-byte value) stored starting at that address.
Throws:
AddressErrorException – If address is not on word boundary.
getWordNoNotify
public int getWordNoNotify(int address)
throws AddressErrorException
Starting at the given word address, read a 4 byte word as an int.
Does not use “get()”; we can do it faster here knowing we’re working only
with full words. Observers are NOT notified.
Parameters:
address – Starting address of word to be read.
Returns:
Word (4-byte value) stored starting at that address.
Throws:
AddressErrorException – If address is not on word boundary.
getHalf
public int getHalf(int address)
throws AddressErrorException
Starting at the given word address, read a 2 byte word into lower 16 bits of int.
Parameters:
address – Starting address of word to be read.
Returns:
Halfword (2-byte value) stored starting at that address, stored in lower 16 bits.
Throws:
AddressErrorException – If address is not on halfword boundary.
getByte
public int getByte(int address)
throws AddressErrorException
Reads specified Memory byte into low order 8 bits of int.
Parameters:
address – Address of Memory byte to be read.
Returns:
Value stored at that address. Only low order 8 bits used.
Throws:
AddressErrorException
getStatement
public ProgramStatement getStatement(int address)
throws AddressErrorException
Gets ProgramStatement from Text Segment.
Parameters:
address – Starting address of Memory address to be read. Must be word boundary.
Returns:
reference to ProgramStatement object associated with that address, or null if none.
Throws:
AddressErrorException – If address is not on word boundary or is outside Text Segment.
See Also:
ProgramStatement
getStatementNoNotify
public ProgramStatement getStatementNoNotify(int address)
throws AddressErrorException
Gets ProgramStatement from Text Segment without notifying observers.
Parameters:
address – Starting address of Memory address to be read. Must be word boundary.
Returns:
reference to ProgramStatement object associated with that address, or null if none.
Throws:
AddressErrorException – If address is not on word boundary or is outside Text Segment.
See Also:
ProgramStatement
wordAligned
public static boolean wordAligned(int address)
Utility to determine if given address is word-aligned.
Parameters:
address – the address to check
Returns:
true if address is word-aligned, false otherwise
doublewordAligned
public static boolean doublewordAligned(int address)
Utility to determine if given address is doubleword-aligned.
Parameters:
address – the address to check
Returns:
true if address is doubleword-aligned, false otherwise
alignToWordBoundary
public static int alignToWordBoundary(int address)
Utility method to align given address to next full word boundary, if not already
aligned.
Parameters:
address – a memory address (any int value is potentially valid)
Returns:
address aligned to next word boundary (divisible by 4)
inTextSegment
public static boolean inTextSegment(int address)
Handy little utility to find out if given address is in MARS text
segment (starts at Memory.textBaseAddress).
Note that MARS does not implement the entire MIPS text segment space,
but it does implement enough for hundreds of thousands of lines
of code.
Parameters:
address – integer memory address
Returns:
true if that address is within MARS-defined text segment,
false otherwise.
inKernelTextSegment
public static boolean inKernelTextSegment(int address)
Handy little utility to find out if given address is in MARS kernel
text segment (starts at Memory.kernelTextBaseAddress).
Parameters:
address – integer memory address
Returns:
true if that address is within MARS-defined kernel text segment,
false otherwise.
inDataSegment
public static boolean inDataSegment(int address)
Handy little utility to find out if given address is in MARS data
segment (starts at Memory.dataSegmentBaseAddress).
Note that MARS does not implement the entire MIPS data segment space,
but it does support at least 4MB.
Parameters:
address – integer memory address
Returns:
true if that address is within MARS-defined data segment,
false otherwise.
inKernelDataSegment
public static boolean inKernelDataSegment(int address)
Handy little utility to find out if given address is in MARS kernel data
segment (starts at Memory.kernelDataSegmentBaseAddress).
Parameters:
address – integer memory address
Returns:
true if that address is within MARS-defined kernel data segment,
false otherwise.
inMemoryMapSegment
public static boolean inMemoryMapSegment(int address)
Handy little utility to find out if given address is in the Memory Map area
starts at Memory.memoryMapBaseAddress, range 0xffff0000 to 0xffffffff.
Parameters:
address – integer memory address
Returns:
true if that address is within MARS-defined memory map (MMIO) area,
false otherwise.
addObserver
public void addObserver(Observer obs)
Method to accept registration from observer for any memory address. Overrides
inherited method. Note to observers: this class delegates Observable operations
so notices will come from the delegate, not the memory object.
Overrides:
addObserver in class Observable
Parameters:
obs – the observer
addObserver
public void addObserver(Observer obs,
int addr)
throws AddressErrorException
Method to accept registration from observer for specific address. This includes
the memory word starting at the given address. Note to observers: this class delegates Observable operations
so notices will come from the delegate, not the memory object.
Parameters:
obs – the observer
addr – the memory address which must be on word boundary
Throws:
AddressErrorException
addObserver
public void addObserver(Observer obs,
int startAddr,
int endAddr)
throws AddressErrorException
Method to accept registration from observer for specific address range. The
last byte included in the address range is the last byte of the word specified
by the ending address. Note to observers: this class delegates Observable operations
so notices will come from the delegate, not the memory object.
Parameters:
obs – the observer
startAddr – the low end of memory address range, must be on word boundary
endAddr – the high end of memory address range, must be on word boundary
Throws:
AddressErrorException
countObservers
public int countObservers()
Return number of observers
Overrides:
countObservers in class Observable
deleteObserver
public void deleteObserver(Observer obs)
Remove specified memory observers
Overrides:
deleteObserver in class Observable
Parameters:
obs – Observer to be removed
deleteObservers
public void deleteObservers()
Remove all memory observers
Overrides:
deleteObservers in class Observable
notifyObservers
public void notifyObservers()
Overridden to be unavailable. The notice that an Observer
receives does not come from the memory object itself, but
instead from a delegate.
Overrides:
notifyObservers in class Observable
Throws:
UnsupportedOperationException
notifyObservers
public void notifyObservers(Object obj)
Overridden to be unavailable. The notice that an Observer
receives does not come from the memory object itself, but
instead from a delegate.
Overrides:
notifyObservers in class Observable
Throws:
UnsupportedOperationException
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
RegisterAccessNotice
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class RegisterAccessNotice
java.lang.Object
mars.mips.hardware.AccessNotice
mars.mips.hardware.RegisterAccessNotice
public class RegisterAccessNotice
extends AccessNotice
Object provided to Observers of runtime access to MIPS register.
Observer can get the access type (R/W) and register number.
Author:
Pete Sanderson
Field Summary
Fields inherited from class mars.mips.hardware.AccessNotice
READ, WRITE
Method Summary
String getRegisterName()
Fetch the register number of register accessed.
String toString()
String representation indicates access type and which register
Methods inherited from class mars.mips.hardware.AccessNotice
accessIsFromGUI, accessIsFromMIPS, getAccessType, getThread
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Method Detail
getRegisterName
public String getRegisterName()
Fetch the register number of register accessed.
toString
public String toString()
String representation indicates access type and which register
Overrides:
toString in class Object
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.mips.hardware
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object mars.mips.hardware.AccessNotice mars.mips.hardware.MemoryAccessNotice
mars.mips.hardware.RegisterAccessNotice
mars.mips.hardware.Coprocessor0
mars.mips.hardware.Coprocessor1
mars.mips.hardware.MemoryConfiguration
mars.mips.hardware.MemoryConfigurations
java.util.Observable mars.mips.hardware.Memory
mars.mips.hardware.Register
mars.mips.hardware.RegisterFile
java.lang.Throwable (implements java.io.Serializable)
java.lang.Exception mars.mips.hardware.AddressErrorException
mars.mips.hardware.InvalidRegisterAccessException
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
RegisterFile
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.hardware
Class RegisterFile
java.lang.Object
mars.mips.hardware.RegisterFile
public class RegisterFile
extends Object
Represents the collection of MIPS registers.
Author:
Jason Bumgarner, Jason Shrewsbury
Field Summary
static int GLOBAL_POINTER_REGISTER
static int STACK_POINTER_REGISTER
Constructor Summary
RegisterFile()
Method Summary
static void addRegistersObserver(Observer observer)
Each individual register is a separate object and Observable.
static void deleteRegistersObserver(Observer observer)
Each individual register is a separate object and Observable.
static int getInitialProgramCounter()
For returning the program counter’s initial (reset) value.
static int getNumber(String n)
For getting the number representation of the register.
static int getProgramCounter()
For returning the program counters value.
static Register getProgramCounterRegister()
Returns Register object for program counter.
static Register[] getRegisters()
For returning the set of registers.
static Register getUserRegister(String Rname)
Get register object corresponding to given name.
static int getValue(int num)
Returns the value of the register who’s number is num.
static void incrementPC()
Method to increment the Program counter in the general case (not a jump or branch).
static void initializeProgramCounter(boolean startAtMain)
Will initialize the Program Counter to either the default reset value, or the address
associated with source program global label “main”, if it exists as a text segment label
and the global setting is set.
static void initializeProgramCounter(int value)
For initializing the Program Counter.
static void resetRegisters()
Method to reinitialize the values of the registers.
static int setProgramCounter(int value)
For setting the Program Counter.
static void showRegisters()
Method for displaying the register values for debugging.
static int updateRegister(int num,
int val)
This method updates the register value who’s number is num.
static void updateRegister(String reg,
int val)
Sets the value of the register given to the value given.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
GLOBAL_POINTER_REGISTER
public static final int GLOBAL_POINTER_REGISTER
See Also:
Constant Field Values
STACK_POINTER_REGISTER
public static final int STACK_POINTER_REGISTER
See Also:
Constant Field Values
Constructor Detail
RegisterFile
public RegisterFile()
Method Detail
showRegisters
public static void showRegisters()
Method for displaying the register values for debugging.
updateRegister
public static int updateRegister(int num,
int val)
This method updates the register value who’s number is num. Also handles the lo and hi registers
Parameters:
num – Register to set the value of.
val – The desired value for the register.
updateRegister
public static void updateRegister(String reg,
int val)
Sets the value of the register given to the value given.
Parameters:
reg – Name of register to set the value of.
val – The desired value for the register.
getValue
public static int getValue(int num)
Returns the value of the register who’s number is num.
Parameters:
num – The register number.
Returns:
The value of the given register.
getNumber
public static int getNumber(String n)
For getting the number representation of the register.
Parameters:
n – The string formatted register name to look for.
Returns:
The number of the register represented by the string
or -1 if no match.
getRegisters
public static Register[] getRegisters()
For returning the set of registers.
Returns:
The set of registers.
getUserRegister
public static Register getUserRegister(String Rname)
Get register object corresponding to given name. If no match, return null.
Parameters:
Rname – The register name, either in $0 or $zero format.
Returns:
The register object,or null if not found.
initializeProgramCounter
public static void initializeProgramCounter(int value)
For initializing the Program Counter. Do not use this to implement jumps and
branches, as it will NOT record a backstep entry with the restore value.
If you need backstepping capability, use setProgramCounter instead.
Parameters:
value – The value to set the Program Counter to.
initializeProgramCounter
public static void initializeProgramCounter(boolean startAtMain)
Will initialize the Program Counter to either the default reset value, or the address
associated with source program global label “main”, if it exists as a text segment label
and the global setting is set.
Parameters:
startAtMain – If true, will set program counter to address of statement labeled
‘main’ (or other defined start label) if defined. If not defined, or if parameter false,
will set program counter to default reset value.
setProgramCounter
public static int setProgramCounter(int value)
For setting the Program Counter. Note that ordinary PC update should be done using
incrementPC() method. Use this only when processing jumps and branches.
Parameters:
value – The value to set the Program Counter to.
Returns:
previous PC value
getProgramCounter
public static int getProgramCounter()
For returning the program counters value.
Returns:
The program counters value as an int.
getProgramCounterRegister
public static Register getProgramCounterRegister()
Returns Register object for program counter. Use with caution.
Returns:
program counter’s Register object.
getInitialProgramCounter
public static int getInitialProgramCounter()
For returning the program counter’s initial (reset) value.
Returns:
The program counter’s initial value
resetRegisters
public static void resetRegisters()
Method to reinitialize the values of the registers.
NOTE: Should not be called from command-mode MARS because this
this method uses global settings from the registry. Command-mode must operate
using only the command switches, not registry settings. It can be called
from tools running stand-alone, and this is done in
AbstractMarsToolAndApplication.
incrementPC
public static void incrementPC()
Method to increment the Program counter in the general case (not a jump or branch).
addRegistersObserver
public static void addRegistersObserver(Observer observer)
Each individual register is a separate object and Observable. This handy method
will add the given Observer to each one. Currently does not apply to Program
Counter.
deleteRegistersObserver
public static void deleteRegistersObserver(Observer observer)
Each individual register is a separate object and Observable. This handy method
will delete the given Observer from each one. Currently does not apply to Program
Counter.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
AsciiTextDumpFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Class AsciiTextDumpFormat
java.lang.Object
mars.mips.dump.AbstractDumpFormat
mars.mips.dump.AsciiTextDumpFormat
All Implemented Interfaces:
DumpFormat
public class AsciiTextDumpFormat
extends AbstractDumpFormat
Class that represents the “ASCII text” memory dump format. Memory contents
are interpreted as ASCII codes. The output
is a text file with one word of MIPS memory per line. The word is formatted
to leave three spaces for each character. Non-printing characters
rendered as period (.) as placeholder. Common escaped characters
rendered using backslash and single-character descriptor, e.g. \t for tab.
Author:
Pete Sanderson
Constructor Summary
AsciiTextDumpFormat()
Constructor.
Method Summary
void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
Interpret MIPS memory contents as ASCII characters.
Methods inherited from class mars.mips.dump.AbstractDumpFormat
getCommandDescriptor, getDescription, getFileExtension, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
AsciiTextDumpFormat
public AsciiTextDumpFormat()
Constructor. There is no standard file extension for this format.
Method Detail
dumpMemoryRange
public void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
throws AddressErrorException,
IOException
Interpret MIPS memory contents as ASCII characters. Each line of
text contains one memory word written in ASCII characters. Those
corresponding to tab, newline, null, etc are rendered as backslash
followed by single-character code, e.g. \t for tab, \0 for null.
Non-printing character (control code,
values above 127) is rendered as a period (.). Written
using PrintStream’s println() method.
Adapted by Pete Sanderson from code written by Greg Gibeling.
Specified by:
dumpMemoryRange in interface DumpFormat
Specified by:
dumpMemoryRange in class AbstractDumpFormat
Parameters:
file – File in which to store MIPS memory contents.
firstAddress – first (lowest) memory address to dump. In bytes but
must be on word boundary.
lastAddress – last (highest) memory address to dump. In bytes but
must be on word boundary. Will dump the word that starts at this address.
Throws:
AddressErrorException – if firstAddress is invalid or not on a word boundary.
IOException – if error occurs during file output.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
BinaryTextDumpFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Class BinaryTextDumpFormat
java.lang.Object
mars.mips.dump.AbstractDumpFormat
mars.mips.dump.BinaryTextDumpFormat
All Implemented Interfaces:
DumpFormat
public class BinaryTextDumpFormat
extends AbstractDumpFormat
Class that represents the “binary text” memory dump format. The output
is a text file with one word of MIPS memory per line. The word is formatted
using ‘0’ and ‘1’ characters, e.g. 01110101110000011111110101010011.
Author:
Pete Sanderson
Constructor Summary
BinaryTextDumpFormat()
Constructor.
Method Summary
void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
Write MIPS memory contents in binary text format.
Methods inherited from class mars.mips.dump.AbstractDumpFormat
getCommandDescriptor, getDescription, getFileExtension, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
BinaryTextDumpFormat
public BinaryTextDumpFormat()
Constructor. There is no standard file extension for this format.
Method Detail
dumpMemoryRange
public void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
throws AddressErrorException,
IOException
Write MIPS memory contents in binary text format. Each line of
text contains one memory word written as 32 ‘0’ and ‘1’ characters. Written
using PrintStream’s println() method.
Adapted by Pete Sanderson from code written by Greg Gibeling.
Specified by:
dumpMemoryRange in interface DumpFormat
Specified by:
dumpMemoryRange in class AbstractDumpFormat
Parameters:
file – File in which to store MIPS memory contents.
firstAddress – first (lowest) memory address to dump. In bytes but
must be on word boundary.
lastAddress – last (highest) memory address to dump. In bytes but
must be on word boundary. Will dump the word that starts at this address.
Throws:
AddressErrorException – if firstAddress is invalid or not on a word boundary.
IOException – if error occurs during file output.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MIFDumpFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Class MIFDumpFormat
java.lang.Object
mars.mips.dump.MIFDumpFormat
public class MIFDumpFormat
extends Object
The Memory Initialization File (.mif) VHDL-supported file format
This is documented for the Altera platform at
www.altera.com/support/software/nativelink/quartus2/glossary/def_mif.html.
Author:
Pete Sanderson
Constructor Summary
MIFDumpFormat()
Constructor.
Method Summary
void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
Write MIPS memory contents according to the Memory Initialization File
(MIF) specification.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
MIFDumpFormat
public MIFDumpFormat()
Constructor. File extention is “mif”.
Method Detail
dumpMemoryRange
public void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
throws AddressErrorException,
IOException
Write MIPS memory contents according to the Memory Initialization File
(MIF) specification.
Parameters:
file – File in which to store MIPS memory contents.
firstAddress – first (lowest) memory address to dump. In bytes but
must be on word boundary.
lastAddress – last (highest) memory address to dump. In bytes but
must be on word boundary. Will dump the word that starts at this address.
Throws:
AddressErrorException – if firstAddress is invalid or not on a word boundary.
IOException – if error occurs during file output.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DumpFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Interface DumpFormat
All Known Implementing Classes:
AbstractDumpFormat, AsciiTextDumpFormat, BinaryDumpFormat, BinaryTextDumpFormat, HexTextDumpFormat, IntelHexDumpFormat, SegmentWindowDumpFormat
public interface DumpFormat
Interface for memory dump file formats. All MARS needs to be able
to do is save an assembled program or data in the specified manner for
a given format. Formats are specified through classes
that implement this interface.
Author:
Pete Sanderson
Method Summary
void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
Write MIPS memory contents according to the
specification for this format.
String getCommandDescriptor()
A short one-word descriptor that will be used by the MARS
command line parser (and the MARS command line user) to specify
that this format is to be used.
String getDescription()
Get a short description of the format, suitable
for displaying along with the extension, if any, in the file
save dialog and also for displaying as a tool tip.
String getFileExtension()
Get the file extension associated with this format.
String toString()
Descriptive name for the format.
Method Detail
getFileExtension
String getFileExtension()
Get the file extension associated with this format.
Returns:
String containing file extension — without the leading “.” — or
null if there is no standard extension.
getDescription
String getDescription()
Get a short description of the format, suitable
for displaying along with the extension, if any, in the file
save dialog and also for displaying as a tool tip.
Returns:
String containing short description to go with the extension
or as tool tip when mouse hovers over GUI component representing
this format.
getCommandDescriptor
String getCommandDescriptor()
A short one-word descriptor that will be used by the MARS
command line parser (and the MARS command line user) to specify
that this format is to be used.
toString
String toString()
Descriptive name for the format.
Overrides:
toString in class Object
Returns:
Format name.
dumpMemoryRange
void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
throws AddressErrorException,
IOException
Write MIPS memory contents according to the
specification for this format.
Parameters:
file – File in which to store MIPS memory contents.
firstAddress – first (lowest) memory address to dump. In bytes but
must be on word boundary.
lastAddress – last (highest) memory address to dump. In bytes but
must be on word boundary. Will dump the word that starts at this address.
Throws:
AddressErrorException – if firstAddress is invalid or not on a word boundary.
IOException – if error occurs during file output.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
mars.mips.dump
Interfaces
DumpFormat
Classes
AbstractDumpFormat
AsciiTextDumpFormat
BinaryDumpFormat
BinaryTextDumpFormat
DumpFormatLoader
HexTextDumpFormat
IntelHexDumpFormat
MIFDumpFormat
SegmentWindowDumpFormat
SegmentWindowDumpFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Class SegmentWindowDumpFormat
java.lang.Object
mars.mips.dump.AbstractDumpFormat
mars.mips.dump.SegmentWindowDumpFormat
All Implemented Interfaces:
DumpFormat
public class SegmentWindowDumpFormat
extends AbstractDumpFormat
Dump MIPS memory contents in Segment Window format. Each line of
text output resembles the Text Segment Window or Data Segment Window
depending on which segment is selected for the dump. Written
using PrintStream’s println() method. Each line of Text Segment
Window represents one word of text segment memory. The line
includes (1) address, (2) machine code in hex, (3) basic instruction,
(4) source line. Each line of Data Segment Window represents 8
words of data segment memory. The line includes address of first
word for that line followed by 8 32-bit values.
In either case, addresses and values are displayed in decimal or
hexadecimal representation according to the corresponding settings.
Author:
Pete Sanderson
Constructor Summary
SegmentWindowDumpFormat()
Constructor.
Method Summary
void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
Write MIPS memory contents in Segment Window format.
Methods inherited from class mars.mips.dump.AbstractDumpFormat
getCommandDescriptor, getDescription, getFileExtension, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
SegmentWindowDumpFormat
public SegmentWindowDumpFormat()
Constructor. There is no standard file extension for this format.
Method Detail
dumpMemoryRange
public void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
throws AddressErrorException,
IOException
Write MIPS memory contents in Segment Window format. Each line of
text output resembles the Text Segment Window or Data Segment Window
depending on which segment is selected for the dump. Written
using PrintStream’s println() method.
Specified by:
dumpMemoryRange in interface DumpFormat
Specified by:
dumpMemoryRange in class AbstractDumpFormat
Parameters:
file – File in which to store MIPS memory contents.
firstAddress – first (lowest) memory address to dump. In bytes but
must be on word boundary.
lastAddress – last (highest) memory address to dump. In bytes but
must be on word boundary. Will dump the word that starts at this address.
Throws:
AddressErrorException – if firstAddress is invalid or not on a word boundary.
IOException – if error occurs during file output.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
DumpFormatLoader
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Class DumpFormatLoader
java.lang.Object
mars.mips.dump.DumpFormatLoader
public class DumpFormatLoader
extends Object
Constructor Summary
DumpFormatLoader()
Method Summary
static DumpFormat findDumpFormatGivenCommandDescriptor(ArrayList formatList,
String formatCommandDescriptor)
ArrayList loadDumpFormats()
Dynamically loads dump formats into an ArrayList.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
DumpFormatLoader
public DumpFormatLoader()
Method Detail
loadDumpFormats
public ArrayList loadDumpFormats()
Dynamically loads dump formats into an ArrayList. This method is adapted from
the loadGameControllers() method in Bret Barker’s GameServer class.
Barker (bret@hypefiend.com) is co-author of the book “Developing Games
in Java”. Also see the ToolLoader and SyscallLoader classes elsewhere in MARS.
findDumpFormatGivenCommandDescriptor
public static DumpFormat findDumpFormatGivenCommandDescriptor(ArrayList formatList,
String formatCommandDescriptor)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.mips.dump
Interface Summary
DumpFormat Interface for memory dump file formats.
Class Summary
AbstractDumpFormat Abstract class for memory dump file formats.
AsciiTextDumpFormat Class that represents the “ASCII text” memory dump format.
BinaryDumpFormat Class that represents the “binary” memory dump format.
BinaryTextDumpFormat Class that represents the “binary text” memory dump format.
DumpFormatLoader
HexTextDumpFormat Class that represents the “hexadecimal text” memory dump format.
IntelHexDumpFormat Intel’s Hex memory initialization format
MIFDumpFormat The Memory Initialization File (.mif) VHDL-supported file format
This is documented for the Altera platform at
www.altera.com/support/software/nativelink/quartus2/glossary/def_mif.html.
SegmentWindowDumpFormat Dump MIPS memory contents in Segment Window format.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
mars.mips.dump Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.mips.dump
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object mars.mips.dump.AbstractDumpFormat (implements mars.mips.dump.DumpFormat)
mars.mips.dump.AsciiTextDumpFormat
mars.mips.dump.BinaryDumpFormat
mars.mips.dump.BinaryTextDumpFormat
mars.mips.dump.HexTextDumpFormat
mars.mips.dump.IntelHexDumpFormat
mars.mips.dump.SegmentWindowDumpFormat
mars.mips.dump.DumpFormatLoader
mars.mips.dump.MIFDumpFormat
Interface Hierarchy
mars.mips.dump.DumpFormat
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
AbstractDumpFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Class AbstractDumpFormat
java.lang.Object
mars.mips.dump.AbstractDumpFormat
All Implemented Interfaces:
DumpFormat
Direct Known Subclasses:
AsciiTextDumpFormat, BinaryDumpFormat, BinaryTextDumpFormat, HexTextDumpFormat, IntelHexDumpFormat, SegmentWindowDumpFormat
public abstract class AbstractDumpFormat
extends Object
implements DumpFormat
Abstract class for memory dump file formats. Provides constructors and
defaults for everything except the dumpMemoryRange method itself.
Author:
Pete Sanderson
Constructor Summary
AbstractDumpFormat(String name,
String commandDescriptor,
String description,
String extension)
Typical constructor.
Method Summary
abstract void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
Write MIPS memory contents according to the
specification for this format.
String getCommandDescriptor()
One-word description of format to be used by MARS command mode parser
and user in conjunction with the “dump” option.
String getDescription()
Get a short description of the format, suitable for displaying along with
the extension, in the file save dialog, or as a tool tip.
String getFileExtension()
Get the file extension associated with this format.
String toString()
String representing this object.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
AbstractDumpFormat
public AbstractDumpFormat(String name,
String commandDescriptor,
String description,
String extension)
Typical constructor. Note you cannot creates objects from this
class but subclass constructor can call this one.
Parameters:
name – Brief descriptive name to be displayed in selection list.
commandDescriptor – One-word descriptive name to be used by MARS command mode parser and user.
Any spaces in this string will be removed.
description – Description to go with standard file extension for
display in file save dialog or to be used as tool tip.
extension – Standard file extension for this format. Null if none.
Method Detail
getFileExtension
public String getFileExtension()
Get the file extension associated with this format.
Specified by:
getFileExtension in interface DumpFormat
Returns:
String containing file extension — without the leading “.” — or
null if there is no standard extension.
getDescription
public String getDescription()
Get a short description of the format, suitable for displaying along with
the extension, in the file save dialog, or as a tool tip.
Specified by:
getDescription in interface DumpFormat
Returns:
String containing short description to go with the extension
or for use as tool tip. Possibly null.
toString
public String toString()
String representing this object.
Specified by:
toString in interface DumpFormat
Overrides:
toString in class Object
Returns:
Name given for this object.
getCommandDescriptor
public String getCommandDescriptor()
One-word description of format to be used by MARS command mode parser
and user in conjunction with the “dump” option.
Specified by:
getCommandDescriptor in interface DumpFormat
Returns:
One-word String describing the format.
dumpMemoryRange
public abstract void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
throws AddressErrorException,
IOException
Write MIPS memory contents according to the
specification for this format.
Specified by:
dumpMemoryRange in interface DumpFormat
Parameters:
file – File in which to store MIPS memory contents.
firstAddress – first (lowest) memory address to dump. In bytes but
must be on word boundary.
lastAddress – last (highest) memory address to dump. In bytes but
must be on word boundary. Will dump the word that starts at this address.
Throws:
AddressErrorException – if firstAddress is invalid or not on a word boundary.
IOException – if error occurs during file output.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
BinaryDumpFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Class BinaryDumpFormat
java.lang.Object
mars.mips.dump.AbstractDumpFormat
mars.mips.dump.BinaryDumpFormat
All Implemented Interfaces:
DumpFormat
public class BinaryDumpFormat
extends AbstractDumpFormat
Class that represents the “binary” memory dump format. The output
is a binary file containing the memory words as a byte stream. Output
is produced using PrintStream’s write() method.
Author:
Pete Sanderson
Constructor Summary
BinaryDumpFormat()
Constructor.
Method Summary
void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
Write MIPS memory contents in pure binary format.
Methods inherited from class mars.mips.dump.AbstractDumpFormat
getCommandDescriptor, getDescription, getFileExtension, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
BinaryDumpFormat
public BinaryDumpFormat()
Constructor. There is no standard file extension for this format.
Method Detail
dumpMemoryRange
public void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
throws AddressErrorException,
IOException
Write MIPS memory contents in pure binary format. One byte at a time
using PrintStream’s write() method. Adapted by Pete Sanderson from
code written by Greg Gibeling.
Specified by:
dumpMemoryRange in interface DumpFormat
Specified by:
dumpMemoryRange in class AbstractDumpFormat
Parameters:
file – File in which to store MIPS memory contents.
firstAddress – first (lowest) memory address to dump. In bytes but
must be on word boundary.
lastAddress – last (highest) memory address to dump. In bytes but
must be on word boundary. Will dump the word that starts at this address.
Throws:
AddressErrorException – if firstAddress is invalid or not on a word boundary.
IOException – if error occurs during file output.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
HexTextDumpFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Class HexTextDumpFormat
java.lang.Object
mars.mips.dump.AbstractDumpFormat
mars.mips.dump.HexTextDumpFormat
All Implemented Interfaces:
DumpFormat
public class HexTextDumpFormat
extends AbstractDumpFormat
Class that represents the “hexadecimal text” memory dump format. The output
is a text file with one word of MIPS memory per line. The word is formatted
using hexadecimal characters, e.g. 3F205A39.
Author:
Pete Sanderson
Constructor Summary
HexTextDumpFormat()
Constructor.
Method Summary
void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
Write MIPS memory contents in hexadecimal text format.
Methods inherited from class mars.mips.dump.AbstractDumpFormat
getCommandDescriptor, getDescription, getFileExtension, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
HexTextDumpFormat
public HexTextDumpFormat()
Constructor. There is no standard file extension for this format.
Method Detail
dumpMemoryRange
public void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
throws AddressErrorException,
IOException
Write MIPS memory contents in hexadecimal text format. Each line of
text contains one memory word written in hexadecimal characters. Written
using PrintStream’s println() method.
Adapted by Pete Sanderson from code written by Greg Gibeling.
Specified by:
dumpMemoryRange in interface DumpFormat
Specified by:
dumpMemoryRange in class AbstractDumpFormat
Parameters:
file – File in which to store MIPS memory contents.
firstAddress – first (lowest) memory address to dump. In bytes but
must be on word boundary.
lastAddress – last (highest) memory address to dump. In bytes but
must be on word boundary. Will dump the word that starts at this address.
Throws:
AddressErrorException – if firstAddress is invalid or not on a word boundary.
IOException – if error occurs during file output.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
IntelHexDumpFormat
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.mips.dump
Class IntelHexDumpFormat
java.lang.Object
mars.mips.dump.AbstractDumpFormat
mars.mips.dump.IntelHexDumpFormat
All Implemented Interfaces:
DumpFormat
public class IntelHexDumpFormat
extends AbstractDumpFormat
Intel’s Hex memory initialization format
Author:
Leo Alterman
Constructor Summary
IntelHexDumpFormat()
Constructor.
Method Summary
void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
Write MIPS memory contents according to the Memory Initialization File
(MIF) specification.
Methods inherited from class mars.mips.dump.AbstractDumpFormat
getCommandDescriptor, getDescription, getFileExtension, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
IntelHexDumpFormat
public IntelHexDumpFormat()
Constructor. File extention is “hex”.
Method Detail
dumpMemoryRange
public void dumpMemoryRange(File file,
int firstAddress,
int lastAddress)
throws AddressErrorException,
IOException
Write MIPS memory contents according to the Memory Initialization File
(MIF) specification.
Specified by:
dumpMemoryRange in interface DumpFormat
Specified by:
dumpMemoryRange in class AbstractDumpFormat
Parameters:
file – File in which to store MIPS memory contents.
firstAddress – first (lowest) memory address to dump. In bytes but
must be on word boundary.
lastAddress – last (highest) memory address to dump. In bytes but
must be on word boundary. Will dump the word that starts at this address.
Throws:
AddressErrorException – if firstAddress is invalid or not on a word boundary.
IOException – if error occurs during file output.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
mars
Classes
ErrorList
ErrorMessage
Globals
MarsLaunch
MarsSplashScreen
MIPSprogram
ProgramStatement
Settings
Exceptions
ProcessingException
ErrorMessage
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
Class ErrorMessage
java.lang.Object
mars.ErrorMessage
public class ErrorMessage
extends Object
Represents occurrance of an error detected during tokenizing, assembly or simulation.
Author:
Pete Sanderson
Field Summary
static boolean ERROR
Constant to indicate this message is error not warning
static boolean WARNING
Constant to indicate this message is warning not error
Constructor Summary
ErrorMessage(boolean isWarning,
MIPSprogram sourceMIPSprogram,
int line,
int position,
String message)
Constructor for ErrorMessage.
ErrorMessage(boolean isWarning,
String filename,
int line,
int position,
String message,
String macroExpansionHistory)
Deprecated. Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
ErrorMessage(MIPSprogram sourceMIPSprogram,
int line,
int position,
String message)
Constructor for ErrorMessage.
ErrorMessage(ProgramStatement statement,
String message)
Constructor for ErrorMessage, to be used for runtime exceptions.
ErrorMessage(String filename,
int line,
int position,
String message)
Deprecated. Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
ErrorMessage(String filename,
int line,
int position,
String message,
String macroExpansionHistory)
Deprecated. Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
Method Summary
String getFilename()
Produce name of file containing error.
int getLine()
Produce line number of error.
String getMacroExpansionHistory()
Returns string describing macro expansion.
String getMessage()
Produce error message.
int getPosition()
Produce position within erroneous line.
boolean isWarning()
Determine whether this message represents error or warning.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
WARNING
public static final boolean WARNING
Constant to indicate this message is warning not error
See Also:
Constant Field Values
ERROR
public static final boolean ERROR
Constant to indicate this message is error not warning
See Also:
Constant Field Values
Constructor Detail
ErrorMessage
@Deprecated
public ErrorMessage(String filename,
int line,
int position,
String message)
Deprecated. Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
Constructor for ErrorMessage.
Parameters:
filename – String containing name of source file in which this error appears.
line – Line number in source program being processed when error occurred.
position – Position within line being processed when error occurred. Normally is starting
position of source token.
message – String containing appropriate error message.
ErrorMessage
@Deprecated
public ErrorMessage(String filename,
int line,
int position,
String message,
String macroExpansionHistory)
Deprecated. Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
Constructor for ErrorMessage.
Parameters:
filename – String containing name of source file in which this error appears.
line – Line number in source program being processed when error occurred.
position – Position within line being processed when error occurred. Normally is starting
position of source token.
message – String containing appropriate error message.
macroExpansionHistory –
ErrorMessage
@Deprecated
public ErrorMessage(boolean isWarning,
String filename,
int line,
int position,
String message,
String macroExpansionHistory)
Deprecated. Newer constructors replace the String filename parameter with a MIPSprogram parameter to provide more information.
Constructor for ErrorMessage.
Parameters:
isWarning – set to WARNING if message is a warning not error, else set to ERROR or omit.
filename – String containing name of source file in which this error appears.
line – Line number in source program being processed when error occurred.
position – Position within line being processed when error occurred. Normally is starting
position of source token.
message – String containing appropriate error message.
macroExpansionHistory – provided so message for macro can include both definition and usage line numbers
ErrorMessage
public ErrorMessage(MIPSprogram sourceMIPSprogram,
int line,
int position,
String message)
Constructor for ErrorMessage. Assumes line number is calculated after any .include files expanded, and
if there were, it will adjust filename and line number so message reflects original file and line number.
Parameters:
sourceMIPSprogram – MIPSprogram object of source file in which this error appears.
line – Line number in source program being processed when error occurred.
position – Position within line being processed when error occurred. Normally is starting
position of source token.
message – String containing appropriate error message.
ErrorMessage
public ErrorMessage(boolean isWarning,
MIPSprogram sourceMIPSprogram,
int line,
int position,
String message)
Constructor for ErrorMessage. Assumes line number is calculated after any .include files expanded, and
if there were, it will adjust filename and line number so message reflects original file and line number.
Parameters:
isWarning – set to WARNING if message is a warning not error, else set to ERROR or omit.
sourceMIPSprogram – MIPSprogram object of source file in which this error appears.
line – Line number in source program being processed when error occurred.
position – Position within line being processed when error occurred. Normally is starting
position of source token.
message – String containing appropriate error message.
ErrorMessage
public ErrorMessage(ProgramStatement statement,
String message)
Constructor for ErrorMessage, to be used for runtime exceptions.
Parameters:
statement – The ProgramStatement object for the instruction causing the runtime error
message – String containing appropriate error message.
Method Detail
getFilename
public String getFilename()
Produce name of file containing error.
Returns:
Returns String containing name of source file containing the error.
getLine
public int getLine()
Produce line number of error.
Returns:
Returns line number in source program where error occurred.
getPosition
public int getPosition()
Produce position within erroneous line.
Returns:
Returns position within line of source program where error occurred.
getMessage
public String getMessage()
Produce error message.
Returns:
Returns String containing textual error message.
isWarning
public boolean isWarning()
Determine whether this message represents error or warning.
Returns:
Returns true if this message reflects warning, false if error.
getMacroExpansionHistory
public String getMacroExpansionHistory()
Returns string describing macro expansion. Empty string if none.
Returns:
string describing macro expansion
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
BackStepper
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator
Class BackStepper
java.lang.Object
mars.simulator.BackStepper
public class BackStepper
extends Object
Used to “step backward” through execution, undoing each instruction.
Author:
Pete Sanderson
Constructor Summary
BackStepper()
Create a fresh BackStepper.
Method Summary
int addConditionFlagClear(int flag)
Add a new “back step” (the undo action) to the stack.
int addConditionFlagSet(int flag)
Add a new “back step” (the undo action) to the stack.
int addCoprocessor0Restore(int register,
int value)
Add a new “back step” (the undo action) to the stack.
int addCoprocessor1Restore(int register,
int value)
Add a new “back step” (the undo action) to the stack.
int addDoNothing(int pc)
Add a new “back step” (the undo action) to the stack.
int addMemoryRestoreByte(int address,
int value)
Add a new “back step” (the undo action) to the stack.
int addMemoryRestoreHalf(int address,
int value)
Add a new “back step” (the undo action) to the stack.
int addMemoryRestoreRawWord(int address,
int value)
Add a new “back step” (the undo action) to the stack.
int addMemoryRestoreWord(int address,
int value)
Add a new “back step” (the undo action) to the stack.
int addPCRestore(int value)
Add a new “back step” (the undo action) to the stack.
int addRegisterFileRestore(int register,
int value)
Add a new “back step” (the undo action) to the stack.
void backStep()
Carry out a “back step”, which will undo the latest execution step.
boolean empty()
Test whether there are steps that can be undone.
boolean enabled()
Determine whether execution “undo” steps are currently being recorded.
boolean inDelaySlot()
Determine whether the next back-step action occurred as the result of
an instruction that executed in the “delay slot” of a delayed branch.
void setEnabled(boolean state)
Set enable status.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
BackStepper
public BackStepper()
Create a fresh BackStepper. It is enabled, which means all
subsequent instruction executions will have their “undo” action
recorded here.
Method Detail
enabled
public boolean enabled()
Determine whether execution “undo” steps are currently being recorded.
Returns:
true if undo steps being recorded, false if not.
setEnabled
public void setEnabled(boolean state)
Set enable status.
Parameters:
state – If true, will begin (or continue) recoding “undo” steps. If false, will stop.
empty
public boolean empty()
Test whether there are steps that can be undone.
Returns:
true if there are no steps to be undone, false otherwise.
inDelaySlot
public boolean inDelaySlot()
Determine whether the next back-step action occurred as the result of
an instruction that executed in the “delay slot” of a delayed branch.
Returns:
true if next backstep is instruction that executed in delay slot,
false otherwise.
backStep
public void backStep()
Carry out a “back step”, which will undo the latest execution step.
Does nothing if backstepping not enabled or if there are no steps to undo.
addMemoryRestoreRawWord
public int addMemoryRestoreRawWord(int address,
int value)
Add a new “back step” (the undo action) to the stack. The action here
is to restore a raw memory word value (setRawWord).
Parameters:
address – The affected memory address.
value – The “restore” value to be stored there.
Returns:
the argument value
addMemoryRestoreWord
public int addMemoryRestoreWord(int address,
int value)
Add a new “back step” (the undo action) to the stack. The action here
is to restore a memory word value.
Parameters:
address – The affected memory address.
value – The “restore” value to be stored there.
Returns:
the argument value
addMemoryRestoreHalf
public int addMemoryRestoreHalf(int address,
int value)
Add a new “back step” (the undo action) to the stack. The action here
is to restore a memory half-word value.
Parameters:
address – The affected memory address.
value – The “restore” value to be stored there, in low order half.
Returns:
the argument value
addMemoryRestoreByte
public int addMemoryRestoreByte(int address,
int value)
Add a new “back step” (the undo action) to the stack. The action here
is to restore a memory byte value.
Parameters:
address – The affected memory address.
value – The “restore” value to be stored there, in low order byte.
Returns:
the argument value
addRegisterFileRestore
public int addRegisterFileRestore(int register,
int value)
Add a new “back step” (the undo action) to the stack. The action here
is to restore a register file register value.
Parameters:
register – The affected register number.
value – The “restore” value to be stored there.
Returns:
the argument value
addPCRestore
public int addPCRestore(int value)
Add a new “back step” (the undo action) to the stack. The action here
is to restore the program counter.
Parameters:
value – The “restore” value to be stored there.
Returns:
the argument value
addCoprocessor0Restore
public int addCoprocessor0Restore(int register,
int value)
Add a new “back step” (the undo action) to the stack. The action here
is to restore a coprocessor 0 register value.
Parameters:
register – The affected register number.
value – The “restore” value to be stored there.
Returns:
the argument value
addCoprocessor1Restore
public int addCoprocessor1Restore(int register,
int value)
Add a new “back step” (the undo action) to the stack. The action here
is to restore a coprocessor 1 register value.
Parameters:
register – The affected register number.
value – The “restore” value to be stored there.
Returns:
the argument value
addConditionFlagSet
public int addConditionFlagSet(int flag)
Add a new “back step” (the undo action) to the stack. The action here
is to set the given coprocessor 1 condition flag (to 1).
Parameters:
flag – The condition flag number.
Returns:
the argument value
addConditionFlagClear
public int addConditionFlagClear(int flag)
Add a new “back step” (the undo action) to the stack. The action here
is to clear the given coprocessor 1 condition flag (to 0).
Parameters:
flag – The condition flag number.
Returns:
the argument value
addDoNothing
public int addDoNothing(int pc)
Add a new “back step” (the undo action) to the stack. The action here
is to do nothing! This is just a place holder so when user is backstepping
through the program no instructions will be skipped. Cosmetic. If the top of the
stack has the same PC counter, the do-nothing action will not be added.
Returns:
0
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Exceptions
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator
Class Exceptions
java.lang.Object
mars.simulator.Exceptions
public class Exceptions
extends Object
Represents an error/interrupt that occurs during execution (simulation).
Author:
Pete Sanderson
Field Summary
static int ADDRESS_EXCEPTION_LOAD
static int ADDRESS_EXCEPTION_STORE
static int ARITHMETIC_OVERFLOW_EXCEPTION
static int BREAKPOINT_EXCEPTION
static int DIVIDE_BY_ZERO_EXCEPTION
static int EXTERNAL_INTERRUPT_DISPLAY
static int EXTERNAL_INTERRUPT_KEYBOARD
The exception number is stored in coprocessor 0 cause register ($13)
Note: the codes for External Interrupts have been modified from MIPS
specs in order to encode two pieces of information.
static int FLOATING_POINT_OVERFLOW
static int FLOATING_POINT_UNDERFLOW
static int RESERVED_INSTRUCTION_EXCEPTION
static int SYSCALL_EXCEPTION
static int TRAP_EXCEPTION
Constructor Summary
Exceptions()
Method Summary
static void setRegisters(int cause)
Given MIPS exception cause code, will place that code into
coprocessor 0 CAUSE register ($13), set the EPC register to
“current” program counter, and set Exception Level bit in STATUS register.
static void setRegisters(int cause,
int addr)
Given MIPS exception cause code and bad address, place the bad address into VADDR
register ($8) then call overloaded setRegisters with the cause code to do the rest.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
EXTERNAL_INTERRUPT_KEYBOARD
public static final int EXTERNAL_INTERRUPT_KEYBOARD
The exception number is stored in coprocessor 0 cause register ($13)
Note: the codes for External Interrupts have been modified from MIPS
specs in order to encode two pieces of information. According
to spec, there is one External Interrupt code, 0. But then
how to distinguish keyboard interrupt from display interrupt?
The Cause register has Interupt Pending bits that can be set.
Bit 8 represents keyboard, bit 9 represents display. Those
bits are included into this code, but shifted right two positions
since the interrupt code will be shifted left two positions
for inserting cause code into bit positions 2-6 in Cause register.
DPS 23 July 2008.
See Also:
Constant Field Values
EXTERNAL_INTERRUPT_DISPLAY
public static final int EXTERNAL_INTERRUPT_DISPLAY
See Also:
Constant Field Values
ADDRESS_EXCEPTION_LOAD
public static final int ADDRESS_EXCEPTION_LOAD
See Also:
Constant Field Values
ADDRESS_EXCEPTION_STORE
public static final int ADDRESS_EXCEPTION_STORE
See Also:
Constant Field Values
SYSCALL_EXCEPTION
public static final int SYSCALL_EXCEPTION
See Also:
Constant Field Values
BREAKPOINT_EXCEPTION
public static final int BREAKPOINT_EXCEPTION
See Also:
Constant Field Values
RESERVED_INSTRUCTION_EXCEPTION
public static final int RESERVED_INSTRUCTION_EXCEPTION
See Also:
Constant Field Values
ARITHMETIC_OVERFLOW_EXCEPTION
public static final int ARITHMETIC_OVERFLOW_EXCEPTION
See Also:
Constant Field Values
TRAP_EXCEPTION
public static final int TRAP_EXCEPTION
See Also:
Constant Field Values
DIVIDE_BY_ZERO_EXCEPTION
public static final int DIVIDE_BY_ZERO_EXCEPTION
See Also:
Constant Field Values
FLOATING_POINT_OVERFLOW
public static final int FLOATING_POINT_OVERFLOW
See Also:
Constant Field Values
FLOATING_POINT_UNDERFLOW
public static final int FLOATING_POINT_UNDERFLOW
See Also:
Constant Field Values
Constructor Detail
Exceptions
public Exceptions()
Method Detail
setRegisters
public static void setRegisters(int cause)
Given MIPS exception cause code, will place that code into
coprocessor 0 CAUSE register ($13), set the EPC register to
“current” program counter, and set Exception Level bit in STATUS register.
Parameters:
cause – The cause code (see Exceptions for a list)
setRegisters
public static void setRegisters(int cause,
int addr)
Given MIPS exception cause code and bad address, place the bad address into VADDR
register ($8) then call overloaded setRegisters with the cause code to do the rest.
Parameters:
cause – The cause code (see Exceptions for a list). Should be address exception.
addr – The address that caused the exception.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator
mars.simulator
Interfaces
Simulator.StopListener
Classes
BackStepper
DelayedBranch
Exceptions
ProgramArgumentList
Simulator
SimulatorNotice
SwingWorker
Simulator.StopListener
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator
Interface Simulator.StopListener
Enclosing class:
Simulator
public static interface Simulator.StopListener
Method Summary
void stopped(Simulator s)
Method Detail
stopped
void stopped(Simulator s)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Simulator
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator
Class Simulator
java.lang.Object
java.util.Observable
mars.simulator.Simulator
public class Simulator
extends Observable
Used to simulate the execution of an assembled MIPS program.
Author:
Pete Sanderson
Nested Class Summary
static interface Simulator.StopListener
Field Summary
static int BREAKPOINT
various reasons for simulate to end…
static int CLIFF_TERMINATION
static int EXCEPTION
static int externalInterruptingDevice
static int MAX_STEPS
static int NO_DEVICE
static int NORMAL_TERMINATION
static int PAUSE_OR_STOP
Method Summary
void addStopListener(Simulator.StopListener l)
static Simulator getInstance()
Returns the Simulator object
static boolean inDelaySlot()
Determine whether or not the next instruction to be executed is in a
“delay slot”.
void removeStopListener(Simulator.StopListener l)
boolean simulate(MIPSprogram p,
int pc,
int maxSteps,
int[] breakPoints,
AbstractAction actor)
Simulate execution of given MIPS program.
void stopExecution(AbstractAction actor)
Set the volatile stop boolean variable checked by the execution
thread at the end of each MIPS instruction execution.
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
NO_DEVICE
public static final int NO_DEVICE
See Also:
Constant Field Values
externalInterruptingDevice
public static volatile int externalInterruptingDevice
BREAKPOINT
public static final int BREAKPOINT
various reasons for simulate to end…
See Also:
Constant Field Values
EXCEPTION
public static final int EXCEPTION
See Also:
Constant Field Values
MAX_STEPS
public static final int MAX_STEPS
See Also:
Constant Field Values
NORMAL_TERMINATION
public static final int NORMAL_TERMINATION
See Also:
Constant Field Values
CLIFF_TERMINATION
public static final int CLIFF_TERMINATION
See Also:
Constant Field Values
PAUSE_OR_STOP
public static final int PAUSE_OR_STOP
See Also:
Constant Field Values
Method Detail
getInstance
public static Simulator getInstance()
Returns the Simulator object
Returns:
the Simulator object in use
inDelaySlot
public static boolean inDelaySlot()
Determine whether or not the next instruction to be executed is in a
“delay slot”. This means delayed branching is enabled, the branch
condition has evaluated true, and the next instruction executed will
be the one following the branch. It is said to occupy the “delay slot.”
Normally programmers put a nop instruction here but it can be anything.
Returns:
true if next instruction is in delay slot, false otherwise.
simulate
public boolean simulate(MIPSprogram p,
int pc,
int maxSteps,
int[] breakPoints,
AbstractAction actor)
throws ProcessingException
Simulate execution of given MIPS program. It must have already been assembled.
Parameters:
p – The MIPSprogram to be simulated.
pc – address of first instruction to simulate; this goes into program counter
maxSteps – maximum number of steps to perform before returning false (0 or less means no max)
breakPoints – array of breakpoint program counter values, use null if none
actor – the GUI component responsible for this call, usually GO or STEP. null if none.
Returns:
true if execution completed, false otherwise
Throws:
ProcessingException – Throws exception if run-time exception occurs.
stopExecution
public void stopExecution(AbstractAction actor)
Set the volatile stop boolean variable checked by the execution
thread at the end of each MIPS instruction execution. If variable
is found to be true, the execution thread will depart
gracefully so the main thread handling the GUI can take over.
This is used by both STOP and PAUSE features.
addStopListener
public void addStopListener(Simulator.StopListener l)
removeStopListener
public void removeStopListener(Simulator.StopListener l)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
SimulatorNotice
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator
Class SimulatorNotice
java.lang.Object
mars.simulator.SimulatorNotice
public class SimulatorNotice
extends Object
Object provided to Observers of the Simulator.
They are notified at important phases of the runtime simulator,
such as start and stop of simulation.
Author:
Pete Sanderson
Field Summary
static int SIMULATOR_START
static int SIMULATOR_STOP
Constructor Summary
SimulatorNotice(int action,
int maxSteps,
double runSpeed,
int programCounter)
Constructor will be called only within this package, so assume
address and length are in valid ranges.
Method Summary
int getAction()
Fetch the memory address that was accessed.
int getMaxSteps()
Fetch the length in bytes of the access operation (4,2,1).
int getProgramCounter()
Fetch the value of the access operation (the value read or written).
double getRunSpeed()
Fetch the value of the access operation (the value read or written).
String toString()
String representation indicates access type, address and length in bytes
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Field Detail
SIMULATOR_START
public static final int SIMULATOR_START
See Also:
Constant Field Values
SIMULATOR_STOP
public static final int SIMULATOR_STOP
See Also:
Constant Field Values
Constructor Detail
SimulatorNotice
public SimulatorNotice(int action,
int maxSteps,
double runSpeed,
int programCounter)
Constructor will be called only within this package, so assume
address and length are in valid ranges.
Method Detail
getAction
public int getAction()
Fetch the memory address that was accessed.
getMaxSteps
public int getMaxSteps()
Fetch the length in bytes of the access operation (4,2,1).
getRunSpeed
public double getRunSpeed()
Fetch the value of the access operation (the value read or written).
getProgramCounter
public int getProgramCounter()
Fetch the value of the access operation (the value read or written).
toString
public String toString()
String representation indicates access type, address and length in bytes
Overrides:
toString in class Object
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars.simulator
Interface Summary
Simulator.StopListener
Class Summary
BackStepper Used to “step backward” through execution, undoing each instruction.
DelayedBranch Represents a (potential) delayed branch.
Exceptions Represents an error/interrupt that occurs during execution (simulation).
ProgramArgumentList Models Program Arguments, one or more strings provided to the MIPS
program at runtime.
Simulator Used to simulate the execution of an assembled MIPS program.
SimulatorNotice Object provided to Observers of the Simulator.
SwingWorker This is the 3rd version of SwingWorker (also known as
SwingWorker 3), an abstract class that you subclass to
perform GUI-related work in a dedicated thread.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
SwingWorker
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator
Class SwingWorker
java.lang.Object
mars.simulator.SwingWorker
public abstract class SwingWorker
extends Object
This is the 3rd version of SwingWorker (also known as
SwingWorker 3), an abstract class that you subclass to
perform GUI-related work in a dedicated thread. For
instructions on and examples of using this class, see:
http://java.sun.com/docs/books/tutorial/uiswing/misc/threads.html
Note that the API changed slightly in the 3rd version:
You must now invoke start() on the SwingWorker after
creating it.
Constructor Summary
SwingWorker(boolean useSwing)
Start a thread that will call the construct method
and then exit.
Method Summary
abstract Object construct()
Compute the value to be returned by the get method.
void finished()
Called on the event dispatching thread (not on the worker thread)
after the construct method has returned.
Object get()
Return the value created by the construct method.
protected Object getValue()
Get the value produced by the worker thread, or null if it
hasn’t been constructed yet.
void interrupt()
A new method that interrupts the worker thread.
void start()
Start the worker thread.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
SwingWorker
public SwingWorker(boolean useSwing)
Start a thread that will call the construct method
and then exit.
Parameters:
useSwing – Set true if MARS is running from GUI, false otherwise.
Method Detail
getValue
protected Object getValue()
Get the value produced by the worker thread, or null if it
hasn’t been constructed yet.
construct
public abstract Object construct()
Compute the value to be returned by the get method.
finished
public void finished()
Called on the event dispatching thread (not on the worker thread)
after the construct method has returned.
interrupt
public void interrupt()
A new method that interrupts the worker thread. Call this method
to force the worker to stop what it’s doing.
get
public Object get()
Return the value created by the construct method.
Returns null if either the constructing thread or the current
thread was interrupted before a value was produced.
Returns:
the value created by the construct method
start
public void start()
Start the worker thread.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
ProgramArgumentList
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator
Class ProgramArgumentList
java.lang.Object
mars.simulator.ProgramArgumentList
public class ProgramArgumentList
extends Object
Models Program Arguments, one or more strings provided to the MIPS
program at runtime. Equivalent to C’s main(int argc, char **argv) or
Java’s main(String[] args).
Author:
Pete Sanderson
Constructor Summary
ProgramArgumentList(ArrayList list)
Constructor that gets list from ArrayList of String, one argument per element.
ProgramArgumentList(ArrayList list,
int startPosition)
Constructor that gets list from section of String ArrayList, one
argument per element.
ProgramArgumentList(String args)
Constructor that parses string to produce list.
ProgramArgumentList(String[] list)
Constructor that gets list from String array, one argument per element.
ProgramArgumentList(String[] list,
int startPosition)
Constructor that gets list from section of String array, one
argument per element.
Method Summary
void storeProgramArguments()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
ProgramArgumentList
public ProgramArgumentList(String args)
Constructor that parses string to produce list. Delimiters
are the default Java StringTokenizer delimiters (space, tab,
newline, return, formfeed)
Parameters:
args – String containing delimiter-separated arguments
ProgramArgumentList
public ProgramArgumentList(String[] list)
Constructor that gets list from String array, one argument per element.
Parameters:
list – Array of String, each element containing one argument
ProgramArgumentList
public ProgramArgumentList(String[] list,
int startPosition)
Constructor that gets list from section of String array, one
argument per element.
Parameters:
args – Array of String, each element containing one argument
startPosition – Index of array element containing the first argument; all remaining
elements are assumed to contain an argument.
ProgramArgumentList
public ProgramArgumentList(ArrayList list)
Constructor that gets list from ArrayList of String, one argument per element.
Parameters:
list – ArrayList of String, each element containing one argument
ProgramArgumentList
public ProgramArgumentList(ArrayList list,
int startPosition)
Constructor that gets list from section of String ArrayList, one
argument per element.
Parameters:
args – ArrayList of String, each element containing one argument
startPosition – Index of array element containing the first argument; all remaining
elements are assumed to contain an argument.
Method Detail
storeProgramArguments
public void storeProgramArguments()
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars.simulator
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object mars.simulator.BackStepper
mars.simulator.DelayedBranch
mars.simulator.Exceptions
java.util.Observable mars.simulator.Simulator
mars.simulator.ProgramArgumentList
mars.simulator.SimulatorNotice
mars.simulator.SwingWorker
Interface Hierarchy
mars.simulator.Simulator.StopListener
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
DelayedBranch
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars.simulator
Class DelayedBranch
java.lang.Object
mars.simulator.DelayedBranch
public class DelayedBranch
extends Object
Represents a (potential) delayed branch. Note it is necessary only when
delayed branching is enabled. Here’s the protocol for using it:
(1) When a runtime decision to branch is made (by either a branch or jump
instruction’s simulate() method in InstructionSet), then if delayed branching
is enabled, the register() method is called with the branch target address but
the program counter is NOT set to the branch target address.
(2) At the end of that instruction cycle, the simulate() method in Simulator
will detect the registered branch, and set its trigger. Don’t do anything yet
because the next instruction cycle is the delay slot and needs to complete.
(3) At the end of the next (delay slot) instruction cycle, the simulate()
method in Simulator will detect the triggered branch, set the program
counter to its target value and clear the delayed branch.
The only interesting situation is when the delay slot itself contains a
successful branch! I tried this with SPIM (e.g. beq followed by b)
and it treats it as if nothing was there and continues the delay slot
into the next cycle. The eventual branch taken is the original one (as one
would hope) but in the meantime the first statement following the sequence
of successful branches will constitute the delay slot and will be executed!
Since only one pending delayed branch can be taken at a time, everything
here is done with statics. The class itself represents the potential branch.
Author:
Pete Sanderson
Constructor Summary
DelayedBranch()
Method Summary
static void register(int targetAddress)
Register the fact that a successful branch is to occur.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
DelayedBranch
public DelayedBranch()
Method Detail
register
public static void register(int targetAddress)
Register the fact that a successful branch is to occur. This is called in
the instruction’s simulated execution (its simulate() method in InstructionSet).
If a branch is registered but not triggered, this registration will be ignored
(cannot happen if class usage protocol is followed). If a branch is currently
registered and triggered, reset the state back to registered (but not triggered)
in order to carry over the delay slot for another execution cycle. This is the
only public member of the class.
Parameters:
targetAddress – The address to branch to after executing the next instruction
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
Package mars
Class Summary
ErrorList Maintains list of generated error messages, regardless of source (tokenizing, parsing,
assembly, execution).
ErrorMessage Represents occurrance of an error detected during tokenizing, assembly or simulation.
Globals Collection of globally-available data structures.
MarsLaunch Launch the Mars application
MarsSplashScreen Produces MARS splash screen.
Adapted from http://www.java-tips.org/content/view/1267/2/
MIPSprogram Internal representations of MIPS program.
ProgramStatement Represents one assembly/machine statement.
Settings Contains various IDE settings.
Exception Summary
ProcessingException Class to represent error that occurs while assembling or running a MIPS program.
Overview Package Class Tree Deprecated Index Help
PREV PACKAGE
NEXT PACKAGE
FRAMES
NO FRAMES
All Classes
ProgramStatement
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
Class ProgramStatement
java.lang.Object
mars.ProgramStatement
public class ProgramStatement
extends Object
Represents one assembly/machine statement. This represents the “bare machine” level.
Pseudo-instructions have already been processed at this point and each assembly
statement generated by them is one of these.
Author:
Pete Sanderson and Jason Bumgarner
Constructor Summary
ProgramStatement(int binaryStatement,
int textAddress)
Constructor for ProgramStatement used only for writing a binary machine
instruction with no source code to refer back to.
ProgramStatement(MIPSprogram sourceMIPSprogram,
String source,
TokenList origTokenList,
TokenList strippedTokenList,
Instruction inst,
int textAddress,
int sourceLine)
Constructor for ProgramStatement when there are links back to all source and token
information.
Method Summary
void buildBasicStatementFromBasicInstruction(ErrorList errors)
Given specification of BasicInstruction for this operator, build the
corresponding assembly statement in basic assembly format (e.g.
void buildMachineStatementFromBasicStatement(ErrorList errors)
Given the current statement in Basic Assembly format (see above), build the
32-bit binary machine code statement.
int getAddress()
Produces Text Segment address where the binary machine statement is stored.
String getBasicAssemblyStatement()
Produces Basic Assembly statement for this MIPS source statement.
int getBinaryStatement()
Produces 32-bit binary machine statement as int.
Instruction getInstruction()
Produces Instruction object corresponding to this statement’s operator.
String getMachineStatement()
Produces binary machine statement as 32 character string, all ‘0’ and ‘1’ chars.
int getOperand(int i)
Produces operand value from given array position (first operand is position 0).
int[] getOperands()
Produces int array of operand values for this statement.
TokenList getOriginalTokenList()
Produces token list generated from original source statement.
String getPrintableBasicAssemblyStatement()
Produces printable Basic Assembly statement for this MIPS source
statement.
String getSource()
Produces MIPS source statement.
String getSourceFile()
Produces String name of the source file containing this statement.
int getSourceLine()
Produces line number of MIPS source statement.
MIPSprogram getSourceMIPSprogram()
Produces MIPSprogram object representing the source file containing this statement.
TokenList getStrippedTokenList()
Produces token list stripped of all but operator and operand tokens.
void setBasicAssemblyStatement(String statement)
Assigns given String to be Basic Assembly statement equivalent to this source line.
void setBinaryStatement(int binaryCode)
Assigns given int to be binary machine code equivalent to this source line.
void setMachineStatement(String statement)
Assigns given String to be binary machine code (32 characters, all of them 0 or 1)
equivalent to this source line.
void setSource(String src)
associates MIPS source statement.
String toString()
Crude attempt at building String representation of this complex structure.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Constructor Detail
ProgramStatement
public ProgramStatement(MIPSprogram sourceMIPSprogram,
String source,
TokenList origTokenList,
TokenList strippedTokenList,
Instruction inst,
int textAddress,
int sourceLine)
Constructor for ProgramStatement when there are links back to all source and token
information. These can be used by a debugger later on.
Parameters:
sourceMIPSprogram – The MIPSprogram object that contains this statement
source – The corresponding MIPS source statement.
origTokenList – Complete list of Token objects (includes labels, comments, parentheses, etc)
strippedTokenList – List of Token objects with all but operators and operands removed.
inst – The Instruction object for this statement’s operator.
textAddress – The Text Segment address in memory where the binary machine code for this statement
is stored.
ProgramStatement
public ProgramStatement(int binaryStatement,
int textAddress)
Constructor for ProgramStatement used only for writing a binary machine
instruction with no source code to refer back to. Originally supported
only NOP instruction (all zeroes), but extended in release 4.4 to support
all basic instructions. This was required for the self-modifying code
feature.
Parameters:
binaryStatement – The 32-bit machine code.
textAddress – The Text Segment address in memory where the binary machine code for this statement
is stored.
Method Detail
buildBasicStatementFromBasicInstruction
public void buildBasicStatementFromBasicInstruction(ErrorList errors)
Given specification of BasicInstruction for this operator, build the
corresponding assembly statement in basic assembly format (e.g. substituting
register numbers for register names, replacing labels by values).
Parameters:
errors – The list of assembly errors encountered so far. May add to it here.
buildMachineStatementFromBasicStatement
public void buildMachineStatementFromBasicStatement(ErrorList errors)
Given the current statement in Basic Assembly format (see above), build the
32-bit binary machine code statement.
Parameters:
errors – The list of assembly errors encountered so far. May add to it here.
toString
public String toString()
Crude attempt at building String representation of this complex structure.
Overrides:
toString in class Object
Returns:
A String representing the ProgramStatement.
setBasicAssemblyStatement
public void setBasicAssemblyStatement(String statement)
Assigns given String to be Basic Assembly statement equivalent to this source line.
Parameters:
statement – A String containing equivalent Basic Assembly statement.
setMachineStatement
public void setMachineStatement(String statement)
Assigns given String to be binary machine code (32 characters, all of them 0 or 1)
equivalent to this source line.
Parameters:
statement – A String containing equivalent machine code.
setBinaryStatement
public void setBinaryStatement(int binaryCode)
Assigns given int to be binary machine code equivalent to this source line.
Parameters:
binaryCode – An int containing equivalent binary machine code.
setSource
public void setSource(String src)
associates MIPS source statement. Used by assembler when generating basic
statements during macro expansion of extended statement.
Parameters:
src – a MIPS source statement.
getSourceMIPSprogram
public MIPSprogram getSourceMIPSprogram()
Produces MIPSprogram object representing the source file containing this statement.
Returns:
The MIPSprogram object. May be null…
getSourceFile
public String getSourceFile()
Produces String name of the source file containing this statement.
Returns:
The file name.
getSource
public String getSource()
Produces MIPS source statement.
Returns:
The MIPS source statement.
getSourceLine
public int getSourceLine()
Produces line number of MIPS source statement.
Returns:
The MIPS source statement line number.
getBasicAssemblyStatement
public String getBasicAssemblyStatement()
Produces Basic Assembly statement for this MIPS source statement.
All numeric values are in decimal.
Returns:
The Basic Assembly statement.
getPrintableBasicAssemblyStatement
public String getPrintableBasicAssemblyStatement()
Produces printable Basic Assembly statement for this MIPS source
statement. This is generated dynamically and any addresses and
values will be rendered in hex or decimal depending on the current
setting.
Returns:
The Basic Assembly statement.
getMachineStatement
public String getMachineStatement()
Produces binary machine statement as 32 character string, all ‘0’ and ‘1’ chars.
Returns:
The String version of 32-bit binary machine code.
getBinaryStatement
public int getBinaryStatement()
Produces 32-bit binary machine statement as int.
Returns:
The int version of 32-bit binary machine code.
getOriginalTokenList
public TokenList getOriginalTokenList()
Produces token list generated from original source statement.
Returns:
The TokenList of Token objects generated from original source.
getStrippedTokenList
public TokenList getStrippedTokenList()
Produces token list stripped of all but operator and operand tokens.
Returns:
The TokenList of Token objects generated by stripping original list of all
except operator and operand tokens.
getInstruction
public Instruction getInstruction()
Produces Instruction object corresponding to this statement’s operator.
Returns:
The Instruction that matches the operator used in this statement.
getAddress
public int getAddress()
Produces Text Segment address where the binary machine statement is stored.
Returns:
address in Text Segment of this binary machine statement.
getOperands
public int[] getOperands()
Produces int array of operand values for this statement.
Returns:
int array of operand values (if any) required by this statement’s operator.
getOperand
public int getOperand(int i)
Produces operand value from given array position (first operand is position 0).
Parameters:
i – Operand position in array (first operand is position 0).
Returns:
Operand value at given operand array position. If < 0 or >= numOperands, it returns -1.
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
MarsLaunch
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
Class MarsLaunch
java.lang.Object
mars.MarsLaunch
public class MarsLaunch
extends Object
Launch the Mars application
Author:
Pete Sanderson
Constructor Summary
MarsLaunch(String[] args)
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
MarsLaunch
public MarsLaunch(String[] args)
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars Class Hierarchy
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
Hierarchy For Package mars
Package Hierarchies:
All Packages
Class Hierarchy
java.lang.Object java.awt.Component (implements java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable)
java.awt.Container java.awt.Window (implements javax.accessibility.Accessible)
javax.swing.JWindow (implements javax.accessibility.Accessible, javax.swing.RootPaneContainer)
mars.MarsSplashScreen
mars.ErrorList
mars.ErrorMessage
mars.Globals
mars.MarsLaunch
mars.MIPSprogram
java.util.Observable mars.Settings
mars.ProgramStatement
java.lang.Throwable (implements java.io.Serializable)
java.lang.Exception mars.ProcessingException
Overview Package Class Tree Deprecated Index Help
PREV
NEXT
FRAMES
NO FRAMES
All Classes
MIPSprogram
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
Class MIPSprogram
java.lang.Object
mars.MIPSprogram
public class MIPSprogram
extends Object
Internal representations of MIPS program. Connects source, tokens and machine code. Having
all these structures available facilitates construction of good messages,
debugging, and easy simulation.
Author:
Pete Sanderson
Constructor Summary
MIPSprogram()
Method Summary
ErrorList assemble(ArrayList MIPSprogramsToAssemble,
boolean extendedAssemblerEnabled)
Assembles the MIPS source program.
ErrorList assemble(ArrayList MIPSprogramsToAssemble,
boolean extendedAssemblerEnabled,
boolean warningsAreErrors)
Assembles the MIPS source program.
boolean backSteppingEnabled()
Returns status of BackStepper associated with this program.
MacroPool createMacroPool()
Instantiates a new MacroPool and sends reference of this
MIPSprogram to it
ArrayList createParsedList()
Produces new empty list to hold parsed source code statements.
BackStepper getBackStepper()
Returns BackStepper associated with this program.
String getFilename()
Produces name of associated source code file.
MacroPool getLocalMacroPool()
Gets local macro pool MacroPool for this program
SymbolTable getLocalSymbolTable()
Returns SymbolTable associated with this program.
ArrayList getMachineList()
Produces list of machine statements that are assembled from the program.
ArrayList getParsedList()
Produces existing list of parsed source code statements.
String getSourceLine(int i)
Produces specified line of MIPS source program.
ArrayList
Retrieve list of source statements that comprise the program.
ArrayList getSourceList()
Produces list of source statements that comprise the program.
Tokenizer getTokenizer()
Retrieves Tokenizer for this program
ArrayList getTokenList()
Produces list of tokens that comprise the program.
boolean inSteppedExecution()
Will be true only while in process of simulating a program statement
in step mode (e.g.
ArrayList prepareFilesForAssembly(ArrayList filenames,
String leadFilename,
String exceptionHandler)
Prepares the given list of files for assembly.
void readSource(String file)
Reads MIPS source code from file into structure.
void setLocalMacroPool(MacroPool macroPool)
Sets local macro pool MacroPool for this program
void setSourceLineList(ArrayList
Set list of source statements that comprise the program.
boolean simulate(int maxSteps)
Simulates execution of the MIPS program.
boolean simulate(int[] breakPoints)
Simulates execution of the MIPS program.
boolean simulateFromPC(int[] breakPoints,
int maxSteps,
AbstractAction a)
Simulates execution of the MIPS program.
boolean simulateStepAtPC(AbstractAction a)
Simulates execution of the MIPS program.
void tokenize()
Tokenizes the MIPS source program.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Constructor Detail
MIPSprogram
public MIPSprogram()
Method Detail
getSourceList
public ArrayList getSourceList()
Produces list of source statements that comprise the program.
Returns:
ArrayList of String. Each String is one line of MIPS source code.
setSourceLineList
public void setSourceLineList(ArrayList
Set list of source statements that comprise the program.
Parameters:
sourceLineList – ArrayList of SourceLine.
Each SourceLine represents one line of MIPS source code.
getSourceLineList
public ArrayList
Retrieve list of source statements that comprise the program.
Returns:
ArrayList of SourceLine.
Each SourceLine represents one line of MIPS source cod
getFilename
public String getFilename()
Produces name of associated source code file.
Returns:
File name as String.
getTokenList
public ArrayList getTokenList()
Produces list of tokens that comprise the program.
Returns:
ArrayList of TokenList. Each TokenList is list of tokens generated by
corresponding line of MIPS source code.
See Also:
TokenList
getTokenizer
public Tokenizer getTokenizer()
Retrieves Tokenizer for this program
Returns:
Tokenizer
createParsedList
public ArrayList createParsedList()
Produces new empty list to hold parsed source code statements.
Returns:
ArrayList of ProgramStatement. Each ProgramStatement represents a parsed
MIPS statement.
See Also:
ProgramStatement
getParsedList
public ArrayList getParsedList()
Produces existing list of parsed source code statements.
Returns:
ArrayList of ProgramStatement. Each ProgramStatement represents a parsed
MIPS statement.
See Also:
ProgramStatement
getMachineList
public ArrayList getMachineList()
Produces list of machine statements that are assembled from the program.
Returns:
ArrayList of ProgramStatement. Each ProgramStatement represents an assembled
basic MIPS instruction.
See Also:
ProgramStatement
getBackStepper
public BackStepper getBackStepper()
Returns BackStepper associated with this program. It is created upon successful assembly.
Returns:
BackStepper object, null if there is none.
getLocalSymbolTable
public SymbolTable getLocalSymbolTable()
Returns SymbolTable associated with this program. It is created at assembly time,
and stores local labels (those not declared using .globl directive).
backSteppingEnabled
public boolean backSteppingEnabled()
Returns status of BackStepper associated with this program.
Returns:
true if enabled, false if disabled or non-existant.
getSourceLine
public String getSourceLine(int i)
Produces specified line of MIPS source program.
Parameters:
i – Line number of MIPS source program to get. Line 1 is first line.
Returns:
Returns specified line of MIPS source. If outside the line range,
it returns null. Line 1 is first line.
readSource
public void readSource(String file)
throws ProcessingException
Reads MIPS source code from file into structure. Will always read from file.
It is GUI responsibility to assure that source edits are written to file
when user selects compile or run/step options.
Parameters:
file – String containing name of MIPS source code file.
Throws:
ProcessingException – Will throw exception if there is any problem reading the file.
tokenize
public void tokenize()
throws ProcessingException
Tokenizes the MIPS source program. Program must have already been read from file.
Throws:
ProcessingException – Will throw exception if errors occured while tokenizing.
prepareFilesForAssembly
public ArrayList prepareFilesForAssembly(ArrayList filenames,
String leadFilename,
String exceptionHandler)
throws ProcessingException
Prepares the given list of files for assembly. This involves
reading and tokenizing all the source files. There may be only one.
Parameters:
filenames – ArrayList containing the source file name(s) in no particular order
leadFilename – String containing name of source file that needs to go first and
will be represented by “this” MIPSprogram object.
exceptionHandler – String containing name of source file containing exception
handler. This will be assembled first, even ahead of leadFilename, to allow it to
include “startup” instructions loaded beginning at 0x00400000. Specify null or
empty String to indicate there is no such designated exception handler.
Returns:
ArrayList containing one MIPSprogram object for each file to assemble.
objects for any additional files (send ArrayList to assembler)
Throws:
ProcessingException – Will throw exception if errors occured while reading or tokenizing.
assemble
public ErrorList assemble(ArrayList MIPSprogramsToAssemble,
boolean extendedAssemblerEnabled)
throws ProcessingException
Assembles the MIPS source program. All files comprising the program must have
already been tokenized. Assembler warnings are not considered errors.
Parameters:
MIPSprogramsToAssemble – ArrayList of MIPSprogram objects, each representing a tokenized source file.
extendedAssemblerEnabled – A boolean value – true means extended (pseudo) instructions
are permitted in source code and false means they are to be flagged as errors.
Returns:
ErrorList containing nothing or only warnings (otherwise would have thrown exception).
Throws:
ProcessingException – Will throw exception if errors occured while assembling.
assemble
public ErrorList assemble(ArrayList MIPSprogramsToAssemble,
boolean extendedAssemblerEnabled,
boolean warningsAreErrors)
throws ProcessingException
Assembles the MIPS source program. All files comprising the program must have
already been tokenized.
Parameters:
MIPSprogramsToAssemble – ArrayList of MIPSprogram objects, each representing a tokenized source file.
extendedAssemblerEnabled – A boolean value – true means extended (pseudo) instructions
are permitted in source code and false means they are to be flagged as errors
warningsAreErrors – A boolean value – true means assembler warnings will be considered errors and terminate
the assemble; false means the assembler will produce warning message but otherwise ignore warnings.
Returns:
ErrorList containing nothing or only warnings (otherwise would have thrown exception).
Throws:
ProcessingException – Will throw exception if errors occured while assembling.
simulate
public boolean simulate(int[] breakPoints)
throws ProcessingException
Simulates execution of the MIPS program. Program must have already been assembled.
Begins simulation at beginning of text segment and continues to completion.
Parameters:
breakPoints – int array of breakpoints (PC addresses). Can be null.
Returns:
true if execution completed and false otherwise
Throws:
ProcessingException – Will throw exception if errors occured while simulating.
simulate
public boolean simulate(int maxSteps)
throws ProcessingException
Simulates execution of the MIPS program. Program must have already been assembled.
Begins simulation at beginning of text segment and continues to completion or
until the specified maximum number of steps are simulated.
Parameters:
maxSteps – maximum number of steps to simulate.
Returns:
true if execution completed and false otherwise
Throws:
ProcessingException – Will throw exception if errors occured while simulating.
simulateFromPC
public boolean simulateFromPC(int[] breakPoints,
int maxSteps,
AbstractAction a)
throws ProcessingException
Simulates execution of the MIPS program. Program must have already been assembled.
Begins simulation at current program counter address and continues until stopped,
paused, maximum steps exceeded, or exception occurs.
Parameters:
breakPoints – int array of breakpoints (PC addresses). Can be null.
maxSteps – maximum number of instruction executions. Default -1 means no maximum.
a – the GUI component responsible for this call (GO normally). set to null if none.
Returns:
true if execution completed and false otherwise
Throws:
ProcessingException – Will throw exception if errors occured while simulating.
simulateStepAtPC
public boolean simulateStepAtPC(AbstractAction a)
throws ProcessingException
Simulates execution of the MIPS program. Program must have already been assembled.
Begins simulation at current program counter address and executes one step.
Parameters:
a – the GUI component responsible for this call (STEP normally). Set to null if none.
Returns:
true if execution completed and false otherwise
Throws:
ProcessingException – Will throw exception if errors occured while simulating.
inSteppedExecution
public boolean inSteppedExecution()
Will be true only while in process of simulating a program statement
in step mode (e.g. returning to GUI after each step). This is used to
prevent spurious AccessNotices from being sent from Memory and Register
to observers at other times (e.g. while updating the data and register
displays, while assembling program’s data segment, etc).
createMacroPool
public MacroPool createMacroPool()
Instantiates a new MacroPool and sends reference of this
MIPSprogram to it
Returns:
instatiated MacroPool
getLocalMacroPool
public MacroPool getLocalMacroPool()
Gets local macro pool MacroPool for this program
Returns:
MacroPool
setLocalMacroPool
public void setLocalMacroPool(MacroPool macroPool)
Sets local macro pool MacroPool for this program
Parameters:
macroPool – reference to MacroPool
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Settings
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
Class Settings
java.lang.Object
java.util.Observable
mars.Settings
public class Settings
extends Observable
Contains various IDE settings. Persistent settings are maintained for the
current user and on the current machine using
Java’s Preference objects. Failing that, default setting values come from
Settings.properties file. If both of those fail, default values come from
static arrays defined in this class. The latter can can be modified prior to
instantiating Settings object.
NOTE: If the Preference objects fail due to security exceptions, changes to
settings will not carry over from one MARS session to the next.
Actual implementation of the Preference objects is platform-dependent.
For Windows, they are stored in Registry. To see, run regedit and browse to:
HKEY_CURRENT_USER\Software\JavaSoft\Prefs\mars
Author:
Pete Sanderson
Field Summary
static int ASSEMBLE_ALL_ENABLED
Flag to determine whether only the current editor source file (enabled false) or
all files in its directory (enabled true) will be assembled when assembly is selected.
static int ASSEMBLE_ON_OPEN_ENABLED
Flag to determine whether or not a file is immediately and automatically assembled
upon opening.
static int AUTO_INDENT
Flag to control whether or not language-aware editor will use auto-indent feature
static int BARE_MACHINE_ENABLED
Flag to determine whether or not program being assembled is limited to
using register numbers instead of names.
static int CARET_BLINK_RATE
Caret blink rate in milliseconds, 0 means don’t blink.
static int DATA_SEGMENT_HIGHLIGHTING
Flag to control whether or not highlighting is applied to data segment window
static int DATASEGMENT_HIGHLIGHT_BACKGROUND
RGB color for text segment highlighted background
static int DATASEGMENT_HIGHLIGHT_FONT
Font for text segment highlighted background
static int DATASEGMENT_HIGHLIGHT_FOREGROUND
RGB color for text segment highlighted foreground
static boolean[] defaultBooleanSettingsValues
Last resort default values for boolean settings; will use only if neither
the Preferences nor the properties file work.
static int DELAYED_BRANCHING_ENABLED
Flag to determine whether or not delayed branching is in effect at MIPS execution.
static int DISPLAY_ADDRESSES_IN_HEX
Default setting for displaying addresses and values in hexidecimal in the Execute
pane.
static int DISPLAY_VALUES_IN_HEX
static int EDITOR_CURRENT_LINE_HIGHLIGHTING
Flag to control whether or not editor will highlight the line currently being edited
static int EDITOR_FONT
Font for the text editor
static int EDITOR_LINE_NUMBERS_DISPLAYED
Flag to determine whether or not the editor will display line numbers.
static int EDITOR_POPUP_PREFIX_LENGTH
Number of letters to be matched by editor’s instruction guide before popup generated (if popup enabled)
static int EDITOR_TAB_SIZE
Editor tab size in characters.
static int EVEN_ROW_BACKGROUND
RGB color for table even row background (text, data, register displays)
static int EVEN_ROW_FONT
Font for table even row background (text, data, register displays)
static int EVEN_ROW_FOREGROUND
RGB color for table even row foreground (text, data, register displays)
static int EXCEPTION_HANDLER
Current specified exception handler file (a MIPS assembly source file)
static int EXCEPTION_HANDLER_ENABLED
Flag to determine whether the currently selected exception handler source file will
be included in each assembly operation.
static int EXTENDED_ASSEMBLER_ENABLED
Flag to determine whether or not program being assembled is limited to
basic MIPS instructions and formats.
static int GENERIC_TEXT_EDITOR
Flag to control whether or not to use generic text editor instead of language-aware styled editor
static int LABEL_SORT_STATE
State for sorting label window display
static int LABEL_WINDOW_VISIBILITY
Default visibilty of label window (symbol table).
static int MEMORY_CONFIGURATION
Identifier of current memory configuration
static int ODD_ROW_BACKGROUND
RGB color for table odd row background (text, data, register displays)
static int ODD_ROW_FONT
Font for table odd row background (text, data, register displays)
static int ODD_ROW_FOREGROUND
RGB color for table odd row foreground (text, data, register displays)
static int POPUP_INSTRUCTION_GUIDANCE
Flag to control whether or not editor will provide popup instruction guidance while typing
static int POPUP_SYSCALL_INPUT
Flag to control whether or not simulator will use popup dialog for input syscalls
static int PROGRAM_ARGUMENTS
Flag to determine whether or not to display and use program arguments
static int REGISTER_HIGHLIGHT_BACKGROUND
RGB color for register highlighted background
static int REGISTER_HIGHLIGHT_FONT
Font for register highlighted background
static int REGISTER_HIGHLIGHT_FOREGROUND
RGB color for register highlighted foreground
static int REGISTERS_HIGHLIGHTING
Flag to control whether or not highlighting is applied to register windows
static int SELF_MODIFYING_CODE_ENABLED
Flag to determine whether a program can write binary code to the text or data segment and
execute that code.
static int START_AT_MAIN
Flag to control whether or not assembler automatically initializes program counter to ‘main’s address
static int TEXT_COLUMN_ORDER
Order of text segment table columns
static int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_BACKGROUND
RGB color for text segment delay slot highlighted background
static int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FONT
Font for text segment delay slot highlighted background
static int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FOREGROUND
RGB color for text segment delay slot highlighted foreground
static int TEXTSEGMENT_HIGHLIGHT_BACKGROUND
RGB color for text segment highlighted background
static int TEXTSEGMENT_HIGHLIGHT_FONT
Font for table odd row foreground (text, data, register displays)
static int TEXTSEGMENT_HIGHLIGHT_FOREGROUND
RGB color for text segment highlighted foreground
static int WARNINGS_ARE_ERRORS
Flag to determine whether or not assembler warnings are considered errors.
Constructor Summary
Settings()
Create Settings object and set to saved values.
Settings(boolean gui)
Create Settings object and set to saved values.
Method Summary
boolean getAssembleAllEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ALL_ENABLED)
boolean getAssembleOnOpenEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ON_OPEN_ENABLED)
boolean getBackSteppingEnabled()
Return whether backstepping is permitted at this time.
boolean getBareMachineEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.BARE_MACHINE_ENABLED)
boolean getBooleanSetting(int id)
Fetch value of a boolean setting given its identifier.
int getCaretBlinkRate()
Retrieve the caret blink rate in milliseconds.
Color getColorSettingByKey(String key)
Get Color object for specified settings key.
Color getColorSettingByPosition(int position)
Get Color object for specified settings name (a static constant).
boolean getDataSegmentHighlighting()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DATA_SEGMENT_HIGHLIGHTING)
Color getDefaultColorSettingByKey(String key)
Get default Color value for specified settings key.
Color getDefaultColorSettingByPosition(int position)
Get default Color object for specified settings name (a static constant).
SyntaxStyle getDefaultEditorSyntaxStyleByPosition(int index)
int getDefaultEditorTabSize()
Get the text editor default tab size in characters
Font getDefaultFontByPosition(int fontSettingPosition)
Retrieve a default Font setting
boolean getDelayedBranchingEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
boolean getDisplayAddressesInHex()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_ADDRESSES_IN_HEX)
boolean getDisplayValuesInHex()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_VALUES_IN_HEX)
Font getEditorFont()
Current editor font.
boolean getEditorLineNumbersDisplayed()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EDITOR_LINE_NUMBERS_DISPLAYED)
int getEditorPopupPrefixLength()
Get number of letters to be matched by editor’s instruction guide before popup generated (if popup enabled).
SyntaxStyle getEditorSyntaxStyleByPosition(int index)
int getEditorTabSize()
Get the tab size in characters.
String getExceptionHandler()
Name of currently selected exception handler file.
boolean getExceptionHandlerEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EXCEPTION_HANDLER_ENABLED)
boolean getExtendedAssemblerEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EXTENDED_ASSEMBLER_ENABLED)
Font getFontByPosition(int fontSettingPosition)
Retrieve a Font setting
String getLabelSortState()
Get the saved state of the Labels Window sorting (can sort by either
label or address and either ascending or descending order).
boolean getLabelWindowVisibility()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.LABEL_WINDOW_VISIBILITY)
String getMemoryConfiguration()
Returns identifier of current built-in memory configuration.
boolean getProgramArguments()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.PROGRAM_ARGUMENTS)
boolean getRegistersHighlighting()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.REGISTERS_HIGHLIGHTING)
boolean getStartAtMain()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.START_AT_MAIN)
int[] getTextColumnOrder()
Order of text segment display columns (there are 5, numbered 0 to 4).
boolean getWarningsAreErrors()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.WARNINGS_ARE_ERRORS)
void reset(boolean gui)
Reset settings to default values, as described in the constructor comments.
void setAssembleAllEnabled(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ALL_ENABLED)
void setAssembleOnOpenEnabled(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ON_OPEN_ENABLED)
void setBooleanSetting(int id,
boolean value)
Set value of a boolean setting given its id and the value.
void setBooleanSettingNonPersistent(int id,
boolean value)
Temporarily establish boolean setting.
void setCaretBlinkRate(int rate)
Set the caret blinking rate in milliseconds.
void setColorSettingByKey(String key,
Color color)
Set Color object for specified settings key.
void setColorSettingByPosition(int position,
Color color)
Set Color object for specified settings name (a static constant).
void setDataSegmentHighlighting(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DATA_SEGMENT_HIGHLIGHTING)
void setDelayedBranchingEnabled(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
void setDelayedBranchingEnabledNonPersistent(boolean value)
Deprecated. Use setBooleanSettingNonPersistent(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
void setDisplayAddressesInHex(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_ADDRESSES_IN_HEX)
void setDisplayValuesInHex(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_VALUES_IN_HEX)
void setEditorFont(Font font)
Set editor font to the specified Font object and write it to persistent storage.
void setEditorLineNumbersDisplayed(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EDITOR_LINE_NUMBERS_DISPLAYED)
void setEditorPopupPrefixLength(int length)
Set number of letters to be matched by editor’s instruction guide before popup generated (if popup enabled).
void setEditorSyntaxStyleByPosition(int index,
SyntaxStyle syntaxStyle)
void setEditorTabSize(int size)
Set the tab size in characters.
void setExceptionHandler(String newFilename)
Set name of exception handler file and write it to persistent storage.
void setExceptionHandlerEnabled(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EXCEPTION_HANDLER_ENABLED)
void setExtendedAssemblerEnabled(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EXTENDED_ASSEMBLER_ENABLED)
void setFontByPosition(int fontSettingPosition,
Font font)
Store a Font setting
void setLabelSortState(String state)
Store the current state of the Labels Window sorter.
void setLabelWindowVisibility(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.LABEL_WINDOW_VISIBILITY)
void setMemoryConfiguration(String config)
Store the identifier of the memory configuration.
void setProgramArguments(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.PROGRAM_ARGUMENTS)
void setRegistersHighlighting(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.REGISTERS_HIGHLIGHTING)
void setStartAtMain(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.START_AT_MAIN)
void setTextColumnOrder(int[] columnOrder)
Store the current order of Text Segment window table columns, so the ordering
can be preserved and restored.
void setWarningsAreErrors(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.WARNINGS_ARE_ERRORS)
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
EXTENDED_ASSEMBLER_ENABLED
public static final int EXTENDED_ASSEMBLER_ENABLED
Flag to determine whether or not program being assembled is limited to
basic MIPS instructions and formats.
See Also:
Constant Field Values
BARE_MACHINE_ENABLED
public static final int BARE_MACHINE_ENABLED
Flag to determine whether or not program being assembled is limited to
using register numbers instead of names. NOTE: Its default value is
false and the IDE provides no means to change it!
See Also:
Constant Field Values
ASSEMBLE_ON_OPEN_ENABLED
public static final int ASSEMBLE_ON_OPEN_ENABLED
Flag to determine whether or not a file is immediately and automatically assembled
upon opening. Handy when using externa editor like mipster.
See Also:
Constant Field Values
ASSEMBLE_ALL_ENABLED
public static final int ASSEMBLE_ALL_ENABLED
Flag to determine whether only the current editor source file (enabled false) or
all files in its directory (enabled true) will be assembled when assembly is selected.
See Also:
Constant Field Values
LABEL_WINDOW_VISIBILITY
public static final int LABEL_WINDOW_VISIBILITY
Default visibilty of label window (symbol table). Default only, dynamic status
maintained by ExecutePane
See Also:
Constant Field Values
DISPLAY_ADDRESSES_IN_HEX
public static final int DISPLAY_ADDRESSES_IN_HEX
Default setting for displaying addresses and values in hexidecimal in the Execute
pane.
See Also:
Constant Field Values
DISPLAY_VALUES_IN_HEX
public static final int DISPLAY_VALUES_IN_HEX
See Also:
Constant Field Values
EXCEPTION_HANDLER_ENABLED
public static final int EXCEPTION_HANDLER_ENABLED
Flag to determine whether the currently selected exception handler source file will
be included in each assembly operation.
See Also:
Constant Field Values
DELAYED_BRANCHING_ENABLED
public static final int DELAYED_BRANCHING_ENABLED
Flag to determine whether or not delayed branching is in effect at MIPS execution.
This means we simulate the pipeline and statement FOLLOWING a successful branch
is executed before branch is taken. DPS 14 June 2007.
See Also:
Constant Field Values
EDITOR_LINE_NUMBERS_DISPLAYED
public static final int EDITOR_LINE_NUMBERS_DISPLAYED
Flag to determine whether or not the editor will display line numbers.
See Also:
Constant Field Values
WARNINGS_ARE_ERRORS
public static final int WARNINGS_ARE_ERRORS
Flag to determine whether or not assembler warnings are considered errors.
See Also:
Constant Field Values
PROGRAM_ARGUMENTS
public static final int PROGRAM_ARGUMENTS
Flag to determine whether or not to display and use program arguments
See Also:
Constant Field Values
DATA_SEGMENT_HIGHLIGHTING
public static final int DATA_SEGMENT_HIGHLIGHTING
Flag to control whether or not highlighting is applied to data segment window
See Also:
Constant Field Values
REGISTERS_HIGHLIGHTING
public static final int REGISTERS_HIGHLIGHTING
Flag to control whether or not highlighting is applied to register windows
See Also:
Constant Field Values
START_AT_MAIN
public static final int START_AT_MAIN
Flag to control whether or not assembler automatically initializes program counter to ‘main’s address
See Also:
Constant Field Values
EDITOR_CURRENT_LINE_HIGHLIGHTING
public static final int EDITOR_CURRENT_LINE_HIGHLIGHTING
Flag to control whether or not editor will highlight the line currently being edited
See Also:
Constant Field Values
POPUP_INSTRUCTION_GUIDANCE
public static final int POPUP_INSTRUCTION_GUIDANCE
Flag to control whether or not editor will provide popup instruction guidance while typing
See Also:
Constant Field Values
POPUP_SYSCALL_INPUT
public static final int POPUP_SYSCALL_INPUT
Flag to control whether or not simulator will use popup dialog for input syscalls
See Also:
Constant Field Values
GENERIC_TEXT_EDITOR
public static final int GENERIC_TEXT_EDITOR
Flag to control whether or not to use generic text editor instead of language-aware styled editor
See Also:
Constant Field Values
AUTO_INDENT
public static final int AUTO_INDENT
Flag to control whether or not language-aware editor will use auto-indent feature
See Also:
Constant Field Values
SELF_MODIFYING_CODE_ENABLED
public static final int SELF_MODIFYING_CODE_ENABLED
Flag to determine whether a program can write binary code to the text or data segment and
execute that code.
See Also:
Constant Field Values
defaultBooleanSettingsValues
public static boolean[] defaultBooleanSettingsValues
Last resort default values for boolean settings; will use only if neither
the Preferences nor the properties file work. If you wish to change them,
do so before instantiating the Settings object.
Values are matched to keys by list position.
EXCEPTION_HANDLER
public static final int EXCEPTION_HANDLER
Current specified exception handler file (a MIPS assembly source file)
See Also:
Constant Field Values
TEXT_COLUMN_ORDER
public static final int TEXT_COLUMN_ORDER
Order of text segment table columns
See Also:
Constant Field Values
LABEL_SORT_STATE
public static final int LABEL_SORT_STATE
State for sorting label window display
See Also:
Constant Field Values
MEMORY_CONFIGURATION
public static final int MEMORY_CONFIGURATION
Identifier of current memory configuration
See Also:
Constant Field Values
CARET_BLINK_RATE
public static final int CARET_BLINK_RATE
Caret blink rate in milliseconds, 0 means don’t blink.
See Also:
Constant Field Values
EDITOR_TAB_SIZE
public static final int EDITOR_TAB_SIZE
Editor tab size in characters.
See Also:
Constant Field Values
EDITOR_POPUP_PREFIX_LENGTH
public static final int EDITOR_POPUP_PREFIX_LENGTH
Number of letters to be matched by editor’s instruction guide before popup generated (if popup enabled)
See Also:
Constant Field Values
EDITOR_FONT
public static final int EDITOR_FONT
Font for the text editor
See Also:
Constant Field Values
EVEN_ROW_FONT
public static final int EVEN_ROW_FONT
Font for table even row background (text, data, register displays)
See Also:
Constant Field Values
ODD_ROW_FONT
public static final int ODD_ROW_FONT
Font for table odd row background (text, data, register displays)
See Also:
Constant Field Values
TEXTSEGMENT_HIGHLIGHT_FONT
public static final int TEXTSEGMENT_HIGHLIGHT_FONT
Font for table odd row foreground (text, data, register displays)
See Also:
Constant Field Values
TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FONT
public static final int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FONT
Font for text segment delay slot highlighted background
See Also:
Constant Field Values
DATASEGMENT_HIGHLIGHT_FONT
public static final int DATASEGMENT_HIGHLIGHT_FONT
Font for text segment highlighted background
See Also:
Constant Field Values
REGISTER_HIGHLIGHT_FONT
public static final int REGISTER_HIGHLIGHT_FONT
Font for register highlighted background
See Also:
Constant Field Values
EVEN_ROW_BACKGROUND
public static final int EVEN_ROW_BACKGROUND
RGB color for table even row background (text, data, register displays)
See Also:
Constant Field Values
EVEN_ROW_FOREGROUND
public static final int EVEN_ROW_FOREGROUND
RGB color for table even row foreground (text, data, register displays)
See Also:
Constant Field Values
ODD_ROW_BACKGROUND
public static final int ODD_ROW_BACKGROUND
RGB color for table odd row background (text, data, register displays)
See Also:
Constant Field Values
ODD_ROW_FOREGROUND
public static final int ODD_ROW_FOREGROUND
RGB color for table odd row foreground (text, data, register displays)
See Also:
Constant Field Values
TEXTSEGMENT_HIGHLIGHT_BACKGROUND
public static final int TEXTSEGMENT_HIGHLIGHT_BACKGROUND
RGB color for text segment highlighted background
See Also:
Constant Field Values
TEXTSEGMENT_HIGHLIGHT_FOREGROUND
public static final int TEXTSEGMENT_HIGHLIGHT_FOREGROUND
RGB color for text segment highlighted foreground
See Also:
Constant Field Values
TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_BACKGROUND
public static final int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_BACKGROUND
RGB color for text segment delay slot highlighted background
See Also:
Constant Field Values
TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FOREGROUND
public static final int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FOREGROUND
RGB color for text segment delay slot highlighted foreground
See Also:
Constant Field Values
DATASEGMENT_HIGHLIGHT_BACKGROUND
public static final int DATASEGMENT_HIGHLIGHT_BACKGROUND
RGB color for text segment highlighted background
See Also:
Constant Field Values
DATASEGMENT_HIGHLIGHT_FOREGROUND
public static final int DATASEGMENT_HIGHLIGHT_FOREGROUND
RGB color for text segment highlighted foreground
See Also:
Constant Field Values
REGISTER_HIGHLIGHT_BACKGROUND
public static final int REGISTER_HIGHLIGHT_BACKGROUND
RGB color for register highlighted background
See Also:
Constant Field Values
REGISTER_HIGHLIGHT_FOREGROUND
public static final int REGISTER_HIGHLIGHT_FOREGROUND
RGB color for register highlighted foreground
See Also:
Constant Field Values
Constructor Detail
Settings
public Settings()
Create Settings object and set to saved values. If saved values not found, will set
based on defaults stored in Settings.properties file. If file problems, will set based
on defaults stored in this class.
Settings
public Settings(boolean gui)
Create Settings object and set to saved values. If saved values not found, will set
based on defaults stored in Settings.properties file. If file problems, will set based
on defaults stored in this class.
Parameters:
gui – true if running the graphical IDE, false if running from command line.
Ignored as of release 3.6 but retained for compatability.
Method Detail
getBackSteppingEnabled
public boolean getBackSteppingEnabled()
Return whether backstepping is permitted at this time. Backstepping is ability to undo execution
steps one at a time. Available only in the IDE. This is not a persistent setting and is not under
MARS user control.
Returns:
true if backstepping is permitted, false otherwise.
reset
public void reset(boolean gui)
Reset settings to default values, as described in the constructor comments.
Parameters:
gui – true if running from GUI IDE and false if running from command mode.
Ignored as of release 3.6 but retained for compatibility.
setEditorSyntaxStyleByPosition
public void setEditorSyntaxStyleByPosition(int index,
SyntaxStyle syntaxStyle)
getEditorSyntaxStyleByPosition
public SyntaxStyle getEditorSyntaxStyleByPosition(int index)
getDefaultEditorSyntaxStyleByPosition
public SyntaxStyle getDefaultEditorSyntaxStyleByPosition(int index)
getBooleanSetting
public boolean getBooleanSetting(int id)
Fetch value of a boolean setting given its identifier.
Parameters:
id – int containing the setting’s identifier (constants listed above)
Returns:
corresponding boolean setting.
Throws:
IllegalArgumentException – if identifier is invalid.
getBareMachineEnabled
public boolean getBareMachineEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.BARE_MACHINE_ENABLED)
Setting for whether user programs limited to “bare machine” formatted basic instructions.
This was added 8 Aug 2006 but is fixed at false for now, due to uncertainty as to what
exactly constitutes “bare machine”.
Returns:
true if only bare machine instructions allowed, false otherwise.
getExtendedAssemblerEnabled
public boolean getExtendedAssemblerEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EXTENDED_ASSEMBLER_ENABLED)
Setting for whether user programs can use pseudo-instructions or extended addressing modes
or alternative instruction formats (all are implemented as pseudo-instructions).
Returns:
true if pseudo-instructions and formats permitted, false otherwise.
getAssembleOnOpenEnabled
public boolean getAssembleOnOpenEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ON_OPEN_ENABLED)
Setting for whether selected program will be automatically assembled upon opening. This
can be useful if user employs an external editor such as MIPSter.
Returns:
true if file is to be automatically assembled upon opening and false otherwise.
getDisplayAddressesInHex
public boolean getDisplayAddressesInHex()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_ADDRESSES_IN_HEX)
Setting for whether Addresses in the Execute pane will be displayed in hexadecimal.
Returns:
true if addresses are displayed in hexadecimal and false otherwise (decimal).
getDisplayValuesInHex
public boolean getDisplayValuesInHex()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_VALUES_IN_HEX)
Setting for whether values in the Execute pane will be displayed in hexadecimal.
Returns:
true if values are displayed in hexadecimal and false otherwise (decimal).
getAssembleAllEnabled
public boolean getAssembleAllEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ALL_ENABLED)
Setting for whether the assemble operation applies only to the file currently open in
the editor or whether it applies to all files in that file’s directory (primitive project
capability). If the “assemble on open” setting is set, this “assemble all” setting will
be applied as soon as the file is opened.
Returns:
true if all files are to be assembled, false if only the file open in editor.
getExceptionHandlerEnabled
public boolean getExceptionHandlerEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EXCEPTION_HANDLER_ENABLED)
Setting for whether the currently selected exception handler
(a MIPS source file) will be automatically included in each
assemble operation.
Returns:
true if exception handler is to be included in assemble, false otherwise.
getDelayedBranchingEnabled
public boolean getDelayedBranchingEnabled()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
Setting for whether delayed branching will be applied during MIPS
program execution. If enabled, the statement following a successful
branch will be executed and then the branch is taken! This simulates
pipelining and all MIPS processors do it. However it is confusing to
assembly language students so is disabled by default. SPIM does same thing.
Returns:
true if delayed branching is enabled, false otherwise.
getLabelWindowVisibility
public boolean getLabelWindowVisibility()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.LABEL_WINDOW_VISIBILITY)
Setting concerning whether or not to display the Labels Window — symbol table.
Returns:
true if label window is to be displayed, false otherwise.
getEditorLineNumbersDisplayed
public boolean getEditorLineNumbersDisplayed()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.EDITOR_LINE_NUMBERS_DISPLAYED)
Setting concerning whether or not the editor will display line numbers.
Returns:
true if line numbers are to be displayed, false otherwise.
getWarningsAreErrors
public boolean getWarningsAreErrors()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.WARNINGS_ARE_ERRORS)
Setting concerning whether or not assembler will consider warnings to be errors.
Returns:
true if warnings are considered errors, false otherwise.
getProgramArguments
public boolean getProgramArguments()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.PROGRAM_ARGUMENTS)
Setting concerning whether or not program arguments can be entered and used.
Returns:
true if program arguments can be entered/used, false otherwise.
getDataSegmentHighlighting
public boolean getDataSegmentHighlighting()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.DATA_SEGMENT_HIGHLIGHTING)
Setting concerning whether or not highlighting is applied to Data Segment window.
Returns:
true if highlighting is to be applied, false otherwise.
getRegistersHighlighting
public boolean getRegistersHighlighting()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.REGISTERS_HIGHLIGHTING)
Setting concerning whether or not highlighting is applied to Registers,
Coprocessor0, and Coprocessor1 windows.
Returns:
true if highlighting is to be applied, false otherwise.
getStartAtMain
public boolean getStartAtMain()
Deprecated. Use getBooleanSetting(int id) with the appropriate boolean setting ID
(e.g. Settings.START_AT_MAIN)
Setting concerning whether or not assembler will automatically initialize
the program counter to address of statement labeled ‘main’ if defined.
Returns:
true if it initializes to ‘main’, false otherwise.
getExceptionHandler
public String getExceptionHandler()
Name of currently selected exception handler file.
Returns:
String pathname of current exception handler file, empty if none.
getMemoryConfiguration
public String getMemoryConfiguration()
Returns identifier of current built-in memory configuration.
Returns:
String identifier of current built-in memory configuration, empty if none.
getEditorFont
public Font getEditorFont()
Current editor font. Retained for compatibility but replaced
by: getFontByPosition(Settings.EDITOR_FONT)
Returns:
Font object for current editor font.
getFontByPosition
public Font getFontByPosition(int fontSettingPosition)
Retrieve a Font setting
Parameters:
fontSettingPosition – constant that identifies which item
Returns:
Font object for given item
getDefaultFontByPosition
public Font getDefaultFontByPosition(int fontSettingPosition)
Retrieve a default Font setting
Parameters:
fontSettingPosition – constant that identifies which item
Returns:
Font object for given item
getTextColumnOrder
public int[] getTextColumnOrder()
Order of text segment display columns (there are 5, numbered 0 to 4).
Returns:
Array of int indicating the order. Original order is 0 1 2 3 4.
getCaretBlinkRate
public int getCaretBlinkRate()
Retrieve the caret blink rate in milliseconds. Blink rate of 0 means
do not blink.
Returns:
int blink rate in milliseconds
getEditorTabSize
public int getEditorTabSize()
Get the tab size in characters.
Returns:
tab size in characters.
getEditorPopupPrefixLength
public int getEditorPopupPrefixLength()
Get number of letters to be matched by editor’s instruction guide before popup generated (if popup enabled).
Should be 1 or 2. If 1, the popup will be generated after first letter typed, based on all matches; if 2,
the popup will be generated after second letter typed.
Returns:
number of letters (should be 1 or 2).
getDefaultEditorTabSize
public int getDefaultEditorTabSize()
Get the text editor default tab size in characters
Returns:
tab size in characters
getLabelSortState
public String getLabelSortState()
Get the saved state of the Labels Window sorting (can sort by either
label or address and either ascending or descending order).
Default state is 0, by ascending addresses.
Returns:
State value 0-7, as a String.
getColorSettingByKey
public Color getColorSettingByKey(String key)
Get Color object for specified settings key.
Returns null if key is not found or its value is not a valid color encoding.
Parameters:
key – the Setting key
Returns:
corresponding Color, or null if key not found or value not valid color
getDefaultColorSettingByKey
public Color getDefaultColorSettingByKey(String key)
Get default Color value for specified settings key.
Returns null if key is not found or its value is not a valid color encoding.
Parameters:
key – the Setting key
Returns:
corresponding default Color, or null if key not found or value not valid color
getColorSettingByPosition
public Color getColorSettingByPosition(int position)
Get Color object for specified settings name (a static constant).
Returns null if argument invalid or its value is not a valid color encoding.
Parameters:
position – the Setting name (see list of static constants)
Returns:
corresponding Color, or null if argument invalid or value not valid color
getDefaultColorSettingByPosition
public Color getDefaultColorSettingByPosition(int position)
Get default Color object for specified settings name (a static constant).
Returns null if argument invalid or its value is not a valid color encoding.
Parameters:
position – the Setting name (see list of static constants)
Returns:
corresponding default Color, or null if argument invalid or value not valid color
setBooleanSetting
public void setBooleanSetting(int id,
boolean value)
Set value of a boolean setting given its id and the value.
Parameters:
id – int containing the setting’s identifier (constants listed above)
value – boolean value to store
Throws:
IllegalArgumentException – if identifier is not valid.
setExtendedAssemblerEnabled
public void setExtendedAssemblerEnabled(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EXTENDED_ASSEMBLER_ENABLED)
Establish setting for whether or not pseudo-instructions and formats are permitted
in user programs. User can change this setting via the IDE. If setting changes,
new setting will be written to properties file.
Parameters:
value – True to permit, false otherwise.
setAssembleOnOpenEnabled
public void setAssembleOnOpenEnabled(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ON_OPEN_ENABLED)
Establish setting for whether a file will be automatically assembled as soon as it
is opened. This is handy for those using an external text editor such as Mipster.
If setting changes, new setting will be written to properties file.
Parameters:
value – True to automatically assemble, false otherwise.
setAssembleAllEnabled
public void setAssembleAllEnabled(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.ASSEMBLE_ALL_ENABLED)
Establish setting for whether a file will be assembled by itself (false) or along
with all other files in its directory (true). This permits multi-file programs
and a primitive “project” capability. If setting changes,
new setting will be written to properties file.
Parameters:
value – True to assemble all, false otherwise.
setDisplayAddressesInHex
public void setDisplayAddressesInHex(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_ADDRESSES_IN_HEX)
Establish setting for whether addresses in the Execute pane will be displayed
in hexadecimal format.
Parameters:
value – True to display addresses in hexadecimal, false for decimal.
setDisplayValuesInHex
public void setDisplayValuesInHex(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DISPLAY_VALUES_IN_HEX)
Establish setting for whether values in the Execute pane will be displayed
in hexadecimal format.
Parameters:
value – True to display values in hexadecimal, false for decimal.
setLabelWindowVisibility
public void setLabelWindowVisibility(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.LABEL_WINDOW_VISIBILITY)
Establish setting for whether the labels window (i.e. symbol table) will
be displayed as part of the Text Segment display. If setting changes,
new setting will be written to properties file.
Parameters:
value – True to dispay labels window, false otherwise.
setExceptionHandlerEnabled
public void setExceptionHandlerEnabled(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EXCEPTION_HANDLER_ENABLED)
Establish setting for whether the currently selected exception handler
(a MIPS source file) will be automatically included in each
assemble operation. If setting changes, new setting will be written
to properties file.
Parameters:
value – True to assemble exception handler, false otherwise.
setDelayedBranchingEnabled
public void setDelayedBranchingEnabled(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
Establish setting for whether delayed branching will be applied during
MIPS program execution. If enabled, the statement following a successful
branch will be executed and then the branch is taken! This simulates
pipelining and all MIPS processors do it. However it is confusing to
assembly language students so is disabled by default. SPIM does same thing.
Parameters:
value – True to enable delayed branching, false otherwise.
setEditorLineNumbersDisplayed
public void setEditorLineNumbersDisplayed(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.EDITOR_LINE_NUMBERS_DISPLAYED)
Establish setting for whether line numbers will be displayed by the
text editor.
Parameters:
value – True to display line numbers, false otherwise.
setWarningsAreErrors
public void setWarningsAreErrors(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.WARNINGS_ARE_ERRORS)
Establish setting for whether assembler warnings will be considered errors.
Parameters:
value – True to consider warnings to be errors, false otherwise.
setProgramArguments
public void setProgramArguments(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.PROGRAM_ARGUMENTS)
Establish setting for whether program arguments can be ented/used.
Parameters:
value – True if program arguments can be entered/used, false otherwise.
setDataSegmentHighlighting
public void setDataSegmentHighlighting(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DATA_SEGMENT_HIGHLIGHTING)
Establish setting for whether highlighting is to be applied to
Data Segment window.
Parameters:
value – True if highlighting is to be applied, false otherwise.
setRegistersHighlighting
public void setRegistersHighlighting(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.REGISTERS_HIGHLIGHTING)
Establish setting for whether highlighting is to be applied to
Registers, Coprocessor0 and Coprocessor1 windows.
Parameters:
value – True if highlighting is to be applied, false otherwise.
setStartAtMain
public void setStartAtMain(boolean value)
Deprecated. Use setBooleanSetting(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.START_AT_MAIN)
Establish setting for whether assembler will automatically initialize
program counter to address of statement labeled ‘main’ if defined.
Parameters:
value – True if PC set to address of ‘main’, false otherwise.
setBooleanSettingNonPersistent
public void setBooleanSettingNonPersistent(int id,
boolean value)
Temporarily establish boolean setting. This setting will NOT be written to persisent
store! Currently this is used only when running MARS from the command line
Parameters:
id – setting identifier. These are defined for this class as static final int.
value – True to enable the setting, false otherwise.
setDelayedBranchingEnabledNonPersistent
public void setDelayedBranchingEnabledNonPersistent(boolean value)
Deprecated. Use setBooleanSettingNonPersistent(int id, boolean value) with the appropriate boolean setting ID
(e.g. Settings.DELAYED_BRANCHING_ENABLED)
Establish setting for whether delayed branching will be applied during
MIPS program execution. This setting will NOT be written to persisent
store! This method should be called only to temporarily set this
setting — currently this is needed only when running MARS from the
command line.
Parameters:
value – True to enabled delayed branching, false otherwise.
setExceptionHandler
public void setExceptionHandler(String newFilename)
Set name of exception handler file and write it to persistent storage.
Parameters:
newFilename – name of exception handler file
setMemoryConfiguration
public void setMemoryConfiguration(String config)
Store the identifier of the memory configuration.
Parameters:
config – A string that identifies the current built-in memory configuration
setCaretBlinkRate
public void setCaretBlinkRate(int rate)
Set the caret blinking rate in milliseconds. Rate of 0 means no blinking.
Parameters:
rate – blink rate in milliseconds
setEditorTabSize
public void setEditorTabSize(int size)
Set the tab size in characters.
Parameters:
size – tab size in characters.
setEditorPopupPrefixLength
public void setEditorPopupPrefixLength(int length)
Set number of letters to be matched by editor’s instruction guide before popup generated (if popup enabled).
Should be 1 or 2. If 1, the popup will be generated after first letter typed, based on all matches; if 2,
the popup will be generated after second letter typed.
Parameters:
number – of letters (should be 1 or 2).
setEditorFont
public void setEditorFont(Font font)
Set editor font to the specified Font object and write it to persistent storage.
This method retained for compatibility but replaced by:
setFontByPosition(Settings.EDITOR_FONT, font)
Parameters:
font – Font object to be used by text editor.
setFontByPosition
public void setFontByPosition(int fontSettingPosition,
Font font)
Store a Font setting
Parameters:
fontSettingPosition – Constant that identifies the item the font goes with
setTextColumnOrder
public void setTextColumnOrder(int[] columnOrder)
Store the current order of Text Segment window table columns, so the ordering
can be preserved and restored.
Parameters:
columnOrder – An array of int indicating column order.
setLabelSortState
public void setLabelSortState(String state)
Store the current state of the Labels Window sorter. There are 8 possible states
as described in LabelsWindow.java
Parameters:
state – The current labels window sorting state, as a String.
setColorSettingByKey
public void setColorSettingByKey(String key,
Color color)
Set Color object for specified settings key. Has no effect if key is invalid.
Parameters:
key – the Setting key
color – the Color to save
setColorSettingByPosition
public void setColorSettingByPosition(int position,
Color color)
Set Color object for specified settings name (a static constant). Has no effect if invalid.
Parameters:
position – the Setting name (see list of static constants)
color – the Color to save
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
Globals
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
mars
Class Globals
java.lang.Object
mars.Globals
public class Globals
extends Object
Collection of globally-available data structures.
Author:
Pete Sanderson
Field Summary
static String ASCII_NON_PRINT
Placeholder for non-printable ASCII codes
static String[] ASCII_TABLE
Array of strings to display for ASCII codes in ASCII display of data segment.
static String copyrightHolders
MARS copyright holders
static String copyrightYears
MARS copyright years
static boolean debug
Flag to determine whether or not to produce internal debugging information.
static int exitCode
MARS exit code — useful with SYSCALL 17 when running from command line (not GUI)
static ArrayList fileExtensions
List of accepted file extensions for MIPS assembly source files.
static String helpPath
Path to folder that contains help text
static String imagesPath
Path to folder that contains images
static InstructionSet instructionSet
The set of implemented MIPS instructions.
static int maximumBacksteps
Maximum number of back-step operations to buffer
static int maximumErrorMessages
Maximum number of assembler errors produced by one assemble operation
static int maximumMessageCharacters
Maximum length of scrolled message window (MARS Messages and Run I/O)
static Memory memory
Simulated MIPS memory component.
static Object memoryAndRegistersLock
Lock variable used at head of synchronized block to guard MIPS memory and registers
static MIPSprogram program
the program currently being worked with.
static boolean runSpeedPanelExists
static SymbolTable symbolTable
Symbol table for file currently being assembled.
static String userInputAlert
String to GUI’s RunI/O text area when echoing user input from pop-up dialog.
static String version
The current MARS version number.
Constructor Summary
Globals()
Method Summary
static String getAsciiNonPrint()
static String[] getAsciiStrings()
static ArrayList getExternalTools()
Get list of MarsTools that reside outside the MARS distribution.
static VenusUI getGui()
static String getPropertyEntry(String propertiesFile,
String propertyName)
Read and return property file value (if any) for requested property.
static Settings getSettings()
ArrayList getSyscallOverrides()
Read any syscall number assignment overrides from config file.
static void initialize(boolean gui)
Method called once upon system initialization to create the global data structures.
static void setGui(VenusUI g)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
instructionSet
public static InstructionSet instructionSet
The set of implemented MIPS instructions.
program
public static MIPSprogram program
the program currently being worked with. Used by GUI only, not command line.
symbolTable
public static SymbolTable symbolTable
Symbol table for file currently being assembled.
memory
public static Memory memory
Simulated MIPS memory component.
memoryAndRegistersLock
public static Object memoryAndRegistersLock
Lock variable used at head of synchronized block to guard MIPS memory and registers
debug
public static boolean debug
Flag to determine whether or not to produce internal debugging information.
userInputAlert
public static String userInputAlert
String to GUI’s RunI/O text area when echoing user input from pop-up dialog.
imagesPath
public static final String imagesPath
Path to folder that contains images
See Also:
Constant Field Values
helpPath
public static final String helpPath
Path to folder that contains help text
See Also:
Constant Field Values
version
public static final String version
The current MARS version number. Can’t wait for “initialize()” call to get it.
See Also:
Constant Field Values
fileExtensions
public static final ArrayList fileExtensions
List of accepted file extensions for MIPS assembly source files.
maximumMessageCharacters
public static final int maximumMessageCharacters
Maximum length of scrolled message window (MARS Messages and Run I/O)
maximumErrorMessages
public static final int maximumErrorMessages
Maximum number of assembler errors produced by one assemble operation
maximumBacksteps
public static final int maximumBacksteps
Maximum number of back-step operations to buffer
copyrightYears
public static final String copyrightYears
MARS copyright years
copyrightHolders
public static final String copyrightHolders
MARS copyright holders
ASCII_NON_PRINT
public static final String ASCII_NON_PRINT
Placeholder for non-printable ASCII codes
ASCII_TABLE
public static final String[] ASCII_TABLE
Array of strings to display for ASCII codes in ASCII display of data segment. ASCII code 0-255 is array index.
exitCode
public static int exitCode
MARS exit code — useful with SYSCALL 17 when running from command line (not GUI)
runSpeedPanelExists
public static boolean runSpeedPanelExists
Constructor Detail
Globals
public Globals()
Method Detail
setGui
public static void setGui(VenusUI g)
getGui
public static VenusUI getGui()
getSettings
public static Settings getSettings()
initialize
public static void initialize(boolean gui)
Method called once upon system initialization to create the global data structures.
getAsciiNonPrint
public static String getAsciiNonPrint()
getAsciiStrings
public static String[] getAsciiStrings()
getExternalTools
public static ArrayList getExternalTools()
Get list of MarsTools that reside outside the MARS distribution.
Currently this is done by adding the tool’s path name to the list
of values for the external_tools property. Use “;” as delimiter!
Returns:
ArrayList. Each item is file path to .class file
of a class that implements MarsTool. If none, returns empty list.
getPropertyEntry
public static String getPropertyEntry(String propertiesFile,
String propertyName)
Read and return property file value (if any) for requested property.
Parameters:
propertiesFile – name of properties file (do NOT include filename extension,
which is assumed to be “.properties”)
propertyName – String containing desired property name
Returns:
String containing associated value; null if property not found
getSyscallOverrides
public ArrayList getSyscallOverrides()
Read any syscall number assignment overrides from config file.
Returns:
ArrayList of SyscallNumberOverride objects
Overview Package Class Tree Deprecated Index Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD
000000
sll
000010
srl
000011
sra
000100
sllv
000110
srlv
000111
srav
001000
jr
001001
jalr
001010
movz
001011
movn
001100
SYSCALL
001101
BREAK
010000
mfhi
010001
mthi
010010
mflo
010011
mtlo
011000
mult
011001
multu
011010
div
011011
divu
100000
add
100001
addu
100010
sub
100011
subu
100100
and
100101
or
100110
xor
100111
nor
101010
slt
101011
sltu
110000
tge
110001
tgeu
110010
tlt
110011
tltu
110100
teq
110110
tne
0
init
1
2
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
28
true
1#4#7#10#11#17
false
1
bit3_1
5
105
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
110
true
2
false
2
bit3_2
110
335
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
105
false
3
false
3
bit3_3
105
155
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
335
true
19
false
4
bit2_1
5
154
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
183
true
5
false
5
bit2_2
183
262
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
154
false
6
false
6
bit2_2
154
560
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
262
true
23
false
7
bit1_1
5
193
100#100#100
255#0#0
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
285
true
8
false
8
bit1_2
285
187
100#100#100
255#0#0
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
193
false
9
false
9
bit1_3
193
300
100#100#100
255#0#0
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
187
true
21
false
10
bit0_1
5
160
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
370
true
0
false
11
opALU0_1
5
140
255#00#00
255#00#00
255#00#00
255#00#00
255#00#00
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
239
false
12#13
false
12
opALU0_2
155
225
255#00#00
255#00#00
255#00#00
255#00#00
255#00#00
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
239
false
14#15
false,
13
and1_in1
245
295
255#00#00
255#00#00
255#00#00
255#00#00
255#00#00
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
147
true
0
false
14
opALU0_3
237
310
255#00#00
255#00#00
255#00#00
255#00#00
255#00#00
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
239
false
16
false
15
or2_in2
245
560
255#00#00
255#00#00
255#00#00
255#00#00
255#00#00
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
230
true
22
false
16
and2_in1
240
300
255#00#00
255#00#00
255#00#00
255#00#00
255#00#00
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
313
true
0
false
17
opALU0_1
5
118
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
390
false
18
false
18
or1_in1
390
570
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
118
true
0
false
19
or0_out
245
305
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
348
true
20
false
20
op3
382
795
100#100#100
100#100#100
100#100#100
255#0#0
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
324
true
0
false
21
or1_in2
374
570
100#100#100
255#0#0
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
157
true
0
false
22
op1
660
795
100#100#100
255#0#0
100#100#100
100#100#100
255#0#0
255#00#00
255#00#00
100#100#100
100#100#100
100#100#100
100#100#100
133
true
0
false
23
op2
665
795
255#0#0
255#0#0
100#100#100
100#100#100
255#0#0
255#0#0
255#00#00
255#0#0
255#0#0
255#0#0
255#0#0
243
true
0
false
mkdir game_temp
move mars/mips/instructions/syscalls/Syscall1*.* game_temp/
move mars/mips/instructions/syscalls/*.java game_temp/
jar cmf mainclass.txt NewMars.jar PseudoOps.txt Config.properties Syscall.properties Settings.properties MARSlicense.txt mainclass.txt MipsXRayOpcode.xml registerDatapath.xml controlDatapath.xml ALUcontrolDatapath.xml Mars.java Mars.class docs help images game mars/*.* mars/venus mars/util mars/tools/ mars/simulator mars/ext/game/*.class mars/assembler mars/mips/dump mars/mips/hardware mars/mips/instructions/*.* mars/mips/instructions/syscalls
move game_temp/* mars/mips/instructions/syscalls
rmdir game_temp
001000
addi
001001
addiu
001010
slti
001011
sltiu
001100
andi
001101
ori
001110
xori
001111
lui
100000
lb
100001
lh
100010
lwl
100011
lw
100100
lbu
100101
lhu
100110
lwr
110001
l1
110001
lwc1
110010
lwc2
110011
pref
110101
ldc1
110110
ldc2
101111
CACHE
111000
sc
111001
swc1
111010
swc2
111101
sdc1
111110
sdc2
101000
sb
101001
sh
101010
swl
101011
sw
101110
swr
000100
beq
000110
blez
000111
bgtz
000101
bne
000010
j
000011
jal
010000
–
010001
–
010010
–
010011
–
000001
SUB.F
010100
–
010101
–
010110
–
010111
–
011000
–
011001
–
011010
–
011011
–
011100
–
011101
–
011110
–
011111
–
101100
–
101101
–
111100
–
111111
–
100111
–
110100
–
110111
–
110111
–
111011
–
000000
r-type
000000
sll
000010
srl
000011
sra
000100
sllv
000110
srlv
000111
srav
001000
jr
001001
jalr
001010
movz
001011
movn
001100
SYSCALL
001101
BREAK
010000
mfhi
010001
mthi
010010
mflo
010011
mtlo
011000
mult
011001
multu
011010
div
011011
divu
100000
add
100001
addu
100010
sub
100011
subu
100100
and
100101
or
100110
xor
100111
nor
101010
slt
101011
sltu
110000
tge
110001
tgeu
110010
tlt
110011
tltu
110100
teq
110110
tne
00000
$zero
00001
at
00010
$v0
00011
$v1
00100
$a0
00101
$a1
00110
$a2
00111
$a3
01000
$t0
01001
$t1
01010
$t2
01011
$t3
01100
$t4
01101
$t5
01110
$t6
01111
$t7
10000
$s0
10001
$s1
10010
$s2
10011
$s3
10100
$s4
10101
$s5
11000
$s6
10111
$s7
11000
$t8
11001
$t9
11010
$k0
11011
$k1
11100
$gp
11101
$sp
11110
$fp
11111
$ra
0
*Program_counter
161
188
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
362
true
1#6
false
1
*nodeADD1input1A
358
95
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
192
false
2#3
false
2
*ADD1input1B
192
253
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
94
true
0
false
3
*ADDA1input2
210
253
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
144
true
5
false
4
outputDATAMEM1
400
415
16#78#139
16#78#139
100#100#100
30#144#255
100#100#100
100#100#100
414
true
101
false
5
*node1ADD2
311
493
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
119
true
13#14
false
6
*instruction_Memory
198
215
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
362
true
7
false
7
*nodeIMrepeated
311
315
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
378
true
8
false
8
nodeIM
311
315
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
378
true
9#10
false
9
nodeSHIFTLEFT1
375
75
255#185#15
255#185#15
255#185#15
255#185#15
255#185#15
255#185#15
317
false
11
false
10
*nodeIM2
322
325
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
378
true
19#20
false
11
*SHIFTLEFT1
317
388
255#185#15
255#185#15
255#185#15
255#185#15
255#185#15
255#185#15
75
true
12
false
12
*nodeMUXC
440
485
255#185#15
255#185#15
255#185#15
255#185#15
255#185#15
255#185#15
75
true
0
false
13
*nodeMUXC1
115
88
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
497
false
18
false
14
node2ADD2
503
595
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
119
true
15#16
false
15
*nodeMUXB
115
100
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
600
false
17
false
16
*ADD2input1
605
650
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
119
true
0
false
17
*MUXB
600
762
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
238#221#130
100
true
87
false
18
*nodeMUXC1
502
793
205#149#15
205#149#15
205#149#15
205#149#15
205#149#15
205#149#15
75
true
42
false
19
*nodeREG2
376
360
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
329
false
24#26
false
20
*nodeMUXA1
385
395
255#127#36
0#191#255
100#100#100
255#127#36
255#127#36
255#127#36
329
false
21#22
false
21
MUXA2
334
365
255#127#36
0#191#255
100#100#100
255#127#36
255#127#36
255#127#36
399
true
0
false
22
*nodeSIGN_EXT
403
461
0#255#255
255#127#36
100#100#100
255#127#36
255#127#36
255#127#36
329
false
23#33
false
23
*SIGN_EXT
333
425
0#255#255
100#100#100
100#100#100
255#127#36
255#127#36
255#127#36
466
true
37
false
24
*nodeREG2A
354
339
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
328
false
30#31
false
25
notUsed
331
415
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
255#255#0
336
true
0
false
26
*nodeREGB
334
344
0#0#255
0#0#255
100#100#100
0#0#255
0#0#255
0#0#255
358
true
27#29
false
27
*nodeMUXA
363
371
0#0#255
0#0#255
100#100#100
0#0#255
0#0#255
0#0#255
348
false
28
false
28
*nodeMUXA
348
362
0#0#255
0#0#255
100#100#100
0#0#255
0#0#255
0#0#255
371
true
0
false
29
*REGB
352
416
0#0#255
0#0#255
100#100#100
0#0#255
0#0#255
0#0#255
358
true
0
false
30
*nodeCTRL2
329
230
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
328
false
32
false
31
*REGinput1
333
415
0#255#0
0#255#0
100#100#100
0#255#0
0#255#0
0#255#0
335
true
0
false
32
*CTRL
328
348
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
255#0#255
230
true
44#45#46#47#48#49#50#51#52
false
33
*nodeALU_CTRL
467
503
205#91#69
205#91#69
100#100#100
205#91#69
205#91#69
255#127#36
329
false
34
false
34
*ALU_CTRL
329
562
205#91#69
205#91#69
100#100#100
205#91#69
205#91#69
255#127#36
503
true
0
false
35
*nodeALUcontrol1
617
650
205#91#69
205#91#69
100#100#100
205#91#69
205#91#69
255#127#36
501
true
36
false
36
*nodeALUcontrol2
501
385
205#91#69
205#91#69
100#100#100
205#91#69
205#91#69
255#127#36
650
false
99
false
37
*nodeSIGN_EXT
500
536
139#115#85
100#100#100
100#100#100
139#115#85
139#115#85
139#115#85
466
true
38
false
38
*nodeSHIFT_LEFT2
466
404
139#115#85
100#100#100
100#100#100
139#115#85
139#115#85
139#115#85
535
false
39#73
false
39
*nodeSHIFT_LEFT2A
395
153
139#115#85
100#100#100
100#100#100
139#115#85
139#115#85
139#115#85
535
false
40
false
40
*SHIFT_LEFT2
535
550
139#115#85
100#100#100
100#100#100
139#115#85
139#115#85
139#115#85
153
true
41
false
41
ADD2
605
652
139#115#85
100#100#100
100#100#100
139#115#85
139#115#85
139#115#85
170
true
72
false
42
*nodeMUXC2
75
108
205#149#15
205#149#15
205#149#15
205#149#15
205#149#15
205#149#15
794
false
43
false
43
*nodeMUXC3
794
804
205#149#15
205#149#15
205#149#15
205#149#15
205#149#15
205#149#15
108
true
0
false
44
*SIG_CTRL_MUXA1
364
341
255#000#000
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
267
true
53
false
45
*SIG_CTRL_AND1
405
723
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
187
true
0
false
46
*SIG_CTRL_MUXB
414
779
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
209
true
86
false
47
*SIG_CTRL_MEMA1
417
939
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
220
true
62
false
48
*SIG_CTRL_MUXE
417
856
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
235
true
58
false
49
*SIG_CTRL_DATAMEMB1
415
762
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
243
true
61
false
50
*SIG_CTRL_ALUCRTL
412
591
255#0#0
255#0#0
100#100#100
255#0#0
255#0#0
100#100#100
255
true
60
false
51
*SIG_CTRL_MUXD
410
565
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
263
true
59
false
52
*SIG_CTRL_REG
402
472
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
275
true
57
false
53
*SIG_CTRL_MUXA2
267
439
255#000#000
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
341
false
54
false
54
*SIG_CTRL_MUXA3
341
382
255#000#000
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
440
true
55
false
55
*SIG_CTRL_MUXA4
440
410
255#000#000
255#0#0
100#100#100
100#100#100
100#100#100
100#100#100
382
false
56
false
56
*REG3
390
415
255#127#36
0#191#255
100#100#100
0#0#255
0#0#255
0#0#255
387
true
98
false
57
*SIG_CTRL_REG2
275
295
255#0#0
255#0#0
100#100#100
255#0#0
100#100#100
100#100#100
472
false
0
false
58
*SIG_CTRL_MUXE2
235
340
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
856
false
0
false
59
*SIG_CTRL_MUXD2
263
365
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
565
false
0
false
60
*SIG_CTRL_ALUCRTL2
255
453
255#0#0
255#0#0
100#100#100
255#0#0
255#0#0
100#100#100
591
false
35
false
61
*SIG_CTRL_DATAMEMB2
243
315
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
762
false
0
false
62
*SIG_CTRL_MEMA2
220
456
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
939
false
63
false
63
*SIG_CTRL_MEMA3
939
773
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
456
true
64
false
64
*SIG_CTRL_MEMA3
456
407
100#100#100
100#100#100
100#100#100
255#0#0
100#100#100
100#100#100
773
false
93
false
65
*REG_OUTPUT1
523
594
0#205#0
0#205#0
100#100#100
0#205#0
0#205#0
0#205#0
320
true
0
false
66
*REG_OUTPUT2
523
524
100#100#100
255#255#0
100#100#100
100#100#100
100#100#100
100#100#100
379
true
67#68
false
67
*REG_OUTPUT2A
531
545
100#100#100
255#255#0
100#100#100
100#100#100
100#100#100
100#100#100
379
true
74
false
68
nodeMEMDATAINPUT1
382
437
100#100#100
255#255#0
100#100#100
100#100#100
100#100#100
100#100#100
526
false
69
false
69
nodeMEMDATAINPUT2
526
680
100#100#100
255#255#0
100#100#100
100#100#100
100#100#100
100#100#100
437
true
70
false
70
nodeMEMDATAINPUT2
437
387
100#100#100
255#255#0
100#100#100
100#100#100
100#100#100
100#100#100
680
false
71
false
71
nodeMEMDATAINPUT2
680
712
100#100#100
255#255#0
100#100#100
100#100#100
100#100#100
100#100#100
387
true
0
false
72
*MUXC
710
762
255#218#185
255#218#185
255#218#185
255#218#185
255#218#185
255#218#185
133
true
0
false
73
nodeMUXD
538
545
139#115#85
100#100#100
100#100#100
139#115#85
139#115#85
139#115#85
400
true
0
false
74
ALUinput2
575
593
139#115#85
255#255#0
100#100#100
139#115#85
139#115#85
139#115#85
388
true
0
false
75
nodeMEMDATAINPUT1A
670
690
16#78#139
16#78#139
100#100#100
16#78#139
16#78#139
100#100#100
364
true
76#77
false
76
*nodeMUXEA1
368
430
16#78#139
16#78#139
100#100#100
100#100#100
100#100#100
100#100#100
692
false
78
false
77
MEMDATAINPUT1B
697
712
100#100#100
100#100#100
100#100#100
16#78#139
16#78#139
100#100#100
364
true
0
false
78
*nodeMUXEA1
692
825
16#78#139
16#78#139
100#100#100
100#100#100
100#100#100
100#100#100
430
true
80
false
79
ZERO_ALU1
670
690
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
340
true
82
false
80
nodeMUXG1B
430
375
16#78#139
16#78#139
100#100#100
100#100#100
100#100#100
100#100#100
825
false
81
false
81
nodeMUXG1C
825
837
16#78#139
16#78#139
100#100#100
100#100#100
100#100#100
100#100#100
375
true
0
false
82
ZERO_ALU1
340
200
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
690
false
83
false
83
ZERO_ALU1
690
725
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
200
true
84
false
84
*AND_MUXC1
742
823
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
192
true
85
false
85
*AND_MUXC2
192
144
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
823
false
88
false
86
*SIG_CTRL_MUXB2
209
146
100#100#100
100#100#100
100#100#100
100#100#100
100#100#100
255#0#0
780
false
0
false
87
*MUXCinput2
790
805
238#221#130
255#218#185
255#218#185
255#218#185
255#218#185
255#218#185
134
true
0
false
88
*PCinput1
832
845
205#149#15
205#149#15
255#218#185
205#149#15
205#149#15
255#218#185
120
true
89
false
89
*PCinput2
120
49
205#149#15
205#149#15
255#218#185
205#149#15
205#149#15
255#218#185
845
false
90
false
90
*PCinput3
845
85
205#149#15
205#149#15
255#218#185
205#149#15
205#149#15
255#218#185
49
true
91
false
91
*PCinput4
49
362
205#149#15
205#149#15
255#218#185
205#149#15
205#149#15
255#218#185
85
false
92
false
92
*PCinput5
85
112
205#149#15
205#149#15
255#218#185
205#149#15
205#149#15
255#218#185
362
true
100
false
93
outputDATAMEM1
810
835
100#100#100
100#100#100
100#100#100
30#144#255
100#100#100
100#100#100
354
true
94
false
94
*outputMUXE1
865
895
16#78#139
16#78#139
100#100#100
30#144#255
100#100#100
100#100#100
365
true
95
false
95
outputDATAMEM1
365
522
16#78#139
16#78#139
100#100#100
30#144#255
100#100#100
100#100#100
895
false
96
false
96
outputDATAMEM1
895
400
16#78#139
16#78#139
100#100#100
30#144#255
100#100#100
100#100#100
522
true
97
false
97
outputDATAMEM1
522
414
16#78#139
16#78#139
100#100#100
30#144#255
100#100#100
100#100#100
400
false
4
false
98
READING
420
300
255#0#0
255#0#0
100#100#100
255#0#0
255#0#0
255#0#0
450
false
65#66
true
99
ALUVALUE
400
315
255#0#0
255#0#0
100#100#100
255#0#0
255#0#0
255#0#0
620
false
75#79
true
100
CP+4
400
370
255#0#0
255#0#0
100#100#100
255#0#0
255#0#0
255#0#0
130
false
0
true
101
WRITING
420
300
255#0#0
255#0#0
100#100#100
255#0#0
255#0#0
255#0#0
450
false
101
true
# maximum length of scrolled text in Mars Message and Run I/O tabs, in bytes.
MessageLimit = 1000000
# Maximum number of errors that can be recorded in one assemble operation.
ErrorLimit = 200
# Maximum number of “backstep” operations that can be taken. An instruction
# may produce more than one (e.g. trap instruction may set several registers)
BackstepLimit = 2000
# Acceptable file extensions for MIPS assembly files. Separate with spaces.
Extensions = asm s
# The set of ASCII strings to use for ASCII display or print
# of data segment contents. This covers 8-bit ASCII codes 0-255.
# The space character (decimal 32, hex 20) is encoded here as
# “space” without the quotes. It will be converted upon reading.
# All non-printable codes are encoded here as “null” without
# the quotes. They will be converted upon reading, to the value
# of variable AsciiNonPrint. If you wish to have non-printing
# codes be displayed as their octal value (see unix od) then
# replace all these null with the codes.
# 0 1 2 3 4 5 6 7 8 9
AsciiTable = \
\\0 null null null null null null null \\b \\t \
\\n \\v \\f \\r null null null null null null \
null null null null null null null null null null \
null null space ! ” # $ % & ‘ \
( ) * + , – . / 0 1 \
2 3 4 5 6 7 8 9 : ; \
< = > ? @ A B C D E \
F G H I J K L M N O \
P Q R S T U V W X Y \
Z [ \\ ] ^ _ ` a b c \
d e f g h i j k l m \
n o p q r s t u v w \
x y z { | } ~ null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null null null null null \
null null null null null null
# Use AsciiNonPrint as placeholder for non-printing ASCII codes.
# To use space character, specify AsciiNonPrint = space.
# The value of this variable will be substituted for the
# string “null” for any element in the Ascii list (above)
# having “null” as its value.
AsciiNonPrint = .
# Example of re-assign syscall number. Remove leading “#” to activate.
# I re-assign to same number since I don’t really want to change them.
# None are necessary here since number is assigned as constructor arg.
# Re-assignment here will override constructor arg though.
# The syscall names must match constructor arg exactly, case-sensitive.
# Re-assignment useful if numbering conflict should someday occur.
PrintInt = 1
PrintFloat = 2
PrintDouble = 3
PrintString = 4
ReadInt = 5
ReadFloat = 6
ReadDouble = 7
ReadString = 8
Sbrk = 9
Exit = 10
PrintChar = 11
ReadChar = 12
Open = 13
Read = 14
Write = 15
Close = 16
Exit2 = 17
Time = 30
MidiOut = 31
Sleep = 32
MidiOutSync = 33
PrintIntHex = 34
PrintIntBinary = 35
PrintIntUnsigned = 36
RandSeed = 40
RandInt = 41
RandIntRange = 42
RandFloat = 43
RandDouble = 44
ConfirmDialog = 50
InputDialogInt = 51
InputDialogFloat = 52
InputDialogDouble = 53
InputDialogString = 54
MessageDialog = 55
MessageDialogInt = 56
MessageDialogFloat = 57
MessageDialogDouble = 58
MessageDialogString = 59
mkdir game_temp
move mars\mips\instructions\syscalls\Syscall1*.* game_temp\
move mars\mips\instructions\syscalls\*.java game_temp\
jar cmf mainclass.txt NewMars.jar PseudoOps.txt Config.properties Syscall.properties Settings.properties MARSlicense.txt mainclass.txt MipsXRayOpcode.xml registerDatapath.xml controlDatapath.xml ALUcontrolDatapath.xml Mars.java Mars.class docs help images game mars/*.* mars/venus mars/util mars/tools/ mars/simulator mars/ext/game/*.class mars/assembler mars/mips/dump mars/mips/hardware mars/mips/instructions/*.* mars/mips/instructions/syscalls
move game_temp\* mars\mips\instructions\syscalls
rmdir game_temp
del mars\ext\game\*.class
del mars\mips\instructions\syscalls\*.class
javac -source 1.5 -target 1.5 mars\ext\game\*.java
javac -source 1.5 -target 1.5 mars\mips\instructions\syscalls\*.java
pause
AbstractMarsToolAndApplication$MessageField
package mars.tools;
synchronized class AbstractMarsToolAndApplication$MessageField extends javax.swing.JTextField {
public void AbstractMarsToolAndApplication$MessageField(AbstractMarsToolAndApplication, String);
private void displayTerminatingMessage(String);
private void displayNonTerminatingMessage(String);
private void displayMessage(String, boolean);
}
MemoryReferenceVisualization$8
package mars.tools;
synchronized class MemoryReferenceVisualization$8 implements java.awt.event.ActionListener {
void MemoryReferenceVisualization$8(MemoryReferenceVisualization);
public void actionPerformed(java.awt.event.ActionEvent);
}
KeyboardAndDisplaySimulator$4
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$4 implements java.awt.event.ActionListener {
void KeyboardAndDisplaySimulator$4(KeyboardAndDisplaySimulator);
public void actionPerformed(java.awt.event.ActionEvent);
}
CacheSimulator$5
package mars.tools;
synchronized class CacheSimulator$5 implements java.awt.event.ActionListener {
void CacheSimulator$5(CacheSimulator);
public void actionPerformed(java.awt.event.ActionEvent);
}
MemoryReferenceVisualization$ColorChooserControls$1
package mars.tools;
synchronized class MemoryReferenceVisualization$ColorChooserControls$1 implements java.awt.event.ActionListener {
void MemoryReferenceVisualization$ColorChooserControls$1(MemoryReferenceVisualization$ColorChooserControls, MemoryReferenceVisualization);
public void actionPerformed(java.awt.event.ActionEvent);
}
AbstractMarsToolAndApplication$CreateAssembleRunMIPSprogram
package mars.tools;
synchronized class AbstractMarsToolAndApplication$CreateAssembleRunMIPSprogram implements Runnable {
private void AbstractMarsToolAndApplication$CreateAssembleRunMIPSprogram(AbstractMarsToolAndApplication);
public void run();
}
MipsXray$1
package mars.tools;
synchronized class MipsXray$1 implements java.awt.event.ActionListener {
void MipsXray$1(MipsXray);
public void actionPerformed(java.awt.event.ActionEvent);
}
BitmapDisplay$4
package mars.tools;
synchronized class BitmapDisplay$4 implements java.awt.event.ActionListener {
void BitmapDisplay$4(BitmapDisplay);
public void actionPerformed(java.awt.event.ActionEvent);
}
FloatRepresentation$InstructionsPane
package mars.tools;
synchronized class FloatRepresentation$InstructionsPane extends javax.swing.JLabel {
void FloatRepresentation$InstructionsPane(FloatRepresentation, java.awt.Component);
public void setText(String);
}
AbstractMarsToolAndApplication$1
package mars.tools;
synchronized class AbstractMarsToolAndApplication$1 extends java.awt.event.WindowAdapter {
void AbstractMarsToolAndApplication$1(AbstractMarsToolAndApplication);
public void windowClosing(java.awt.event.WindowEvent);
}
AbstractMarsToolAndApplication$3
package mars.tools;
synchronized class AbstractMarsToolAndApplication$3 implements java.awt.event.ActionListener {
void AbstractMarsToolAndApplication$3(AbstractMarsToolAndApplication);
public void actionPerformed(java.awt.event.ActionEvent);
}
BitmapDisplay$6
package mars.tools;
synchronized class BitmapDisplay$6 implements java.awt.event.ActionListener {
void BitmapDisplay$6(BitmapDisplay);
public void actionPerformed(java.awt.event.ActionEvent);
}
MipsXray$Vertex
package mars.tools;
synchronized class MipsXray$Vertex {
private int numIndex;
private int init;
private int end;
private int current;
private String name;
public static final int movingUpside = 1;
public static final int movingDownside = 2;
public static final int movingLeft = 3;
public static final int movingRight = 4;
public int direction;
public int oppositeAxis;
private boolean isMovingXaxis;
private java.awt.Color color;
private boolean first_interaction;
private boolean active;
private boolean isText;
private java.util.ArrayList targetVertex;
public void MipsXray$Vertex(MipsXray, int, int, int, String, int, boolean, String, String, boolean);
public int getDirection();
public boolean isText();
public java.util.ArrayList getTargetVertex();
public int getNumIndex();
public void setNumIndex(int);
public int getInit();
public void setInit(int);
public int getEnd();
public void setEnd(int);
public int getCurrent();
public void setCurrent(int);
public String getName();
public void setName(String);
public int getOppositeAxis();
public void setOppositeAxis(int);
public boolean isMovingXaxis();
public void setMovingXaxis(boolean);
public java.awt.Color getColor();
public void setColor(java.awt.Color);
public boolean isFirst_interaction();
public void setFirst_interaction(boolean);
public boolean isActive();
public void setActive(boolean);
}
FloatRepresentation$1
package mars.tools;
synchronized class FloatRepresentation$1 implements java.awt.event.ActionListener {
void FloatRepresentation$1(FloatRepresentation);
public void actionPerformed(java.awt.event.ActionEvent);
}
ScavengerHunt$ScavengerHuntDisplay
package mars.tools;
synchronized class ScavengerHunt$ScavengerHuntDisplay extends javax.swing.JPanel {
private int width;
private int height;
private boolean clearTheDisplay;
public void ScavengerHunt$ScavengerHuntDisplay(ScavengerHunt, int, int);
public void redraw();
public void clear();
public void paintComponent(java.awt.Graphics);
}
SettingsDialog2
package mars.tools;
synchronized class SettingsDialog2 extends javax.swing.JDialog {
javax.swing.JButton applyButton;
javax.swing.JButton cancelButton;
javax.swing.JCheckBox captureResizeCheckBox;
javax.swing.JCheckBox captureMoveCheckBox;
javax.swing.JCheckBox captureRescaleCheckBox;
javax.swing.JRadioButton captureDisplayCenteredButton;
javax.swing.JRadioButton captureDisplayUpperleftButton;
Integer[] scribblerLineWidthSettings;
javax.swing.JComboBox lineWidthSetting;
javax.swing.JButton lineColorSetting;
javax.swing.JCheckBox dialogCentered;
javax.swing.JDialog dialog;
java.awt.Color scribblerLineColorSetting;
static final String SETTINGS_APPLY_TOOLTIP_TEXT = Apply current settings and close the dialog.;
static final String SETTINGS_CANCEL_TOOLTIP_TEXT = Close the dialog without applying any setting changes.;
static final String SETTINGS_SCRIBBLER_WIDTH_TOOLTIP_TEXT = Scribbler line thickness in pixels.;
static final String SETTINGS_SCRIBBLER_COLOR_TOOLTIP_TEXT = Click here to change Scribbler line color.;
static final String SETTINGS_DIALOG_CENTERED_TOOLTIP_TEXT = Whether to center this dialog over the Magnifier.;
void SettingsDialog2(javax.swing.JFrame);
private javax.swing.JPanel getButtonRowPanel();
private javax.swing.JPanel getAutomaticCaptureSettingsPanel();
private javax.swing.JPanel getCaptureDisplayPanel();
private javax.swing.JPanel getScribblerPanel(javax.swing.JDialog);
}
AbstractMarsToolAndApplication$MessageField$MessageWriter
package mars.tools;
synchronized class AbstractMarsToolAndApplication$MessageField$MessageWriter implements Runnable {
private String text;
private boolean terminatingMessage;
public void AbstractMarsToolAndApplication$MessageField$MessageWriter(AbstractMarsToolAndApplication$MessageField, String, boolean);
public void run();
}
KeyboardAndDisplaySimulator
package mars.tools;
public synchronized class KeyboardAndDisplaySimulator extends AbstractMarsToolAndApplication {
private static String version;
private static String heading;
private static String displayPanelTitle;
private static String keyboardPanelTitle;
private static char VT_FILL;
public static java.awt.Dimension preferredTextAreaDimension;
private static java.awt.Insets textAreaInsets;
private final KeyboardAndDisplaySimulator$TransmitterDelayTechnique[] delayTechniques;
public static int RECEIVER_CONTROL;
public static int RECEIVER_DATA;
public static int TRANSMITTER_CONTROL;
public static int TRANSMITTER_DATA;
private boolean countingInstructions;
private int instructionCount;
private int transmitDelayInstructionCountLimit;
private int currentDelayInstructionLimit;
private int intWithCharacterToDisplay;
private boolean displayAfterDelay;
private boolean displayRandomAccessMode;
private int rows;
private int columns;
private KeyboardAndDisplaySimulator$DisplayResizeAdapter updateDisplayBorder;
private KeyboardAndDisplaySimulator simulator;
private javax.swing.JPanel keyboardAndDisplay;
private javax.swing.JScrollPane displayScrollPane;
private javax.swing.JTextArea display;
private javax.swing.JPanel displayPanel;
private javax.swing.JPanel displayOptions;
private javax.swing.JComboBox delayTechniqueChooser;
private KeyboardAndDisplaySimulator$DelayLengthPanel delayLengthPanel;
private javax.swing.JSlider delayLengthSlider;
private javax.swing.JCheckBox displayAfterDelayCheckBox;
private javax.swing.JPanel keyboardPanel;
private javax.swing.JScrollPane keyAccepterScrollPane;
private javax.swing.JTextArea keyEventAccepter;
private javax.swing.JButton fontButton;
private java.awt.Font defaultFont;
private static final char CLEAR_SCREEN = 12;
private static final char SET_CURSOR_X_Y = 7;
public void KeyboardAndDisplaySimulator(String, String);
public void KeyboardAndDisplaySimulator();
public static void main(String[]);
public String getName();
protected void initializePreGUI();
protected void addAsObserver();
protected javax.swing.JComponent buildMainDisplayArea();
protected void processMIPSUpdate(java.util.Observable, mars.mips.hardware.AccessNotice);
private void displayCharacter(int);
protected void initializePostGUI();
protected void reset();
private void initializeDisplay(boolean);
private void repaintDisplayPanelBorder();
private java.awt.Dimension getDisplayPanelTextDimensions();
protected javax.swing.JComponent getHelpComponent();
private javax.swing.JComponent buildDisplay();
private javax.swing.JComponent buildKeyboard();
private void updateMMIOControl(int, int);
private void updateMMIOControlAndData(int, int, int, int);
private synchronized void updateMMIOControlAndData(int, int, int, int, boolean);
private static boolean isReadyBitSet(int);
private static int readyBitSet(int);
private static int readyBitCleared(int);
private void initializeTransmitDelaySimulator();
private int generateDelay();
static void
}
AbstractMarsToolAndApplication
package mars.tools;
public abstract synchronized class AbstractMarsToolAndApplication extends javax.swing.JFrame implements MarsTool, java.util.Observer {
protected boolean isBeingUsedAsAMarsTool;
protected AbstractMarsToolAndApplication thisMarsApp;
private javax.swing.JDialog dialog;
protected java.awt.Window theWindow;
javax.swing.JLabel headingLabel;
private String title;
private String heading;
private javax.swing.border.EmptyBorder emptyBorder;
private java.awt.Color backgroundColor;
private int lowMemoryAddress;
private int highMemoryAddress;
private volatile boolean observing;
private java.io.File mostRecentlyOpenedFile;
private Runnable interactiveGUIUpdater;
private AbstractMarsToolAndApplication$MessageField operationStatusMessages;
private javax.swing.JButton openFileButton;
private javax.swing.JButton assembleRunButton;
private javax.swing.JButton stopButton;
private boolean multiFileAssemble;
protected AbstractMarsToolAndApplication$ConnectButton connectButton;
protected void AbstractMarsToolAndApplication(String, String);
public abstract String getName();
protected abstract javax.swing.JComponent buildMainDisplayArea();
public void go();
public void action();
protected void initializePreGUI();
protected void initializePostGUI();
protected void reset();
protected javax.swing.JComponent buildHeadingArea();
protected javax.swing.JComponent buildButtonAreaMarsTool();
protected javax.swing.JComponent buildButtonAreaStandAlone();
public void update(java.util.Observable, Object);
protected void processMIPSUpdate(java.util.Observable, mars.mips.hardware.AccessNotice);
protected void performSpecialClosingDuties();
protected void addAsObserver();
protected void addAsObserver(int, int);
protected void addAsObserver(mars.mips.hardware.Register);
protected void deleteAsObserver();
protected void deleteAsObserver(mars.mips.hardware.Register);
protected boolean isObserving();
protected void updateDisplay();
protected javax.swing.JComponent getHelpComponent();
private void performToolClosingDuties();
private void performAppClosingDuties();
}
MarsBot$BotRunnable
package mars.tools;
synchronized class MarsBot$BotRunnable implements Runnable {
javax.swing.JPanel panel;
public void MarsBot$BotRunnable(MarsBot);
public void run();
}
AbstractMarsToolAndApplication$EnterKeyListener
package mars.tools;
public synchronized class AbstractMarsToolAndApplication$EnterKeyListener extends java.awt.event.KeyAdapter {
javax.swing.AbstractButton myButton;
public void AbstractMarsToolAndApplication$EnterKeyListener(AbstractMarsToolAndApplication, javax.swing.AbstractButton);
public void keyPressed(java.awt.event.KeyEvent);
}
CacheSimulator$3
package mars.tools;
synchronized class CacheSimulator$3 implements java.awt.event.ActionListener {
void CacheSimulator$3(CacheSimulator);
public void actionPerformed(java.awt.event.ActionEvent);
}
KeyboardAndDisplaySimulator$2
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$2 implements javax.swing.event.CaretListener {
void KeyboardAndDisplaySimulator$2(KeyboardAndDisplaySimulator);
public void caretUpdate(javax.swing.event.CaretEvent);
}
ScribblerSettings
package mars.tools;
synchronized class ScribblerSettings {
private int width;
private java.awt.Color color;
public void ScribblerSettings(int, java.awt.Color);
public int getLineWidth();
public java.awt.Color getLineColor();
public void setLineWidth(int);
public void setLineColor(java.awt.Color);
}
CacheSimulator
package mars.tools;
public synchronized class CacheSimulator extends AbstractMarsToolAndApplication {
private static boolean debug;
private static String version;
private static String heading;
private javax.swing.JComboBox cacheBlockSizeSelector;
private javax.swing.JComboBox cacheBlockCountSelector;
private javax.swing.JComboBox cachePlacementSelector;
private javax.swing.JComboBox cacheReplacementSelector;
private javax.swing.JComboBox cacheSetSizeSelector;
private javax.swing.JTextField memoryAccessCountDisplay;
private javax.swing.JTextField cacheHitCountDisplay;
private javax.swing.JTextField cacheMissCountDisplay;
private javax.swing.JTextField replacementPolicyDisplay;
private javax.swing.JTextField cachableAddressesDisplay;
private javax.swing.JTextField cacheSizeDisplay;
private javax.swing.JProgressBar cacheHitRateDisplay;
private CacheSimulator$Animation animations;
private javax.swing.JPanel logPanel;
private javax.swing.JScrollPane logScroll;
private javax.swing.JTextArea logText;
private javax.swing.JCheckBox logShow;
private javax.swing.border.EmptyBorder emptyBorder;
private java.awt.Font countFonts;
private java.awt.Color backgroundColor;
private int[] cacheBlockSizeChoicesInt;
private int[] cacheBlockCountChoicesInt;
private String[] cacheBlockSizeChoices;
private String[] cacheBlockCountChoices;
private String[] placementPolicyChoices;
private final int DIRECT;
private final int FULL;
private final int SET;
private String[] replacementPolicyChoices;
private final int LRU;
private final int RANDOM;
private String[] cacheSetSizeChoices;
private int defaultCacheBlockSizeIndex;
private int defaultCacheBlockCountIndex;
private int defaultPlacementPolicyIndex;
private int defaultReplacementPolicyIndex;
private int defaultCacheSetSizeIndex;
private CacheSimulator$AbstractCache theCache;
private int memoryAccessCount;
private int cacheHitCount;
private int cacheMissCount;
private double cacheHitRate;
private java.util.Random randu;
public void CacheSimulator(String, String);
public void CacheSimulator();
public static void main(String[]);
public String getName();
protected javax.swing.JComponent buildMainDisplayArea();
private javax.swing.JComponent buildLogArea();
private javax.swing.JComponent buildOrganizationArea();
private javax.swing.JComponent buildPerformanceArea();
protected void processMIPSUpdate(java.util.Observable, mars.mips.hardware.AccessNotice);
protected void initializePreGUI();
protected void initializePostGUI();
protected void reset();
protected void updateDisplay();
private String[] determineSetSizeChoices(int, int);
private void updateCacheSetSizeSelector();
private CacheSimulator$AbstractCache createNewCache();
private void resetCounts();
private void updateMemoryAccessCountDisplay();
private void updateCacheHitCountDisplay();
private void updateCacheMissCountDisplay();
private void updateCacheHitRateDisplay();
private void updateCacheSizeDisplay();
private javax.swing.JPanel getPanelWithBorderLayout();
private void resetLogDisplay();
private void writeLog(String);
static void
}
BitmapDisplay$2
package mars.tools;
synchronized class BitmapDisplay$2 implements java.awt.event.ActionListener {
void BitmapDisplay$2(BitmapDisplay);
public void actionPerformed(java.awt.event.ActionEvent);
}
AbstractMarsToolAndApplication$7
package mars.tools;
synchronized class AbstractMarsToolAndApplication$7 implements java.awt.event.ActionListener {
void AbstractMarsToolAndApplication$7(AbstractMarsToolAndApplication);
public void actionPerformed(java.awt.event.ActionEvent);
}
CacheSimulator$CacheAccessResult
package mars.tools;
synchronized class CacheSimulator$CacheAccessResult {
private boolean hitOrMiss;
private int blockNumber;
public void CacheSimulator$CacheAccessResult(CacheSimulator, boolean, int);
public boolean isHit();
public int getBlock();
}
ScavengerHunt$1
package mars.tools;
synchronized class ScavengerHunt$1 {
}
ScavengerHunt$PlayerData
package mars.tools;
synchronized class ScavengerHunt$PlayerData {
int whereAmIX;
int whereAmIY;
int energy;
int color;
long finishTime;
boolean[] hasVisitedLoc;
boolean finis;
private void ScavengerHunt$PlayerData(ScavengerHunt);
public void setWhereAmI(int, int);
public void setEnergy(int);
public void setColor(int);
public int getWhereAmIX();
public int getWhereAmIY();
public int getColor();
public boolean hasVisited(int);
public void setVisited(int);
public void setFinished();
public boolean isFinished();
public long getFinishTime();
public long getFinishMin();
public long getFinishSec();
public long getFinishMillisec();
public void setFinishTime(long);
public int getEnergy();
}
KeyboardAndDisplaySimulator$DisplayResizeAdapter
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$DisplayResizeAdapter extends java.awt.event.ComponentAdapter {
private void KeyboardAndDisplaySimulator$DisplayResizeAdapter(KeyboardAndDisplaySimulator);
public void componentResized(java.awt.event.ComponentEvent);
}
AbstractMarsToolAndApplication$5
package mars.tools;
synchronized class AbstractMarsToolAndApplication$5 implements java.awt.event.ActionListener {
void AbstractMarsToolAndApplication$5(AbstractMarsToolAndApplication);
public void actionPerformed(java.awt.event.ActionEvent);
}
CacheSimulator$AbstractCache
package mars.tools;
abstract synchronized class CacheSimulator$AbstractCache {
private int numberOfBlocks;
private int blockSizeInWords;
private int setSizeInBlocks;
private int numberOfSets;
protected CacheSimulator$CacheBlock[] blocks;
protected void CacheSimulator$AbstractCache(CacheSimulator, int, int, int);
public int getNumberOfBlocks();
public int getNumberOfSets();
public int getSetSizeInBlocks();
public int getBlockSizeInWords();
public int getCacheSizeInWords();
public int getCacheSizeInBytes();
public int getSetNumber(int);
public int getTag(int);
public int getFirstBlockToSearch(int);
public int getLastBlockToSearch(int);
public void reset();
public abstract CacheSimulator$CacheAccessResult isItAHitThenReadOnMiss(int);
}
CacheSimulator$Animation
package mars.tools;
synchronized class CacheSimulator$Animation {
private javax.swing.Box animation;
private javax.swing.JTextField[] blocks;
public final java.awt.Color hitColor;
public final java.awt.Color missColor;
public final java.awt.Color defaultColor;
public void CacheSimulator$Animation(CacheSimulator);
private javax.swing.Box getAnimationBox();
public int getNumberOfBlocks();
public void showHit(int);
public void showMiss(int);
public void reset();
private void fillAnimationBoxWithCacheBlocks();
}
MipsXray
package mars.tools;
public synchronized class MipsXray extends AbstractMarsToolAndApplication {
private static final long serialVersionUID = -1;
private static String heading;
private static String version;
protected java.awt.Graphics g;
protected int lastAddress;
protected javax.swing.JLabel label;
private java.awt.Container painel;
private MipsXray$DatapathAnimation datapathAnimation;
private java.awt.GraphicsConfiguration gc;
private java.awt.image.BufferedImage datapath;
private String instructionBinary;
private javax.swing.JButton Assemble;
private javax.swing.JButton Step;
private javax.swing.JButton runBackStep;
private javax.swing.Action runAssembleAction;
private javax.swing.Action runStepAction;
private javax.swing.Action runBackstepAction;
private mars.venus.VenusUI mainUI;
private javax.swing.JToolBar toolbar;
private javax.swing.Timer time;
public void MipsXray(String, String);
public void MipsXray();
public String getName();
protected javax.swing.JComponent getHelpComponent();
protected javax.swing.JComponent buildAnimationSequence();
protected javax.swing.JComponent buildMainDisplayArea();
protected javax.swing.JComponent buildMainDisplayArea(String);
protected void addAsObserver();
protected void processMIPSUpdate(java.util.Observable, mars.mips.hardware.AccessNotice);
public void updateDisplay();
private javax.swing.JToolBar setUpToolBar();
private void createActionObjects();
static void
}
CacheSimulator$1
package mars.tools;
synchronized class CacheSimulator$1 implements java.awt.event.ItemListener {
void CacheSimulator$1(CacheSimulator);
public void itemStateChanged(java.awt.event.ItemEvent);
}
CacheSimulator$AnyCache
package mars.tools;
synchronized class CacheSimulator$AnyCache extends CacheSimulator$AbstractCache {
private final int SET_FULL;
private final int HIT;
private final int MISS;
public void CacheSimulator$AnyCache(CacheSimulator, int, int, int);
public CacheSimulator$CacheAccessResult isItAHitThenReadOnMiss(int);
private int selectBlockToReplace(int, int);
}
FloatRepresentation$HexToBinaryGraphicPanel
package mars.tools;
synchronized class FloatRepresentation$HexToBinaryGraphicPanel extends javax.swing.JPanel {
void FloatRepresentation$HexToBinaryGraphicPanel(FloatRepresentation);
public void paintComponent(java.awt.Graphics);
}
MagnifierImage$Scribbler
package mars.tools;
synchronized class MagnifierImage$Scribbler {
private ScribblerSettings scribblerSettings;
private java.awt.BasicStroke drawingStroke;
protected int last_x;
protected int last_y;
void MagnifierImage$Scribbler(MagnifierImage, ScribblerSettings);
public java.awt.Color getColor();
public int getLineWidth();
public void setColor(java.awt.Color);
public void setLineWidth(int);
private java.awt.BasicStroke getStroke();
private void setStroke(java.awt.BasicStroke);
public void moveto(int, int);
public void lineto(int, int, java.awt.Graphics2D);
}
KeyboardAndDisplaySimulator$FontChanger
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$FontChanger implements java.awt.event.ActionListener {
private void KeyboardAndDisplaySimulator$FontChanger(KeyboardAndDisplaySimulator);
public void actionPerformed(java.awt.event.ActionEvent);
}
AbstractMarsToolAndApplication$2
package mars.tools;
synchronized class AbstractMarsToolAndApplication$2 extends java.awt.event.WindowAdapter {
void AbstractMarsToolAndApplication$2(AbstractMarsToolAndApplication);
public void windowClosing(java.awt.event.WindowEvent);
}
BitmapDisplay
package mars.tools;
public synchronized class BitmapDisplay extends AbstractMarsToolAndApplication {
private static String version;
private static String heading;
private javax.swing.JComboBox visualizationUnitPixelWidthSelector;
private javax.swing.JComboBox visualizationUnitPixelHeightSelector;
private javax.swing.JComboBox visualizationPixelWidthSelector;
private javax.swing.JComboBox visualizationPixelHeightSelector;
private javax.swing.JComboBox displayBaseAddressSelector;
private java.awt.Graphics drawingArea;
private javax.swing.JPanel canvas;
private javax.swing.JPanel results;
private javax.swing.border.EmptyBorder emptyBorder;
private java.awt.Font countFonts;
private java.awt.Color backgroundColor;
private final String[] visualizationUnitPixelWidthChoices;
private final int defaultVisualizationUnitPixelWidthIndex;
private final String[] visualizationUnitPixelHeightChoices;
private final int defaultVisualizationUnitPixelHeightIndex;
private final String[] displayAreaPixelWidthChoices;
private final int defaultDisplayWidthIndex;
private final String[] displayAreaPixelHeightChoices;
private final int defaultDisplayHeightIndex;
private int unitPixelWidth;
private int unitPixelHeight;
private int displayAreaWidthInPixels;
private int displayAreaHeightInPixels;
private String[] displayBaseAddressChoices;
private int[] displayBaseAddresses;
private int defaultBaseAddressIndex;
private int baseAddress;
private BitmapDisplay$Grid theGrid;
public void BitmapDisplay(String, String);
public void BitmapDisplay();
public static void main(String[]);
public String getName();
protected void addAsObserver();
protected javax.swing.JComponent buildMainDisplayArea();
protected void processMIPSUpdate(java.util.Observable, mars.mips.hardware.AccessNotice);
protected void initializePreGUI();
protected void initializePostGUI();
protected void reset();
protected void updateDisplay();
protected javax.swing.JComponent getHelpComponent();
private javax.swing.JComponent buildOrganizationArea();
private javax.swing.JComponent buildVisualizationArea();
private void initializeDisplayBaseChoices();
private void updateBaseAddress();
private java.awt.Dimension getDisplayAreaDimension();
private void resetCounts();
private int getIntComboBoxSelection(javax.swing.JComboBox);
private javax.swing.JPanel getPanelWithBorderLayout();
private BitmapDisplay$Grid createNewGrid();
private void updateColorForAddress(mars.mips.hardware.MemoryAccessNotice);
static void
}
AbstractMarsToolAndApplication$10
package mars.tools;
synchronized class AbstractMarsToolAndApplication$10 implements java.awt.event.ActionListener {
void AbstractMarsToolAndApplication$10(AbstractMarsToolAndApplication);
public void actionPerformed(java.awt.event.ActionEvent);
}
ScribblerSettings2
package mars.tools;
synchronized class ScribblerSettings2 {
private int width;
private java.awt.Color color;
public void ScribblerSettings2(int, java.awt.Color);
public int getLineWidth();
public java.awt.Color getLineColor();
public void setLineWidth(int);
public void setLineColor(java.awt.Color);
}
AbstractMarsToolAndApplication$GUIUpdater
package mars.tools;
synchronized class AbstractMarsToolAndApplication$GUIUpdater implements Runnable {
private void AbstractMarsToolAndApplication$GUIUpdater(AbstractMarsToolAndApplication);
public void run();
}
CacheSimulator$CacheBlock
package mars.tools;
synchronized class CacheSimulator$CacheBlock {
private boolean valid;
private int tag;
private int sizeInWords;
private int mostRecentAccessTime;
public void CacheSimulator$CacheBlock(CacheSimulator, int);
}
FunctionUnitVisualization
package mars.tools;
public synchronized class FunctionUnitVisualization extends javax.swing.JFrame {
private javax.swing.JPanel contentPane;
private String instruction;
private int register;
private int control;
private int aluControl;
private int alu;
private int currentUnit;
public void FunctionUnitVisualization(String, int);
public void run();
}
CacheSimulator$4
package mars.tools;
synchronized class CacheSimulator$4 implements java.awt.event.ActionListener {
void CacheSimulator$4(CacheSimulator);
public void actionPerformed(java.awt.event.ActionEvent);
}
IntroToTools
package mars.tools;
public synchronized class IntroToTools extends AbstractMarsToolAndApplication {
private static String heading;
private static String version;
public void IntroToTools(String, String);
public void IntroToTools();
public static void main(String[]);
public String getName();
protected javax.swing.JComponent buildMainDisplayArea();
static void
}
UnitAnimation
package mars.tools;
synchronized class UnitAnimation extends javax.swing.JPanel implements java.awt.event.ActionListener {
private static final long serialVersionUID = -2681757800180958534;
private int PERIOD;
private static final int PWIDTH = 1000;
private static final int PHEIGHT = 574;
private java.awt.GraphicsConfiguration gc;
private java.awt.GraphicsDevice gd;
private int accelMemory;
private java.text.DecimalFormat df;
private int counter;
private boolean justStarted;
private int indexX;
private int indexY;
private boolean xIsMoving;
private boolean yIsMoving;
private java.util.Vector outputGraph;
private java.util.ArrayList vertexList;
private java.util.ArrayList vertexTraversed;
private java.util.HashMap registerEquivalenceTable;
private String instructionCode;
private int countRegLabel;
private int countALULabel;
private int countPCLabel;
private int register;
private int control;
private int aluControl;
private int alu;
private int datapatTypeUsed;
private Boolean cursorInIM;
private Boolean cursorInALU;
private Boolean cursorInDataMem;
private Boolean cursorInReg;
private java.awt.Graphics2D g2d;
private java.awt.image.BufferedImage datapath;
public void UnitAnimation(String, int);
public void loadHashMapValues();
public void importXmlStringData(String, java.util.HashMap, String, String, String);
public void importXmlDatapathMap(String, String);
public void importXmlDatapathMapAluControl(String, String);
public void startAnimation(String);
private void initImages();
public void updateDisplay();
public void actionPerformed(java.awt.event.ActionEvent);
public void paintComponent(java.awt.Graphics);
private void drawImage(java.awt.Graphics2D, java.awt.image.BufferedImage, int, int, java.awt.Color);
public void printTrackLtoR(UnitAnimation$Vertex);
public void printTrackRtoL(UnitAnimation$Vertex);
public void printTrackDtoU(UnitAnimation$Vertex);
public void printTrackUtoD(UnitAnimation$Vertex);
public String parseBinToInt(String);
private void executeAnimation(java.awt.Graphics);
}
FloatRepresentation$BinaryFractionDisplayTextField
package mars.tools;
synchronized class FloatRepresentation$BinaryFractionDisplayTextField extends javax.swing.JTextField {
public void FloatRepresentation$BinaryFractionDisplayTextField(FloatRepresentation, String, int);
public void paintComponent(java.awt.Graphics);
}
KeyboardAndDisplaySimulator$TransmitterDelayTechnique
package mars.tools;
abstract interface KeyboardAndDisplaySimulator$TransmitterDelayTechnique {
public abstract int generateDelay(double);
}
BitmapDisplay$5
package mars.tools;
synchronized class BitmapDisplay$5 implements java.awt.event.ActionListener {
void BitmapDisplay$5(BitmapDisplay);
public void actionPerformed(java.awt.event.ActionEvent);
}
MarsTool
package mars.tools;
public abstract interface MarsTool {
public abstract String getName();
public abstract void action();
}
AbstractMarsToolAndApplication$4
package mars.tools;
synchronized class AbstractMarsToolAndApplication$4 implements java.awt.event.ActionListener {
void AbstractMarsToolAndApplication$4(AbstractMarsToolAndApplication);
public void actionPerformed(java.awt.event.ActionEvent);
}
BitmapDisplay$1
package mars.tools;
synchronized class BitmapDisplay$1 implements java.awt.event.ActionListener {
void BitmapDisplay$1(BitmapDisplay);
public void actionPerformed(java.awt.event.ActionEvent);
}
CaptureDisplayAlignmentStrategy
package mars.tools;
abstract interface CaptureDisplayAlignmentStrategy {
public abstract void setScrollBarValue(javax.swing.JScrollBar);
}
InstructionStatistics
package mars.tools;
public synchronized class InstructionStatistics extends AbstractMarsToolAndApplication {
private static String NAME;
private static String VERSION;
private static String HEADING;
private static final int MAX_CATEGORY = 5;
private static final int CATEGORY_ALU = 0;
private static final int CATEGORY_JUMP = 1;
private static final int CATEGORY_BRANCH = 2;
private static final int CATEGORY_MEM = 3;
private static final int CATEGORY_OTHER = 4;
private javax.swing.JTextField m_tfTotalCounter;
private javax.swing.JTextField[] m_tfCounters;
private javax.swing.JProgressBar[] m_pbCounters;
private int m_totalCounter;
private int[] m_counters;
private String[] m_categoryLabels;
protected int lastAddress;
public void InstructionStatistics(String, String);
public void InstructionStatistics();
public String getName();
protected javax.swing.JComponent buildMainDisplayArea();
protected void addAsObserver();
protected int getInstructionCategory(mars.ProgramStatement);
protected void processMIPSUpdate(java.util.Observable, mars.mips.hardware.AccessNotice);
protected void initializePreGUI();
protected void reset();
protected void updateDisplay();
static void
}
FloatRepresentation$DecimalDisplayKeystokeListenter
package mars.tools;
synchronized class FloatRepresentation$DecimalDisplayKeystokeListenter extends java.awt.event.KeyAdapter {
private void FloatRepresentation$DecimalDisplayKeystokeListenter(FloatRepresentation);
public void keyTyped(java.awt.event.KeyEvent);
public void keyPressed(java.awt.event.KeyEvent);
private boolean isDecimalFloatDigit(char);
}
DigitalLabSim$SevenSegmentPanel
package mars.tools;
public synchronized class DigitalLabSim$SevenSegmentPanel extends javax.swing.JPanel {
public DigitalLabSim$SevenSegmentDisplay[] display;
public void DigitalLabSim$SevenSegmentPanel(DigitalLabSim);
public void modifyDisplay(int, char);
public void resetSevenSegment();
}
KeyboardAndDisplaySimulator$1
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$1 implements java.awt.event.ActionListener {
void KeyboardAndDisplaySimulator$1(KeyboardAndDisplaySimulator, String);
public void actionPerformed(java.awt.event.ActionEvent);
}
FloatRepresentation$BinaryDisplayKeystrokeListener
package mars.tools;
synchronized class FloatRepresentation$BinaryDisplayKeystrokeListener extends java.awt.event.KeyAdapter {
private int bitLength;
public void FloatRepresentation$BinaryDisplayKeystrokeListener(FloatRepresentation, int);
public void keyTyped(java.awt.event.KeyEvent);
public void keyPressed(java.awt.event.KeyEvent);
private boolean isBinaryDigit(char);
}
KeyboardAndDisplaySimulator$NormallyDistributedDelay
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$NormallyDistributedDelay implements KeyboardAndDisplaySimulator$TransmitterDelayTechnique {
java.util.Random randn;
public void KeyboardAndDisplaySimulator$NormallyDistributedDelay(KeyboardAndDisplaySimulator);
public String toString();
public int generateDelay(double);
}
KeyboardAndDisplaySimulator$DelayLengthPanel$DelayLengthListener
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$DelayLengthPanel$DelayLengthListener implements javax.swing.event.ChangeListener {
private void KeyboardAndDisplaySimulator$DelayLengthPanel$DelayLengthListener(KeyboardAndDisplaySimulator$DelayLengthPanel);
public void stateChanged(javax.swing.event.ChangeEvent);
}
SettingsDialog
package mars.tools;
synchronized class SettingsDialog extends javax.swing.JDialog {
javax.swing.JButton applyButton;
javax.swing.JButton cancelButton;
javax.swing.JCheckBox captureResizeCheckBox;
javax.swing.JCheckBox captureMoveCheckBox;
javax.swing.JCheckBox captureRescaleCheckBox;
javax.swing.JRadioButton captureDisplayCenteredButton;
javax.swing.JRadioButton captureDisplayUpperleftButton;
Integer[] scribblerLineWidthSettings;
javax.swing.JComboBox lineWidthSetting;
javax.swing.JButton lineColorSetting;
javax.swing.JCheckBox dialogCentered;
javax.swing.JDialog dialog;
java.awt.Color scribblerLineColorSetting;
static final String SETTINGS_APPLY_TOOLTIP_TEXT = Apply current settings and close the dialog.;
static final String SETTINGS_CANCEL_TOOLTIP_TEXT = Close the dialog without applying any setting changes.;
static final String SETTINGS_SCRIBBLER_WIDTH_TOOLTIP_TEXT = Scribbler line thickness in pixels.;
static final String SETTINGS_SCRIBBLER_COLOR_TOOLTIP_TEXT = Click here to change Scribbler line color.;
static final String SETTINGS_DIALOG_CENTERED_TOOLTIP_TEXT = Whether to center this dialog over the Magnifier.;
void SettingsDialog(javax.swing.JFrame);
private javax.swing.JPanel getButtonRowPanel();
private javax.swing.JPanel getAutomaticCaptureSettingsPanel();
private javax.swing.JPanel getCaptureDisplayPanel();
private javax.swing.JPanel getScribblerPanel(javax.swing.JDialog);
}
ScreenMagnifier$1
package mars.tools;
final synchronized class ScreenMagnifier$1 implements Runnable {
void ScreenMagnifier$1();
public void run();
}
CacheSimulator$2
package mars.tools;
synchronized class CacheSimulator$2 implements java.awt.event.ActionListener {
void CacheSimulator$2(CacheSimulator);
public void actionPerformed(java.awt.event.ActionEvent);
}
KeyboardAndDisplaySimulator$3
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$3 implements java.awt.event.ActionListener {
void KeyboardAndDisplaySimulator$3(KeyboardAndDisplaySimulator);
public void actionPerformed(java.awt.event.ActionEvent);
}
KeyboardAndDisplaySimulator$FontSettingDialog
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$FontSettingDialog extends mars.venus.AbstractFontSettingDialog {
private boolean resultOK;
public void KeyboardAndDisplaySimulator$FontSettingDialog(KeyboardAndDisplaySimulator, java.awt.Frame, String, java.awt.Font);
private java.awt.Font showDialog();
protected void closeDialog();
private void performCancel();
protected java.awt.Component buildControlPanel();
protected void apply(java.awt.Font);
}
ScavengerHunt
package mars.tools;
public synchronized class ScavengerHunt implements java.util.Observer, MarsTool {
private static final int GRAPHIC_WIDTH = 712;
private static final int GRAPHIC_HEIGHT = 652;
private static final int NUM_PLAYERS = 22;
private static final int MAX_X_MOVEMENT = 2;
private static final int MAX_Y_MOVEMENT = 2;
private static final double MAX_MOVE_DISTANCE = 2.5;
private static final int ENERGY_AWARD = 20;
private static final int ENERGY_PER_MOVE = 1;
private static final int SIZE_OF_TASK = 20;
private static final int NUM_LOCATIONS = 7;
private static final int START_AND_END_LOCATION = 255;
private static final int ADMINISTRATOR_ID = 999;
private static final int ADDR_AUTHENTICATION = -8192;
private static final int ADDR_PLAYER_ID = -8188;
private static final int ADDR_GAME_ON = -8184;
private static final int ADDR_NUM_TURNS = -8180;
private static final int ADDR_BASE = -32768;
private static final int MEM_PER_PLAYER = 1024;
private static final int OFFSET_WHERE_AM_I_X = 0;
private static final int OFFSET_WHERE_AM_I_Y = 4;
private static final int OFFSET_MOVE_TO_X = 8;
private static final int OFFSET_MOVE_TO_Y = 12;
private static final int OFFSET_MOVE_READY = 16;
private static final int OFFSET_ENERGY = 20;
private static final int OFFSET_NUMBER_LOCATIONS = 24;
private static final int OFFSET_PLAYER_COLOR = 28;
private static final int OFFSET_SIZE_OF_TASK = 32;
private static final int OFFSET_LOC_ARRAY = 36;
private static final int OFFSET_TASK_COMPLETE = 292;
private static final int OFFSET_TASK_ARRAY = 296;
private ScavengerHunt$ScavengerHuntDisplay graphicArea;
private int authenticationValue;
private boolean GameOn;
private static int SetWordCounter;
private static int accessCounter;
private static int playerID;
private boolean KENVDEBUG;
private static ScavengerHunt$PlayerData[] pd;
private static ScavengerHunt$Location[] loc;
private java.util.Random randomStream;
private long startTime;
public void ScavengerHunt();
public String getName();
public void action();
public void update(java.util.Observable, Object);
private void toolSetWord(int, int);
private int toolGetWord(int);
private int toolReadPlayerData(int, int);
private void toolWritePlayerData(int, int, int);
private void initializeScavengerData();
static void
}
KeyboardAndDisplaySimulator$UniformlyDistributedDelay
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$UniformlyDistributedDelay implements KeyboardAndDisplaySimulator$TransmitterDelayTechnique {
java.util.Random randu;
public void KeyboardAndDisplaySimulator$UniformlyDistributedDelay(KeyboardAndDisplaySimulator);
public String toString();
public int generateDelay(double);
}
ScavengerHunt$ScavengerHuntRunnable
package mars.tools;
synchronized class ScavengerHunt$ScavengerHuntRunnable implements Runnable {
javax.swing.JPanel panel;
public void ScavengerHunt$ScavengerHuntRunnable(ScavengerHunt);
public void run();
}
BitmapDisplay$3
package mars.tools;
synchronized class BitmapDisplay$3 implements java.awt.event.ActionListener {
void BitmapDisplay$3(BitmapDisplay);
public void actionPerformed(java.awt.event.ActionEvent);
}
AbstractMarsToolAndApplication$6
package mars.tools;
synchronized class AbstractMarsToolAndApplication$6 implements java.awt.event.ActionListener {
void AbstractMarsToolAndApplication$6(AbstractMarsToolAndApplication);
public void actionPerformed(java.awt.event.ActionEvent);
}
MemoryReferenceVisualization$GraphicsPanel
package mars.tools;
synchronized class MemoryReferenceVisualization$GraphicsPanel extends javax.swing.JPanel {
private void MemoryReferenceVisualization$GraphicsPanel(MemoryReferenceVisualization);
public void paint(java.awt.Graphics);
private void paintHashMarks(java.awt.Graphics, MemoryReferenceVisualization$Grid);
private void paintGrid(java.awt.Graphics, MemoryReferenceVisualization$Grid);
private java.awt.Color getContrastingColor(java.awt.Color);
}
MarsBot
package mars.tools;
public synchronized class MarsBot implements java.util.Observer, MarsTool {
private static final int GRAPHIC_WIDTH = 512;
private static final int GRAPHIC_HEIGHT = 512;
private static final int ADDR_HEADING = -32752;
private static final int ADDR_LEAVETRACK = -32736;
private static final int ADDR_WHEREAREWEX = -32720;
private static final int ADDR_WHEREAREWEY = -32704;
private static final int ADDR_MOVE = -32688;
private MarsBot$MarsBotDisplay graphicArea;
private int MarsBotHeading;
private boolean MarsBotLeaveTrack;
private double MarsBotXPosition;
private double MarsBotYPosition;
private boolean MarsBotMoving;
private final int trackPts;
private java.awt.Point[] arrayOfTrack;
private int trackIndex;
public void MarsBot();
public String getName();
public void action();
public void update(java.util.Observable, Object);
}
SettingsDialog2$1
package mars.tools;
synchronized class SettingsDialog2$1 implements java.awt.event.ActionListener {
void SettingsDialog2$1(SettingsDialog2);
public void actionPerformed(java.awt.event.ActionEvent);
}
ScreenMagnifier
package mars.tools;
public synchronized class ScreenMagnifier implements MarsTool {
public void ScreenMagnifier();
public String getName();
public void action();
public static void main(String[]);
}
MemoryReferenceVisualization$3
package mars.tools;
synchronized class MemoryReferenceVisualization$3 implements java.awt.event.ActionListener {
void MemoryReferenceVisualization$3(MemoryReferenceVisualization);
public void actionPerformed(java.awt.event.ActionEvent);
}
Magnifier
package mars.tools;
synchronized class Magnifier extends javax.swing.JFrame implements java.awt.event.ComponentListener {
static java.awt.Robot robot;
javax.swing.JButton close;
javax.swing.JButton capture;
javax.swing.JButton settings;
javax.swing.JSpinner scaleAdjuster;
javax.swing.JScrollPane view;
java.awt.Dimension frameSize;
java.awt.Dimension viewSize;
MagnifierImage magnifierImage;
java.awt.event.ActionListener captureActionListener;
CaptureModel captureResize;
CaptureModel captureMove;
CaptureModel captureRescale;
CaptureModel captureDisplayCenter;
CaptureModel captureDisplayUpperleft;
CaptureModel dialogDisplayCenter;
ScribblerSettings scribblerSettings;
static final double SCALE_MINIMUM = 1.0;
static final double SCALE_MAXIMUM = 4.0;
static final double SCALE_INCREMENT = 0.5;
static final double SCALE_DEFAULT = 2.0;
double scale;
CaptureDisplayAlignmentStrategy alignment;
CaptureRectangleStrategy captureLocationSize;
javax.swing.JFrame frame;
static final String CAPTURE_TOOLTIP_TEXT = Capture, scale, and display pixels that lay beneath the Magnifier.;
static final String SETTINGS_TOOLTIP_TEXT = Show dialog for changing tool settings.;
static final String SCALE_TOOLTIP_TEXT = Magnification scale for captured image.;
static final String CLOSE_TOOLTIP_TEXT = Exit the Screen Magnifier. Changed settings are NOT retained.;
void Magnifier();
private void createSettings();
private javax.swing.JButton getHelpButton();
java.awt.image.BufferedImage captureScreenSection(java.awt.Rectangle);
java.awt.Rectangle getFrameRectangle();
java.awt.Rectangle getScreenRectangle();
public void componentMoved(java.awt.event.ComponentEvent);
public void componentResized(java.awt.event.ComponentEvent);
public void componentShown(java.awt.event.ComponentEvent);
public void componentHidden(java.awt.event.ComponentEvent);
}
BitmapDisplay$Grid
package mars.tools;
synchronized class BitmapDisplay$Grid {
java.awt.Color[][] grid;
int rows;
int columns;
private void BitmapDisplay$Grid(BitmapDisplay, int, int);
private int getRows();
private int getColumns();
private java.awt.Color getElement(int, int);
private java.awt.Color getElementFast(int, int);
private void setElement(int, int, int);
private void setElement(int, int, java.awt.Color);
private void reset();
}
KeyboardAndDisplaySimulator$FontSettingDialog$3
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$FontSettingDialog$3 implements java.awt.event.ActionListener {
void KeyboardAndDisplaySimulator$FontSettingDialog$3(KeyboardAndDisplaySimulator$FontSettingDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
ScavengerHunt$ScavengerHuntRunnable$1
package mars.tools;
synchronized class ScavengerHunt$ScavengerHuntRunnable$1 implements java.awt.event.ActionListener {
void ScavengerHunt$ScavengerHuntRunnable$1(ScavengerHunt$ScavengerHuntRunnable, ScavengerHunt);
public void actionPerformed(java.awt.event.ActionEvent);
}
Magnifier$4
package mars.tools;
synchronized class Magnifier$4 implements javax.swing.event.ChangeListener {
void Magnifier$4(Magnifier);
public void stateChanged(javax.swing.event.ChangeEvent);
}
CaptureMagnifierRectangle
package mars.tools;
synchronized class CaptureMagnifierRectangle implements CaptureRectangleStrategy {
void CaptureMagnifierRectangle();
public java.awt.Rectangle getCaptureRectangle(java.awt.Rectangle);
}
BHTSimGUI$1
package mars.tools;
synchronized class BHTSimGUI$1 extends javax.swing.table.DefaultTableCellRenderer {
private java.text.DecimalFormat formatter;
void BHTSimGUI$1(BHTSimGUI);
public void setValue(Object);
}
KeyboardAndDisplaySimulator$FontSettingDialog$1
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$FontSettingDialog$1 implements java.awt.event.ActionListener {
void KeyboardAndDisplaySimulator$FontSettingDialog$1(KeyboardAndDisplaySimulator$FontSettingDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
MemoryReferenceVisualization$1
package mars.tools;
synchronized class MemoryReferenceVisualization$1 implements java.awt.event.ActionListener {
void MemoryReferenceVisualization$1(MemoryReferenceVisualization);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsDialog$2
package mars.tools;
synchronized class SettingsDialog$2 implements java.awt.event.ActionListener {
void SettingsDialog$2(SettingsDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
BHTSimGUI
package mars.tools;
public synchronized class BHTSimGUI extends javax.swing.JPanel {
private javax.swing.JTextField m_tfInstruction;
private javax.swing.JTextField m_tfAddress;
private javax.swing.JTextField m_tfIndex;
private javax.swing.JComboBox m_cbBHTentries;
private javax.swing.JComboBox m_cbBHThistory;
private javax.swing.JComboBox m_cbBHTinitVal;
private javax.swing.JTable m_tabBHT;
private javax.swing.JTextArea m_taLog;
public static final java.awt.Color COLOR_PREPREDICTION;
public static final java.awt.Color COLOR_PREDICTION_CORRECT;
public static final java.awt.Color COLOR_PREDICTION_INCORRECT;
public static final String BHT_TAKE_BRANCH = TAKE;
public static final String BHT_DO_NOT_TAKE_BRANCH = NOT TAKE;
public void BHTSimGUI();
private javax.swing.JTable createAndInitTable();
private javax.swing.JPanel buildInfoPanel();
private javax.swing.JPanel buildConfigPanel();
private javax.swing.JPanel buildLogPanel();
public javax.swing.JComboBox getCbBHTentries();
public javax.swing.JComboBox getCbBHThistory();
public javax.swing.JComboBox getCbBHTinitVal();
public javax.swing.JTable getTabBHT();
public javax.swing.JTextArea getTaLog();
public javax.swing.JTextField getTfInstruction();
public javax.swing.JTextField getTfAddress();
public javax.swing.JTextField getTfIndex();
static void
}
CaptureDisplayCentered
package mars.tools;
synchronized class CaptureDisplayCentered implements CaptureDisplayAlignmentStrategy {
void CaptureDisplayCentered();
public void setScrollBarValue(javax.swing.JScrollBar);
}
AbstractMarsToolAndApplication$8
package mars.tools;
synchronized class AbstractMarsToolAndApplication$8 implements java.awt.event.ActionListener {
void AbstractMarsToolAndApplication$8(AbstractMarsToolAndApplication);
public void actionPerformed(java.awt.event.ActionEvent);
}
InstructionCounter
package mars.tools;
public synchronized class InstructionCounter extends AbstractMarsToolAndApplication {
private static String name;
private static String version;
private static String heading;
protected int counter;
private javax.swing.JTextField counterField;
protected int counterR;
private javax.swing.JTextField counterRField;
private javax.swing.JProgressBar progressbarR;
protected int counterI;
private javax.swing.JTextField counterIField;
private javax.swing.JProgressBar progressbarI;
protected int counterJ;
private javax.swing.JTextField counterJField;
private javax.swing.JProgressBar progressbarJ;
protected int lastAddress;
public void InstructionCounter(String, String);
public void InstructionCounter();
public String getName();
protected javax.swing.JComponent buildMainDisplayArea();
protected void addAsObserver();
protected void processMIPSUpdate(java.util.Observable, mars.mips.hardware.AccessNotice);
protected void initializePreGUI();
protected void reset();
protected void updateDisplay();
static void
}
SettingsDialog2$3
package mars.tools;
synchronized class SettingsDialog2$3 implements java.awt.event.ActionListener {
void SettingsDialog2$3(SettingsDialog2, javax.swing.JDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
MarsBot$MarsBotDisplay
package mars.tools;
synchronized class MarsBot$MarsBotDisplay extends javax.swing.JPanel {
private int width;
private int height;
private boolean clearTheDisplay;
public void MarsBot$MarsBotDisplay(MarsBot, int, int);
public void redraw();
public void clear();
public void paintComponent(java.awt.Graphics);
}
KeyboardAndDisplaySimulator$KeyboardKeyListener
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$KeyboardKeyListener implements java.awt.event.KeyListener {
private void KeyboardAndDisplaySimulator$KeyboardKeyListener(KeyboardAndDisplaySimulator);
public void keyTyped(java.awt.event.KeyEvent);
public void keyPressed(java.awt.event.KeyEvent);
public void keyReleased(java.awt.event.KeyEvent);
}
DigitalLabSim
package mars.tools;
public synchronized class DigitalLabSim extends AbstractMarsToolAndApplication {
private static String heading;
private static String version;
private static final int IN_ADRESS_DISPLAY_1;
private static final int IN_ADRESS_DISPLAY_2;
private static final int IN_ADRESS_HEXA_KEYBOARD;
private static final int IN_ADRESS_COUNTER;
private static final int OUT_ADRESS_HEXA_KEYBOARD;
public static final int EXTERNAL_INTERRUPT_TIMER = 256;
public static final int EXTERNAL_INTERRUPT_HEXA_KEYBOARD = 512;
private static javax.swing.JPanel panelTools;
private DigitalLabSim$SevenSegmentPanel sevenSegPanel;
private static int KeyBoardValueButtonClick;
private DigitalLabSim$HexaKeyboard hexaKeyPanel;
private static boolean KeyboardInterruptOnOff;
private static int CounterValueMax;
private static int CounterValue;
private static boolean CounterInterruptOnOff;
private static DigitalLabSim$OneSecondCounter SecondCounter;
public void DigitalLabSim(String, String);
public void DigitalLabSim();
public static void main(String[]);
public String getName();
protected void addAsObserver();
public void update(java.util.Observable, Object);
protected void reset();
protected javax.swing.JComponent buildMainDisplayArea();
private synchronized void updateMMIOControlAndData(int, int);
protected javax.swing.JComponent getHelpComponent();
public void updateSevenSegment(int, char);
public void updateHexaKeyboard(char);
public void updateOneSecondCounter(char);
static void
}
MemoryReferenceVisualization$ColorChooserControls$ColorChooserListener
package mars.tools;
synchronized class MemoryReferenceVisualization$ColorChooserControls$ColorChooserListener implements javax.swing.event.ChangeListener {
private void MemoryReferenceVisualization$ColorChooserControls$ColorChooserListener(MemoryReferenceVisualization$ColorChooserControls);
public void stateChanged(javax.swing.event.ChangeEvent);
}
Magnifier$2
package mars.tools;
synchronized class Magnifier$2 implements java.awt.event.ActionListener {
void Magnifier$2(Magnifier);
public void actionPerformed(java.awt.event.ActionEvent);
}
CaptureModel
package mars.tools;
synchronized class CaptureModel {
private boolean enabled;
public void CaptureModel(boolean);
public boolean isEnabled();
public void setEnabled(boolean);
}
BHTSimulator
package mars.tools;
public synchronized class BHTSimulator extends AbstractMarsToolAndApplication implements java.awt.event.ActionListener {
public static final int BHT_DEFAULT_SIZE = 16;
public static final int BHT_DEFAULT_HISTORY = 1;
public static final boolean BHT_DEFAULT_INITVAL = 0;
public static final String BHT_NAME = BHT Simulator;
public static final String BHT_VERSION = Version 1.0 (Ingo Kofler);
public static final String BHT_HEADING = Branch History Table Simulator;
private BHTSimGUI m_gui;
private BHTableModel m_bhtModel;
private int m_pendingBranchInstAddress;
private boolean m_lastBranchTaken;
public void BHTSimulator();
protected void addAsObserver();
protected javax.swing.JComponent buildMainDisplayArea();
public String getName();
protected void reset();
public void actionPerformed(java.awt.event.ActionEvent);
protected void resetSimulator();
protected void handlePreBranchInst(mars.ProgramStatement);
protected void handleExecBranchInst(int, boolean);
protected static boolean isBranchInstruction(mars.ProgramStatement);
protected static boolean willBranch(mars.ProgramStatement);
protected static int extractBranchAddress(mars.ProgramStatement);
protected void processMIPSUpdate(java.util.Observable, mars.mips.hardware.AccessNotice);
}
MemoryReferenceVisualization$5
package mars.tools;
synchronized class MemoryReferenceVisualization$5 implements java.awt.event.ActionListener {
void MemoryReferenceVisualization$5(MemoryReferenceVisualization);
public void actionPerformed(java.awt.event.ActionEvent);
}
UnitAnimation$Vertex
package mars.tools;
synchronized class UnitAnimation$Vertex {
private int numIndex;
private int init;
private int end;
private int current;
private String name;
public static final int movingUpside = 1;
public static final int movingDownside = 2;
public static final int movingLeft = 3;
public static final int movingRight = 4;
public int direction;
public int oppositeAxis;
private boolean isMovingXaxis;
private java.awt.Color color;
private boolean first_interaction;
private boolean active;
private boolean isText;
private java.util.ArrayList targetVertex;
public void UnitAnimation$Vertex(UnitAnimation, int, int, int, String, int, boolean, String, String, boolean);
public int getDirection();
public boolean isText();
public java.util.ArrayList getTargetVertex();
public int getNumIndex();
public void setNumIndex(int);
public int getInit();
public void setInit(int);
public int getEnd();
public void setEnd(int);
public int getCurrent();
public void setCurrent(int);
public String getName();
public void setName(String);
public int getOppositeAxis();
public void setOppositeAxis(int);
public boolean isMovingXaxis();
public void setMovingXaxis(boolean);
public java.awt.Color getColor();
public void setColor(java.awt.Color);
public boolean isFirst_interaction();
public void setFirst_interaction(boolean);
public boolean isActive();
public void setActive(boolean);
}
BHTEntry
package mars.tools;
public synchronized class BHTEntry {
private boolean[] m_history;
private boolean m_prediction;
private int m_incorrect;
private int m_correct;
public void BHTEntry(int, boolean);
public boolean getPrediction();
public void updatePrediction(boolean);
public int getStatsPredIncorrect();
public int getStatsPredCorrect();
public double getStatsPredPrecision();
public String getHistoryAsStr();
public String getPredictionAsStr();
}
MemoryReferenceVisualization$7
package mars.tools;
synchronized class MemoryReferenceVisualization$7 implements java.awt.event.ActionListener {
void MemoryReferenceVisualization$7(MemoryReferenceVisualization);
public void actionPerformed(java.awt.event.ActionEvent);
}
BitmapDisplay$GraphicsPanel
package mars.tools;
synchronized class BitmapDisplay$GraphicsPanel extends javax.swing.JPanel {
private void BitmapDisplay$GraphicsPanel(BitmapDisplay);
public void paint(java.awt.Graphics);
private void paintGrid(java.awt.Graphics, BitmapDisplay$Grid);
}
MarsBot$BotRunnable$2
package mars.tools;
synchronized class MarsBot$BotRunnable$2 implements java.awt.event.ActionListener {
void MarsBot$BotRunnable$2(MarsBot$BotRunnable, MarsBot, javax.swing.JFrame);
public void actionPerformed(java.awt.event.ActionEvent);
}
DigitalLabSim$SevenSegmentDisplay
package mars.tools;
public synchronized class DigitalLabSim$SevenSegmentDisplay extends javax.swing.JComponent {
public char aff;
public void DigitalLabSim$SevenSegmentDisplay(DigitalLabSim, char);
public void modifyDisplay(char);
public void SwitchSegment(java.awt.Graphics, char);
public void paint(java.awt.Graphics);
}
AbstractMarsToolAndApplication$ConnectButton
package mars.tools;
public synchronized class AbstractMarsToolAndApplication$ConnectButton extends javax.swing.JButton {
private static final String connectText = Connect to MIPS;
private static final String disconnectText = Disconnect from MIPS;
public void AbstractMarsToolAndApplication$ConnectButton(AbstractMarsToolAndApplication);
public void connect();
public void disconnect();
public boolean isConnected();
}
KeyboardAndDisplaySimulator$1$1
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$1$1 implements java.awt.event.ActionListener {
void KeyboardAndDisplaySimulator$1$1(KeyboardAndDisplaySimulator$1, javax.swing.JDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
MagnifierImage$1
package mars.tools;
synchronized class MagnifierImage$1 extends java.awt.event.MouseAdapter {
void MagnifierImage$1(MagnifierImage);
public void mousePressed(java.awt.event.MouseEvent);
}
DigitalLabSim$1
package mars.tools;
synchronized class DigitalLabSim$1 implements java.awt.event.ActionListener {
void DigitalLabSim$1(DigitalLabSim);
public void actionPerformed(java.awt.event.ActionEvent);
}
MemoryReferenceVisualization$Grid
package mars.tools;
synchronized class MemoryReferenceVisualization$Grid {
int[][] grid;
int rows;
int columns;
private void MemoryReferenceVisualization$Grid(MemoryReferenceVisualization, int, int);
private int getRows();
private int getColumns();
private int getElement(int, int);
private int getElementFast(int, int);
private int incrementElement(int, int);
private void reset();
}
DigitalLabSim$HexaKeyboard
package mars.tools;
public synchronized class DigitalLabSim$HexaKeyboard extends javax.swing.JPanel {
public javax.swing.JButton[] button;
public void DigitalLabSim$HexaKeyboard(DigitalLabSim);
public void resetHexaKeyboard();
}
SettingsDialog$3
package mars.tools;
synchronized class SettingsDialog$3 implements java.awt.event.ActionListener {
void SettingsDialog$3(SettingsDialog, javax.swing.JDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
DigitalLabSim$HexaKeyboard$EcouteurClick
package mars.tools;
public synchronized class DigitalLabSim$HexaKeyboard$EcouteurClick implements java.awt.event.MouseListener {
private int buttonValue;
public void DigitalLabSim$HexaKeyboard$EcouteurClick(DigitalLabSim$HexaKeyboard, int);
public void mouseEntered(java.awt.event.MouseEvent);
public void mouseExited(java.awt.event.MouseEvent);
public void mousePressed(java.awt.event.MouseEvent);
public void mouseReleased(java.awt.event.MouseEvent);
public void mouseClicked(java.awt.event.MouseEvent);
}
ScavengerHunt$ScavengerHuntRunnable$2
package mars.tools;
synchronized class ScavengerHunt$ScavengerHuntRunnable$2 extends java.awt.event.WindowAdapter {
void ScavengerHunt$ScavengerHuntRunnable$2(ScavengerHunt$ScavengerHuntRunnable, ScavengerHunt, javax.swing.JDialog);
public void windowClosing(java.awt.event.WindowEvent);
}
DigitalLabSim$OneSecondCounter
package mars.tools;
public synchronized class DigitalLabSim$OneSecondCounter {
public void DigitalLabSim$OneSecondCounter(DigitalLabSim);
public void resetOneSecondCounter();
}
AbstractMarsToolAndApplication$9
package mars.tools;
synchronized class AbstractMarsToolAndApplication$9 implements java.awt.event.ActionListener {
void AbstractMarsToolAndApplication$9(AbstractMarsToolAndApplication);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsDialog2$2
package mars.tools;
synchronized class SettingsDialog2$2 implements java.awt.event.ActionListener {
void SettingsDialog2$2(SettingsDialog2);
public void actionPerformed(java.awt.event.ActionEvent);
}
FloatRepresentation$BinaryToDecimalFormulaGraphic
package mars.tools;
synchronized class FloatRepresentation$BinaryToDecimalFormulaGraphic extends javax.swing.JPanel {
final String subtractLabelTrailer;
final int arrowHeadOffset;
final int lowerY;
final int upperY;
int centerX;
int exponentCenterX;
int subtractLabelWidth;
int subtractLabelHeight;
int centerY;
int upperYArrowHead;
int currentExponent;
void FloatRepresentation$BinaryToDecimalFormulaGraphic(FloatRepresentation);
public void paintComponent(java.awt.Graphics);
public void drawSubtractLabel(int);
private void drawSubtractLabel(java.awt.Graphics, String);
private String buildSubtractLabel(int);
}
BHTableModel
package mars.tools;
public synchronized class BHTableModel extends javax.swing.table.AbstractTableModel {
private java.util.Vector m_entries;
private int m_entryCnt;
private int m_historySize;
private String[] m_columnNames;
private Class[] m_columnClasses;
public void BHTableModel(int, int, boolean);
public String getColumnName(int);
public Class getColumnClass(int);
public int getColumnCount();
public int getRowCount();
public Object getValueAt(int, int);
public void initBHT(int, int, boolean);
public int getIdxForAddress(int);
public boolean getPredictionAtIdx(int);
public void updatePredictionAtIdx(int, boolean);
}
Magnifier$5
package mars.tools;
synchronized class Magnifier$5 implements java.awt.event.ActionListener {
void Magnifier$5(Magnifier);
public void actionPerformed(java.awt.event.ActionEvent);
}
CaptureRectangleStrategy
package mars.tools;
abstract interface CaptureRectangleStrategy {
public abstract java.awt.Rectangle getCaptureRectangle(java.awt.Rectangle);
}
SettingsDialog$1
package mars.tools;
synchronized class SettingsDialog$1 implements java.awt.event.ActionListener {
void SettingsDialog$1(SettingsDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
MemoryReferenceVisualization$2
package mars.tools;
synchronized class MemoryReferenceVisualization$2 implements java.awt.event.ActionListener {
void MemoryReferenceVisualization$2(MemoryReferenceVisualization);
public void actionPerformed(java.awt.event.ActionEvent);
}
KeyboardAndDisplaySimulator$FontSettingDialog$2
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$FontSettingDialog$2 implements java.awt.event.ActionListener {
void KeyboardAndDisplaySimulator$FontSettingDialog$2(KeyboardAndDisplaySimulator$FontSettingDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
KeyboardAndDisplaySimulator$DelayLengthPanel
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$DelayLengthPanel extends javax.swing.JPanel {
private static final int DELAY_INDEX_MIN = 0;
private static final int DELAY_INDEX_MAX = 40;
private static final int DELAY_INDEX_INIT = 4;
private double[] delayTable;
private javax.swing.JLabel sliderLabel;
private volatile int delayLengthIndex;
public void KeyboardAndDisplaySimulator$DelayLengthPanel(KeyboardAndDisplaySimulator);
public double getDelayLength();
private String setLabel(int);
}
FloatRepresentation$FlavorsOfFloat
package mars.tools;
synchronized class FloatRepresentation$FlavorsOfFloat {
String hexString;
String binaryString;
String decimalString;
String expansionString;
int intValue;
private void FloatRepresentation$FlavorsOfFloat(FloatRepresentation);
public FloatRepresentation$FlavorsOfFloat buildOneFromHexString(String);
private FloatRepresentation$FlavorsOfFloat buildOneFromBinaryString();
private FloatRepresentation$FlavorsOfFloat buildOneFromDecimalString(String);
private FloatRepresentation$FlavorsOfFloat buildOneFromInt(int);
public String buildExpansionFromBinaryString(String);
private String getFullBinaryStringFromDisplays();
private String addLeadingZeroes(String, int);
}
MagnifierImage
package mars.tools;
synchronized class MagnifierImage extends javax.swing.JPanel {
private Magnifier frame;
private java.awt.Rectangle screenRectangle;
private static java.awt.Robot robot;
private java.awt.Image image;
private MagnifierImage$Scribbler scribbler;
public void MagnifierImage(Magnifier);
public java.awt.Image getImage();
public void paintComponent(java.awt.Graphics);
public void setImage(java.awt.Image);
static java.awt.Image getScaledImage(java.awt.Image, double, int);
static java.awt.Image getScaledImage(java.awt.Image, double);
}
Magnifier$1
package mars.tools;
synchronized class Magnifier$1 implements java.awt.event.ActionListener {
void Magnifier$1(Magnifier);
public void actionPerformed(java.awt.event.ActionEvent);
}
MemoryReferenceVisualization$ColorChooserControls
package mars.tools;
synchronized class MemoryReferenceVisualization$ColorChooserControls {
private javax.swing.JLabel sliderLabel;
private javax.swing.JSlider colorRangeSlider;
private javax.swing.JButton currentColorButton;
private javax.swing.JPanel colorChooserRow;
private javax.swing.JPanel countDisplayRow;
private volatile int counterIndex;
private void MemoryReferenceVisualization$ColorChooserControls(MemoryReferenceVisualization);
private String setLabel(int);
}
MemoryReferenceVisualization$6
package mars.tools;
synchronized class MemoryReferenceVisualization$6 implements java.awt.event.ActionListener {
void MemoryReferenceVisualization$6(MemoryReferenceVisualization);
public void actionPerformed(java.awt.event.ActionEvent);
}
MipsXray$DatapathAnimation
package mars.tools;
synchronized class MipsXray$DatapathAnimation extends javax.swing.JPanel implements java.awt.event.ActionListener, java.awt.event.MouseListener {
private static final long serialVersionUID = -2681757800180958534;
private int PERIOD;
private static final int PWIDTH = 1000;
private static final int PHEIGHT = 574;
private java.awt.GraphicsConfiguration gc;
private java.awt.GraphicsDevice gd;
private int accelMemory;
private java.text.DecimalFormat df;
private int counter;
private boolean justStarted;
private int indexX;
private int indexY;
private boolean xIsMoving;
private boolean yIsMoving;
private java.util.Vector outputGraph;
private java.util.ArrayList vertexList;
private java.util.ArrayList vertexTraversed;
private java.util.HashMap opcodeEquivalenceTable;
private java.util.HashMap functionEquivalenceTable;
private java.util.HashMap registerEquivalenceTable;
private String instructionCode;
private int countRegLabel;
private int countALULabel;
private int countPCLabel;
private java.awt.Color green1;
private java.awt.Color green2;
private java.awt.Color yellow2;
private java.awt.Color orange1;
private java.awt.Color orange;
private java.awt.Color blue2;
private int register;
private int control;
private int aluControl;
private int alu;
private int currentUnit;
private java.awt.Graphics2D g2d;
private java.awt.image.BufferedImage datapath;
public void mousePressed(java.awt.event.MouseEvent);
public void MipsXray$DatapathAnimation(MipsXray, String);
public void loadHashMapValues();
public void importXmlStringData(String, java.util.HashMap, String, String, String);
public void importXmlDatapathMap(String, String);
public void setUpInstructionInfo(java.awt.Graphics2D);
public void startAnimation(String);
private void initImages();
public void actionPerformed(java.awt.event.ActionEvent);
public void paintComponent(java.awt.Graphics);
private void drawImage(java.awt.Graphics2D, java.awt.image.BufferedImage, int, int, java.awt.Color);
public void printTrackLtoR(MipsXray$Vertex);
public void printTrackRtoL(MipsXray$Vertex);
public void printTrackDtoU(MipsXray$Vertex);
public void printTrackUtoD(MipsXray$Vertex);
public void printTextDtoU(MipsXray$Vertex);
public String parseBinToInt(String);
private void executeAnimation(java.awt.Graphics);
public void mouseClicked(java.awt.event.MouseEvent);
public void mouseEntered(java.awt.event.MouseEvent);
public void mouseExited(java.awt.event.MouseEvent);
public void mouseReleased(java.awt.event.MouseEvent);
}
CaptureScaledRectangle
package mars.tools;
synchronized class CaptureScaledRectangle implements CaptureRectangleStrategy {
void CaptureScaledRectangle();
public java.awt.Rectangle getCaptureRectangle(java.awt.Rectangle);
}
CaptureDisplayUpperleft
package mars.tools;
synchronized class CaptureDisplayUpperleft implements CaptureDisplayAlignmentStrategy {
void CaptureDisplayUpperleft();
public void setScrollBarValue(javax.swing.JScrollBar);
}
MemoryReferenceVisualization$CounterColorScale
package mars.tools;
synchronized class MemoryReferenceVisualization$CounterColorScale {
MemoryReferenceVisualization$CounterColor[] counterColors;
void MemoryReferenceVisualization$CounterColorScale(MemoryReferenceVisualization, MemoryReferenceVisualization$CounterColor[]);
private java.awt.Color getColor(int);
private int getHighEndOfRange(int);
private void insertOrReplace(MemoryReferenceVisualization$CounterColor);
}
KeyboardAndDisplaySimulator$FixedLengthDelay
package mars.tools;
synchronized class KeyboardAndDisplaySimulator$FixedLengthDelay implements KeyboardAndDisplaySimulator$TransmitterDelayTechnique {
private void KeyboardAndDisplaySimulator$FixedLengthDelay(KeyboardAndDisplaySimulator);
public String toString();
public int generateDelay(double);
}
MemoryReferenceVisualization
package mars.tools;
public synchronized class MemoryReferenceVisualization extends AbstractMarsToolAndApplication {
private static String version;
private static String heading;
private javax.swing.JComboBox wordsPerUnitSelector;
private javax.swing.JComboBox visualizationUnitPixelWidthSelector;
private javax.swing.JComboBox visualizationUnitPixelHeightSelector;
private javax.swing.JComboBox visualizationPixelWidthSelector;
private javax.swing.JComboBox visualizationPixelHeightSelector;
private javax.swing.JComboBox displayBaseAddressSelector;
private javax.swing.JCheckBox drawHashMarksSelector;
private java.awt.Graphics drawingArea;
private javax.swing.JPanel canvas;
private javax.swing.JPanel results;
private javax.swing.border.EmptyBorder emptyBorder;
private java.awt.Font countFonts;
private java.awt.Color backgroundColor;
private final String[] wordsPerUnitChoices;
private final int defaultWordsPerUnitIndex;
private final String[] visualizationUnitPixelWidthChoices;
private final int defaultVisualizationUnitPixelWidthIndex;
private final String[] visualizationUnitPixelHeightChoices;
private final int defaultVisualizationUnitPixelHeightIndex;
private final String[] displayAreaPixelWidthChoices;
private final int defaultDisplayWidthIndex;
private final String[] displayAreaPixelHeightChoices;
private final int defaultDisplayHeightIndex;
private final boolean defaultDrawHashMarks;
private int unitPixelWidth;
private int unitPixelHeight;
private int wordsPerUnit;
private int visualizationAreaWidthInPixels;
private int visualizationAreaHeightInPixels;
private MemoryReferenceVisualization$CounterColor[] defaultCounterColors;
private int[] countTable;
private final int COUNT_INDEX_INIT;
private String[] displayBaseAddressChoices;
private int[] displayBaseAddresses;
private int defaultBaseAddressIndex;
private int baseAddress;
private MemoryReferenceVisualization$Grid theGrid;
private MemoryReferenceVisualization$CounterColorScale counterColorScale;
public void MemoryReferenceVisualization(String, String);
public void MemoryReferenceVisualization();
public static void main(String[]);
public String getName();
protected void addAsObserver();
protected javax.swing.JComponent buildMainDisplayArea();
protected void processMIPSUpdate(java.util.Observable, mars.mips.hardware.AccessNotice);
protected void initializePreGUI();
protected void initializePostGUI();
protected void reset();
protected void updateDisplay();
protected javax.swing.JComponent getHelpComponent();
private javax.swing.JComponent buildOrganizationArea();
private javax.swing.JComponent buildVisualizationArea();
private void initializeDisplayBaseChoices();
private void updateBaseAddress();
private java.awt.Dimension getDisplayAreaDimension();
private void resetCounts();
private int getIntComboBoxSelection(javax.swing.JComboBox);
private javax.swing.JPanel getPanelWithBorderLayout();
private MemoryReferenceVisualization$Grid createNewGrid();
private void incrementReferenceCountForAddress(int);
static void
}
MagnifierImage$2
package mars.tools;
synchronized class MagnifierImage$2 extends java.awt.event.MouseMotionAdapter {
void MagnifierImage$2(MagnifierImage);
public void mouseDragged(java.awt.event.MouseEvent);
}
MemoryReferenceVisualization$CounterColor
package mars.tools;
synchronized class MemoryReferenceVisualization$CounterColor implements Comparable {
private int colorRangeStart;
private java.awt.Color associatedColor;
public void MemoryReferenceVisualization$CounterColor(MemoryReferenceVisualization, int, java.awt.Color);
public int compareTo(Object);
}
MemoryReferenceVisualization$4
package mars.tools;
synchronized class MemoryReferenceVisualization$4 implements java.awt.event.ActionListener {
void MemoryReferenceVisualization$4(MemoryReferenceVisualization);
public void actionPerformed(java.awt.event.ActionEvent);
}
FloatRepresentation$HexDisplayKeystrokeListener
package mars.tools;
synchronized class FloatRepresentation$HexDisplayKeystrokeListener extends java.awt.event.KeyAdapter {
private int digitLength;
public void FloatRepresentation$HexDisplayKeystrokeListener(FloatRepresentation, int);
public void keyTyped(java.awt.event.KeyEvent);
public void keyPressed(java.awt.event.KeyEvent);
private boolean isHexDigit(char);
}
MarsBot$BotRunnable$1
package mars.tools;
synchronized class MarsBot$BotRunnable$1 implements java.awt.event.ActionListener {
void MarsBot$BotRunnable$1(MarsBot$BotRunnable, MarsBot);
public void actionPerformed(java.awt.event.ActionEvent);
}
ScavengerHunt$Location
package mars.tools;
synchronized class ScavengerHunt$Location {
public int X;
public int Y;
private void ScavengerHunt$Location(ScavengerHunt);
}
FloatRepresentation
package mars.tools;
public synchronized class FloatRepresentation extends AbstractMarsToolAndApplication {
private static String version;
private static String heading;
private static final String title = Floating Point Representation, ;
private static final String defaultHex = 00000000;
private static final String defaultDecimal = 0.0;
private static final String defaultBinarySign = 0;
private static final String defaultBinaryExponent = 00000000;
private static final String defaultBinaryFraction = 00000000000000000000000;
private static final int maxLengthHex = 8;
private static final int maxLengthBinarySign = 1;
private static final int maxLengthBinaryExponent = 8;
private static final int maxLengthBinaryFraction = 23;
private static final int maxLengthBinaryTotal = 32;
private static final int maxLengthDecimal = 20;
private static final String denormalizedLabel = significand (denormalized – no ‘hidden bit’);
private static final String normalizedLabel = significand (‘hidden bit’ underlined) ;
private static final java.awt.Font instructionsFont;
private static final java.awt.Font hexDisplayFont;
private static final java.awt.Font binaryDisplayFont;
private static final java.awt.Font decimalDisplayFont;
private static final java.awt.Color hexDisplayColor;
private static final java.awt.Color binaryDisplayColor;
private static final java.awt.Color decimalDisplayColor;
private static final String expansionFontTag = ;
private static final String instructionFontTag = ;
private static final int exponentBias = 127;
private mars.mips.hardware.Register attachedRegister;
private mars.mips.hardware.Register[] fpRegisters;
private FloatRepresentation thisFloatTool;
private javax.swing.JPanel binarySignDecoratedDisplay;
private javax.swing.JPanel binaryExponentDecoratedDisplay;
private javax.swing.JPanel binaryFractionDecoratedDisplay;
private javax.swing.JTextField hexDisplay;
private javax.swing.JTextField decimalDisplay;
private javax.swing.JTextField binarySignDisplay;
private javax.swing.JTextField binaryExponentDisplay;
private javax.swing.JTextField binaryFractionDisplay;
private javax.swing.JLabel expansionDisplay;
private javax.swing.JLabel significandLabel;
private FloatRepresentation$BinaryToDecimalFormulaGraphic binaryToDecimalFormulaGraphic;
private FloatRepresentation$InstructionsPane instructions;
private String defaultInstructions;
private static final String zeroes = 0000000000000000000000000000000000000000000000000000000000000000;
private static final String HTMLspaces = ;
public void FloatRepresentation(String, String);
public void FloatRepresentation();
public static void main(String[]);
public String getName();
protected void addAsObserver();
protected void deleteAsObserver();
protected javax.swing.JComponent buildMainDisplayArea();
public void update(java.util.Observable, Object);
protected void reset();
protected javax.swing.JComponent buildDisplayArea();
private synchronized void updateAnyAttachedRegister(int);
private void updateDisplays(FloatRepresentation$FlavorsOfFloat);
private void updateDisplaysAndRegister(FloatRepresentation$FlavorsOfFloat);
private void updateSignificandLabel(FloatRepresentation$FlavorsOfFloat);
static void
}
Magnifier$3
package mars.tools;
synchronized class Magnifier$3 implements java.awt.event.ActionListener {
void Magnifier$3(Magnifier);
public void actionPerformed(java.awt.event.ActionEvent);
}
TokenList
package mars.assembler;
public synchronized class TokenList implements Cloneable {
private java.util.ArrayList tokenList;
private String processedLine;
public void TokenList();
public void setProcessedLine(String);
public String getProcessedLine();
public Token get(int);
public void set(int, Token);
public int size();
public void add(Token);
public void remove(int);
public boolean isEmpty();
public String toString();
public String toTypeString();
public Object clone();
}
Directives
package mars.assembler;
public final synchronized class Directives {
private static java.util.ArrayList directiveList;
public static final Directives DATA;
public static final Directives TEXT;
public static final Directives WORD;
public static final Directives ASCII;
public static final Directives ASCIIZ;
public static final Directives BYTE;
public static final Directives ALIGN;
public static final Directives HALF;
public static final Directives SPACE;
public static final Directives DOUBLE;
public static final Directives FLOAT;
public static final Directives EXTERN;
public static final Directives KDATA;
public static final Directives KTEXT;
public static final Directives GLOBL;
public static final Directives SET;
public static final Directives EQV;
public static final Directives MACRO;
public static final Directives END_MACRO;
public static final Directives INCLUDE;
private String descriptor;
private String description;
private void Directives();
private void Directives(String, String);
public static Directives matchDirective(String);
public static java.util.ArrayList prefixMatchDirectives(String);
public String toString();
public String getName();
public String getDescription();
public static java.util.ArrayList getDirectiveList();
public static boolean isIntegerDirective(Directives);
public static boolean isFloatingDirective(Directives);
static void
}
TokenTypes
package mars.assembler;
public final synchronized class TokenTypes {
public static final String TOKEN_DELIMITERS = ,();
public static final TokenTypes COMMENT;
public static final TokenTypes DIRECTIVE;
public static final TokenTypes OPERATOR;
public static final TokenTypes DELIMITER;
public static final TokenTypes REGISTER_NAME;
public static final TokenTypes REGISTER_NUMBER;
public static final TokenTypes FP_REGISTER_NAME;
public static final TokenTypes IDENTIFIER;
public static final TokenTypes LEFT_PAREN;
public static final TokenTypes RIGHT_PAREN;
public static final TokenTypes INTEGER_5;
public static final TokenTypes INTEGER_16;
public static final TokenTypes INTEGER_16U;
public static final TokenTypes INTEGER_32;
public static final TokenTypes REAL_NUMBER;
public static final TokenTypes QUOTED_STRING;
public static final TokenTypes PLUS;
public static final TokenTypes MINUS;
public static final TokenTypes COLON;
public static final TokenTypes ERROR;
public static final TokenTypes MACRO_PARAMETER;
private String descriptor;
private void TokenTypes();
private void TokenTypes(String);
public String toString();
public static TokenTypes matchTokenType(String);
public static boolean isIntegerTokenType(TokenTypes);
public static boolean isFloatingTokenType(TokenTypes);
public static boolean isValidIdentifier(String);
static void
}
TranslationCode
package mars.assembler;
public abstract interface TranslationCode {
public abstract void translate();
}
Tokenizer
package mars.assembler;
public synchronized class Tokenizer {
private mars.ErrorList errors;
private mars.MIPSprogram sourceMIPSprogram;
private java.util.HashMap equivalents;
private static final String escapedCharacters = ‘”\ntbrf0;
private static final String[] escapedCharactersValues;
public void Tokenizer();
public void Tokenizer(mars.MIPSprogram);
public java.util.ArrayList tokenize(mars.MIPSprogram) throws mars.ProcessingException;
private java.util.ArrayList processIncludes(mars.MIPSprogram, java.util.Map) throws mars.ProcessingException;
public TokenList tokenizeExampleInstruction(String) throws mars.ProcessingException;
public TokenList tokenizeLine(int, String);
public TokenList tokenizeLine(int, String, mars.ErrorList);
public TokenList tokenizeLine(int, String, mars.ErrorList, boolean);
public TokenList tokenizeLine(mars.MIPSprogram, int, String, boolean);
private TokenList processEqv(mars.MIPSprogram, int, String, TokenList);
public mars.ErrorList getErrors();
private void processCandidateToken(char[], mars.MIPSprogram, int, String, int, int, TokenList);
private String preprocessCharacterLiteral(String);
static void
}
MacroPool
package mars.assembler;
public synchronized class MacroPool {
private mars.MIPSprogram program;
private java.util.ArrayList macroList;
private Macro current;
private java.util.ArrayList callStack;
private java.util.ArrayList callStackOrigLines;
private int counter;
public void MacroPool(mars.MIPSprogram);
public void beginMacro(Token);
public void commitMacro(Token);
public Macro getMatchingMacro(TokenList, int);
public boolean matchesAnyMacroName(String);
public Macro getCurrent();
public void setCurrent(Macro);
public int getNextCounter();
public java.util.ArrayList getCallStack();
public boolean pushOnCallStack(Token);
public void popFromCallStack();
public String getExpansionHistory();
}
Macro
package mars.assembler;
public synchronized class Macro {
private String name;
private mars.MIPSprogram program;
private java.util.ArrayList labels;
private int fromLine;
private int toLine;
private int origFromLine;
private int origToLine;
private java.util.ArrayList args;
public void Macro();
public String getName();
public void setName(String);
public mars.MIPSprogram getProgram();
public void setProgram(mars.MIPSprogram);
public int getFromLine();
public int getOriginalFromLine();
public void setFromLine(int);
public void setOriginalFromLine(int);
public int getToLine();
public int getOriginalToLine();
public void setToLine(int);
public void setOriginalToLine(int);
public java.util.ArrayList getArgs();
public void setArgs(java.util.ArrayList);
public boolean equals(Object);
public void addArg(String);
public String getSubstitutedLine(int, TokenList, long, mars.ErrorList);
private boolean tokenIsMacroLabel(String);
private String replaceToken(String, Token, String);
public static boolean tokenIsMacroParameter(String, boolean);
public void addLabel(String);
public void readyForCommit();
}
Assembler$DataSegmentForwardReferences
package mars.assembler;
synchronized class Assembler$DataSegmentForwardReferences {
private java.util.ArrayList forwardReferenceList;
private void Assembler$DataSegmentForwardReferences(Assembler);
private int size();
private void add(int, int, Token);
private void add(Assembler$DataSegmentForwardReferences);
private void clear();
private int resolve(SymbolTable);
private void generateErrorMessages(mars.ErrorList);
}
SourceLine
package mars.assembler;
public synchronized class SourceLine {
private String source;
private String filename;
private mars.MIPSprogram mipsProgram;
private int lineNumber;
public void SourceLine(String, mars.MIPSprogram, int);
public String getSource();
public String getFilename();
public int getLineNumber();
public mars.MIPSprogram getMIPSprogram();
}
Assembler$ProgramStatementComparator
package mars.assembler;
synchronized class Assembler$ProgramStatementComparator implements java.util.Comparator {
private void Assembler$ProgramStatementComparator(Assembler);
public int compare(Object, Object);
public boolean equals(Object);
}
SymbolTable
package mars.assembler;
public synchronized class SymbolTable {
private static String startLabel;
private String filename;
private java.util.ArrayList table;
public static final int NOT_FOUND = -1;
public void SymbolTable(String);
public void addSymbol(Token, int, boolean, mars.ErrorList);
public void removeSymbol(Token);
public int getAddress(String);
public int getAddressLocalOrGlobal(String);
public Symbol getSymbol(String);
public Symbol getSymbolGivenAddress(String);
public Symbol getSymbolGivenAddressLocalOrGlobal(String);
public java.util.ArrayList getDataSymbols();
public java.util.ArrayList getTextSymbols();
public java.util.ArrayList getAllSymbols();
public int getSize();
public void clear();
public void fixSymbolTableAddress(int, int);
public static String getStartLabel();
static void
}
DataTypes
package mars.assembler;
public final synchronized class DataTypes {
public static final int DOUBLE_SIZE = 8;
public static final int FLOAT_SIZE = 4;
public static final int WORD_SIZE = 4;
public static final int HALF_SIZE = 2;
public static final int BYTE_SIZE = 1;
public static final int CHAR_SIZE = 1;
public static final int MAX_WORD_VALUE = 2147483647;
public static final int MIN_WORD_VALUE = -2147483648;
public static final int MAX_HALF_VALUE = 32767;
public static final int MIN_HALF_VALUE = -32768;
public static final int MAX_UHALF_VALUE = 65535;
public static final int MIN_UHALF_VALUE = 0;
public static final int MAX_BYTE_VALUE = 127;
public static final int MIN_BYTE_VALUE = -128;
public static final double MAX_FLOAT_VALUE = 3.4028234663852886E38;
public static final double LOW_FLOAT_VALUE = -3.4028234663852886E38;
public static final double MAX_DOUBLE_VALUE = 1.7976931348623157E308;
public static final double LOW_DOUBLE_VALUE = -1.7976931348623157E308;
public void DataTypes();
public static int getLengthInBytes(Directives);
public static boolean outOfRange(Directives, int);
public static boolean outOfRange(Directives, double);
}
Token
package mars.assembler;
public synchronized class Token {
private TokenTypes type;
private String value;
private mars.MIPSprogram sourceMIPSprogram;
private int sourceLine;
private int sourcePos;
private mars.MIPSprogram originalMIPSprogram;
private int originalSourceLine;
public void Token(TokenTypes, String, mars.MIPSprogram, int, int);
public void setOriginal(mars.MIPSprogram, int);
public mars.MIPSprogram getOriginalProgram();
public int getOriginalSourceLine();
public TokenTypes getType();
public void setType(TokenTypes);
public String getValue();
public String toString();
public mars.MIPSprogram getSourceMIPSprogram();
public int getSourceLine();
public int getStartPos();
}
Assembler$UserKernelAddressSpace
package mars.assembler;
synchronized class Assembler$UserKernelAddressSpace {
int[] address;
int currentAddressSpace;
private final int USER;
private final int KERNEL;
private void Assembler$UserKernelAddressSpace(Assembler, int, int);
private int get();
private void set(int);
private void increment(int);
private void setAddressSpace(int);
}
Assembler$1
package mars.assembler;
synchronized class Assembler$1 {
}
Assembler
package mars.assembler;
public synchronized class Assembler {
private java.util.ArrayList machineList;
private mars.ErrorList errors;
private boolean inDataSegment;
private boolean inMacroSegment;
private int externAddress;
private boolean autoAlign;
private Directives currentDirective;
private Directives dataDirective;
private mars.MIPSprogram fileCurrentlyBeingAssembled;
private TokenList globalDeclarationList;
private Assembler$UserKernelAddressSpace textAddress;
private Assembler$UserKernelAddressSpace dataAddress;
private Assembler$DataSegmentForwardReferences currentFileDataSegmentForwardReferences;
private Assembler$DataSegmentForwardReferences accumulatedDataSegmentForwardReferences;
public void Assembler();
public java.util.ArrayList assemble(mars.MIPSprogram, boolean) throws mars.ProcessingException;
public java.util.ArrayList assemble(mars.MIPSprogram, boolean, boolean) throws mars.ProcessingException;
public mars.ErrorList getErrorList();
public java.util.ArrayList assemble(java.util.ArrayList, boolean) throws mars.ProcessingException;
public java.util.ArrayList assemble(java.util.ArrayList, boolean, boolean) throws mars.ProcessingException;
private void catchDuplicateAddresses(java.util.ArrayList, mars.ErrorList);
private java.util.ArrayList parseLine(TokenList, String, int, boolean);
private void detectLabels(TokenList, Macro);
private boolean compactTranslationCanBeApplied(mars.ProgramStatement);
private TokenList stripComment(TokenList);
private void stripLabels(TokenList);
private boolean parseAndRecordLabel(TokenList);
private boolean tokenListBeginsWithLabel(TokenList);
private void executeDirective(TokenList);
private void transferGlobals();
private void executeDirectiveContinuation(TokenList);
private java.util.ArrayList matchInstruction(Token);
private void storeNumeric(TokenList, Directives, mars.ErrorList);
private void storeInteger(Token, Directives, mars.ErrorList);
private void storeRealNumber(Token, Directives, mars.ErrorList);
private void storeStrings(TokenList, Directives, mars.ErrorList);
private boolean passesDataSegmentCheck(Token);
private int writeToDataSegment(int, int, Token, mars.ErrorList);
private void writeDoubleToDataSegment(double, Token, mars.ErrorList);
private int alignToBoundary(int, int);
}
OperandFormat
package mars.assembler;
public synchronized class OperandFormat {
private void OperandFormat();
static boolean tokenOperandMatch(TokenList, mars.mips.instructions.Instruction, mars.ErrorList);
static mars.mips.instructions.Instruction bestOperandMatch(TokenList, java.util.ArrayList);
private static boolean numOperandsCheck(TokenList, mars.mips.instructions.Instruction, mars.ErrorList);
private static boolean operandTypeCheck(TokenList, mars.mips.instructions.Instruction, mars.ErrorList);
private static void generateMessage(Token, String, mars.ErrorList);
}
Symbol
package mars.assembler;
public synchronized class Symbol {
private String name;
private int address;
private boolean data;
public static final boolean TEXT_SYMBOL = 0;
public static final boolean DATA_SYMBOL = 1;
public void Symbol(String, int, boolean);
public int getAddress();
public String getName();
public boolean getType();
public void setAddress(int);
}
Assembler$DataSegmentForwardReferences$DataSegmentForwardReference
package mars.assembler;
synchronized class Assembler$DataSegmentForwardReferences$DataSegmentForwardReference {
int patchAddress;
int length;
Token token;
void Assembler$DataSegmentForwardReferences$DataSegmentForwardReference(Assembler$DataSegmentForwardReferences, int, int, Token);
}
PropertiesFile
package mars.util;
public synchronized class PropertiesFile {
public void PropertiesFile();
public static java.util.Properties loadPropertiesFromFile(String);
}
EditorFont
package mars.util;
public synchronized class EditorFont {
private static final String[] styleStrings;
private static final int[] styleInts;
public static final String DEFAULT_STYLE_STRING;
public static final int DEFAULT_STYLE_INT;
public static final int MIN_SIZE = 6;
public static final int MAX_SIZE = 72;
public static final int DEFAULT_SIZE = 12;
private static final String[] allCommonFamilies;
private static final String TAB_STRING = ;
private static final char TAB_CHAR = 9;
private static final String SPACES = ;
private static final String[] commonFamilies;
public void EditorFont();
public static String[] getCommonFamilies();
public static String[] getAllFamilies();
public static String[] getFontStyleStrings();
public static int styleStringToStyleInt(String);
public static String styleIntToStyleString(int);
public static String sizeIntToSizeString(int);
public static int sizeStringToSizeInt(String);
public static java.awt.Font createFontFromStringValues(String, String, String);
public static String substituteSpacesForTabs(String);
public static String substituteSpacesForTabs(String, int);
private static String[] actualCommonFamilies();
static void
}
FilenameFinder$1
package mars.util;
synchronized class FilenameFinder$1 {
}
MemoryDump
package mars.util;
public synchronized class MemoryDump {
public static java.util.ArrayList dumpTriples;
private static final java.util.HashMap segmentBoundMap;
private static final String[] segmentNames;
private static int[] baseAddresses;
private static int[] limitAddresses;
public void MemoryDump();
public static Integer[] getSegmentBounds(String);
public static String[] getSegmentNames();
public static int[] getBaseAddresses(String[]);
public static int[] getLimitAddresses(String[]);
public static int getAddressOfFirstNull(int, int) throws mars.mips.hardware.AddressErrorException;
static void
}
Binary
package mars.util;
public synchronized class Binary {
private static char[] chars;
private static final long UNSIGNED_BASE = 4294967296;
public void Binary();
public static String intToBinaryString(int, int);
public static String intToBinaryString(int);
public static String longToBinaryString(long, int);
public static String longToBinaryString(long);
public static int binaryStringToInt(String);
public static long binaryStringToLong(String);
public static String binaryStringToHexString(String);
public static String hexStringToBinaryString(String);
public static char binaryStringToHexDigit(String);
public static String intToHexString(int);
public static String intToHalfHexString(int);
public static String longToHexString(long);
public static String unsignedIntToIntString(int);
public static String intToAscii(int);
public static int stringToInt(String) throws NumberFormatException;
public static long stringToLong(String) throws NumberFormatException;
public static int highOrderLongToInt(long);
public static int lowOrderLongToInt(long);
public static long twoIntsToLong(int, int);
public static int bitValue(int, int);
public static int bitValue(long, int);
public static int setBit(int, int);
public static int clearBit(int, int);
public static int setByte(int, int, int);
public static int getByte(int, int);
public static boolean isHex(String);
public static boolean isOctal(String);
static void
}
SystemIO
package mars.util;
public synchronized class SystemIO {
public static final int SYSCALL_BUFSIZE = 128;
public static final int SYSCALL_MAXFILES = 32;
public static String fileErrorString;
private static final int O_RDONLY = 0;
private static final int O_WRONLY = 1;
private static final int O_RDWR = 2;
private static final int O_APPEND = 8;
private static final int O_CREAT = 512;
private static final int O_TRUNC = 1024;
private static final int O_EXCL = 2048;
private static final int STDIN = 0;
private static final int STDOUT = 1;
private static final int STDERR = 2;
private static java.io.BufferedReader inputReader;
public void SystemIO();
public static int readInteger(int);
public static float readFloat(int);
public static double readDouble(int);
public static void printString(String);
public static String readString(int, int);
public static int readChar(int);
public static int writeToFile(int, byte[], int);
public static int readFromFile(int, byte[], int);
public static int openFile(String, int);
public static void closeFile(int);
public static void resetFiles();
public static String getFileErrorMessage();
private static java.io.BufferedReader getInputReader();
static void
}
SystemIO$FileIOData
package mars.util;
synchronized class SystemIO$FileIOData {
private static String[] fileNames;
private static int[] fileFlags;
private static Object[] streams;
private void SystemIO$FileIOData();
private static void resetFiles();
private static void setupStdio();
private static void setStreamInUse(int, Object);
private static Object getStreamInUse(int);
private static boolean filenameInUse(String);
private static boolean fdInUse(int, int);
private static void close(int);
private static int nowOpening(String, int);
static void
}
FilenameFinder
package mars.util;
public synchronized class FilenameFinder {
private static final String JAR_EXTENSION = .jar;
private static final String FILE_URL = file:;
private static final String JAR_URI_PREFIX = jar:;
private static final boolean NO_DIRECTORIES = 0;
public static String MATCH_ALL_EXTENSIONS;
public void FilenameFinder();
public static java.util.ArrayList getFilenameList(ClassLoader, String, String);
public static java.util.ArrayList getFilenameList(ClassLoader, String, java.util.ArrayList);
public static java.util.ArrayList getFilenameList(String, String);
public static java.util.ArrayList getFilenameList(String, java.util.ArrayList);
public static java.util.ArrayList getFilenameList(java.util.ArrayList, String);
public static java.util.ArrayList getFilenameList(java.util.ArrayList, java.util.ArrayList);
public static String getExtension(java.io.File);
public static javax.swing.filechooser.FileFilter getFileFilter(java.util.ArrayList, String, boolean);
public static javax.swing.filechooser.FileFilter getFileFilter(java.util.ArrayList, String);
public static javax.swing.filechooser.FileFilter getFileFilter(String, String, boolean);
public static javax.swing.filechooser.FileFilter getFileFilter(String, String);
public static boolean fileExtensionMatch(String, String);
private static java.util.ArrayList getListFromJar(String, String, String);
private static String extractJarFilename(String);
private static String checkFileExtension(String);
static void
}
FilenameFinder$MarsFileFilter
package mars.util;
synchronized class FilenameFinder$MarsFileFilter extends javax.swing.filechooser.FileFilter {
private java.util.ArrayList extensions;
private String fullDescription;
private boolean acceptDirectories;
private void FilenameFinder$MarsFileFilter(java.util.ArrayList, String, boolean);
private String buildFullDescription(String, java.util.ArrayList);
public String getDescription();
public boolean accept(java.io.File);
}
MarsSplashScreen
package mars;
public synchronized class MarsSplashScreen extends javax.swing.JWindow {
private int duration;
public void MarsSplashScreen(int);
public void showSplash();
}
SettingsMemoryConfigurationAction$MemoryConfigurationDialog
package mars.venus;
synchronized class SettingsMemoryConfigurationAction$MemoryConfigurationDialog extends javax.swing.JDialog implements java.awt.event.ActionListener {
javax.swing.JTextField[] addressDisplay;
javax.swing.JLabel[] nameDisplay;
SettingsMemoryConfigurationAction$ConfigurationButton selectedConfigurationButton;
SettingsMemoryConfigurationAction$ConfigurationButton initialConfigurationButton;
public void SettingsMemoryConfigurationAction$MemoryConfigurationDialog(SettingsMemoryConfigurationAction, java.awt.Frame, String, boolean);
private javax.swing.JPanel buildDialogPanel();
private java.awt.Component buildConfigChooser();
private java.awt.Component buildConfigDisplay();
public void actionPerformed(java.awt.event.ActionEvent);
private java.awt.Component buildControlPanel();
private void performApply();
private void performClose();
private void performReset();
private void setConfigDisplay(mars.mips.hardware.MemoryConfiguration);
}
HelpHelpAction$1
package mars.venus;
synchronized class HelpHelpAction$1 extends java.awt.event.WindowAdapter {
void HelpHelpAction$1(HelpHelpAction, javax.swing.JDialog);
public void windowClosing(java.awt.event.WindowEvent);
}
DataSegmentWindow$10
package mars.venus;
synchronized class DataSegmentWindow$10 implements java.awt.event.ActionListener {
void DataSegmentWindow$10(DataSegmentWindow);
public void actionPerformed(java.awt.event.ActionEvent);
}
EditFindReplaceAction$FindReplaceDialog$2
package mars.venus;
synchronized class EditFindReplaceAction$FindReplaceDialog$2 implements java.awt.event.ActionListener {
void EditFindReplaceAction$FindReplaceDialog$2(EditFindReplaceAction$FindReplaceDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsHighlightingAction$BackgroundChanger
package mars.venus;
synchronized class SettingsHighlightingAction$BackgroundChanger implements java.awt.event.ActionListener {
private int position;
public void SettingsHighlightingAction$BackgroundChanger(SettingsHighlightingAction, int);
public void actionPerformed(java.awt.event.ActionEvent);
}
MessagesPane$Asker$1$1
package mars.venus;
synchronized class MessagesPane$Asker$1$1 implements Runnable {
void MessagesPane$Asker$1$1(MessagesPane$Asker$1, javax.swing.event.DocumentEvent);
public void run();
}
SettingsHighlightingAction$2
package mars.venus;
synchronized class SettingsHighlightingAction$2 extends javax.swing.JCheckBox {
void SettingsHighlightingAction$2(SettingsHighlightingAction);
protected void processMouseEvent(java.awt.event.MouseEvent);
protected void processKeyEvent(java.awt.event.KeyEvent);
}
EditPane$2
package mars.venus;
synchronized class EditPane$2 implements java.awt.event.ItemListener {
void EditPane$2(EditPane);
public void itemStateChanged(java.awt.event.ItemEvent);
}
TextSegmentWindow$1
package mars.venus;
synchronized class TextSegmentWindow$1 {
}
SettingsEditorAction$EditorFontDialog$8
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$8 implements javax.swing.event.ChangeListener {
void SettingsEditorAction$EditorFontDialog$8(SettingsEditorAction$EditorFontDialog);
public void stateChanged(javax.swing.event.ChangeEvent);
}
SettingsWarningsAreErrorsAction
package mars.venus;
public synchronized class SettingsWarningsAreErrorsAction extends GuiAction {
public void SettingsWarningsAreErrorsAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
MessagesPane$Asker
package mars.venus;
synchronized class MessagesPane$Asker implements Runnable {
java.util.concurrent.ArrayBlockingQueue resultQueue;
int initialPos;
int maxLen;
final javax.swing.event.DocumentListener listener;
final javax.swing.text.NavigationFilter navigationFilter;
final mars.simulator.Simulator$StopListener stopListener;
void MessagesPane$Asker(MessagesPane, int);
public void run();
void cleanup();
void returnResponse();
String response();
}
MonoRightCellRenderer
package mars.venus;
synchronized class MonoRightCellRenderer extends javax.swing.table.DefaultTableCellRenderer {
public static final java.awt.Font MONOSPACED_PLAIN_12POINT;
void MonoRightCellRenderer();
public java.awt.Component getTableCellRendererComponent(javax.swing.JTable, Object, boolean, boolean, int, int);
static void
}
GuiAction
package mars.venus;
public synchronized class GuiAction extends javax.swing.AbstractAction {
protected VenusUI mainUI;
protected void GuiAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
FileExitAction
package mars.venus;
public synchronized class FileExitAction extends GuiAction {
public void FileExitAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsAssembleAllAction
package mars.venus;
public synchronized class SettingsAssembleAllAction extends GuiAction {
public void SettingsAssembleAllAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
Coprocessor1Window$MyTippedJTable$1
package mars.venus;
synchronized class Coprocessor1Window$MyTippedJTable$1 extends javax.swing.table.JTableHeader {
void Coprocessor1Window$MyTippedJTable$1(Coprocessor1Window$MyTippedJTable, javax.swing.table.TableColumnModel);
public String getToolTipText(java.awt.event.MouseEvent);
}
FileDumpMemoryAction$DumpFormatComboBoxRenderer
package mars.venus;
synchronized class FileDumpMemoryAction$DumpFormatComboBoxRenderer extends javax.swing.plaf.basic.BasicComboBoxRenderer {
private javax.swing.JComboBox myMaster;
public void FileDumpMemoryAction$DumpFormatComboBoxRenderer(FileDumpMemoryAction, javax.swing.JComboBox);
public java.awt.Component getListCellRendererComponent(javax.swing.JList, Object, int, boolean, boolean);
}
FileStatus
package mars.venus;
public synchronized class FileStatus {
public static final int NO_FILE = 0;
public static final int NEW_NOT_EDITED = 1;
public static final int NEW_EDITED = 2;
public static final int NOT_EDITED = 3;
public static final int EDITED = 4;
public static final int RUNNABLE = 5;
public static final int RUNNING = 6;
public static final int TERMINATED = 7;
public static final int OPENING = 8;
private static int systemStatus;
private static boolean systemAssembled;
private static boolean systemSaved;
private static boolean systemEdited;
private static String systemName;
private static java.io.File systemFile;
private int status;
private java.io.File file;
public static void set(int);
public static int get();
public static void setAssembled(boolean);
public static void setSaved(boolean);
public static void setEdited(boolean);
public static void setName(String);
public static void setFile(java.io.File);
public static java.io.File getFile();
public static String getName();
public static boolean isAssembled();
public static boolean isSaved();
public static boolean isEdited();
public static void reset();
public void FileStatus();
public void FileStatus(int, String);
public void setFileStatus(int);
public int getFileStatus();
public boolean isNew();
public boolean hasUnsavedEdits();
public void setPathname(String);
public void setPathname(String, String);
public String getPathname();
public String getFilename();
public String getParent();
public void updateStaticFileStatus();
}
SettingsHighlightingAction$ForegroundChanger
package mars.venus;
synchronized class SettingsHighlightingAction$ForegroundChanger implements java.awt.event.ActionListener {
private int position;
public void SettingsHighlightingAction$ForegroundChanger(SettingsHighlightingAction, int);
public void actionPerformed(java.awt.event.ActionEvent);
}
NumberDisplayBaseChooser
package mars.venus;
public synchronized class NumberDisplayBaseChooser extends javax.swing.JCheckBox {
public static final int DECIMAL = 10;
public static final int HEXADECIMAL = 16;
public static final int ASCII = 0;
private int base;
private javax.swing.JCheckBoxMenuItem settingMenuItem;
public void NumberDisplayBaseChooser(String, boolean);
public int getBase();
public void setBase(int);
public static String formatUnsignedInteger(int, int);
public static String formatNumber(int, int);
public static String formatNumber(float, int);
public static String formatNumber(double, int);
public String formatNumber(int);
public String formatUnsignedInteger(int);
public static String formatFloatNumber(int, int);
public static String formatDoubleNumber(long, int);
public void setSettingsMenuItem(javax.swing.JCheckBoxMenuItem);
public static int getBase(boolean);
}
EditFindReplaceAction
package mars.venus;
public synchronized class EditFindReplaceAction extends GuiAction {
private static String searchString;
private static boolean caseSensitivity;
private static final String DIALOG_TITLE = Find and Replace;
javax.swing.JDialog findReplaceDialog;
public void EditFindReplaceAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
static void
}
DataSegmentWindow$NextButton
package mars.venus;
synchronized class DataSegmentWindow$NextButton extends RepeatButton {
public void DataSegmentWindow$NextButton(DataSegmentWindow, javax.swing.Icon);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsAssembleOnOpenAction
package mars.venus;
public synchronized class SettingsAssembleOnOpenAction extends GuiAction {
public void SettingsAssembleOnOpenAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsHighlightingAction$6
package mars.venus;
synchronized class SettingsHighlightingAction$6 implements java.awt.event.ActionListener {
void SettingsHighlightingAction$6(SettingsHighlightingAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsHighlightingAction$DefaultChanger
package mars.venus;
synchronized class SettingsHighlightingAction$DefaultChanger implements java.awt.event.ItemListener {
private int position;
public void SettingsHighlightingAction$DefaultChanger(SettingsHighlightingAction, int);
public void itemStateChanged(java.awt.event.ItemEvent);
}
Coprocessor1Window$MyTippedJTable
package mars.venus;
synchronized class Coprocessor1Window$MyTippedJTable extends javax.swing.JTable {
private String[] regToolTips;
private String[] columnToolTips;
void Coprocessor1Window$MyTippedJTable(Coprocessor1Window, Coprocessor1Window$RegTableModel);
public String getToolTipText(java.awt.event.MouseEvent);
protected javax.swing.table.JTableHeader createDefaultTableHeader();
}
EditFindReplaceAction$FindReplaceDialog$4
package mars.venus;
synchronized class EditFindReplaceAction$FindReplaceDialog$4 implements java.awt.event.ActionListener {
void EditFindReplaceAction$FindReplaceDialog$4(EditFindReplaceAction$FindReplaceDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
FileCloseAction
package mars.venus;
public synchronized class FileCloseAction extends GuiAction {
public void FileCloseAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
AbstractFontSettingDialog$ComboBoxRenderer
package mars.venus;
synchronized class AbstractFontSettingDialog$ComboBoxRenderer extends javax.swing.JLabel implements javax.swing.ListCellRenderer {
javax.swing.JSeparator separator;
public void AbstractFontSettingDialog$ComboBoxRenderer(AbstractFontSettingDialog);
public java.awt.Component getListCellRendererComponent(javax.swing.JList, Object, int, boolean, boolean);
}
SettingsEditorAction$EditorFontDialog$ForegroundChanger
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$ForegroundChanger implements java.awt.event.ActionListener {
private int row;
public void SettingsEditorAction$EditorFontDialog$ForegroundChanger(SettingsEditorAction$EditorFontDialog, int);
public void actionPerformed(java.awt.event.ActionEvent);
}
RunStepAction
package mars.venus;
public synchronized class RunStepAction extends GuiAction {
String name;
ExecutePane executePane;
public void RunStepAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
public void stepped(boolean, int, mars.ProcessingException);
private void processProgramArgumentsIfAny();
}
SettingsEditorAction$EditorFontDialog$BoldItalicChanger
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$BoldItalicChanger implements java.awt.event.ActionListener {
private int row;
public void SettingsEditorAction$EditorFontDialog$BoldItalicChanger(SettingsEditorAction$EditorFontDialog, int);
public void actionPerformed(java.awt.event.ActionEvent);
}
VenusUI$2
package mars.venus;
synchronized class VenusUI$2 extends java.awt.event.WindowAdapter {
void VenusUI$2(VenusUI);
public void windowClosing(java.awt.event.WindowEvent);
}
SettingsHighlightingAction$4
package mars.venus;
synchronized class SettingsHighlightingAction$4 implements java.awt.event.ActionListener {
void SettingsHighlightingAction$4(SettingsHighlightingAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
PopupListener
package mars.venus;
public synchronized class PopupListener extends java.awt.event.MouseAdapter {
private javax.swing.JPopupMenu popup;
public void PopupListener(javax.swing.JPopupMenu);
public void mousePressed(java.awt.event.MouseEvent);
public void mouseReleased(java.awt.event.MouseEvent);
private void maybeShowPopup(java.awt.event.MouseEvent);
}
DataSegmentWindow$8
package mars.venus;
synchronized class DataSegmentWindow$8 implements java.awt.event.ActionListener {
void DataSegmentWindow$8(DataSegmentWindow);
public void actionPerformed(java.awt.event.ActionEvent);
}
EditPasteAction
package mars.venus;
public synchronized class EditPasteAction extends GuiAction {
public void EditPasteAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
FilePrintAction
package mars.venus;
public synchronized class FilePrintAction extends GuiAction {
public void FilePrintAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsEditorAction
package mars.venus;
public synchronized class SettingsEditorAction extends GuiAction {
javax.swing.JDialog editorDialog;
javax.swing.JComboBox fontFamilySelector;
javax.swing.JComboBox fontStyleSelector;
javax.swing.JSlider tabSizeSelector;
javax.swing.JTextField fontSizeDisplay;
String initialFontFamily;
String initialFontStyle;
String initialFontSize;
private static final int gridVGap = 2;
private static final int gridHGap = 2;
private static final javax.swing.border.Border ColorSelectButtonEnabledBorder;
private static final javax.swing.border.Border ColorSelectButtonDisabledBorder;
private static final String GENERIC_TOOL_TIP_TEXT = Use generic editor (original MARS editor, similar to Notepad) instead of language-aware styled editor;
private static final String SAMPLE_TOOL_TIP_TEXT = Current setting; modify using buttons to the right;
private static final String FOREGROUND_TOOL_TIP_TEXT = Click, to select text color;
private static final String BOLD_TOOL_TIP_TEXT = Toggle text bold style;
private static final String ITALIC_TOOL_TIP_TEXT = Toggle text italic style;
private static final String DEFAULT_TOOL_TIP_TEXT = Check, to select defaults (disables buttons);
private static final String BOLD_BUTTON_TOOL_TIP_TEXT = B;
private static final String ITALIC_BUTTON_TOOL_TIP_TEXT = I;
private static final String TAB_SIZE_TOOL_TIP_TEXT = Current tab size in characters;
private static final String BLINK_SPINNER_TOOL_TIP_TEXT = Current blinking rate in milliseconds;
private static final String BLINK_SAMPLE_TOOL_TIP_TEXT = Displays current blinking rate;
private static final String CURRENT_LINE_HIGHLIGHT_TOOL_TIP_TEXT = Check, to highlight line currently being edited;
private static final String AUTO_INDENT_TOOL_TIP_TEXT = Check, to enable auto-indent to previous line when Enter key is pressed;
private static final String[] POPUP_GUIDANCE_TOOL_TIP_TEXT;
public void SettingsEditorAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
static void
}
EditFindReplaceAction$FindReplaceDialog$1
package mars.venus;
synchronized class EditFindReplaceAction$FindReplaceDialog$1 extends java.awt.event.WindowAdapter {
void EditFindReplaceAction$FindReplaceDialog$1(EditFindReplaceAction$FindReplaceDialog, EditFindReplaceAction);
public void windowClosing(java.awt.event.WindowEvent);
}
LabelsWindow$LabelsForSymbolTable
package mars.venus;
synchronized class LabelsWindow$LabelsForSymbolTable {
private mars.MIPSprogram myMIPSprogram;
private Object[][] labelData;
private javax.swing.JTable labelTable;
private java.util.ArrayList symbols;
private mars.assembler.SymbolTable symbolTable;
private String tableName;
public void LabelsWindow$LabelsForSymbolTable(LabelsWindow, mars.MIPSprogram);
public String getSymbolTableName();
public boolean hasSymbols();
private javax.swing.JTable generateLabelTable();
public void updateLabelAddresses();
}
TextSegmentWindow$MyTableColumnMovingListener
package mars.venus;
synchronized class TextSegmentWindow$MyTableColumnMovingListener implements javax.swing.event.TableColumnModelListener {
private void TextSegmentWindow$MyTableColumnMovingListener(TextSegmentWindow);
public void columnAdded(javax.swing.event.TableColumnModelEvent);
public void columnRemoved(javax.swing.event.TableColumnModelEvent);
public void columnMarginChanged(javax.swing.event.ChangeEvent);
public void columnSelectionChanged(javax.swing.event.ListSelectionEvent);
public void columnMoved(javax.swing.event.TableColumnModelEvent);
}
ToolLoader
package mars.venus;
public synchronized class ToolLoader {
private static final String CLASS_PREFIX = mars.tools.;
private static final String TOOLS_DIRECTORY_PATH = mars/tools;
private static final String TOOLS_MENU_NAME = Tools;
private static final String MARSTOOL_INTERFACE = MarsTool.class;
private static final String CLASS_EXTENSION = class;
public void ToolLoader();
public javax.swing.JMenu buildToolsMenu();
private java.util.ArrayList loadMarsTools();
}
SettingsEditorAction$EditorFontDialog$9
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$9 extends javax.swing.JCheckBox {
void SettingsEditorAction$EditorFontDialog$9(SettingsEditorAction$EditorFontDialog);
protected void processMouseEvent(java.awt.event.MouseEvent);
protected void processKeyEvent(java.awt.event.KeyEvent);
}
SettingsHighlightingAction$3
package mars.venus;
synchronized class SettingsHighlightingAction$3 implements java.awt.event.ActionListener {
void SettingsHighlightingAction$3(SettingsHighlightingAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
LabelsWindow$LabelDisplayMouseListener
package mars.venus;
synchronized class LabelsWindow$LabelDisplayMouseListener extends java.awt.event.MouseAdapter {
private void LabelsWindow$LabelDisplayMouseListener(LabelsWindow);
public void mouseClicked(java.awt.event.MouseEvent);
}
DataSegmentWindow$MyTippedJTable$1
package mars.venus;
synchronized class DataSegmentWindow$MyTippedJTable$1 extends javax.swing.table.JTableHeader {
void DataSegmentWindow$MyTippedJTable$1(DataSegmentWindow$MyTippedJTable, javax.swing.table.TableColumnModel);
public String getToolTipText(java.awt.event.MouseEvent);
}
RunStopAction
package mars.venus;
public synchronized class RunStopAction extends GuiAction {
public void RunStopAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
LabelsWindow$1
package mars.venus;
synchronized class LabelsWindow$1 {
}
HelpHelpAction$2
package mars.venus;
synchronized class HelpHelpAction$2 implements java.awt.event.ActionListener {
void HelpHelpAction$2(HelpHelpAction, javax.swing.JDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
Coprocessor0Window$RegisterCellRenderer
package mars.venus;
synchronized class Coprocessor0Window$RegisterCellRenderer extends javax.swing.table.DefaultTableCellRenderer {
private java.awt.Font font;
private int alignment;
public void Coprocessor0Window$RegisterCellRenderer(Coprocessor0Window, java.awt.Font, int);
public java.awt.Component getTableCellRendererComponent(javax.swing.JTable, Object, boolean, boolean, int, int);
}
RunAssembleAction
package mars.venus;
public synchronized class RunAssembleAction extends GuiAction {
private static java.util.ArrayList MIPSprogramsToAssemble;
private static boolean extendedAssemblerEnabled;
private static boolean warningsAreErrors;
private static final int LINE_LENGTH_LIMIT = 60;
public void RunAssembleAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
static java.util.ArrayList getMIPSprogramsToAssemble();
static boolean getExtendedAssemblerEnabled();
static boolean getWarningsAreErrors();
public void actionPerformed(java.awt.event.ActionEvent);
private String buildFileNameList(String, java.util.ArrayList);
}
EditCopyAction
package mars.venus;
public synchronized class EditCopyAction extends GuiAction {
public void EditCopyAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
Coprocessor0Window$MyTippedJTable
package mars.venus;
synchronized class Coprocessor0Window$MyTippedJTable extends javax.swing.JTable {
private String[] regToolTips;
private String[] columnToolTips;
void Coprocessor0Window$MyTippedJTable(Coprocessor0Window, Coprocessor0Window$RegTableModel);
public String getToolTipText(java.awt.event.MouseEvent);
protected javax.swing.table.JTableHeader createDefaultTableHeader();
}
RunToggleBreakpointsAction
package mars.venus;
public synchronized class RunToggleBreakpointsAction extends GuiAction {
public void RunToggleBreakpointsAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
LabelsWindow$LabelItemListener
package mars.venus;
synchronized class LabelsWindow$LabelItemListener implements java.awt.event.ItemListener {
private void LabelsWindow$LabelItemListener(LabelsWindow);
public void itemStateChanged(java.awt.event.ItemEvent);
}
SettingsProgramArgumentsAction
package mars.venus;
public synchronized class SettingsProgramArgumentsAction extends GuiAction {
public void SettingsProgramArgumentsAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
ColorSelectButton
package mars.venus;
synchronized class ColorSelectButton extends javax.swing.JButton {
public static final javax.swing.border.Border ColorSelectButtonEnabledBorder;
public static final javax.swing.border.Border ColorSelectButtonDisabledBorder;
void ColorSelectButton();
public void setEnabled(boolean);
static void
}
FileNewAction
package mars.venus;
public synchronized class FileNewAction extends GuiAction {
public void FileNewAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
EditCutAction
package mars.venus;
public synchronized class EditCutAction extends GuiAction {
public void EditCutAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$insert_tab
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$insert_tab implements java.awt.event.ActionListener {
public void InputHandler$insert_tab();
public void actionPerformed(java.awt.event.ActionEvent);
}
KeywordMap
package mars.venus.editors.jeditsyntax;
public synchronized class KeywordMap {
protected int mapLength;
private KeywordMap$Keyword[] map;
private boolean ignoreCase;
public void KeywordMap(boolean);
public void KeywordMap(boolean, int);
public byte lookup(javax.swing.text.Segment, int, int);
public void add(String, byte);
public boolean getIgnoreCase();
public void setIgnoreCase(boolean);
protected int getStringMapKey(String);
protected int getSegmentMapKey(javax.swing.text.Segment, int, int);
}
InputHandler$backspace_word
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$backspace_word implements java.awt.event.ActionListener {
public void InputHandler$backspace_word();
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$MacroRecorder
package mars.venus.editors.jeditsyntax;
public abstract interface InputHandler$MacroRecorder {
public abstract void actionPerformed(java.awt.event.ActionListener, String);
}
InputHandler
package mars.venus.editors.jeditsyntax;
public abstract synchronized class InputHandler extends java.awt.event.KeyAdapter {
public static final String SMART_HOME_END_PROPERTY = InputHandler.homeEnd;
public static final java.awt.event.ActionListener BACKSPACE;
public static final java.awt.event.ActionListener BACKSPACE_WORD;
public static final java.awt.event.ActionListener DELETE;
public static final java.awt.event.ActionListener DELETE_WORD;
public static final java.awt.event.ActionListener END;
public static final java.awt.event.ActionListener DOCUMENT_END;
public static final java.awt.event.ActionListener SELECT_ALL;
public static final java.awt.event.ActionListener SELECT_END;
public static final java.awt.event.ActionListener SELECT_DOC_END;
public static final java.awt.event.ActionListener INSERT_BREAK;
public static final java.awt.event.ActionListener INSERT_TAB;
public static final java.awt.event.ActionListener HOME;
public static final java.awt.event.ActionListener DOCUMENT_HOME;
public static final java.awt.event.ActionListener SELECT_HOME;
public static final java.awt.event.ActionListener SELECT_DOC_HOME;
public static final java.awt.event.ActionListener NEXT_CHAR;
public static final java.awt.event.ActionListener NEXT_LINE;
public static final java.awt.event.ActionListener NEXT_PAGE;
public static final java.awt.event.ActionListener NEXT_WORD;
public static final java.awt.event.ActionListener SELECT_NEXT_CHAR;
public static final java.awt.event.ActionListener SELECT_NEXT_LINE;
public static final java.awt.event.ActionListener SELECT_NEXT_PAGE;
public static final java.awt.event.ActionListener SELECT_NEXT_WORD;
public static final java.awt.event.ActionListener OVERWRITE;
public static final java.awt.event.ActionListener PREV_CHAR;
public static final java.awt.event.ActionListener PREV_LINE;
public static final java.awt.event.ActionListener PREV_PAGE;
public static final java.awt.event.ActionListener PREV_WORD;
public static final java.awt.event.ActionListener SELECT_PREV_CHAR;
public static final java.awt.event.ActionListener SELECT_PREV_LINE;
public static final java.awt.event.ActionListener SELECT_PREV_PAGE;
public static final java.awt.event.ActionListener SELECT_PREV_WORD;
public static final java.awt.event.ActionListener REPEAT;
public static final java.awt.event.ActionListener TOGGLE_RECT;
public static final java.awt.event.ActionListener CLIP_COPY;
public static final java.awt.event.ActionListener CLIP_PASTE;
public static final java.awt.event.ActionListener CLIP_CUT;
public static final java.awt.event.ActionListener INSERT_CHAR;
private static java.util.Hashtable actions;
protected java.awt.event.ActionListener grabAction;
protected boolean repeat;
protected int repeatCount;
protected InputHandler$MacroRecorder recorder;
public void InputHandler();
public static java.awt.event.ActionListener getAction(String);
public static String getActionName(java.awt.event.ActionListener);
public static java.util.Enumeration getActions();
public abstract void addDefaultKeyBindings();
public abstract void addKeyBinding(String, java.awt.event.ActionListener);
public abstract void removeKeyBinding(String);
public abstract void removeAllKeyBindings();
public void grabNextKeyStroke(java.awt.event.ActionListener);
public boolean isRepeatEnabled();
public void setRepeatEnabled(boolean);
public int getRepeatCount();
public void setRepeatCount(int);
public InputHandler$MacroRecorder getMacroRecorder();
public void setMacroRecorder(InputHandler$MacroRecorder);
public abstract InputHandler copy();
public void executeAction(java.awt.event.ActionListener, Object, String);
public static JEditTextArea getTextArea(java.util.EventObject);
protected void handleGrabAction(java.awt.event.KeyEvent);
static void
}
InputHandler$repeat
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$repeat implements java.awt.event.ActionListener, InputHandler$NonRecordable {
public void InputHandler$repeat();
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$delete_word
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$delete_word implements java.awt.event.ActionListener {
public void InputHandler$delete_word();
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$insert_break
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$insert_break implements java.awt.event.ActionListener {
public void InputHandler$insert_break();
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$prev_word
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$prev_word implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$prev_word(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$backspace
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$backspace implements java.awt.event.ActionListener {
public void InputHandler$backspace();
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$insert_char
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$insert_char implements java.awt.event.ActionListener, InputHandler$NonRepeatable {
public void InputHandler$insert_char();
public void actionPerformed(java.awt.event.ActionEvent);
}
PopupHelpItem
package mars.venus.editors.jeditsyntax;
public synchronized class PopupHelpItem {
private String tokenText;
private String example;
private String description;
private boolean exact;
private int exampleLength;
private static final String spaces = ;
public void PopupHelpItem(String, String, String, boolean);
public void PopupHelpItem(String, String, String);
public String getTokenText();
public String getExample();
public String getDescription();
public boolean getExact();
public int getExampleLength();
public String getExamplePaddedToLength(int);
public void setExample(String);
public void setDescription(String);
public static int maxExampleLength(java.util.ArrayList);
}
JEditTextArea$AdjustHandler
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$AdjustHandler implements java.awt.event.AdjustmentListener {
void JEditTextArea$AdjustHandler(JEditTextArea);
public void adjustmentValueChanged(java.awt.event.AdjustmentEvent);
}
JEditTextArea$ScrollLayout
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$ScrollLayout implements java.awt.LayoutManager {
private java.awt.Component center;
private java.awt.Component right;
private java.awt.Component bottom;
private java.util.Vector leftOfScrollBar;
void JEditTextArea$ScrollLayout(JEditTextArea);
public void addLayoutComponent(String, java.awt.Component);
public void removeLayoutComponent(java.awt.Component);
public java.awt.Dimension preferredLayoutSize(java.awt.Container);
public java.awt.Dimension minimumLayoutSize(java.awt.Container);
public void layoutContainer(java.awt.Container);
}
SyntaxUtilities
package mars.venus.editors.jeditsyntax;
public synchronized class SyntaxUtilities {
public static boolean popupShowing;
public static javax.swing.Popup popup;
public static boolean regionMatches(boolean, javax.swing.text.Segment, int, String);
public static boolean regionMatches(boolean, javax.swing.text.Segment, int, char[]);
public static SyntaxStyle[] getDefaultSyntaxStyles();
public static SyntaxStyle[] getCurrentSyntaxStyles();
public static int paintSyntaxLine(javax.swing.text.Segment, tokenmarker.Token, SyntaxStyle[], javax.swing.text.TabExpander, java.awt.Graphics, int, int);
private void SyntaxUtilities();
static void
}
InputHandler$clip_copy
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$clip_copy implements java.awt.event.ActionListener {
public void InputHandler$clip_copy();
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$NonRepeatable
package mars.venus.editors.jeditsyntax;
public abstract interface InputHandler$NonRepeatable {
}
InputHandler$end
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$end implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$end(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$prev_page
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$prev_page implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$prev_page(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
JEditTextArea
package mars.venus.editors.jeditsyntax;
public synchronized class JEditTextArea extends javax.swing.JComponent {
public static String LEFT_OF_SCROLLBAR;
public static java.awt.Color POPUP_HELP_TEXT_COLOR;
private static final int VERTICAL_SCROLLBAR_UNIT_INCREMENT_IN_LINES = 1;
private static final int LINES_PER_MOUSE_WHEEL_NOTCH = 3;
private javax.swing.JScrollBar lineNumbersVertical;
javax.swing.JPopupMenu popupMenu;
protected static String CENTER;
protected static String RIGHT;
protected static String BOTTOM;
protected static JEditTextArea focusedComponent;
protected static javax.swing.Timer caretTimer;
protected TextAreaPainter painter;
protected javax.swing.JPopupMenu popup;
protected javax.swing.event.EventListenerList listenerList;
protected JEditTextArea$MutableCaretEvent caretEvent;
protected boolean caretBlinks;
protected boolean caretVisible;
protected boolean blink;
protected boolean editable;
protected int caretBlinkRate;
protected int firstLine;
protected int visibleLines;
protected int electricScroll;
protected int horizontalOffset;
protected javax.swing.JScrollBar vertical;
protected javax.swing.JScrollBar horizontal;
protected boolean scrollBarsInitialized;
protected InputHandler inputHandler;
protected SyntaxDocument document;
protected JEditTextArea$DocumentHandler documentHandler;
protected javax.swing.text.Segment lineSegment;
protected int selectionStart;
protected int selectionStartLine;
protected int selectionEnd;
protected int selectionEndLine;
protected boolean biasLeft;
protected int bracketPosition;
protected int bracketLine;
protected int magicCaret;
protected boolean overwrite;
protected boolean rectSelect;
protected boolean unredoing;
public void JEditTextArea(javax.swing.JComponent);
public void JEditTextArea(TextAreaDefaults, javax.swing.JComponent);
public final TextAreaPainter getPainter();
public final InputHandler getInputHandler();
public void setInputHandler(InputHandler);
public final boolean isCaretBlinkEnabled();
public void setCaretBlinkEnabled(boolean);
public final boolean isCaretVisible();
public void setCaretVisible(boolean);
public final void blinkCaret();
public final int getElectricScroll();
public final void setElectricScroll(int);
public void updateScrollBars();
public final int getFirstLine();
public void setFirstLine(int);
public final int getVisibleLines();
public final void recalculateVisibleLines();
public final int getHorizontalOffset();
public void setHorizontalOffset(int);
public boolean setOrigin(int, int);
public boolean scrollToCaret();
public boolean scrollTo(int, int);
public int lineToY(int);
public int yToLine(int);
public final int offsetToX(int, int);
public int _offsetToX(int, int);
public int xToOffset(int, int);
public int xyToOffset(int, int);
public final javax.swing.text.Document getDocument();
public void setDocument(SyntaxDocument);
public final tokenmarker.TokenMarker getTokenMarker();
public final void setTokenMarker(tokenmarker.TokenMarker);
public final int getDocumentLength();
public final int getLineCount();
public final int getLineOfOffset(int);
public int getLineStartOffset(int);
public int getLineEndOffset(int);
public int getLineLength(int);
public String getText();
public void setText(String);
public final String getText(int, int);
public final void getText(int, int, javax.swing.text.Segment);
public final String getLineText(int);
public final void getLineText(int, javax.swing.text.Segment);
public final int getSelectionStart();
public int getSelectionStart(int);
public final int getSelectionStartLine();
public final void setSelectionStart(int);
public final int getSelectionEnd();
public int getSelectionEnd(int);
public final int getSelectionEndLine();
public final void setSelectionEnd(int);
public final int getCaretPosition();
public final int getCaretLine();
public final int getMarkPosition();
public final int getMarkLine();
public final void setCaretPosition(int);
public final void selectAll();
public final void selectNone();
public void select(int, int);
public final String getSelectedText();
public void setSelectedText(String);
public final boolean isEditable();
public final void setEditable(boolean);
public final javax.swing.JPopupMenu getRightClickPopup();
public final void setRightClickPopup(javax.swing.JPopupMenu);
public final int getMagicCaretPosition();
public final void setMagicCaretPosition(int);
public void overwriteSetSelectedText(String);
public final boolean isOverwriteEnabled();
public final void setOverwriteEnabled(boolean);
public final boolean isSelectionRectangular();
public final void setSelectionRectangular(boolean);
public final int getBracketPosition();
public final int getBracketLine();
public final void addCaretListener(javax.swing.event.CaretListener);
public final void removeCaretListener(javax.swing.event.CaretListener);
public void cut();
public void copy();
public void paste();
public void removeNotify();
public void processKeyEvent(java.awt.event.KeyEvent);
protected void fireCaretEvent();
protected void updateBracketHighlight(int);
protected void documentChanged(javax.swing.event.DocumentEvent);
public String getSyntaxSensitiveToolTipText(int, int);
public String getAutoIndent();
public String getLeadingWhiteSpace();
private java.util.ArrayList getSyntaxSensitiveHelpAtLineOffset(int, int, boolean);
private void applySyntaxSensitiveHelp();
private void checkAutoIndent(java.awt.event.KeyEvent);
private void checkPopupMenu(java.awt.event.KeyEvent);
private boolean checkPopupCompletion(java.awt.event.KeyEvent);
static void
}
SyntaxDocument
package mars.venus.editors.jeditsyntax;
public synchronized class SyntaxDocument extends javax.swing.text.PlainDocument {
protected tokenmarker.TokenMarker tokenMarker;
public void SyntaxDocument();
public tokenmarker.TokenMarker getTokenMarker();
public void setTokenMarker(tokenmarker.TokenMarker);
public void tokenizeLines();
public void tokenizeLines(int, int);
public void beginCompoundEdit();
public void endCompoundEdit();
public void addUndoableEdit(javax.swing.undo.UndoableEdit);
protected void fireInsertUpdate(javax.swing.event.DocumentEvent);
protected void fireRemoveUpdate(javax.swing.event.DocumentEvent);
}
InputHandler$home
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$home implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$home(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
KeywordMap$Keyword
package mars.venus.editors.jeditsyntax;
synchronized class KeywordMap$Keyword {
public char[] keyword;
public byte id;
public KeywordMap$Keyword next;
public void KeywordMap$Keyword(KeywordMap, char[], byte, KeywordMap$Keyword);
}
JEditTextArea$FocusHandler
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$FocusHandler implements java.awt.event.FocusListener {
void JEditTextArea$FocusHandler(JEditTextArea);
public void focusGained(java.awt.event.FocusEvent);
public void focusLost(java.awt.event.FocusEvent);
}
InputHandler$next_char
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$next_char implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$next_char(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$clip_cut
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$clip_cut implements java.awt.event.ActionListener {
public void InputHandler$clip_cut();
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$Wrapper
package mars.venus.editors.jeditsyntax;
public abstract interface InputHandler$Wrapper {
}
MIPSTokenMarker
package mars.venus.editors.jeditsyntax.tokenmarker;
public synchronized class MIPSTokenMarker extends TokenMarker {
private static mars.venus.editors.jeditsyntax.KeywordMap cKeywords;
private static String[] tokenLabels;
private static String[] tokenExamples;
private mars.venus.editors.jeditsyntax.KeywordMap keywords;
private int lastOffset;
private int lastKeyword;
public void MIPSTokenMarker();
public void MIPSTokenMarker(mars.venus.editors.jeditsyntax.KeywordMap);
public static String[] getMIPSTokenLabels();
public static String[] getMIPSTokenExamples();
public byte markTokensImpl(byte, javax.swing.text.Segment, int);
public java.util.ArrayList getTokenExactMatchHelp(Token, String);
public java.util.ArrayList getTokenPrefixMatchHelp(String, Token, Token, String);
private java.util.ArrayList getTextFromDirectiveMatch(String, boolean);
private java.util.ArrayList getTextFromInstructionMatch(String, boolean);
public static mars.venus.editors.jeditsyntax.KeywordMap getKeywords();
private boolean doKeyword(javax.swing.text.Segment, int, char);
private boolean tokenListContainsKeyword();
}
TokenMarker
package mars.venus.editors.jeditsyntax.tokenmarker;
public abstract synchronized class TokenMarker {
protected Token firstToken;
protected Token lastToken;
protected TokenMarker$LineInfo[] lineInfo;
protected int length;
protected int lastLine;
protected boolean nextLineRequested;
public Token markTokens(javax.swing.text.Segment, int);
protected abstract byte markTokensImpl(byte, javax.swing.text.Segment, int);
public boolean supportsMultilineTokens();
public void insertLines(int, int);
public void deleteLines(int, int);
public int getLineCount();
public boolean isNextLineRequested();
public java.util.ArrayList getTokenExactMatchHelp(Token, String);
public java.util.ArrayList getTokenPrefixMatchHelp(String, Token, Token, String);
protected void TokenMarker();
protected void ensureCapacity(int);
protected void addToken(int, byte);
}
Token
package mars.venus.editors.jeditsyntax.tokenmarker;
public synchronized class Token {
public static final byte NULL = 0;
public static final byte COMMENT1 = 1;
public static final byte COMMENT2 = 2;
public static final byte LITERAL1 = 3;
public static final byte LITERAL2 = 4;
public static final byte LABEL = 5;
public static final byte KEYWORD1 = 6;
public static final byte KEYWORD2 = 7;
public static final byte KEYWORD3 = 8;
public static final byte OPERATOR = 9;
public static final byte INVALID = 10;
public static final byte MACRO_ARG = 11;
public static final byte ID_COUNT = 12;
public static final byte INTERNAL_FIRST = 100;
public static final byte INTERNAL_LAST = 126;
public static final byte END = 127;
public int length;
public byte id;
public Token next;
public void Token(int, byte);
public String toString();
}
TokenMarker$LineInfo
package mars.venus.editors.jeditsyntax.tokenmarker;
public synchronized class TokenMarker$LineInfo {
public byte token;
public Object obj;
public void TokenMarker$LineInfo(TokenMarker);
public void TokenMarker$LineInfo(TokenMarker, byte, Object);
}
InputHandler$prev_line
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$prev_line implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$prev_line(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
SyntaxStyle
package mars.venus.editors.jeditsyntax;
public synchronized class SyntaxStyle {
private java.awt.Color color;
private boolean italic;
private boolean bold;
private java.awt.Font lastFont;
private java.awt.Font lastStyledFont;
private java.awt.FontMetrics fontMetrics;
public void SyntaxStyle(java.awt.Color, boolean, boolean);
public java.awt.Color getColor();
public String getColorAsHexString();
public boolean isPlain();
public boolean isItalic();
public boolean isBold();
public java.awt.Font getStyledFont(java.awt.Font);
public java.awt.FontMetrics getFontMetrics(java.awt.Font);
public void setGraphicsFlags(java.awt.Graphics, java.awt.Font);
public String toString();
}
InputHandler$overwrite
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$overwrite implements java.awt.event.ActionListener {
public void InputHandler$overwrite();
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$select_all
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$select_all implements java.awt.event.ActionListener {
public void InputHandler$select_all();
public void actionPerformed(java.awt.event.ActionEvent);
}
JEditTextArea$2
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$2 implements Runnable {
void JEditTextArea$2(JEditTextArea, javax.swing.MenuElement[]);
public void run();
}
InputHandler$document_end
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$document_end implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$document_end(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
TextAreaDefaults
package mars.venus.editors.jeditsyntax;
public synchronized class TextAreaDefaults {
private static TextAreaDefaults DEFAULTS;
public InputHandler inputHandler;
public SyntaxDocument document;
public boolean editable;
public boolean caretVisible;
public boolean caretBlinks;
public boolean blockCaret;
public int caretBlinkRate;
public int electricScroll;
public int tabSize;
public int cols;
public int rows;
public SyntaxStyle[] styles;
public java.awt.Color caretColor;
public java.awt.Color selectionColor;
public java.awt.Color lineHighlightColor;
public boolean lineHighlight;
public java.awt.Color bracketHighlightColor;
public boolean bracketHighlight;
public java.awt.Color eolMarkerColor;
public boolean eolMarkers;
public boolean paintInvalid;
public javax.swing.JPopupMenu popup;
public void TextAreaDefaults();
public static TextAreaDefaults getDefaults();
}
JEditTextArea$PopupHelpActionListener
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$PopupHelpActionListener implements java.awt.event.ActionListener {
private String tokenText;
private String text;
public void JEditTextArea$PopupHelpActionListener(JEditTextArea, String, String);
public void actionPerformed(java.awt.event.ActionEvent);
}
TextAreaPainter
package mars.venus.editors.jeditsyntax;
public synchronized class TextAreaPainter extends javax.swing.JComponent implements javax.swing.text.TabExpander {
int currentLineIndex;
tokenmarker.Token currentLineTokens;
javax.swing.text.Segment currentLine;
protected JEditTextArea textArea;
protected SyntaxStyle[] styles;
protected java.awt.Color caretColor;
protected java.awt.Color selectionColor;
protected java.awt.Color lineHighlightColor;
protected java.awt.Color bracketHighlightColor;
protected java.awt.Color eolMarkerColor;
protected boolean blockCaret;
protected boolean lineHighlight;
protected boolean bracketHighlight;
protected boolean paintInvalid;
protected boolean eolMarkers;
protected int cols;
protected int rows;
protected int tabSize;
protected int tabSizeChars;
protected java.awt.FontMetrics fm;
protected TextAreaPainter$Highlight highlights;
public void TextAreaPainter(JEditTextArea, TextAreaDefaults);
public final boolean isManagingFocus();
public int getTabSize();
public void setTabSize(int);
public final SyntaxStyle[] getStyles();
public final void setStyles(SyntaxStyle[]);
public final java.awt.Color getCaretColor();
public final void setCaretColor(java.awt.Color);
public final java.awt.Color getSelectionColor();
public final void setSelectionColor(java.awt.Color);
public final java.awt.Color getLineHighlightColor();
public final void setLineHighlightColor(java.awt.Color);
public final boolean isLineHighlightEnabled();
public final void setLineHighlightEnabled(boolean);
public final java.awt.Color getBracketHighlightColor();
public final void setBracketHighlightColor(java.awt.Color);
public final boolean isBracketHighlightEnabled();
public final void setBracketHighlightEnabled(boolean);
public final boolean isBlockCaretEnabled();
public final void setBlockCaretEnabled(boolean);
public final java.awt.Color getEOLMarkerColor();
public final void setEOLMarkerColor(java.awt.Color);
public final boolean getEOLMarkersPainted();
public final void setEOLMarkersPainted(boolean);
public boolean getInvalidLinesPainted();
public void setInvalidLinesPainted(boolean);
public void addCustomHighlight(TextAreaPainter$Highlight);
public String getToolTipText(java.awt.event.MouseEvent);
public java.awt.FontMetrics getFontMetrics();
public void setFont(java.awt.Font);
public void paint(java.awt.Graphics);
public final void invalidateLine(int);
public final void invalidateLineRange(int, int);
public final void invalidateSelectedLines();
public float nextTabStop(float, int);
public java.awt.Dimension getPreferredSize();
public java.awt.Dimension getMinimumSize();
protected void paintLine(java.awt.Graphics, tokenmarker.TokenMarker, int, int);
protected void paintPlainLine(java.awt.Graphics, int, java.awt.Font, java.awt.Color, int, int);
protected void paintSyntaxLine(java.awt.Graphics, tokenmarker.TokenMarker, int, java.awt.Font, java.awt.Color, int, int);
protected void paintHighlight(java.awt.Graphics, int, int);
protected void paintLineHighlight(java.awt.Graphics, int, int);
protected void paintBracketHighlight(java.awt.Graphics, int, int);
protected void paintCaret(java.awt.Graphics, int, int);
}
InputHandler$next_word
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$next_word implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$next_word(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
JEditBasedTextArea$1
package mars.venus.editors.jeditsyntax;
synchronized class JEditBasedTextArea$1 implements javax.swing.event.UndoableEditListener {
void JEditBasedTextArea$1(JEditBasedTextArea);
public void undoableEditHappened(javax.swing.event.UndoableEditEvent);
}
JEditBasedTextArea
package mars.venus.editors.jeditsyntax;
public synchronized class JEditBasedTextArea extends JEditTextArea implements mars.venus.editors.MARSTextEditingArea, javax.swing.event.CaretListener {
private mars.venus.EditPane editPane;
private javax.swing.undo.UndoManager undoManager;
private javax.swing.event.UndoableEditListener undoableEditListener;
private boolean isCompoundEdit;
private javax.swing.undo.CompoundEdit compoundEdit;
private JEditBasedTextArea sourceCode;
public void JEditBasedTextArea(mars.venus.EditPane, javax.swing.JComponent);
public void setFont(java.awt.Font);
public java.awt.Font getFont();
public void setLineHighlightEnabled(boolean);
public void setCaretBlinkRate(int);
public void setTabSize(int);
public void updateSyntaxStyles();
public java.awt.Component getOuterComponent();
public void discardAllUndoableEdits();
public void caretUpdate(javax.swing.event.CaretEvent);
public void replaceSelection(String);
public void setSelectionVisible(boolean);
public void setSourceCode(String, boolean);
public javax.swing.undo.UndoManager getUndoManager();
public void undo();
public void redo();
public int doFindText(String, boolean);
public int nextIndex(String, String, int, boolean);
public int doReplace(String, String, boolean);
public int doReplaceAll(String, String, boolean);
}
JEditTextArea$MouseHandler
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$MouseHandler extends java.awt.event.MouseAdapter {
void JEditTextArea$MouseHandler(JEditTextArea);
public void mousePressed(java.awt.event.MouseEvent);
private void doSingleClick(java.awt.event.MouseEvent, int, int, int);
private void doDoubleClick(java.awt.event.MouseEvent, int, int, int) throws javax.swing.text.BadLocationException;
private void doTripleClick(java.awt.event.MouseEvent, int, int, int);
}
InputHandler$next_page
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$next_page implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$next_page(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
JEditTextArea$CaretBlinker
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$CaretBlinker implements java.awt.event.ActionListener {
void JEditTextArea$CaretBlinker();
public void actionPerformed(java.awt.event.ActionEvent);
}
JEditTextArea$ComponentHandler
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$ComponentHandler extends java.awt.event.ComponentAdapter {
void JEditTextArea$ComponentHandler(JEditTextArea);
public void componentResized(java.awt.event.ComponentEvent);
}
JEditTextArea$MutableCaretEvent
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$MutableCaretEvent extends javax.swing.event.CaretEvent {
void JEditTextArea$MutableCaretEvent(JEditTextArea);
public int getDot();
public int getMark();
}
InputHandler$document_home
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$document_home implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$document_home(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
JEditTextArea$CaretUndo
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$CaretUndo extends javax.swing.undo.AbstractUndoableEdit {
private int start;
private int end;
void JEditTextArea$CaretUndo(JEditTextArea, int, int);
public boolean isSignificant();
public String getPresentationName();
public void undo() throws javax.swing.undo.CannotUndoException;
public void redo() throws javax.swing.undo.CannotRedoException;
public boolean addEdit(javax.swing.undo.UndoableEdit);
}
JEditTextArea$1
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$1 implements java.awt.KeyEventDispatcher {
void JEditTextArea$1(JEditTextArea);
public boolean dispatchKeyEvent(java.awt.event.KeyEvent);
}
TextAreaPainter$Highlight
package mars.venus.editors.jeditsyntax;
public abstract interface TextAreaPainter$Highlight {
public abstract void init(JEditTextArea, TextAreaPainter$Highlight);
public abstract void paintHighlight(java.awt.Graphics, int, int);
public abstract String getToolTipText(java.awt.event.MouseEvent);
}
InputHandler$prev_char
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$prev_char implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$prev_char(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
JEditTextArea$AdjustHandler$1
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$AdjustHandler$1 implements Runnable {
void JEditTextArea$AdjustHandler$1(JEditTextArea$AdjustHandler, java.awt.event.AdjustmentEvent);
public void run();
}
TextUtilities
package mars.venus.editors.jeditsyntax;
public synchronized class TextUtilities {
public void TextUtilities();
public static int findMatchingBracket(javax.swing.text.Document, int) throws javax.swing.text.BadLocationException;
public static int findWordStart(String, int, String);
public static int findWordEnd(String, int, String);
}
InputHandler$clip_paste
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$clip_paste implements java.awt.event.ActionListener {
public void InputHandler$clip_paste();
public void actionPerformed(java.awt.event.ActionEvent);
}
DefaultInputHandler
package mars.venus.editors.jeditsyntax;
public synchronized class DefaultInputHandler extends InputHandler {
private java.util.Hashtable bindings;
private java.util.Hashtable currentBindings;
public void DefaultInputHandler();
public void addDefaultKeyBindings();
public void addKeyBinding(String, java.awt.event.ActionListener);
public void removeKeyBinding(String);
public void removeAllKeyBindings();
public InputHandler copy();
public void keyPressed(java.awt.event.KeyEvent);
public void keyTyped(java.awt.event.KeyEvent);
public static javax.swing.KeyStroke parseKeyStroke(String);
private void DefaultInputHandler(DefaultInputHandler);
}
JEditTextArea$DragHandler
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$DragHandler implements java.awt.event.MouseMotionListener {
void JEditTextArea$DragHandler(JEditTextArea);
public void mouseDragged(java.awt.event.MouseEvent);
public void mouseMoved(java.awt.event.MouseEvent);
}
InputHandler$NonRecordable
package mars.venus.editors.jeditsyntax;
public abstract interface InputHandler$NonRecordable {
}
InputHandler$next_line
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$next_line implements java.awt.event.ActionListener {
private boolean select;
public void InputHandler$next_line(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
}
InputHandler$toggle_rect
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$toggle_rect implements java.awt.event.ActionListener {
public void InputHandler$toggle_rect();
public void actionPerformed(java.awt.event.ActionEvent);
}
JEditTextArea$MouseWheelHandler
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$MouseWheelHandler implements java.awt.event.MouseWheelListener {
void JEditTextArea$MouseWheelHandler(JEditTextArea);
public void mouseWheelMoved(java.awt.event.MouseWheelEvent);
}
InstructionMouseEvent
package mars.venus.editors.jeditsyntax;
synchronized class InstructionMouseEvent extends java.awt.event.MouseEvent {
private javax.swing.text.Segment line;
public void InstructionMouseEvent(java.awt.Component, int, int, javax.swing.text.Segment);
public javax.swing.text.Segment getLine();
}
JEditTextArea$DocumentHandler
package mars.venus.editors.jeditsyntax;
synchronized class JEditTextArea$DocumentHandler implements javax.swing.event.DocumentListener {
void JEditTextArea$DocumentHandler(JEditTextArea);
public void insertUpdate(javax.swing.event.DocumentEvent);
public void removeUpdate(javax.swing.event.DocumentEvent);
public void changedUpdate(javax.swing.event.DocumentEvent);
}
InputHandler$delete
package mars.venus.editors.jeditsyntax;
public synchronized class InputHandler$delete implements java.awt.event.ActionListener {
public void InputHandler$delete();
public void actionPerformed(java.awt.event.ActionEvent);
}
GenericTextArea$1
package mars.venus.editors.generic;
synchronized class GenericTextArea$1 implements javax.swing.event.ChangeListener {
void GenericTextArea$1(GenericTextArea);
public void stateChanged(javax.swing.event.ChangeEvent);
}
GenericTextArea
package mars.venus.editors.generic;
public synchronized class GenericTextArea extends javax.swing.JTextArea implements mars.venus.editors.MARSTextEditingArea {
private mars.venus.EditPane editPane;
private javax.swing.undo.UndoManager undoManager;
private javax.swing.event.UndoableEditListener undoableEditListener;
private javax.swing.JTextArea sourceCode;
private javax.swing.JScrollPane editAreaScrollPane;
private boolean isCompoundEdit;
private javax.swing.undo.CompoundEdit compoundEdit;
public void GenericTextArea(mars.venus.EditPane, javax.swing.JComponent);
public void setLineHighlightEnabled(boolean);
public void updateSyntaxStyles();
public void setCaretBlinkRate(int);
public java.awt.Component getOuterComponent();
public void setSourceCode(String, boolean);
public void discardAllUndoableEdits();
public void setText(String);
public void setCaretVisible(boolean);
public void setSelectionVisible(boolean);
public javax.swing.undo.UndoManager getUndoManager();
public void undo();
public void redo();
public int doFindText(String, boolean);
public int nextIndex(String, String, int, boolean);
public int doReplace(String, String, boolean);
public int doReplaceAll(String, String, boolean);
}
GenericTextArea$2
package mars.venus.editors.generic;
synchronized class GenericTextArea$2 implements javax.swing.event.UndoableEditListener {
void GenericTextArea$2(GenericTextArea);
public void undoableEditHappened(javax.swing.event.UndoableEditEvent);
}
MARSTextEditingArea
package mars.venus.editors;
public abstract interface MARSTextEditingArea {
public static final int TEXT_NOT_FOUND = 0;
public static final int TEXT_FOUND = 1;
public static final int TEXT_REPLACED_FOUND_NEXT = 2;
public static final int TEXT_REPLACED_NOT_FOUND_NEXT = 3;
public abstract void copy();
public abstract void cut();
public abstract int doFindText(String, boolean);
public abstract int doReplace(String, String, boolean);
public abstract int doReplaceAll(String, String, boolean);
public abstract int getCaretPosition();
public abstract javax.swing.text.Document getDocument();
public abstract String getSelectedText();
public abstract int getSelectionEnd();
public abstract int getSelectionStart();
public abstract void select(int, int);
public abstract void selectAll();
public abstract String getText();
public abstract javax.swing.undo.UndoManager getUndoManager();
public abstract void paste();
public abstract void replaceSelection(String);
public abstract void setCaretPosition(int);
public abstract void setEditable(boolean);
public abstract void setSelectionEnd(int);
public abstract void setSelectionStart(int);
public abstract void setText(String);
public abstract void setFont(java.awt.Font);
public abstract java.awt.Font getFont();
public abstract boolean requestFocusInWindow();
public abstract java.awt.FontMetrics getFontMetrics(java.awt.Font);
public abstract void setBackground(java.awt.Color);
public abstract void setEnabled(boolean);
public abstract void grabFocus();
public abstract void redo();
public abstract void revalidate();
public abstract void setSourceCode(String, boolean);
public abstract void setCaretVisible(boolean);
public abstract void setSelectionVisible(boolean);
public abstract void undo();
public abstract void discardAllUndoableEdits();
public abstract void setLineHighlightEnabled(boolean);
public abstract void setCaretBlinkRate(int);
public abstract void setTabSize(int);
public abstract void updateSyntaxStyles();
public abstract java.awt.Component getOuterComponent();
}
EditPane$1
package mars.venus;
synchronized class EditPane$1 implements javax.swing.event.DocumentListener {
void EditPane$1(EditPane);
public void insertUpdate(javax.swing.event.DocumentEvent);
public void removeUpdate(javax.swing.event.DocumentEvent);
public void changedUpdate(javax.swing.event.DocumentEvent);
}
SettingsHighlightingAction$1
package mars.venus;
synchronized class SettingsHighlightingAction$1 extends java.awt.event.WindowAdapter {
void SettingsHighlightingAction$1(SettingsHighlightingAction);
public void windowClosing(java.awt.event.WindowEvent);
}
SettingsValueDisplayBaseAction
package mars.venus;
public synchronized class SettingsValueDisplayBaseAction extends GuiAction {
public void SettingsValueDisplayBaseAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
MessagesPane$Asker$1$2
package mars.venus;
synchronized class MessagesPane$Asker$1$2 implements Runnable {
void MessagesPane$Asker$1$2(MessagesPane$Asker$1, javax.swing.event.DocumentEvent);
public void run();
}
LabelsWindow$MyTippedJTable
package mars.venus;
synchronized class LabelsWindow$MyTippedJTable extends javax.swing.JTable {
void LabelsWindow$MyTippedJTable(LabelsWindow, LabelsWindow$LabelTableModel);
protected javax.swing.table.JTableHeader createDefaultTableHeader();
public java.awt.Component prepareRenderer(javax.swing.table.TableCellRenderer, int, int);
}
SettingsPopupInputAction
package mars.venus;
public synchronized class SettingsPopupInputAction extends GuiAction {
public void SettingsPopupInputAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
EditSelectAllAction
package mars.venus;
public synchronized class EditSelectAllAction extends GuiAction {
public void EditSelectAllAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
EditFindReplaceAction$FindReplaceDialog$3
package mars.venus;
synchronized class EditFindReplaceAction$FindReplaceDialog$3 implements java.awt.event.ActionListener {
void EditFindReplaceAction$FindReplaceDialog$3(EditFindReplaceAction$FindReplaceDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
DataSegmentWindow$PrevButton
package mars.venus;
synchronized class DataSegmentWindow$PrevButton extends RepeatButton {
public void DataSegmentWindow$PrevButton(DataSegmentWindow, javax.swing.Icon);
public void actionPerformed(java.awt.event.ActionEvent);
}
VenusUI
package mars.venus;
public synchronized class VenusUI extends javax.swing.JFrame {
VenusUI mainUI;
public javax.swing.JMenuBar menu;
javax.swing.JToolBar toolbar;
MainPane mainPane;
RegistersPane registersPane;
RegistersWindow registersTab;
Coprocessor1Window coprocessor1Tab;
Coprocessor0Window coprocessor0Tab;
MessagesPane messagesPane;
javax.swing.JSplitPane splitter;
javax.swing.JSplitPane horizonSplitter;
javax.swing.JPanel north;
private int frameState;
private static int menuState;
private static boolean reset;
private static boolean started;
Editor editor;
private javax.swing.JMenu file;
private javax.swing.JMenu run;
private javax.swing.JMenu window;
private javax.swing.JMenu help;
private javax.swing.JMenu edit;
private javax.swing.JMenu settings;
private javax.swing.JMenuItem fileNew;
private javax.swing.JMenuItem fileOpen;
private javax.swing.JMenuItem fileClose;
private javax.swing.JMenuItem fileCloseAll;
private javax.swing.JMenuItem fileSave;
private javax.swing.JMenuItem fileSaveAs;
private javax.swing.JMenuItem fileSaveAll;
private javax.swing.JMenuItem fileDumpMemory;
private javax.swing.JMenuItem filePrint;
private javax.swing.JMenuItem fileExit;
private javax.swing.JMenuItem editUndo;
private javax.swing.JMenuItem editRedo;
private javax.swing.JMenuItem editCut;
private javax.swing.JMenuItem editCopy;
private javax.swing.JMenuItem editPaste;
private javax.swing.JMenuItem editFindReplace;
private javax.swing.JMenuItem editSelectAll;
private javax.swing.JMenuItem runGo;
private javax.swing.JMenuItem runStep;
private javax.swing.JMenuItem runBackstep;
private javax.swing.JMenuItem runReset;
private javax.swing.JMenuItem runAssemble;
private javax.swing.JMenuItem runStop;
private javax.swing.JMenuItem runPause;
private javax.swing.JMenuItem runClearBreakpoints;
private javax.swing.JMenuItem runToggleBreakpoints;
private javax.swing.JCheckBoxMenuItem settingsLabel;
private javax.swing.JCheckBoxMenuItem settingsPopupInput;
private javax.swing.JCheckBoxMenuItem settingsValueDisplayBase;
private javax.swing.JCheckBoxMenuItem settingsAddressDisplayBase;
private javax.swing.JCheckBoxMenuItem settingsExtended;
private javax.swing.JCheckBoxMenuItem settingsAssembleOnOpen;
private javax.swing.JCheckBoxMenuItem settingsAssembleAll;
private javax.swing.JCheckBoxMenuItem settingsWarningsAreErrors;
private javax.swing.JCheckBoxMenuItem settingsStartAtMain;
private javax.swing.JCheckBoxMenuItem settingsDelayedBranching;
private javax.swing.JCheckBoxMenuItem settingsProgramArguments;
private javax.swing.JCheckBoxMenuItem settingsSelfModifyingCode;
private javax.swing.JMenuItem settingsExceptionHandler;
private javax.swing.JMenuItem settingsEditor;
private javax.swing.JMenuItem settingsHighlighting;
private javax.swing.JMenuItem settingsMemoryConfiguration;
private javax.swing.JMenuItem helpHelp;
private javax.swing.JMenuItem helpAbout;
private javax.swing.JButton Undo;
private javax.swing.JButton Redo;
private javax.swing.JButton Cut;
private javax.swing.JButton Copy;
private javax.swing.JButton Paste;
private javax.swing.JButton FindReplace;
private javax.swing.JButton SelectAll;
private javax.swing.JButton New;
private javax.swing.JButton Open;
private javax.swing.JButton Save;
private javax.swing.JButton SaveAs;
private javax.swing.JButton SaveAll;
private javax.swing.JButton DumpMemory;
private javax.swing.JButton Print;
private javax.swing.JButton Run;
private javax.swing.JButton Assemble;
private javax.swing.JButton Reset;
private javax.swing.JButton Step;
private javax.swing.JButton Backstep;
private javax.swing.JButton Stop;
private javax.swing.JButton Pause;
private javax.swing.JButton Help;
private javax.swing.Action fileNewAction;
private javax.swing.Action fileOpenAction;
private javax.swing.Action fileCloseAction;
private javax.swing.Action fileCloseAllAction;
private javax.swing.Action fileSaveAction;
private javax.swing.Action fileSaveAsAction;
private javax.swing.Action fileSaveAllAction;
private javax.swing.Action fileDumpMemoryAction;
private javax.swing.Action filePrintAction;
private javax.swing.Action fileExitAction;
EditUndoAction editUndoAction;
EditRedoAction editRedoAction;
private javax.swing.Action editCutAction;
private javax.swing.Action editCopyAction;
private javax.swing.Action editPasteAction;
private javax.swing.Action editFindReplaceAction;
private javax.swing.Action editSelectAllAction;
private javax.swing.Action runAssembleAction;
private javax.swing.Action runGoAction;
private javax.swing.Action runStepAction;
private javax.swing.Action runBackstepAction;
private javax.swing.Action runResetAction;
private javax.swing.Action runStopAction;
private javax.swing.Action runPauseAction;
private javax.swing.Action runClearBreakpointsAction;
private javax.swing.Action runToggleBreakpointsAction;
private javax.swing.Action settingsLabelAction;
private javax.swing.Action settingsPopupInputAction;
private javax.swing.Action settingsValueDisplayBaseAction;
private javax.swing.Action settingsAddressDisplayBaseAction;
private javax.swing.Action settingsExtendedAction;
private javax.swing.Action settingsAssembleOnOpenAction;
private javax.swing.Action settingsAssembleAllAction;
private javax.swing.Action settingsWarningsAreErrorsAction;
private javax.swing.Action settingsStartAtMainAction;
private javax.swing.Action settingsProgramArgumentsAction;
private javax.swing.Action settingsDelayedBranchingAction;
private javax.swing.Action settingsExceptionHandlerAction;
private javax.swing.Action settingsEditorAction;
private javax.swing.Action settingsHighlightingAction;
private javax.swing.Action settingsMemoryConfigurationAction;
private javax.swing.Action settingsSelfModifyingCodeAction;
private javax.swing.Action helpHelpAction;
private javax.swing.Action helpAboutAction;
public void VenusUI(String);
private void createActionObjects();
private javax.swing.JMenuBar setUpMenuBar();
javax.swing.JToolBar setUpToolBar();
void setMenuState(int);
void setMenuStateInitial();
void setMenuStateNotEdited();
void setMenuStateEditing();
void setMenuStateEditingNew();
void setMenuStateRunnable();
void setMenuStateRunning();
void setMenuStateTerminated();
public static int getMenuState();
public static void setReset(boolean);
public static void setStarted(boolean);
public static boolean getReset();
public static boolean getStarted();
public Editor getEditor();
public MainPane getMainPane();
public MessagesPane getMessagesPane();
public RegistersPane getRegistersPane();
public javax.swing.JCheckBoxMenuItem getValueDisplayBaseMenuItem();
public javax.swing.JCheckBoxMenuItem getAddressDisplayBaseMenuItem();
public javax.swing.Action getRunAssembleAction();
public void haveMenuRequestFocus();
public void dispatchEventToMenu(java.awt.event.KeyEvent);
private void setupPopupMenu();
static void
}
Coprocessor1Window$RegTableModel
package mars.venus;
synchronized class Coprocessor1Window$RegTableModel extends javax.swing.table.AbstractTableModel {
final String[] columnNames;
Object[][] data;
public void Coprocessor1Window$RegTableModel(Coprocessor1Window, Object[][]);
public int getColumnCount();
public int getRowCount();
public String getColumnName(int);
public Object getValueAt(int, int);
public Class getColumnClass(int);
public boolean isCellEditable(int, int);
public void setValueAt(Object, int, int);
private void setDisplayAndModelValueAt(Object, int, int);
private void printDebugData();
}
DataSegmentWindow$9
package mars.venus;
synchronized class DataSegmentWindow$9 implements java.awt.event.ActionListener {
void DataSegmentWindow$9(DataSegmentWindow);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsStartAtMainAction
package mars.venus;
public synchronized class SettingsStartAtMainAction extends GuiAction {
public void SettingsStartAtMainAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
FileDumpMemoryAction
package mars.venus;
public synchronized class FileDumpMemoryAction extends GuiAction {
private javax.swing.JDialog dumpDialog;
private static final String title = Dump Memory To File;
private String[] segmentArray;
private int[] baseAddressArray;
private int[] limitAddressArray;
private int[] highAddressArray;
private String[] segmentListArray;
private int[] segmentListBaseArray;
private int[] segmentListHighArray;
private javax.swing.JComboBox segmentListSelector;
private javax.swing.JComboBox formatListSelector;
public void FileDumpMemoryAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
private boolean dumpMemory();
private javax.swing.JDialog createDumpDialog();
private javax.swing.JPanel buildDialogPanel();
private boolean performDump(int, int, mars.mips.dump.DumpFormat);
private void closeDialog();
}
SettingsHighlightingAction$5
package mars.venus;
synchronized class SettingsHighlightingAction$5 implements java.awt.event.ActionListener {
void SettingsHighlightingAction$5(SettingsHighlightingAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
Coprocessor0Window
package mars.venus;
public synchronized class Coprocessor0Window extends javax.swing.JPanel implements java.util.Observer {
private static javax.swing.JTable table;
private static mars.mips.hardware.Register[] registers;
private Object[][] tableData;
private boolean highlighting;
private int highlightRow;
private ExecutePane executePane;
private int[] rowGivenRegNumber;
private static final int NAME_COLUMN = 0;
private static final int NUMBER_COLUMN = 1;
private static final int VALUE_COLUMN = 2;
private static mars.Settings settings;
public void Coprocessor0Window();
public Object[][] setupWindow();
public void clearWindow();
public void clearHighlighting();
public void refresh();
public void updateRegisters();
public void updateRegisters(int);
public void updateRegisterValue(int, int, int);
public void update(java.util.Observable, Object);
void highlightCellForRegister(mars.mips.hardware.Register);
}
RepeatButton
package mars.venus;
public synchronized class RepeatButton extends javax.swing.JButton implements java.awt.event.ActionListener, java.awt.event.MouseListener {
private boolean pressed;
private boolean repeatEnabled;
private javax.swing.Timer timer;
private int initialDelay;
private int delay;
private int modifiers;
private static boolean testing;
public void RepeatButton();
public void RepeatButton(javax.swing.Action);
public void RepeatButton(javax.swing.Icon);
public void RepeatButton(String);
public void RepeatButton(String, javax.swing.Icon);
private void init();
public int getDelay();
public void setDelay(int);
public int getInitialDelay();
public void setInitialDelay(int);
public boolean isRepeatEnabled();
public void setRepeatEnabled(boolean);
public void setEnabled(boolean);
public void actionPerformed(java.awt.event.ActionEvent);
public void mouseClicked(java.awt.event.MouseEvent);
public void mousePressed(java.awt.event.MouseEvent);
public void mouseReleased(java.awt.event.MouseEvent);
public void mouseEntered(java.awt.event.MouseEvent);
public void mouseExited(java.awt.event.MouseEvent);
public static void main(String[]);
static void
}
SettingsLabelAction
package mars.venus;
public synchronized class SettingsLabelAction extends GuiAction {
public void SettingsLabelAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
LabelsWindow$MyTippedJTable$SymbolTableHeader$SymbolTableHeaderMouseListener
package mars.venus;
synchronized class LabelsWindow$MyTippedJTable$SymbolTableHeader$SymbolTableHeaderMouseListener implements java.awt.event.MouseListener {
private void LabelsWindow$MyTippedJTable$SymbolTableHeader$SymbolTableHeaderMouseListener(LabelsWindow$MyTippedJTable$SymbolTableHeader);
public void mouseClicked(java.awt.event.MouseEvent);
public void mouseEntered(java.awt.event.MouseEvent);
public void mouseExited(java.awt.event.MouseEvent);
public void mousePressed(java.awt.event.MouseEvent);
public void mouseReleased(java.awt.event.MouseEvent);
}
RegistersPane
package mars.venus;
public synchronized class RegistersPane extends javax.swing.JTabbedPane {
RegistersWindow regsTab;
Coprocessor1Window cop1Tab;
Coprocessor0Window cop0Tab;
private VenusUI mainUI;
public void RegistersPane(VenusUI, RegistersWindow, Coprocessor1Window, Coprocessor0Window);
public RegistersWindow getRegistersWindow();
public Coprocessor1Window getCoprocessor1Window();
public Coprocessor0Window getCoprocessor0Window();
}
SettingsHighlightingAction
package mars.venus;
public synchronized class SettingsHighlightingAction extends GuiAction {
javax.swing.JDialog highlightDialog;
private static final int[] backgroundSettingPositions;
private static final int[] foregroundSettingPositions;
private static final int[] fontSettingPositions;
javax.swing.JButton[] backgroundButtons;
javax.swing.JButton[] foregroundButtons;
javax.swing.JButton[] fontButtons;
javax.swing.JCheckBox[] defaultCheckBoxes;
javax.swing.JLabel[] samples;
java.awt.Color[] currentNondefaultBackground;
java.awt.Color[] currentNondefaultForeground;
java.awt.Color[] initialSettingsBackground;
java.awt.Color[] initialSettingsForeground;
java.awt.Font[] initialFont;
java.awt.Font[] currentFont;
java.awt.Font[] currentNondefaultFont;
javax.swing.JButton dataHighlightButton;
javax.swing.JButton registerHighlightButton;
boolean currentDataHighlightSetting;
boolean initialDataHighlightSetting;
boolean currentRegisterHighlightSetting;
boolean initialRegisterHighlightSetting;
private static final int gridVGap = 2;
private static final int gridHGap = 2;
private static final String SAMPLE_TOOL_TIP_TEXT = Preview based on background and text color settings;
private static final String BACKGROUND_TOOL_TIP_TEXT = Click, to select background color;
private static final String FOREGROUND_TOOL_TIP_TEXT = Click, to select text color;
private static final String FONT_TOOL_TIP_TEXT = Click, to select text font;
private static final String DEFAULT_TOOL_TIP_TEXT = Check, to select default color (disables color select buttons);
public static final String CLOSE_TOOL_TIP_TEXT = Apply current settings and close dialog;
public static final String APPLY_TOOL_TIP_TEXT = Apply current settings now and leave dialog open;
public static final String RESET_TOOL_TIP_TEXT = Reset to initial settings without applying;
public static final String CANCEL_TOOL_TIP_TEXT = Close dialog without applying current settings;
private static final String DATA_HIGHLIGHT_ENABLE_TOOL_TIP_TEXT = Click, to enable or disable highlighting in Data Segment window;
private static final String REGISTER_HIGHLIGHT_ENABLE_TOOL_TIP_TEXT = Click, to enable or disable highlighting in Register windows;
private static final String fontButtonText = font;
public void SettingsHighlightingAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
private javax.swing.JPanel buildDialogPanel();
private String getHighlightControlText(boolean);
private void initializeButtonColors();
private void setHighlightingSettings();
private void resetButtonColors();
private void closeDialog();
static void
}
TextSegmentWindow$CheckBoxTableCellRenderer
package mars.venus;
synchronized class TextSegmentWindow$CheckBoxTableCellRenderer extends javax.swing.JCheckBox implements javax.swing.table.TableCellRenderer {
javax.swing.border.Border noFocusBorder;
javax.swing.border.Border focusBorder;
public void TextSegmentWindow$CheckBoxTableCellRenderer(TextSegmentWindow);
public java.awt.Component getTableCellRendererComponent(javax.swing.JTable, Object, boolean, boolean, int, int);
}
EditTabbedPane
package mars.venus;
public synchronized class EditTabbedPane extends javax.swing.JTabbedPane {
EditPane editTab;
MainPane mainPane;
private VenusUI mainUI;
private Editor editor;
private EditTabbedPane$FileOpener fileOpener;
public void EditTabbedPane(VenusUI, Editor, MainPane);
public EditPane getCurrentEditTab();
public void setCurrentEditTab(EditPane);
public EditPane getCurrentEditTabForFile(java.io.File);
public void newFile();
public boolean openFile();
public boolean openFile(java.io.File);
public boolean closeCurrentFile();
public boolean closeAllFiles();
public boolean saveCurrentFile();
private boolean saveFile(EditPane);
public boolean saveAsCurrentFile();
private java.io.File saveAsFile(EditPane);
public boolean saveAllFiles();
public void remove(EditPane);
private void updateTitlesAndMenuState(EditPane);
private void updateTitles(EditPane);
public EditPane getEditPaneForFile(String);
public boolean editsSavedOrAbandoned();
private int confirm(String);
}
HelpHelpAction$MyCellRenderer
package mars.venus;
synchronized class HelpHelpAction$MyCellRenderer extends javax.swing.JLabel implements javax.swing.ListCellRenderer {
private void HelpHelpAction$MyCellRenderer(HelpHelpAction);
public java.awt.Component getListCellRendererComponent(javax.swing.JList, Object, int, boolean, boolean);
}
EditFindReplaceAction$FindReplaceDialog$5
package mars.venus;
synchronized class EditFindReplaceAction$FindReplaceDialog$5 implements java.awt.event.ActionListener {
void EditFindReplaceAction$FindReplaceDialog$5(EditFindReplaceAction$FindReplaceDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
HelpHelpAction
package mars.venus;
public synchronized class HelpHelpAction extends GuiAction {
static java.awt.Color altBackgroundColor;
public static final String descriptionDetailSeparator = :;
public void HelpHelpAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
private java.awt.Dimension getSize();
public void actionPerformed(java.awt.event.ActionEvent);
private javax.swing.JPanel createHTMLHelpPanel(String);
private javax.swing.JPanel createCopyrightInfoPanel();
private javax.swing.JPanel createMarsHelpInfoPanel();
private javax.swing.JPanel createMipsHelpInfoPanel();
private javax.swing.JScrollPane createMipsDirectivesHelpPane();
private javax.swing.JScrollPane createMipsInstructionHelpPane(String);
static void
}
EditUndoAction
package mars.venus;
public synchronized class EditUndoAction extends GuiAction {
public void EditUndoAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
void updateUndoState();
}
SettingsExceptionHandlerAction$ExceptionHandlerSettingAction
package mars.venus;
synchronized class SettingsExceptionHandlerAction$ExceptionHandlerSettingAction implements java.awt.event.ActionListener {
private void SettingsExceptionHandlerAction$ExceptionHandlerSettingAction(SettingsExceptionHandlerAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
FileSaveAllAction
package mars.venus;
public synchronized class FileSaveAllAction extends GuiAction {
public void FileSaveAllAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsHighlightingAction$7
package mars.venus;
synchronized class SettingsHighlightingAction$7 implements java.awt.event.ActionListener {
void SettingsHighlightingAction$7(SettingsHighlightingAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
ExecutePane
package mars.venus;
public synchronized class ExecutePane extends javax.swing.JDesktopPane {
private RegistersWindow registerValues;
private Coprocessor1Window coprocessor1Values;
private Coprocessor0Window coprocessor0Values;
private DataSegmentWindow dataSegment;
private TextSegmentWindow textSegment;
private LabelsWindow labelValues;
private VenusUI mainUI;
private NumberDisplayBaseChooser valueDisplayBase;
private NumberDisplayBaseChooser addressDisplayBase;
private boolean labelWindowVisible;
public void ExecutePane(VenusUI, RegistersWindow, Coprocessor1Window, Coprocessor0Window);
public void setWindowBounds();
public void setLabelWindowVisibility(boolean);
public void clearPane();
public TextSegmentWindow getTextSegmentWindow();
public DataSegmentWindow getDataSegmentWindow();
public RegistersWindow getRegistersWindow();
public Coprocessor1Window getCoprocessor1Window();
public Coprocessor0Window getCoprocessor0Window();
public LabelsWindow getLabelsWindow();
public int getValueDisplayBase();
public int getAddressDisplayBase();
public NumberDisplayBaseChooser getValueDisplayBaseChooser();
public NumberDisplayBaseChooser getAddressDisplayBaseChooser();
public void numberDisplayBaseChanged(NumberDisplayBaseChooser);
}
VenusUI$1
package mars.venus;
synchronized class VenusUI$1 extends java.awt.event.WindowAdapter {
void VenusUI$1(VenusUI);
public void windowOpened(java.awt.event.WindowEvent);
}
DataSegmentWindow$7
package mars.venus;
synchronized class DataSegmentWindow$7 implements java.awt.event.ActionListener {
void DataSegmentWindow$7(DataSegmentWindow);
public void actionPerformed(java.awt.event.ActionEvent);
}
TextSegmentWindow$MachineCodeCellRenderer
package mars.venus;
synchronized class TextSegmentWindow$MachineCodeCellRenderer extends javax.swing.table.DefaultTableCellRenderer {
void TextSegmentWindow$MachineCodeCellRenderer(TextSegmentWindow);
public java.awt.Component getTableCellRendererComponent(javax.swing.JTable, Object, boolean, boolean, int, int);
}
AbstractFontSettingDialog
package mars.venus;
public abstract synchronized class AbstractFontSettingDialog extends javax.swing.JDialog {
javax.swing.JDialog editorDialog;
javax.swing.JComboBox fontFamilySelector;
javax.swing.JComboBox fontStyleSelector;
javax.swing.JSlider fontSizeSelector;
javax.swing.JSpinner fontSizeSpinSelector;
javax.swing.JLabel fontSample;
protected java.awt.Font currentFont;
String initialFontFamily;
String initialFontStyle;
String initialFontSize;
private static String SEPARATOR;
public void AbstractFontSettingDialog(java.awt.Frame, String, boolean, java.awt.Font);
protected javax.swing.JPanel buildDialogPanel();
protected abstract java.awt.Component buildControlPanel();
public java.awt.Font getFont();
protected void performApply();
protected void closeDialog();
protected void reset();
protected abstract void apply(java.awt.Font);
private java.util.Vector makeVectorData(String[][]);
static void
}
SettingsEditorAction$EditorFontDialog$1
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$1 implements java.awt.event.ActionListener {
void SettingsEditorAction$EditorFontDialog$1(SettingsEditorAction$EditorFontDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
RegistersWindow$RegTableModel
package mars.venus;
synchronized class RegistersWindow$RegTableModel extends javax.swing.table.AbstractTableModel {
final String[] columnNames;
Object[][] data;
public void RegistersWindow$RegTableModel(RegistersWindow, Object[][]);
public int getColumnCount();
public int getRowCount();
public String getColumnName(int);
public Object getValueAt(int, int);
public Class getColumnClass(int);
public boolean isCellEditable(int, int);
public void setValueAt(Object, int, int);
private void setDisplayAndModelValueAt(Object, int, int);
private void printDebugData();
}
MessagesPane$Asker$3
package mars.venus;
synchronized class MessagesPane$Asker$3 implements mars.simulator.Simulator$StopListener {
void MessagesPane$Asker$3(MessagesPane$Asker);
public void stopped(mars.simulator.Simulator);
}
DataSegmentWindow$DataTableModel
package mars.venus;
synchronized class DataSegmentWindow$DataTableModel extends javax.swing.table.AbstractTableModel {
String[] columnNames;
Object[][] data;
public void DataSegmentWindow$DataTableModel(DataSegmentWindow, Object[][], String[]);
public int getColumnCount();
public int getRowCount();
public String getColumnName(int);
public Object getValueAt(int, int);
public boolean isCellEditable(int, int);
public Class getColumnClass(int);
public void setValueAt(Object, int, int);
private void setDisplayAndModelValueAt(Object, int, int);
private void printDebugData();
}
LabelsWindow
package mars.venus;
public synchronized class LabelsWindow extends javax.swing.JInternalFrame {
private java.awt.Container contentPane;
private javax.swing.JPanel labelPanel;
private javax.swing.JCheckBox dataLabels;
private javax.swing.JCheckBox textLabels;
private java.util.ArrayList listOfLabelsForSymbolTable;
private LabelsWindow labelsWindow;
private static final int MAX_DISPLAYED_CHARS = 24;
private static final int PREFERRED_NAME_COLUMN_WIDTH = 60;
private static final int PREFERRED_ADDRESS_COLUMN_WIDTH = 60;
private static final int LABEL_COLUMN = 0;
private static final int ADDRESS_COLUMN = 1;
private static final String[] columnToolTips;
private static String[] columnNames;
private java.util.Comparator tableSortComparator;
private final java.util.Comparator[] tableSortingComparators;
private static final int[][] sortStateTransitions;
private static final char ASCENDING_SYMBOL = 9650;
private static final char DESCENDING_SYMBOL = 9660;
private static final String[][] sortColumnHeadings;
private int sortState;
public void LabelsWindow();
public void setupTable();
public void clearWindow();
private javax.swing.JScrollPane generateLabelScrollPane();
public void updateLabelAddresses();
static void
}
LabelsWindow$MyTippedJTable$SymbolTableHeader
package mars.venus;
synchronized class LabelsWindow$MyTippedJTable$SymbolTableHeader extends javax.swing.table.JTableHeader {
public void LabelsWindow$MyTippedJTable$SymbolTableHeader(LabelsWindow$MyTippedJTable, javax.swing.table.TableColumnModel);
public String getToolTipText(java.awt.event.MouseEvent);
}
TextSegmentWindow$CodeCellRenderer
package mars.venus;
synchronized class TextSegmentWindow$CodeCellRenderer extends javax.swing.table.DefaultTableCellRenderer {
void TextSegmentWindow$CodeCellRenderer(TextSegmentWindow);
public java.awt.Component getTableCellRendererComponent(javax.swing.JTable, Object, boolean, boolean, int, int);
}
MainPane$1
package mars.venus;
synchronized class MainPane$1 implements javax.swing.event.ChangeListener {
void MainPane$1(MainPane);
public void stateChanged(javax.swing.event.ChangeEvent);
}
SettingsHighlightingAction$FontSettingDialog$2
package mars.venus;
synchronized class SettingsHighlightingAction$FontSettingDialog$2 implements java.awt.event.ActionListener {
void SettingsHighlightingAction$FontSettingDialog$2(SettingsHighlightingAction$FontSettingDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
TextSegmentWindow$MyTippedJTable
package mars.venus;
synchronized class TextSegmentWindow$MyTippedJTable extends javax.swing.JTable {
private javax.swing.table.JTableHeader tableHeader;
private String[] columnToolTips;
void TextSegmentWindow$MyTippedJTable(TextSegmentWindow, TextSegmentWindow$TextTableModel);
protected javax.swing.table.JTableHeader createDefaultTableHeader();
public java.awt.Rectangle getRectForColumnIndex(int);
}
EditFindReplaceAction$FindReplaceDialog
package mars.venus;
synchronized class EditFindReplaceAction$FindReplaceDialog extends javax.swing.JDialog {
javax.swing.JButton findButton;
javax.swing.JButton replaceButton;
javax.swing.JButton replaceAllButton;
javax.swing.JButton closeButton;
javax.swing.JTextField findInputField;
javax.swing.JTextField replaceInputField;
javax.swing.JCheckBox caseSensitiveCheckBox;
javax.swing.JRadioButton linearFromStart;
javax.swing.JRadioButton circularFromCursor;
private javax.swing.JLabel resultsLabel;
public static final String FIND_TOOL_TIP_TEXT = Find next occurrence of given text; wraps around at end;
public static final String REPLACE_TOOL_TIP_TEXT = Replace current occurrence of text then find next;
public static final String REPLACE_ALL_TOOL_TIP_TEXT = Replace all occurrences of text;
public static final String CLOSE_TOOL_TIP_TEXT = Close the dialog;
public static final String RESULTS_TOOL_TIP_TEXT = Outcome of latest operation (button click);
public static final String RESULTS_TEXT_FOUND = Text found;
public static final String RESULTS_TEXT_NOT_FOUND = Text not found;
public static final String RESULTS_TEXT_REPLACED = Text replaced and found next;
public static final String RESULTS_TEXT_REPLACED_LAST = Text replaced; last occurrence;
public static final String RESULTS_TEXT_REPLACED_ALL = Replaced;
public static final String RESULTS_NO_TEXT_TO_FIND = No text to find;
public void EditFindReplaceAction$FindReplaceDialog(EditFindReplaceAction, java.awt.Frame, String, boolean);
private javax.swing.JPanel buildDialogPanel();
private java.awt.Component buildInputPanel();
private java.awt.Component buildOptionsPanel();
private java.awt.Component buildControlPanel();
private void performFind();
private void performReplace();
private void performReplaceAll();
private void performClose();
}
HardcopyWriter
package mars.venus;
public synchronized class HardcopyWriter extends java.io.Writer {
protected java.awt.PrintJob job;
protected java.awt.Graphics page;
protected String jobname;
protected int fontsize;
protected String time;
protected java.awt.Dimension pagesize;
protected int pagedpi;
protected java.awt.Font font;
protected java.awt.Font headerfont;
protected java.awt.FontMetrics metrics;
protected java.awt.FontMetrics headermetrics;
protected int x0;
protected int y0;
protected int width;
protected int height;
protected int headery;
protected int charwidth;
protected int lineheight;
protected int lineascent;
protected int chars_per_line;
protected int lines_per_page;
protected int chars_per_tab;
protected int charnum;
protected int linenum;
protected int pagenum;
private boolean last_char_was_return;
protected static java.util.Properties printprops;
public void HardcopyWriter(java.awt.Frame, String, int, double, double, double, double) throws HardcopyWriter$PrintCanceledException;
public void write(char[], int, int);
public void flush();
public void close();
public void setFontStyle(int);
public void pageBreak();
public int getCharactersPerLine();
public int getLinesPerPage();
protected void newline();
protected void newpage();
public static void main(String[]);
static void
}
NumberDisplayBaseChooser$1
package mars.venus;
synchronized class NumberDisplayBaseChooser$1 implements java.awt.event.ItemListener {
void NumberDisplayBaseChooser$1(NumberDisplayBaseChooser);
public void itemStateChanged(java.awt.event.ItemEvent);
}
MessagesPane$4
package mars.venus;
synchronized class MessagesPane$4 implements Runnable {
void MessagesPane$4(MessagesPane, String);
public void run();
}
SettingsExceptionHandlerAction
package mars.venus;
public synchronized class SettingsExceptionHandlerAction extends GuiAction {
javax.swing.JDialog exceptionHandlerDialog;
javax.swing.JCheckBox exceptionHandlerSetting;
javax.swing.JButton exceptionHandlerSelectionButton;
javax.swing.JTextField exceptionHandlerDisplay;
boolean initialSelected;
String initialPathname;
public void SettingsExceptionHandlerAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
private javax.swing.JPanel buildDialogPanel();
private void performOK();
private void closeDialog();
}
SettingsAddressDisplayBaseAction
package mars.venus;
public synchronized class SettingsAddressDisplayBaseAction extends GuiAction {
public void SettingsAddressDisplayBaseAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
DataSegmentWindow$AddressCellRenderer
package mars.venus;
synchronized class DataSegmentWindow$AddressCellRenderer extends javax.swing.table.DefaultTableCellRenderer {
void DataSegmentWindow$AddressCellRenderer(DataSegmentWindow);
public java.awt.Component getTableCellRendererComponent(javax.swing.JTable, Object, boolean, boolean, int, int);
}
DataSegmentWindow$MyTippedJTable
package mars.venus;
synchronized class DataSegmentWindow$MyTippedJTable extends javax.swing.JTable {
private String[] columnToolTips;
void DataSegmentWindow$MyTippedJTable(DataSegmentWindow, DataSegmentWindow$DataTableModel);
protected javax.swing.table.JTableHeader createDefaultTableHeader();
}
SettingsMemoryConfigurationAction$MemoryConfigurationDialog$4
package mars.venus;
synchronized class SettingsMemoryConfigurationAction$MemoryConfigurationDialog$4 implements java.awt.event.ActionListener {
void SettingsMemoryConfigurationAction$MemoryConfigurationDialog$4(SettingsMemoryConfigurationAction$MemoryConfigurationDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
AbstractFontSettingDialog$2
package mars.venus;
synchronized class AbstractFontSettingDialog$2 implements javax.swing.event.ChangeListener {
void AbstractFontSettingDialog$2(AbstractFontSettingDialog);
public void stateChanged(javax.swing.event.ChangeEvent);
}
SettingsExceptionHandlerAction$2
package mars.venus;
synchronized class SettingsExceptionHandlerAction$2 implements java.awt.event.ActionListener {
void SettingsExceptionHandlerAction$2(SettingsExceptionHandlerAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsEditorAction$EditorFontDialog$3
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$3 implements java.awt.event.ActionListener {
void SettingsEditorAction$EditorFontDialog$3(SettingsEditorAction$EditorFontDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
Coprocessor0Window$RegTableModel
package mars.venus;
synchronized class Coprocessor0Window$RegTableModel extends javax.swing.table.AbstractTableModel {
final String[] columnNames;
Object[][] data;
public void Coprocessor0Window$RegTableModel(Coprocessor0Window, Object[][]);
public int getColumnCount();
public int getRowCount();
public String getColumnName(int);
public Object getValueAt(int, int);
public Class getColumnClass(int);
public boolean isCellEditable(int, int);
public void setValueAt(Object, int, int);
private void setDisplayAndModelValueAt(Object, int, int);
private void printDebugData();
}
MessagesPane$Asker$1
package mars.venus;
synchronized class MessagesPane$Asker$1 implements javax.swing.event.DocumentListener {
void MessagesPane$Asker$1(MessagesPane$Asker);
public void insertUpdate(javax.swing.event.DocumentEvent);
public void removeUpdate(javax.swing.event.DocumentEvent);
public void changedUpdate(javax.swing.event.DocumentEvent);
}
RunClearBreakpointsAction
package mars.venus;
public synchronized class RunClearBreakpointsAction extends GuiAction implements javax.swing.event.TableModelListener {
public void RunClearBreakpointsAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
public void tableChanged(javax.swing.event.TableModelEvent);
}
DataSegmentWindow$5
package mars.venus;
synchronized class DataSegmentWindow$5 implements java.awt.event.ActionListener {
void DataSegmentWindow$5(DataSegmentWindow);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsSelfModifyingCodeAction
package mars.venus;
public synchronized class SettingsSelfModifyingCodeAction extends GuiAction {
public void SettingsSelfModifyingCodeAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
HelpHelpAction$HelpHyperlinkListener$2
package mars.venus;
synchronized class HelpHelpAction$HelpHyperlinkListener$2 implements java.awt.event.ActionListener {
void HelpHelpAction$HelpHyperlinkListener$2(HelpHelpAction$HelpHyperlinkListener);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsEditorAction$EditorFontDialog$7
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$7 implements javax.swing.event.ChangeListener {
void SettingsEditorAction$EditorFontDialog$7(SettingsEditorAction$EditorFontDialog);
public void stateChanged(javax.swing.event.ChangeEvent);
}
FileOpenAction
package mars.venus;
public synchronized class FileOpenAction extends GuiAction {
private java.io.File mostRecentlyOpenedFile;
private javax.swing.JFileChooser fileChooser;
private int fileFilterCount;
private java.util.ArrayList fileFilterList;
private java.beans.PropertyChangeListener listenForUserAddedFileFilter;
public void FileOpenAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
RegistersWindow$RegisterCellRenderer
package mars.venus;
synchronized class RegistersWindow$RegisterCellRenderer extends javax.swing.table.DefaultTableCellRenderer {
private java.awt.Font font;
private int alignment;
public void RegistersWindow$RegisterCellRenderer(RegistersWindow, java.awt.Font, int);
public java.awt.Component getTableCellRendererComponent(javax.swing.JTable, Object, boolean, boolean, int, int);
}
SettingsHighlightingAction$FontSettingDialog
package mars.venus;
synchronized class SettingsHighlightingAction$FontSettingDialog extends AbstractFontSettingDialog {
private boolean resultOK;
public void SettingsHighlightingAction$FontSettingDialog(SettingsHighlightingAction, java.awt.Frame, String, java.awt.Font);
private java.awt.Font showDialog();
protected void closeDialog();
private void performOK();
private void performCancel();
protected java.awt.Component buildControlPanel();
protected void apply(java.awt.Font);
}
DataSegmentWindow$1
package mars.venus;
synchronized class DataSegmentWindow$1 implements java.awt.event.ActionListener {
void DataSegmentWindow$1(DataSegmentWindow);
public void actionPerformed(java.awt.event.ActionEvent);
}
FileDumpMemoryAction$1
package mars.venus;
synchronized class FileDumpMemoryAction$1 extends java.awt.event.WindowAdapter {
void FileDumpMemoryAction$1(FileDumpMemoryAction);
public void windowClosing(java.awt.event.WindowEvent);
}
SettingsMemoryConfigurationAction
package mars.venus;
public synchronized class SettingsMemoryConfigurationAction extends GuiAction {
javax.swing.JDialog configDialog;
javax.swing.JComboBox fontFamilySelector;
javax.swing.JComboBox fontStyleSelector;
javax.swing.JSlider fontSizeSelector;
javax.swing.JTextField fontSizeDisplay;
SettingsMemoryConfigurationAction thisAction;
String initialFontFamily;
String initialFontStyle;
String initialFontSize;
public void SettingsMemoryConfigurationAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsDelayedBranchingAction
package mars.venus;
public synchronized class SettingsDelayedBranchingAction extends GuiAction {
public void SettingsDelayedBranchingAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
MessagesPane
package mars.venus;
public synchronized class MessagesPane extends javax.swing.JTabbedPane {
javax.swing.JTextArea assemble;
javax.swing.JTextArea run;
javax.swing.JPanel assembleTab;
javax.swing.JPanel runTab;
public static final int MAXIMUM_SCROLLED_CHARACTERS;
public static final int NUMBER_OF_CHARACTERS_TO_CUT;
public void MessagesPane();
private javax.swing.Box createBoxForButton(javax.swing.JButton);
public void selectErrorMessage(String, int, int);
public void selectEditorTextLine(String, int, int);
public javax.swing.JTextArea getAssembleTextArea();
public javax.swing.JTextArea getRunTextArea();
public void postMarsMessage(String);
public void postRunMessage(String);
public void selectMarsMessageTab();
public void selectRunMessageTab();
public String getInputString(String);
public String getInputString(int);
static void
}
SettingsEditorAction$EditorFontDialog$DefaultChanger
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$DefaultChanger implements java.awt.event.ItemListener {
private int row;
public void SettingsEditorAction$EditorFontDialog$DefaultChanger(SettingsEditorAction$EditorFontDialog, int);
public void itemStateChanged(java.awt.event.ItemEvent);
}
RunBackstepAction
package mars.venus;
public synchronized class RunBackstepAction extends GuiAction {
String name;
ExecutePane executePane;
public void RunBackstepAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
EditTabbedPane$FileOpener
package mars.venus;
synchronized class EditTabbedPane$FileOpener {
private java.io.File mostRecentlyOpenedFile;
private javax.swing.JFileChooser fileChooser;
private int fileFilterCount;
private java.util.ArrayList fileFilterList;
private java.beans.PropertyChangeListener listenForUserAddedFileFilter;
private Editor theEditor;
public void EditTabbedPane$FileOpener(EditTabbedPane, Editor);
private boolean openFile();
private boolean openFile(java.io.File);
private void setChoosableFileFilters();
}
RunSpeedPanel$RunSpeedListener
package mars.venus;
synchronized class RunSpeedPanel$RunSpeedListener implements javax.swing.event.ChangeListener {
private void RunSpeedPanel$RunSpeedListener(RunSpeedPanel);
public void stateChanged(javax.swing.event.ChangeEvent);
}
TextSegmentWindow
package mars.venus;
public synchronized class TextSegmentWindow extends javax.swing.JInternalFrame implements java.util.Observer {
private javax.swing.JPanel programArgumentsPanel;
private javax.swing.JTextField programArgumentsTextField;
private static final int PROGRAM_ARGUMENT_TEXTFIELD_COLUMNS = 40;
private javax.swing.JTable table;
private javax.swing.JScrollPane tableScroller;
private Object[][] data;
private int[] intAddresses;
private java.util.Hashtable addressRows;
private java.util.Hashtable executeMods;
private java.awt.Container contentPane;
private TextSegmentWindow$TextTableModel tableModel;
private java.awt.Font tableCellFont;
private boolean codeHighlighting;
private boolean breakpointsEnabled;
private int highlightAddress;
private javax.swing.event.TableModelListener tableModelListener;
private boolean inDelaySlot;
private static String[] columnNames;
private static final int BREAK_COLUMN = 0;
private static final int ADDRESS_COLUMN = 1;
private static final int CODE_COLUMN = 2;
private static final int BASIC_COLUMN = 3;
private static final int SOURCE_COLUMN = 4;
private static final java.awt.Font monospacedPlain12Point;
private static final String modifiedCodeMarker = —— ;
public void TextSegmentWindow();
public void setupTable();
public String getProgramArguments();
public void addProgramArgumentsPanel();
public void removeProgramArgumentsPanel();
public void clearWindow();
public void registerTableModelListener(javax.swing.event.TableModelListener);
public void updateCodeAddresses();
public void updateBasicStatements();
public void update(java.util.Observable, Object);
void resetModifiedSourceCode();
int getIntCodeAddressAtRow(int);
public int getBreakpointCount();
public int[] getSortedBreakPointsArray();
public void clearAllBreakpoints();
public void highlightStepAtPC();
public void highlightStepAtPC(boolean);
public void highlightStepAtAddress(int);
public void highlightStepAtAddress(int, boolean);
public void setCodeHighlighting(boolean);
public boolean getCodeHighlighting();
public void unhighlightAllSteps();
void selectStepAtAddress(int);
public void toggleBreakpoints();
private void addAsTextSegmentObserver();
private void deleteAsTextSegmentObserver();
private void reorderColumns();
private int findRowForAddress(int) throws IllegalArgumentException;
static void
}
SettingsMemoryConfigurationAction$MemoryConfigurationDialog$2
package mars.venus;
synchronized class SettingsMemoryConfigurationAction$MemoryConfigurationDialog$2 implements java.awt.event.ActionListener {
void SettingsMemoryConfigurationAction$MemoryConfigurationDialog$2(SettingsMemoryConfigurationAction$MemoryConfigurationDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
AbstractFontSettingDialog$4
package mars.venus;
synchronized class AbstractFontSettingDialog$4 implements java.awt.event.ActionListener {
void AbstractFontSettingDialog$4(AbstractFontSettingDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
LabelsWindow$LabelAddressAscendingComparator
package mars.venus;
synchronized class LabelsWindow$LabelAddressAscendingComparator implements java.util.Comparator {
private void LabelsWindow$LabelAddressAscendingComparator(LabelsWindow);
public int compare(Object, Object);
}
FileDumpMemoryAction$3
package mars.venus;
synchronized class FileDumpMemoryAction$3 implements java.awt.event.ActionListener {
void FileDumpMemoryAction$3(FileDumpMemoryAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
MessagesPane$2
package mars.venus;
synchronized class MessagesPane$2 extends java.awt.event.MouseAdapter {
void MessagesPane$2(MessagesPane);
public void mouseClicked(java.awt.event.MouseEvent);
}
RegistersWindow$MyTippedJTable
package mars.venus;
synchronized class RegistersWindow$MyTippedJTable extends javax.swing.JTable {
private String[] regToolTips;
private String[] columnToolTips;
void RegistersWindow$MyTippedJTable(RegistersWindow, RegistersWindow$RegTableModel);
public String getToolTipText(java.awt.event.MouseEvent);
protected javax.swing.table.JTableHeader createDefaultTableHeader();
}
SettingsEditorAction$EditorFontDialog
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog extends AbstractFontSettingDialog {
private javax.swing.JButton[] foregroundButtons;
private javax.swing.JLabel[] samples;
private javax.swing.JToggleButton[] bold;
private javax.swing.JToggleButton[] italic;
private javax.swing.JCheckBox[] useDefault;
private int[] syntaxStyleIndex;
private editors.jeditsyntax.SyntaxStyle[] defaultStyles;
private editors.jeditsyntax.SyntaxStyle[] initialStyles;
private editors.jeditsyntax.SyntaxStyle[] currentStyles;
private java.awt.Font previewFont;
private javax.swing.JPanel dialogPanel;
private javax.swing.JPanel syntaxStylePanel;
private javax.swing.JPanel otherSettingsPanel;
private javax.swing.JSlider tabSizeSelector;
private javax.swing.JSpinner tabSizeSpinSelector;
private javax.swing.JSpinner blinkRateSpinSelector;
private javax.swing.JSpinner popupPrefixLengthSpinSelector;
private javax.swing.JCheckBox lineHighlightCheck;
private javax.swing.JCheckBox genericEditorCheck;
private javax.swing.JCheckBox autoIndentCheck;
private javax.swing.text.Caret blinkCaret;
private javax.swing.JTextField blinkSample;
private javax.swing.ButtonGroup popupGuidanceButtons;
private javax.swing.JRadioButton[] popupGuidanceOptions;
private boolean syntaxStylesAction;
private int initialEditorTabSize;
private int initialCaretBlinkRate;
private int initialPopupGuidance;
private boolean initialLineHighlighting;
private boolean initialGenericTextEditor;
private boolean initialAutoIndent;
public void SettingsEditorAction$EditorFontDialog(SettingsEditorAction, java.awt.Frame, String, boolean, java.awt.Font);
protected javax.swing.JPanel buildDialogPanel();
protected java.awt.Component buildControlPanel();
protected void apply(java.awt.Font);
protected void reset();
private void resetOtherSettings();
private javax.swing.JPanel buildOtherSettingsPanel();
private javax.swing.JPanel buildSyntaxStylePanel();
private void initializeSyntaxStyleChangeables();
private void setSampleStyles(javax.swing.JLabel, editors.jeditsyntax.SyntaxStyle);
}
LabelsWindow$LabelNameAscendingComparator
package mars.venus;
synchronized class LabelsWindow$LabelNameAscendingComparator implements java.util.Comparator {
private void LabelsWindow$LabelNameAscendingComparator(LabelsWindow);
public int compare(Object, Object);
}
RunSpeedPanel
package mars.venus;
public synchronized class RunSpeedPanel extends javax.swing.JPanel {
public static final double UNLIMITED_SPEED = 40.0;
private static final int SPEED_INDEX_MIN = 0;
private static final int SPEED_INDEX_MAX = 40;
private static final int SPEED_INDEX_INIT = 40;
private static final int SPEED_INDEX_INTERACTION_LIMIT = 35;
private double[] speedTable;
private javax.swing.JLabel sliderLabel;
private javax.swing.JSlider runSpeedSlider;
private static RunSpeedPanel runSpeedPanel;
private volatile int runSpeedIndex;
public static RunSpeedPanel getInstance();
private void RunSpeedPanel();
public double getRunSpeed();
private String setLabel(int);
static void
}
DataSegmentWindow$3
package mars.venus;
synchronized class DataSegmentWindow$3 implements java.awt.event.ActionListener {
void DataSegmentWindow$3(DataSegmentWindow);
public void actionPerformed(java.awt.event.ActionEvent);
}
RunGoAction
package mars.venus;
public synchronized class RunGoAction extends GuiAction {
public static int defaultMaxSteps;
public static int maxSteps;
private String name;
private ExecutePane executePane;
public void RunGoAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
public void paused(boolean, int, mars.ProcessingException);
public void stopped(mars.ProcessingException, int);
public static void resetMaxSteps();
private void processProgramArgumentsIfAny();
static void
}
EditTabbedPane$1
package mars.venus;
synchronized class EditTabbedPane$1 implements javax.swing.event.ChangeListener {
void EditTabbedPane$1(EditTabbedPane);
public void stateChanged(javax.swing.event.ChangeEvent);
}
SettingsEditorAction$EditorFontDialog$5
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$5 implements java.awt.event.ItemListener {
void SettingsEditorAction$EditorFontDialog$5(SettingsEditorAction$EditorFontDialog);
public void itemStateChanged(java.awt.event.ItemEvent);
}
TextSegmentWindow$MyTippedJTable$TextTableHeader
package mars.venus;
synchronized class TextSegmentWindow$MyTippedJTable$TextTableHeader extends javax.swing.table.JTableHeader {
public void TextSegmentWindow$MyTippedJTable$TextTableHeader(TextSegmentWindow$MyTippedJTable, javax.swing.table.TableColumnModel);
public String getToolTipText(java.awt.event.MouseEvent);
}
SettingsExtendedAction
package mars.venus;
public synchronized class SettingsExtendedAction extends GuiAction {
public void SettingsExtendedAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
HelpAboutAction
package mars.venus;
public synchronized class HelpAboutAction extends GuiAction {
public void HelpAboutAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsMemoryConfigurationAction$MemoryConfigurationDialog$5
package mars.venus;
synchronized class SettingsMemoryConfigurationAction$MemoryConfigurationDialog$5 implements java.awt.event.ActionListener {
void SettingsMemoryConfigurationAction$MemoryConfigurationDialog$5(SettingsMemoryConfigurationAction$MemoryConfigurationDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
AbstractFontSettingDialog$3
package mars.venus;
synchronized class AbstractFontSettingDialog$3 implements javax.swing.event.ChangeListener {
void AbstractFontSettingDialog$3(AbstractFontSettingDialog);
public void stateChanged(javax.swing.event.ChangeEvent);
}
SettingsExceptionHandlerAction$3
package mars.venus;
synchronized class SettingsExceptionHandlerAction$3 implements java.awt.event.ActionListener {
void SettingsExceptionHandlerAction$3(SettingsExceptionHandlerAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
TextSegmentWindow$TextTableModel
package mars.venus;
synchronized class TextSegmentWindow$TextTableModel extends javax.swing.table.AbstractTableModel {
Object[][] data;
public void TextSegmentWindow$TextTableModel(TextSegmentWindow, Object[][]);
public int getColumnCount();
public int getRowCount();
public String getColumnName(int);
public Object getValueAt(int, int);
public Class getColumnClass(int);
public boolean isCellEditable(int, int);
public void setValueAt(Object, int, int);
private void printDebugData();
}
LabelsWindow$LabelTableModel
package mars.venus;
synchronized class LabelsWindow$LabelTableModel extends javax.swing.table.AbstractTableModel {
String[] columns;
Object[][] data;
public void LabelsWindow$LabelTableModel(LabelsWindow, Object[][], String[]);
public int getColumnCount();
public int getRowCount();
public String getColumnName(int);
public Object getValueAt(int, int);
public Class getColumnClass(int);
public void setValueAt(Object, int, int);
private void printDebugData();
}
FileDumpMemoryAction$4
package mars.venus;
synchronized class FileDumpMemoryAction$4 implements java.awt.event.ActionListener {
void FileDumpMemoryAction$4(FileDumpMemoryAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
RegistersWindow$MyTippedJTable$1
package mars.venus;
synchronized class RegistersWindow$MyTippedJTable$1 extends javax.swing.table.JTableHeader {
void RegistersWindow$MyTippedJTable$1(RegistersWindow$MyTippedJTable, javax.swing.table.TableColumnModel);
public String getToolTipText(java.awt.event.MouseEvent);
}
RunSpeedPanel$1
package mars.venus;
synchronized class RunSpeedPanel$1 {
}
SettingsHighlightingAction$FontSettingDialog$1
package mars.venus;
synchronized class SettingsHighlightingAction$FontSettingDialog$1 implements java.awt.event.ActionListener {
void SettingsHighlightingAction$FontSettingDialog$1(SettingsHighlightingAction$FontSettingDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsHighlightingAction$8
package mars.venus;
synchronized class SettingsHighlightingAction$8 implements java.awt.event.ActionListener {
void SettingsHighlightingAction$8(SettingsHighlightingAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
MainPane
package mars.venus;
public synchronized class MainPane extends javax.swing.JTabbedPane {
EditPane editTab;
ExecutePane executeTab;
EditTabbedPane editTabbedPane;
private VenusUI mainUI;
public void MainPane(VenusUI, Editor, RegistersWindow, Coprocessor1Window, Coprocessor0Window);
public EditPane getEditPane();
public javax.swing.JComponent getEditTabbedPane();
public ExecutePane getExecutePane();
public ExecutePane getExecuteTab();
}
DataSegmentWindow$4
package mars.venus;
synchronized class DataSegmentWindow$4 implements java.awt.event.ActionListener {
void DataSegmentWindow$4(DataSegmentWindow);
public void actionPerformed(java.awt.event.ActionEvent);
}
RegistersWindow
package mars.venus;
public synchronized class RegistersWindow extends javax.swing.JPanel implements java.util.Observer {
private static javax.swing.JTable table;
private static mars.mips.hardware.Register[] registers;
private Object[][] tableData;
private boolean highlighting;
private int highlightRow;
private ExecutePane executePane;
private static final int NAME_COLUMN = 0;
private static final int NUMBER_COLUMN = 1;
private static final int VALUE_COLUMN = 2;
private static mars.Settings settings;
public void RegistersWindow();
public Object[][] setupWindow();
public void clearWindow();
public void clearHighlighting();
public void refresh();
public void updateRegisters();
public void updateRegisters(int);
public void updateRegisterValue(int, int, int);
private void updateRegisterUnsignedValue(int, int, int);
public void update(java.util.Observable, Object);
void highlightCellForRegister(mars.mips.hardware.Register);
}
SettingsEditorAction$EditorFontDialog$2
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$2 implements java.awt.event.ActionListener {
void SettingsEditorAction$EditorFontDialog$2(SettingsEditorAction$EditorFontDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
HelpHelpAction$HelpHyperlinkListener
package mars.venus;
synchronized class HelpHelpAction$HelpHyperlinkListener implements javax.swing.event.HyperlinkListener {
javax.swing.JDialog webpageDisplay;
javax.swing.JTextField webpageURL;
private static final String cannotDisplayMessage =
private void HelpHelpAction$HelpHyperlinkListener(HelpHelpAction);
public void hyperlinkUpdate(javax.swing.event.HyperlinkEvent);
}
DataSegmentWindow
package mars.venus;
public synchronized class DataSegmentWindow extends javax.swing.JInternalFrame implements java.util.Observer {
private static final String[] dataSegmentNames;
private static Object[][] dataData;
private static javax.swing.JTable dataTable;
private javax.swing.JScrollPane dataTableScroller;
private java.awt.Container contentPane;
private javax.swing.JPanel tablePanel;
private javax.swing.JButton dataButton;
private javax.swing.JButton nextButton;
private javax.swing.JButton prevButton;
private javax.swing.JButton stakButton;
private javax.swing.JButton globButton;
private javax.swing.JButton heapButton;
private javax.swing.JButton kernButton;
private javax.swing.JButton extnButton;
private javax.swing.JButton mmioButton;
private javax.swing.JButton textButton;
private javax.swing.JCheckBox asciiDisplayCheckBox;
static final int VALUES_PER_ROW = 8;
static final int NUMBER_OF_ROWS = 16;
static final int NUMBER_OF_COLUMNS = 9;
static final int BYTES_PER_VALUE = 4;
static final int BYTES_PER_ROW = 32;
static final int MEMORY_CHUNK_SIZE = 512;
static final int PREV_NEXT_CHUNK_SIZE = 256;
static final int ADDRESS_COLUMN = 0;
static final boolean USER_MODE = 0;
static final boolean KERNEL_MODE = 1;
private boolean addressHighlighting;
private boolean asciiDisplay;
private int addressRow;
private int addressColumn;
private int addressRowFirstAddress;
private mars.Settings settings;
int firstAddress;
int homeAddress;
boolean userOrKernelMode;
javax.swing.JComboBox baseAddressSelector;
private String[] displayBaseAddressChoices;
private int[] displayBaseAddresses;
private int defaultBaseAddressIndex;
javax.swing.JButton[] baseAddressButtons;
private static final int EXTERN_BASE_ADDRESS_INDEX = 0;
private static final int GLOBAL_POINTER_ADDRESS_INDEX = 3;
private static final int TEXT_BASE_ADDRESS_INDEX = 5;
private static final int DATA_BASE_ADDRESS_INDEX = 1;
private static final int HEAP_BASE_ADDRESS_INDEX = 2;
private static final int STACK_POINTER_BASE_ADDRESS_INDEX = 4;
private static final int KERNEL_DATA_BASE_ADDRESS_INDEX = 6;
private static final int MMIO_BASE_ADDRESS_INDEX = 7;
private int[] displayBaseAddressArray;
String[] descriptions;
public void DataSegmentWindow(NumberDisplayBaseChooser[]);
public void updateBaseAddressComboBox();
void selectCellForAddress(int);
void highlightCellForAddress(int);
private java.awt.Point displayCellForAddress(int);
private void initializeBaseAddressChoices();
private String[] createBaseAddressLabelsArray(int[], String[]);
private int getBaseAddressIndexForAddress(int);
private javax.swing.JScrollPane generateDataPanel();
private String getHeaderStringForColumn(int, int);
public void setupTable();
public void clearWindow();
public void clearHighlighting();
private int getValueDisplayFormat();
public void updateModelForMemoryRange(int);
public void updateCell(int, int);
public void updateDataAddresses();
public void updateValues();
public void resetMemoryRange();
public void resetValues();
private void disableAllButtons();
private void enableAllButtons();
private void addButtonActionListenersAndInitialize();
private int setFirstAddressAndPrevNextButtonEnableStatus(int);
public void update(java.util.Observable, Object);
static void
}
MessagesPane$Asker$2
package mars.venus;
synchronized class MessagesPane$Asker$2 extends javax.swing.text.NavigationFilter {
void MessagesPane$Asker$2(MessagesPane$Asker);
public void moveDot(javax.swing.text.NavigationFilter$FilterBypass, int, javax.swing.text.Position$Bias);
public void setDot(javax.swing.text.NavigationFilter$FilterBypass, int, javax.swing.text.Position$Bias);
}
AbstractFontSettingDialog$BlockComboListener
package mars.venus;
synchronized class AbstractFontSettingDialog$BlockComboListener implements java.awt.event.ActionListener {
javax.swing.JComboBox combo;
Object currentItem;
void AbstractFontSettingDialog$BlockComboListener(AbstractFontSettingDialog, javax.swing.JComboBox);
public void actionPerformed(java.awt.event.ActionEvent);
}
Editor
package mars.venus;
public synchronized class Editor {
public static final int MIN_TAB_SIZE = 1;
public static final int MAX_TAB_SIZE = 32;
public static final int MIN_BLINK_RATE = 0;
public static final int MAX_BLINK_RATE = 1000;
private VenusUI mainUI;
private EditTabbedPane editTabbedPane;
private String mainUIbaseTitle;
private int newUsageCount;
private String defaultOpenDirectory;
private String currentOpenDirectory;
private String defaultSaveDirectory;
private String currentSaveDirectory;
public void Editor(VenusUI);
public void setEditTabbedPane(EditTabbedPane);
public String getCurrentOpenDirectory();
void setCurrentOpenDirectory(String);
public String getCurrentSaveDirectory();
void setCurrentSaveDirectory(String);
public String getNextDefaultFilename();
public void setTitle(String, String, int);
public void newFile();
public boolean close();
public boolean closeAll();
public boolean save();
public boolean saveAs();
public boolean saveAll();
public boolean open();
public boolean editsSavedOrAbandoned();
}
DataSegmentWindow$6
package mars.venus;
synchronized class DataSegmentWindow$6 implements java.awt.event.ActionListener {
void DataSegmentWindow$6(DataSegmentWindow);
public void actionPerformed(java.awt.event.ActionEvent);
}
LabelsWindow$DescendingComparator
package mars.venus;
synchronized class LabelsWindow$DescendingComparator implements java.util.Comparator {
private java.util.Comparator opposite;
private void LabelsWindow$DescendingComparator(LabelsWindow, java.util.Comparator);
public int compare(Object, Object);
}
FileSaveAction
package mars.venus;
public synchronized class FileSaveAction extends GuiAction {
public void FileSaveAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsHighlightingAction$FontSettingDialog$3
package mars.venus;
synchronized class SettingsHighlightingAction$FontSettingDialog$3 implements java.awt.event.ActionListener {
void SettingsHighlightingAction$FontSettingDialog$3(SettingsHighlightingAction$FontSettingDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
ToolAction
package mars.venus;
public synchronized class ToolAction extends javax.swing.AbstractAction {
private Class toolClass;
public void ToolAction(Class, String);
public void actionPerformed(java.awt.event.ActionEvent);
}
TextSegmentWindow$MyTippedJTable$TextTableHeader$TextTableHeaderMouseListener
package mars.venus;
synchronized class TextSegmentWindow$MyTippedJTable$TextTableHeader$TextTableHeaderMouseListener implements java.awt.event.MouseListener {
private void TextSegmentWindow$MyTippedJTable$TextTableHeader$TextTableHeaderMouseListener(TextSegmentWindow$MyTippedJTable$TextTableHeader);
public void mouseClicked(java.awt.event.MouseEvent);
public void mouseEntered(java.awt.event.MouseEvent);
public void mouseExited(java.awt.event.MouseEvent);
public void mousePressed(java.awt.event.MouseEvent);
public void mouseReleased(java.awt.event.MouseEvent);
}
AbstractFontSettingDialog$1
package mars.venus;
synchronized class AbstractFontSettingDialog$1 extends java.awt.event.WindowAdapter {
void AbstractFontSettingDialog$1(AbstractFontSettingDialog);
public void windowClosing(java.awt.event.WindowEvent);
}
SettingsExceptionHandlerAction$1
package mars.venus;
synchronized class SettingsExceptionHandlerAction$1 extends java.awt.event.WindowAdapter {
void SettingsExceptionHandlerAction$1(SettingsExceptionHandlerAction);
public void windowClosing(java.awt.event.WindowEvent);
}
Coprocessor1Window
package mars.venus;
public synchronized class Coprocessor1Window extends javax.swing.JPanel implements java.awt.event.ActionListener, java.util.Observer {
private static javax.swing.JTable table;
private static mars.mips.hardware.Register[] registers;
private Object[][] tableData;
private boolean highlighting;
private int highlightRow;
private ExecutePane executePane;
private javax.swing.JCheckBox[] conditionFlagCheckBox;
private static final int NAME_COLUMN = 0;
private static final int FLOAT_COLUMN = 1;
private static final int DOUBLE_COLUMN = 2;
private static mars.Settings settings;
public void Coprocessor1Window();
public void actionPerformed(java.awt.event.ActionEvent);
public Object[][] setupWindow();
public void clearWindow();
public void clearHighlighting();
public void refresh();
public void updateRegisters();
public void updateRegisters(int);
private void updateConditionFlagDisplay();
public void updateFloatRegisterValue(int, int, int);
public void updateDoubleRegisterValue(int, int);
public void update(java.util.Observable, Object);
void highlightCellForRegister(mars.mips.hardware.Register);
}
SettingsHighlightingAction$FontChanger
package mars.venus;
synchronized class SettingsHighlightingAction$FontChanger implements java.awt.event.ActionListener {
private int position;
public void SettingsHighlightingAction$FontChanger(SettingsHighlightingAction, int);
public void actionPerformed(java.awt.event.ActionEvent);
}
TextSegmentWindow$ModifiedCode
package mars.venus;
synchronized class TextSegmentWindow$ModifiedCode {
private Integer row;
private Object code;
private Object basic;
private Object source;
private void TextSegmentWindow$ModifiedCode(TextSegmentWindow, Integer, Object, Object, Object);
private Integer getRow();
private Object getCode();
private Object getBasic();
private Object getSource();
}
MessagesPane$3
package mars.venus;
synchronized class MessagesPane$3 implements java.awt.event.ActionListener {
void MessagesPane$3(MessagesPane);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsExceptionHandlerAction$ExceptionHandlerSelectionAction
package mars.venus;
synchronized class SettingsExceptionHandlerAction$ExceptionHandlerSelectionAction implements java.awt.event.ActionListener {
private void SettingsExceptionHandlerAction$ExceptionHandlerSelectionAction(SettingsExceptionHandlerAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
EditTabbedPane$FileOpener$ChoosableFileFilterChangeListener
package mars.venus;
synchronized class EditTabbedPane$FileOpener$ChoosableFileFilterChangeListener implements java.beans.PropertyChangeListener {
private void EditTabbedPane$FileOpener$ChoosableFileFilterChangeListener(EditTabbedPane$FileOpener);
public void propertyChange(java.beans.PropertyChangeEvent);
}
DataSegmentWindow$CustomComboBoxModel
package mars.venus;
synchronized class DataSegmentWindow$CustomComboBoxModel extends javax.swing.DefaultComboBoxModel {
public void DataSegmentWindow$CustomComboBoxModel(DataSegmentWindow, Object[]);
private void forceComboBoxUpdate(int);
}
FileDumpMemoryAction$2
package mars.venus;
synchronized class FileDumpMemoryAction$2 implements java.awt.event.ActionListener {
void FileDumpMemoryAction$2(FileDumpMemoryAction);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsMemoryConfigurationAction$MemoryConfigurationDialog$3
package mars.venus;
synchronized class SettingsMemoryConfigurationAction$MemoryConfigurationDialog$3 implements java.awt.event.ActionListener {
void SettingsMemoryConfigurationAction$MemoryConfigurationDialog$3(SettingsMemoryConfigurationAction$MemoryConfigurationDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
FileSaveAsAction
package mars.venus;
public synchronized class FileSaveAsAction extends GuiAction {
public void FileSaveAsAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
FileCloseAllAction
package mars.venus;
public synchronized class FileCloseAllAction extends GuiAction {
public void FileCloseAllAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
SettingsEditorAction$EditorFontDialog$4
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$4 implements java.awt.event.ActionListener {
void SettingsEditorAction$EditorFontDialog$4(SettingsEditorAction$EditorFontDialog);
public void actionPerformed(java.awt.event.ActionEvent);
}
HelpHelpAction$HelpHyperlinkListener$1
package mars.venus;
synchronized class HelpHelpAction$HelpHyperlinkListener$1 implements javax.swing.event.HyperlinkListener {
void HelpHelpAction$HelpHyperlinkListener$1(HelpHelpAction$HelpHyperlinkListener);
public void hyperlinkUpdate(javax.swing.event.HyperlinkEvent);
}
SettingsMemoryConfigurationAction$ConfigurationButton
package mars.venus;
synchronized class SettingsMemoryConfigurationAction$ConfigurationButton extends javax.swing.JRadioButton {
private mars.mips.hardware.MemoryConfiguration configuration;
public void SettingsMemoryConfigurationAction$ConfigurationButton(SettingsMemoryConfigurationAction, mars.mips.hardware.MemoryConfiguration);
public mars.mips.hardware.MemoryConfiguration getConfiguration();
}
DataSegmentWindow$2
package mars.venus;
synchronized class DataSegmentWindow$2 implements java.awt.event.ItemListener {
void DataSegmentWindow$2(DataSegmentWindow);
public void itemStateChanged(java.awt.event.ItemEvent);
}
RunPauseAction
package mars.venus;
public synchronized class RunPauseAction extends GuiAction {
public void RunPauseAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
Coprocessor0Window$MyTippedJTable$1
package mars.venus;
synchronized class Coprocessor0Window$MyTippedJTable$1 extends javax.swing.table.JTableHeader {
void Coprocessor0Window$MyTippedJTable$1(Coprocessor0Window$MyTippedJTable, javax.swing.table.TableColumnModel);
public String getToolTipText(java.awt.event.MouseEvent);
}
EditPane
package mars.venus;
public synchronized class EditPane extends javax.swing.JPanel implements java.util.Observer {
private editors.MARSTextEditingArea sourceCode;
private VenusUI mainUI;
private String currentDirectoryPath;
private javax.swing.JLabel caretPositionLabel;
private javax.swing.JCheckBox showLineNumbers;
private javax.swing.JLabel lineNumbers;
private static int count;
private boolean isCompoundEdit;
private javax.swing.undo.CompoundEdit compoundEdit;
private FileStatus fileStatus;
private static final String spaces = ;
private static final char newline = 10;
public void EditPane(VenusUI);
public void setSourceCode(String, boolean);
public void discardAllUndoableEdits();
public String getLineNumbersList(javax.swing.text.Document);
public int getSourceLineCount();
public String getSource();
public void setFileStatus(int);
public int getFileStatus();
public String getFilename();
public String getPathname();
public void setPathname(String);
public boolean hasUnsavedEdits();
public boolean isNew();
public void tellEditingComponentToRequestFocusInWindow();
public void updateStaticFileStatus();
public javax.swing.undo.UndoManager getUndoManager();
public void copyText();
public void cutText();
public void pasteText();
public void selectAllText();
public void undo();
public void redo();
public void updateUndoState();
public void updateRedoState();
public boolean showingLineNumbers();
public void setShowLineNumbersEnabled(boolean);
public void displayCaretPosition(int);
public void displayCaretPosition(java.awt.Point);
public java.awt.Point convertStreamPositionToLineColumn(int);
public int convertLineColumnToStreamPosition(int, int);
public void selectLine(int);
public void selectLine(int, int);
public int doFindText(String, boolean);
public int doReplace(String, String, boolean);
public int doReplaceAll(String, String, boolean);
public void update(java.util.Observable, Object);
private java.awt.Font getLineNumberFont(java.awt.Font);
static void
}
SettingsEditorAction$EditorFontDialog$6
package mars.venus;
synchronized class SettingsEditorAction$EditorFontDialog$6 implements javax.swing.event.ChangeListener {
void SettingsEditorAction$EditorFontDialog$6(SettingsEditorAction$EditorFontDialog);
public void stateChanged(javax.swing.event.ChangeEvent);
}
MessagesPane$Asker$4
package mars.venus;
synchronized class MessagesPane$Asker$4 implements Runnable {
void MessagesPane$Asker$4(MessagesPane$Asker);
public void run();
}
SettingsMemoryConfigurationAction$MemoryConfigurationDialog$1
package mars.venus;
synchronized class SettingsMemoryConfigurationAction$MemoryConfigurationDialog$1 extends java.awt.event.WindowAdapter {
void SettingsMemoryConfigurationAction$MemoryConfigurationDialog$1(SettingsMemoryConfigurationAction$MemoryConfigurationDialog, SettingsMemoryConfigurationAction);
public void windowClosing(java.awt.event.WindowEvent);
}
RunResetAction
package mars.venus;
public synchronized class RunResetAction extends GuiAction {
public void RunResetAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
}
EditRedoAction
package mars.venus;
public synchronized class EditRedoAction extends GuiAction {
public void EditRedoAction(String, javax.swing.Icon, String, Integer, javax.swing.KeyStroke, VenusUI);
public void actionPerformed(java.awt.event.ActionEvent);
void updateRedoState();
}
HardcopyWriter$PrintCanceledException
package mars.venus;
public synchronized class HardcopyWriter$PrintCanceledException extends Exception {
public void HardcopyWriter$PrintCanceledException(String);
}
ToolLoader$MarsToolClassAndInstance
package mars.venus;
synchronized class ToolLoader$MarsToolClassAndInstance {
Class marsToolClass;
mars.tools.MarsTool marsToolInstance;
void ToolLoader$MarsToolClassAndInstance(ToolLoader, Class, mars.tools.MarsTool);
}
MessagesPane$1
package mars.venus;
synchronized class MessagesPane$1 implements java.awt.event.ActionListener {
void MessagesPane$1(MessagesPane);
public void actionPerformed(java.awt.event.ActionEvent);
}
Coprocessor1Window$RegisterCellRenderer
package mars.venus;
synchronized class Coprocessor1Window$RegisterCellRenderer extends javax.swing.table.DefaultTableCellRenderer {
private java.awt.Font font;
private int alignment;
public void Coprocessor1Window$RegisterCellRenderer(Coprocessor1Window, java.awt.Font, int);
public java.awt.Component getTableCellRendererComponent(javax.swing.JTable, Object, boolean, boolean, int, int);
}
SoundPlayer
package mars.ext.game;
public synchronized class SoundPlayer {
private java.util.HashMap soundsMap;
private java.util.ArrayList loopSounds;
public void SoundPlayer();
private void loadSounds();
public void play(int, boolean);
public void stopSound(int);
public void enable(boolean);
public void stopAll();
public void loopAll(boolean, boolean);
public static void main(String[]);
}
Sprite
package mars.ext.game.util;
public synchronized class Sprite {
private String file;
private java.awt.image.BufferedImage image;
private java.awt.image.BufferedImage[][] images;
public void Sprite(String);
public void loadImages(int, int, int, int, int, int, int);
public java.awt.image.BufferedImage getImage(int, int, int, int);
public java.awt.image.BufferedImage[][] getImages();
public java.awt.image.BufferedImage getImage(int, int);
public java.awt.image.BufferedImage[] getSpriteArray(int);
}
Progress
package mars.ext.game.util;
public synchronized class Progress {
private static Progress instance;
private java.util.Properties properties;
private void Progress();
public static Progress getInstance();
public String get(String);
public void set(String, String);
public void store();
}
MMIOThread
package mars.ext.game;
public synchronized class MMIOThread extends Thread {
private MMIOInput mmioInput;
private java.util.Vector events;
boolean isFinish;
public void MMIOThread(MMIOInput);
public synchronized void stopProcess();
public synchronized Object[] getEvent();
public synchronized void add(int, Character);
public void run();
}
ActiveElementInterface
package mars.ext.game;
public abstract interface ActiveElementInterface {
public abstract int getScore();
public abstract void deductHitPoint(int);
public abstract void setDirection(boolean);
public abstract boolean getDirection();
public abstract void setSpeed(int);
public abstract int getSpeed();
public abstract void updateLocation();
public abstract int getHitPoint();
}
GameBombObject
package mars.ext.game;
public synchronized class GameBombObject extends GameObject implements ActiveElementInterface {
public static final int HIT_POINT = 1;
private java.awt.Image image;
private java.awt.Image explodeImage;
private int speed;
private int hitPoint;
public void GameBombObject(int, int, int, String, String);
public void GameBombObject(int, String, String);
public void paint(java.awt.Graphics);
public int getScore();
public void deductHitPoint(int);
public int getHitPoint();
public void setDirection(boolean);
public boolean getDirection();
public void setSpeed(int);
public int getSpeed();
public void updateLocation();
}
GameScreen$1
package mars.ext.game;
synchronized class GameScreen$1 extends java.awt.event.WindowAdapter {
void GameScreen$1(GameScreen);
public void windowClosed(java.awt.event.WindowEvent);
}
GameScreen$ScreenPanel
package mars.ext.game;
synchronized class GameScreen$ScreenPanel extends javax.swing.JPanel {
public void GameScreen$ScreenPanel(GameScreen);
public void paintComponent(java.awt.Graphics);
}
GameObject
package mars.ext.game;
public abstract synchronized class GameObject {
protected int id;
protected int xLoc;
protected int yLoc;
protected int type;
public int direction;
public int direction_;
public void GameObject(int);
public void GameObject(int, int, int);
public void GameObject(int, int);
public void GameObject(int, int, int, int);
public abstract void paint(java.awt.Graphics);
public int getId();
public void setXLoc(int);
public int getXLoc();
public void setYLoc(int);
public int getYLoc();
public void setDirection(int, int);
public void setLocations(int, int);
public int getType();
}
GameBulletObject
package mars.ext.game;
public synchronized class GameBulletObject extends GameObject {
private java.awt.Image image;
private int owner;
private int type;
private int dir;
private int speed;
private int size;
private boolean hit;
private boolean isDestroyed;
public void GameBulletObject(int, int, int, int, int, int);
public void paint(java.awt.Graphics);
public void updateLocation();
}
GameRemoteBombObject
package mars.ext.game;
public synchronized class GameRemoteBombObject extends GameObject implements ActiveElementInterface {
public static final int HIT_POINT = 1;
private java.awt.Image activeImage;
private java.awt.Image inactiveImage;
private java.awt.Image explodeImage;
private boolean isActive;
private int hitPoint;
private int speed;
public void GameRemoteBombObject(int, int, int, String, String, String);
public void GameRemoteBombObject(int, String, String, String);
public boolean isActive();
public void setActive(boolean);
public void paint(java.awt.Graphics);
public int getScore();
public void deductHitPoint(int);
public int getHitPoint();
public void setDirection(boolean);
public boolean getDirection();
public void setSpeed(int);
public int getSpeed();
public void updateLocation();
}
MMIOInput
package mars.ext.game;
public synchronized class MMIOInput implements java.awt.event.KeyListener, java.util.Observer {
public static int RECEIVER_CONTROL;
public static int RECEIVER_DATA;
private MMIOThread mmioThread;
private boolean noRepeatedKeyEvents;
private int keyPressNum;
private char lastKeyChar;
private boolean acceptClearInput;
public void MMIOInput(boolean);
public void destroy();
void addAsObserver();
public void update(java.util.Observable, Object);
private void updateMMIOControl(int, int);
private void updateMMIOControlAndData(int, int, int, int);
private void updateMMIOControlAndData(int, int, int, int, boolean);
private boolean isReadyBitSet(int);
private int readyBitSet(int);
private int readyBitCleared(int);
public void writeInput(char);
public void clearInput();
public void keyTyped(java.awt.event.KeyEvent);
public synchronized void processKeyPress(char);
public synchronized void keyPressed(java.awt.event.KeyEvent);
public synchronized void processKeyRelease(char);
public synchronized void keyReleased(java.awt.event.KeyEvent);
}
GamePlayerObject
package mars.ext.game;
public synchronized class GamePlayerObject extends GameObject {
private int size;
private int dir;
private int speed;
private int frame;
private boolean hit;
private boolean isAI;
private boolean isShooting;
private GameBulletObject bullet;
private double shootRate;
private boolean isDestroyed;
private int tempX;
private int tempY;
private java.awt.Image image;
private int lives;
private boolean isProtected;
private int protectedTime;
public void GamePlayerObject(int, int, int);
public void paint(java.awt.Graphics);
}
GameImage
package mars.ext.game;
public synchronized class GameImage extends GameObject {
public java.awt.Image image;
public java.awt.Graphics2D graphics2D;
private util.Sprite sprite;
public void GameImage(int, int, int, int[][], int, int, int, int, int);
public java.awt.Image createImage(String, int);
public void paint(java.awt.Graphics);
}
GameTextObject
package mars.ext.game;
public synchronized class GameTextObject extends GameObject {
private String text;
private java.awt.Font font;
private java.awt.Color color;
public void GameTextObject(int, int, int);
public void GameTextObject(int);
public void paint(java.awt.Graphics);
public void setText(String);
public void setFontSize(int) throws GameException;
public void setFont(String, int, boolean) throws GameException;
public void setColor(int) throws GameException;
}
GameScreen
package mars.ext.game;
public synchronized class GameScreen extends javax.swing.JFrame {
private java.awt.image.BufferedImage offscreenImage;
public int width;
public int height;
private String title;
private int score;
private int simpleBombLeft;
private int remoteBombLeft;
private java.awt.Font font;
private java.util.ArrayList gameObjs;
private SoundPlayer soundPlayer;
private MMIOInput keyListener;
private GameImage bgImage;
private GameScreen$ScreenPanel panel;
private boolean useBomb;
public GameImage mazeImage;
public int mazeWidth;
public int cellWidth;
public int mazeHeight;
public int cellHeight;
public int bitmapRow;
public int bitmapColumn;
private int[][] mazeBitmap;
private java.util.ArrayList pathList;
private int topObjectType;
private int level;
private static GameScreen instance;
public static GameScreen getInstance();
public static synchronized GameScreen createIntance(String) throws Exception;
private void initGameScreen();
public void loadMaze(java.util.Properties, int);
private void GameScreen(String) throws Exception;
public void playSound(int, boolean);
public void stopSound(int);
public void addGameObject(int, GameObject, int);
public GameObject getGameObject(int, int);
public void removeAllObjects(int);
public java.util.Hashtable getAllObjects(int);
public void refreshScreen();
public void updateScore(int);
public void updateLevel(int);
public int getLevel();
public boolean moveAllObj(int, int, int);
public int[] getRandomPath();
private void redrawScreen(java.awt.Graphics2D);
public int getBitmapCell(int, int);
public void editBitmapCell(int, int, int);
public void editBitmapCell(int, int);
private void createMazeBitmap(String);
private void loadRouteFile();
static void
}
GameException
package mars.ext.game;
public synchronized class GameException extends Exception {
public void GameException(String);
}
GameConfigFile
package mars.ext.game;
public synchronized class GameConfigFile {
public static java.util.Properties properties;
public static int[] prevImagePackIndex;
static java.util.Random rand;
static int[] imagePackCount;
static java.util.Hashtable imageArchive;
static java.util.ArrayList routeList;
static int prevRouteIndex;
static final int WALL = 1;
static final int GRID = 2;
static final int GRASS = -1;
static final int WATER = 4;
static final int ICE = 5;
static final int HOME = 9;
static final int ANOTHREHOME = 8;
static final int offsetX = 32;
static final int offsetY = 16;
static final int tileSize = 16;
static final int tankSize = 16;
static final int homeSize = 32;
static final int UP = 0;
static final int DOWN = 1;
static final int LEFT = 2;
static final int RIGHT = 3;
static final String SOUND_START = /game/sounds/start.wav;
static final String SOUND_MOVE = /game/sounds/move.wav;
static final String SOUND_TANKCRACK = /game/sounds/tankCrack.wav;
static final String SOUND_BULLETCRACK = /game/sounds/bulletCrack.wav;
static final String SOUND_ATTACK = /game/sounds/attack.wav;
static final String SOUND_PLAYERCRACK = /game/sounds/playerCrack.wav;
static final String SOUND_PROP = /game/sounds/prop.wav;
static final String RESOURCE_IMAGE = /game/images/tankAll.gif;
static String[] usedGameSounds;
public static int[][] playerPosiontions;
public static java.util.Map POS;
private void GameConfigFile();
static void
}
MazeGameObject
package mars.ext.game;
public synchronized class MazeGameObject extends GameObject implements ActiveElementInterface {
private java.util.ArrayList images;
private int hitPoint;
private boolean isRight;
private int speed;
public int curImageIndex;
public int delImageIndex;
private java.util.ArrayList route;
private String action;
private int destX;
private int destY;
private int routeStepIndex;
private int[][] markedRoute;
private boolean seekTarget;
private int images_per_dir;
private int cur_dir_indx;
public boolean bombUsed;
public int bombPower;
public boolean bombPowerUp;
public int bombTimerThreshold;
public int bombTimer;
public int flame_x;
public int flame_y;
int imgIndex;
public int blastSteps;
int flameStepTimerThreshold;
int flameTimer;
public int nEnd;
public int sEnd;
public int wEnd;
public int eEnd;
public boolean bombPlaySound;
java.util.ArrayList flameImgs;
public int powerUpId;
public int textType;
public int textDisplayX;
public int textDisplayY;
public int textColor;
public int powerTextTimerThres;
public int powerTextTimer;
public int pair;
public static int remaining_monster_num;
public static int total_monster_num;
public boolean survival;
int remianingSteps;
int enemySpeed;
public int[] enemyRoute;
public int latestMove;
int routIdx;
int enemyIdx;
public int enemyBulletNum;
public boolean destroyed;
public boolean hitWall;
int interval;
int bulletSpeed;
java.util.ArrayList xypair;
int objectSize;
boolean enableDrawBrickWall;
int drawBrickWall;
public int bulletMove(int[][]);
public void enemyChasePlayer();
public void enemyChaseHome();
public int coordinateTransform(int, int);
public int[] tankPositions1();
public int[] tankPositions1(int, int);
public int[][] tankPositions2();
public int useBomb(int);
public void bombExplosion();
public void bombPowerUp();
public void bombPowerUpAct();
public void destroyBomb();
public int checkExplosionCollision(int, int);
public void MazeGameObject(int, int, int, int);
public void useImagePack(int);
public void MultiDirImages(int, int, int);
private java.awt.Image createImage(String);
public java.awt.image.BufferedImage Rotate(java.awt.Image, int);
public java.awt.Rectangle CalcRotatedSize(java.awt.Rectangle, int);
public void drawBrickWallBreak(java.util.ArrayList, int);
public void paint(java.awt.Graphics);
public int getScore();
public void deductHitPoint(int);
public int getHitPoint();
public void setDirection(boolean);
public boolean getDirection();
public void setSpeed(int);
public int getSpeed();
public void setHitPoint(int);
public void updateLocation();
public boolean isIntersected(int, int, int, int);
private double getSqDist(int, int, int, int);
private void resetMarkedRoute();
private void resetRouteState();
private void markRoute(int, int, int, int);
private int getMarkedRoute(int, int, int, int);
private void loadRoute(GameScreen);
public void nextRouteStep(GameScreen, MazeGameObject);
private void setLocationsWrap(int, int, int, int);
public void incImageIndex();
static void
}
ProgramStatement$BasicStatementList$ListElement
package mars;
synchronized class ProgramStatement$BasicStatementList$ListElement {
int type;
String sValue;
int iValue;
void ProgramStatement$BasicStatementList$ListElement(ProgramStatement$BasicStatementList, int, String, int);
}
ErrorList
package mars;
public synchronized class ErrorList {
private java.util.ArrayList messages;
private int errorCount;
private int warningCount;
public static final String ERROR_MESSAGE_PREFIX = Error;
public static final String WARNING_MESSAGE_PREFIX = Warning;
public static final String FILENAME_PREFIX = in ;
public static final String LINE_PREFIX = line ;
public static final String POSITION_PREFIX = column ;
public static final String MESSAGE_SEPARATOR = : ;
public void ErrorList();
public java.util.ArrayList getErrorMessages();
public boolean errorsOccurred();
public boolean warningsOccurred();
public void add(ErrorMessage);
public void add(ErrorMessage, int);
public int errorCount();
public int warningCount();
public boolean errorLimitExceeded();
public int getErrorLimit();
public String generateErrorReport();
public String generateWarningReport();
public String generateErrorAndWarningReport();
private String generateReport(boolean);
}
InstructionSet$62
package mars.mips.instructions;
synchronized class InstructionSet$62 implements SimulationCode {
void InstructionSet$62(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$27
package mars.mips.instructions;
synchronized class InstructionSet$27 implements SimulationCode {
void InstructionSet$27(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$143
package mars.mips.instructions;
synchronized class InstructionSet$143 implements SimulationCode {
void InstructionSet$143(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$106
package mars.mips.instructions;
synchronized class InstructionSet$106 implements SimulationCode {
void InstructionSet$106(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$46
package mars.mips.instructions;
synchronized class InstructionSet$46 implements SimulationCode {
void InstructionSet$46(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$122
package mars.mips.instructions;
synchronized class InstructionSet$122 implements SimulationCode {
void InstructionSet$122(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$86
package mars.mips.instructions;
synchronized class InstructionSet$86 implements SimulationCode {
void InstructionSet$86(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$84
package mars.mips.instructions;
synchronized class InstructionSet$84 implements SimulationCode {
void InstructionSet$84(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$79
package mars.mips.instructions;
synchronized class InstructionSet$79 implements SimulationCode {
void InstructionSet$79(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$44
package mars.mips.instructions;
synchronized class InstructionSet$44 implements SimulationCode {
void InstructionSet$44(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$120
package mars.mips.instructions;
synchronized class InstructionSet$120 implements SimulationCode {
void InstructionSet$120(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$60
package mars.mips.instructions;
synchronized class InstructionSet$60 implements SimulationCode {
void InstructionSet$60(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$25
package mars.mips.instructions;
synchronized class InstructionSet$25 implements SimulationCode {
void InstructionSet$25(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$141
package mars.mips.instructions;
synchronized class InstructionSet$141 implements SimulationCode {
void InstructionSet$141(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$104
package mars.mips.instructions;
synchronized class InstructionSet$104 implements SimulationCode {
void InstructionSet$104(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$139
package mars.mips.instructions;
synchronized class InstructionSet$139 implements SimulationCode {
void InstructionSet$139(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$18
package mars.mips.instructions;
synchronized class InstructionSet$18 implements SimulationCode {
void InstructionSet$18(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$145
package mars.mips.instructions;
synchronized class InstructionSet$145 implements SimulationCode {
void InstructionSet$145(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$100
package mars.mips.instructions;
synchronized class InstructionSet$100 implements SimulationCode {
void InstructionSet$100(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$64
package mars.mips.instructions;
synchronized class InstructionSet$64 implements SimulationCode {
void InstructionSet$64(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$21
package mars.mips.instructions;
synchronized class InstructionSet$21 implements SimulationCode {
void InstructionSet$21(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$99
package mars.mips.instructions;
synchronized class InstructionSet$99 implements SimulationCode {
void InstructionSet$99(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$59
package mars.mips.instructions;
synchronized class InstructionSet$59 implements SimulationCode {
void InstructionSet$59(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$38
package mars.mips.instructions;
synchronized class InstructionSet$38 implements SimulationCode {
void InstructionSet$38(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$80
package mars.mips.instructions;
synchronized class InstructionSet$80 implements SimulationCode {
void InstructionSet$80(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$119
package mars.mips.instructions;
synchronized class InstructionSet$119 implements SimulationCode {
void InstructionSet$119(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$124
package mars.mips.instructions;
synchronized class InstructionSet$124 implements SimulationCode {
void InstructionSet$124(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$40
package mars.mips.instructions;
synchronized class InstructionSet$40 implements SimulationCode {
void InstructionSet$40(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallLoader
package mars.mips.instructions;
synchronized class SyscallLoader {
private static final String CLASS_PREFIX = mars.mips.instructions.syscalls.;
private static final String SYSCALLS_DIRECTORY_PATH = mars/mips/instructions/syscalls;
private static final String SYSCALL_INTERFACE = Syscall.class;
private static final String SYSCALL_ABSTRACT = AbstractSyscall.class;
private static final String CLASS_EXTENSION = class;
private java.util.ArrayList syscallList;
void SyscallLoader();
void loadSyscalls();
private java.util.ArrayList processSyscallNumberOverrides(java.util.ArrayList);
syscalls.Syscall findSyscall(int);
}
ExtendedInstruction
package mars.mips.instructions;
public synchronized class ExtendedInstruction extends Instruction {
private java.util.ArrayList translationStrings;
private java.util.ArrayList compactTranslationStrings;
public void ExtendedInstruction(String, String, String, String);
public void ExtendedInstruction(String, String, String);
public void ExtendedInstruction(String, String);
public int getInstructionLength();
public java.util.ArrayList getBasicIntructionTemplateList();
public int getCompactInstructionLength();
public boolean hasCompactTranslation();
public java.util.ArrayList getCompactBasicIntructionTemplateList();
public static String makeTemplateSubstitutions(mars.MIPSprogram, String, mars.assembler.TokenList);
private static String substitute(String, String, String);
private static String substituteFirst(String, String, String);
private java.util.ArrayList buildTranslationList(String);
private int getInstructionLength(java.util.ArrayList);
}
InstructionSet$126
package mars.mips.instructions;
synchronized class InstructionSet$126 implements SimulationCode {
void InstructionSet$126(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$42
package mars.mips.instructions;
synchronized class InstructionSet$42 implements SimulationCode {
void InstructionSet$42(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$82
package mars.mips.instructions;
synchronized class InstructionSet$82 implements SimulationCode {
void InstructionSet$82(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$147
package mars.mips.instructions;
synchronized class InstructionSet$147 implements SimulationCode {
void InstructionSet$147(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$102
package mars.mips.instructions;
synchronized class InstructionSet$102 implements SimulationCode {
void InstructionSet$102(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
BasicInstructionFormat
package mars.mips.instructions;
public synchronized class BasicInstructionFormat {
public static final BasicInstructionFormat R_FORMAT;
public static final BasicInstructionFormat I_FORMAT;
public static final BasicInstructionFormat I_BRANCH_FORMAT;
public static final BasicInstructionFormat J_FORMAT;
private void BasicInstructionFormat();
static void
}
InstructionSet$9
package mars.mips.instructions;
synchronized class InstructionSet$9 implements SimulationCode {
void InstructionSet$9(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$66
package mars.mips.instructions;
synchronized class InstructionSet$66 implements SimulationCode {
void InstructionSet$66(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$23
package mars.mips.instructions;
synchronized class InstructionSet$23 implements SimulationCode {
void InstructionSet$23(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$121
package mars.mips.instructions;
synchronized class InstructionSet$121 implements SimulationCode {
void InstructionSet$121(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$45
package mars.mips.instructions;
synchronized class InstructionSet$45 implements SimulationCode {
void InstructionSet$45(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$85
package mars.mips.instructions;
synchronized class InstructionSet$85 implements SimulationCode {
void InstructionSet$85(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$78
package mars.mips.instructions;
synchronized class InstructionSet$78 implements SimulationCode {
void InstructionSet$78(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$19
package mars.mips.instructions;
synchronized class InstructionSet$19 implements SimulationCode {
void InstructionSet$19(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$138
package mars.mips.instructions;
synchronized class InstructionSet$138 implements SimulationCode {
void InstructionSet$138(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$105
package mars.mips.instructions;
synchronized class InstructionSet$105 implements SimulationCode {
void InstructionSet$105(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$140
package mars.mips.instructions;
synchronized class InstructionSet$140 implements SimulationCode {
void InstructionSet$140(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$24
package mars.mips.instructions;
synchronized class InstructionSet$24 implements SimulationCode {
void InstructionSet$24(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$61
package mars.mips.instructions;
synchronized class InstructionSet$61 implements SimulationCode {
void InstructionSet$61(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$107
package mars.mips.instructions;
synchronized class InstructionSet$107 implements SimulationCode {
void InstructionSet$107(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$142
package mars.mips.instructions;
synchronized class InstructionSet$142 implements SimulationCode {
void InstructionSet$142(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$26
package mars.mips.instructions;
synchronized class InstructionSet$26 implements SimulationCode {
void InstructionSet$26(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$63
package mars.mips.instructions;
synchronized class InstructionSet$63 implements SimulationCode {
void InstructionSet$63(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$87
package mars.mips.instructions;
synchronized class InstructionSet$87 implements SimulationCode {
void InstructionSet$87(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SimulationCode
package mars.mips.instructions;
public abstract interface SimulationCode {
public abstract void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$123
package mars.mips.instructions;
synchronized class InstructionSet$123 implements SimulationCode {
void InstructionSet$123(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$47
package mars.mips.instructions;
synchronized class InstructionSet$47 implements SimulationCode {
void InstructionSet$47(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$83
package mars.mips.instructions;
synchronized class InstructionSet$83 implements SimulationCode {
void InstructionSet$83(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$43
package mars.mips.instructions;
synchronized class InstructionSet$43 implements SimulationCode {
void InstructionSet$43(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$127
package mars.mips.instructions;
synchronized class InstructionSet$127 implements SimulationCode {
void InstructionSet$127(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$22
package mars.mips.instructions;
synchronized class InstructionSet$22 implements SimulationCode {
void InstructionSet$22(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$67
package mars.mips.instructions;
synchronized class InstructionSet$67 implements SimulationCode {
void InstructionSet$67(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$103
package mars.mips.instructions;
synchronized class InstructionSet$103 implements SimulationCode {
void InstructionSet$103(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$146
package mars.mips.instructions;
synchronized class InstructionSet$146 implements SimulationCode {
void InstructionSet$146(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$8
package mars.mips.instructions;
synchronized class InstructionSet$8 implements SimulationCode {
void InstructionSet$8(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
BasicInstruction
package mars.mips.instructions;
public synchronized class BasicInstruction extends Instruction {
private String instructionName;
private BasicInstructionFormat instructionFormat;
private String operationMask;
private SimulationCode simulationCode;
private int opcodeMask;
private int opcodeMatch;
public void BasicInstruction(String, String, BasicInstructionFormat, String, SimulationCode);
public void BasicInstruction(String, BasicInstructionFormat, String, SimulationCode);
public String getOperationMask();
public BasicInstructionFormat getInstructionFormat();
public SimulationCode getSimulationCode();
public int getOpcodeMask();
public int getOpcodeMatch();
}
InstructionSet$58
package mars.mips.instructions;
synchronized class InstructionSet$58 implements SimulationCode {
void InstructionSet$58(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Instruction
package mars.mips.instructions;
public abstract synchronized class Instruction {
public static final int INSTRUCTION_LENGTH = 4;
public static final int INSTRUCTION_LENGTH_BITS = 32;
public static char[] operandMask;
protected String mnemonic;
protected String exampleFormat;
protected String description;
protected mars.assembler.TokenList tokenList;
public void Instruction();
public String getName();
public String getExampleFormat();
public String getDescription();
public mars.assembler.TokenList getTokenList();
public int getInstructionLength();
protected String extractOperator(String);
protected void createExampleTokenList();
static void
}
InstructionSet$20
package mars.mips.instructions;
synchronized class InstructionSet$20 implements SimulationCode {
void InstructionSet$20(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$65
package mars.mips.instructions;
synchronized class InstructionSet$65 implements SimulationCode {
void InstructionSet$65(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$98
package mars.mips.instructions;
synchronized class InstructionSet$98 implements SimulationCode {
void InstructionSet$98(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$101
package mars.mips.instructions;
synchronized class InstructionSet$101 implements SimulationCode {
void InstructionSet$101(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$144
package mars.mips.instructions;
synchronized class InstructionSet$144 implements SimulationCode {
void InstructionSet$144(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$41
package mars.mips.instructions;
synchronized class InstructionSet$41 implements SimulationCode {
void InstructionSet$41(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$125
package mars.mips.instructions;
synchronized class InstructionSet$125 implements SimulationCode {
void InstructionSet$125(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$118
package mars.mips.instructions;
synchronized class InstructionSet$118 implements SimulationCode {
void InstructionSet$118(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$39
package mars.mips.instructions;
synchronized class InstructionSet$39 implements SimulationCode {
void InstructionSet$39(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$81
package mars.mips.instructions;
synchronized class InstructionSet$81 implements SimulationCode {
void InstructionSet$81(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$151
package mars.mips.instructions;
synchronized class InstructionSet$151 implements SimulationCode {
void InstructionSet$151(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$114
package mars.mips.instructions;
synchronized class InstructionSet$114 implements SimulationCode {
void InstructionSet$114(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$70
package mars.mips.instructions;
synchronized class InstructionSet$70 implements SimulationCode {
void InstructionSet$70(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$35
package mars.mips.instructions;
synchronized class InstructionSet$35 implements SimulationCode {
void InstructionSet$35(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$129
package mars.mips.instructions;
synchronized class InstructionSet$129 implements SimulationCode {
void InstructionSet$129(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$69
package mars.mips.instructions;
synchronized class InstructionSet$69 implements SimulationCode {
void InstructionSet$69(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$94
package mars.mips.instructions;
synchronized class InstructionSet$94 implements SimulationCode {
void InstructionSet$94(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$6
package mars.mips.instructions;
synchronized class InstructionSet$6 implements SimulationCode {
void InstructionSet$6(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$148
package mars.mips.instructions;
synchronized class InstructionSet$148 implements SimulationCode {
void InstructionSet$148(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$130
package mars.mips.instructions;
synchronized class InstructionSet$130 implements SimulationCode {
void InstructionSet$130(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$54
package mars.mips.instructions;
synchronized class InstructionSet$54 implements SimulationCode {
void InstructionSet$54(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$11
package mars.mips.instructions;
synchronized class InstructionSet$11 implements SimulationCode {
void InstructionSet$11(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$132
package mars.mips.instructions;
synchronized class InstructionSet$132 implements SimulationCode {
void InstructionSet$132(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$56
package mars.mips.instructions;
synchronized class InstructionSet$56 implements SimulationCode {
void InstructionSet$56(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$13
package mars.mips.instructions;
synchronized class InstructionSet$13 implements SimulationCode {
void InstructionSet$13(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$96
package mars.mips.instructions;
synchronized class InstructionSet$96 implements SimulationCode {
void InstructionSet$96(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$4
package mars.mips.instructions;
synchronized class InstructionSet$4 implements SimulationCode {
void InstructionSet$4(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$153
package mars.mips.instructions;
synchronized class InstructionSet$153 implements SimulationCode {
void InstructionSet$153(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$116
package mars.mips.instructions;
synchronized class InstructionSet$116 implements SimulationCode {
void InstructionSet$116(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$72
package mars.mips.instructions;
synchronized class InstructionSet$72 implements SimulationCode {
void InstructionSet$72(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$37
package mars.mips.instructions;
synchronized class InstructionSet$37 implements SimulationCode {
void InstructionSet$37(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$MatchMap
package mars.mips.instructions;
synchronized class InstructionSet$MatchMap implements Comparable {
private int mask;
private int maskLength;
private java.util.HashMap matchMap;
public void InstructionSet$MatchMap(int, java.util.HashMap);
public boolean equals(Object);
public int compareTo(Object);
public BasicInstruction find(int);
}
InstructionSet$76
package mars.mips.instructions;
synchronized class InstructionSet$76 implements SimulationCode {
void InstructionSet$76(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$33
package mars.mips.instructions;
synchronized class InstructionSet$33 implements SimulationCode {
void InstructionSet$33(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$112
package mars.mips.instructions;
synchronized class InstructionSet$112 implements SimulationCode {
void InstructionSet$112(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$52
package mars.mips.instructions;
synchronized class InstructionSet$52 implements SimulationCode {
void InstructionSet$52(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$17
package mars.mips.instructions;
synchronized class InstructionSet$17 implements SimulationCode {
void InstructionSet$17(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$136
package mars.mips.instructions;
synchronized class InstructionSet$136 implements SimulationCode {
void InstructionSet$136(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$92
package mars.mips.instructions;
synchronized class InstructionSet$92 implements SimulationCode {
void InstructionSet$92(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$109
package mars.mips.instructions;
synchronized class InstructionSet$109 implements SimulationCode {
void InstructionSet$109(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$2
package mars.mips.instructions;
synchronized class InstructionSet$2 implements SimulationCode {
void InstructionSet$2(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$90
package mars.mips.instructions;
synchronized class InstructionSet$90 implements SimulationCode {
void InstructionSet$90(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$28
package mars.mips.instructions;
synchronized class InstructionSet$28 implements SimulationCode {
void InstructionSet$28(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$50
package mars.mips.instructions;
synchronized class InstructionSet$50 implements SimulationCode {
void InstructionSet$50(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$15
package mars.mips.instructions;
synchronized class InstructionSet$15 implements SimulationCode {
void InstructionSet$15(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$134
package mars.mips.instructions;
synchronized class InstructionSet$134 implements SimulationCode {
void InstructionSet$134(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet
package mars.mips.instructions;
public synchronized class InstructionSet {
private java.util.ArrayList instructionList;
private java.util.ArrayList opcodeMatchMaps;
private SyscallLoader syscallLoader;
public void InstructionSet();
public java.util.ArrayList getInstructionList();
public void populate();
public BasicInstruction findByBinaryCode(int);
private void addPseudoInstructions();
public java.util.ArrayList matchOperator(String);
public java.util.ArrayList prefixMatchOperator(String);
private void findAndSimulateSyscall(int, mars.ProgramStatement) throws mars.ProcessingException;
private void processBranch(int);
private void processJump(int);
private void processReturnAddress(int);
}
InstructionSet$89
package mars.mips.instructions;
synchronized class InstructionSet$89 implements SimulationCode {
void InstructionSet$89(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$74
package mars.mips.instructions;
synchronized class InstructionSet$74 implements SimulationCode {
void InstructionSet$74(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$31
package mars.mips.instructions;
synchronized class InstructionSet$31 implements SimulationCode {
void InstructionSet$31(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$155
package mars.mips.instructions;
synchronized class InstructionSet$155 implements SimulationCode {
void InstructionSet$155(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$110
package mars.mips.instructions;
synchronized class InstructionSet$110 implements SimulationCode {
void InstructionSet$110(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$49
package mars.mips.instructions;
synchronized class InstructionSet$49 implements SimulationCode {
void InstructionSet$49(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$5
package mars.mips.instructions;
synchronized class InstructionSet$5 implements SimulationCode {
void InstructionSet$5(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$97
package mars.mips.instructions;
synchronized class InstructionSet$97 implements SimulationCode {
void InstructionSet$97(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$12
package mars.mips.instructions;
synchronized class InstructionSet$12 implements SimulationCode {
void InstructionSet$12(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$57
package mars.mips.instructions;
synchronized class InstructionSet$57 implements SimulationCode {
void InstructionSet$57(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$133
package mars.mips.instructions;
synchronized class InstructionSet$133 implements SimulationCode {
void InstructionSet$133(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$36
package mars.mips.instructions;
synchronized class InstructionSet$36 implements SimulationCode {
void InstructionSet$36(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$73
package mars.mips.instructions;
synchronized class InstructionSet$73 implements SimulationCode {
void InstructionSet$73(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$117
package mars.mips.instructions;
synchronized class InstructionSet$117 implements SimulationCode {
void InstructionSet$117(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$152
package mars.mips.instructions;
synchronized class InstructionSet$152 implements SimulationCode {
void InstructionSet$152(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$128
package mars.mips.instructions;
synchronized class InstructionSet$128 implements SimulationCode {
void InstructionSet$128(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$34
package mars.mips.instructions;
synchronized class InstructionSet$34 implements SimulationCode {
void InstructionSet$34(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$71
package mars.mips.instructions;
synchronized class InstructionSet$71 implements SimulationCode {
void InstructionSet$71(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$115
package mars.mips.instructions;
synchronized class InstructionSet$115 implements SimulationCode {
void InstructionSet$115(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$150
package mars.mips.instructions;
synchronized class InstructionSet$150 implements SimulationCode {
void InstructionSet$150(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$10
package mars.mips.instructions;
synchronized class InstructionSet$10 implements SimulationCode {
void InstructionSet$10(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$55
package mars.mips.instructions;
synchronized class InstructionSet$55 implements SimulationCode {
void InstructionSet$55(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$131
package mars.mips.instructions;
synchronized class InstructionSet$131 implements SimulationCode {
void InstructionSet$131(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$7
package mars.mips.instructions;
synchronized class InstructionSet$7 implements SimulationCode {
void InstructionSet$7(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$149
package mars.mips.instructions;
synchronized class InstructionSet$149 implements SimulationCode {
void InstructionSet$149(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$68
package mars.mips.instructions;
synchronized class InstructionSet$68 implements SimulationCode {
void InstructionSet$68(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$95
package mars.mips.instructions;
synchronized class InstructionSet$95 implements SimulationCode {
void InstructionSet$95(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$135
package mars.mips.instructions;
synchronized class InstructionSet$135 implements SimulationCode {
void InstructionSet$135(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$14
package mars.mips.instructions;
synchronized class InstructionSet$14 implements SimulationCode {
void InstructionSet$14(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$51
package mars.mips.instructions;
synchronized class InstructionSet$51 implements SimulationCode {
void InstructionSet$51(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$91
package mars.mips.instructions;
synchronized class InstructionSet$91 implements SimulationCode {
void InstructionSet$91(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$29
package mars.mips.instructions;
synchronized class InstructionSet$29 implements SimulationCode {
void InstructionSet$29(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$108
package mars.mips.instructions;
synchronized class InstructionSet$108 implements SimulationCode {
void InstructionSet$108(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$3
package mars.mips.instructions;
synchronized class InstructionSet$3 implements SimulationCode {
void InstructionSet$3(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$48
package mars.mips.instructions;
synchronized class InstructionSet$48 implements SimulationCode {
void InstructionSet$48(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$111
package mars.mips.instructions;
synchronized class InstructionSet$111 implements SimulationCode {
void InstructionSet$111(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$154
package mars.mips.instructions;
synchronized class InstructionSet$154 implements SimulationCode {
void InstructionSet$154(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$88
package mars.mips.instructions;
synchronized class InstructionSet$88 implements SimulationCode {
void InstructionSet$88(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$30
package mars.mips.instructions;
synchronized class InstructionSet$30 implements SimulationCode {
void InstructionSet$30(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$75
package mars.mips.instructions;
synchronized class InstructionSet$75 implements SimulationCode {
void InstructionSet$75(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$113
package mars.mips.instructions;
synchronized class InstructionSet$113 implements SimulationCode {
void InstructionSet$113(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$32
package mars.mips.instructions;
synchronized class InstructionSet$32 implements SimulationCode {
void InstructionSet$32(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$77
package mars.mips.instructions;
synchronized class InstructionSet$77 implements SimulationCode {
void InstructionSet$77(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallInputDialogDouble
package mars.mips.instructions.syscalls;
public synchronized class SyscallInputDialogDouble extends AbstractSyscall {
public void SyscallInputDialogDouble();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallClose
package mars.mips.instructions.syscalls;
public synchronized class SyscallClose extends AbstractSyscall {
public void SyscallClose();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallRandInt
package mars.mips.instructions.syscalls;
public synchronized class SyscallRandInt extends AbstractSyscall {
public void SyscallRandInt();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall101GameRefreshScreen
package mars.mips.instructions.syscalls;
public synchronized class Syscall101GameRefreshScreen extends AbstractSyscall {
public void Syscall101GameRefreshScreen();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallMidiOutSync
package mars.mips.instructions.syscalls;
public synchronized class SyscallMidiOutSync extends AbstractSyscall {
static final int rangeLowEnd = 0;
static final int rangeHighEnd = 127;
public void SyscallMidiOutSync();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallReadInt
package mars.mips.instructions.syscalls;
public synchronized class SyscallReadInt extends AbstractSyscall {
public void SyscallReadInt();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallSbrk
package mars.mips.instructions.syscalls;
public synchronized class SyscallSbrk extends AbstractSyscall {
public void SyscallSbrk();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallPrintString
package mars.mips.instructions.syscalls;
public synchronized class SyscallPrintString extends AbstractSyscall {
public void SyscallPrintString();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall
package mars.mips.instructions.syscalls;
public abstract interface Syscall {
public abstract String getName();
public abstract void setNumber(int);
public abstract int getNumber();
public abstract void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallMessageDialogString
package mars.mips.instructions.syscalls;
public synchronized class SyscallMessageDialogString extends AbstractSyscall {
public void SyscallMessageDialogString();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallWrite
package mars.mips.instructions.syscalls;
public synchronized class SyscallWrite extends AbstractSyscall {
public void SyscallWrite();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallConfirmDialog
package mars.mips.instructions.syscalls;
public synchronized class SyscallConfirmDialog extends AbstractSyscall {
public void SyscallConfirmDialog();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall100CreateGame
package mars.mips.instructions.syscalls;
public synchronized class Syscall100CreateGame extends AbstractSyscall {
public void Syscall100CreateGame();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall107ChangeObjectDirection
package mars.mips.instructions.syscalls;
public synchronized class Syscall107ChangeObjectDirection extends AbstractSyscall {
public void Syscall107ChangeObjectDirection();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallMidiOut
package mars.mips.instructions.syscalls;
public synchronized class SyscallMidiOut extends AbstractSyscall {
static final int rangeLowEnd = 0;
static final int rangeHighEnd = 127;
public void SyscallMidiOut();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallTime
package mars.mips.instructions.syscalls;
public synchronized class SyscallTime extends AbstractSyscall {
public void SyscallTime();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallReadString
package mars.mips.instructions.syscalls;
public synchronized class SyscallReadString extends AbstractSyscall {
public void SyscallReadString();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall106GameGetObjLocation
package mars.mips.instructions.syscalls;
public synchronized class Syscall106GameGetObjLocation extends AbstractSyscall {
public void Syscall106GameGetObjLocation();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
AbstractSyscall
package mars.mips.instructions.syscalls;
public abstract synchronized class AbstractSyscall implements Syscall {
private int serviceNumber;
private String serviceName;
public void AbstractSyscall(int, String);
public String getName();
public void setNumber(int);
public int getNumber();
public abstract void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallRandFloat
package mars.mips.instructions.syscalls;
public synchronized class SyscallRandFloat extends AbstractSyscall {
public void SyscallRandFloat();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallReadChar
package mars.mips.instructions.syscalls;
public synchronized class SyscallReadChar extends AbstractSyscall {
public void SyscallReadChar();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall105CreateGameText
package mars.mips.instructions.syscalls;
public synchronized class Syscall105CreateGameText extends AbstractSyscall {
public void Syscall105CreateGameText();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
EndOfTrackListener
package mars.mips.instructions.syscalls;
synchronized class EndOfTrackListener implements javax.sound.midi.MetaEventListener {
private boolean endedYet;
void EndOfTrackListener();
public synchronized void meta(javax.sound.midi.MetaMessage);
public synchronized void awaitEndOfTrack() throws InterruptedException;
}
Tone
package mars.mips.instructions.syscalls;
synchronized class Tone implements Runnable {
public static final int TEMPO = 1000;
public static final int DEFAULT_CHANNEL = 0;
private byte pitch;
private int duration;
private byte instrument;
private byte volume;
private static java.util.concurrent.locks.Lock openLock;
public void Tone(byte, int, byte, byte);
public void run();
private void playTone();
static void
}
SyscallPrintChar
package mars.mips.instructions.syscalls;
public synchronized class SyscallPrintChar extends AbstractSyscall {
public void SyscallPrintChar();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall103CreateGameObject
package mars.mips.instructions.syscalls;
public synchronized class Syscall103CreateGameObject extends AbstractSyscall {
public void Syscall103CreateGameObject();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallReadDouble
package mars.mips.instructions.syscalls;
public synchronized class SyscallReadDouble extends AbstractSyscall {
public void SyscallReadDouble();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallMessageDialog
package mars.mips.instructions.syscalls;
public synchronized class SyscallMessageDialog extends AbstractSyscall {
public void SyscallMessageDialog();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallInputDialogString
package mars.mips.instructions.syscalls;
public synchronized class SyscallInputDialogString extends AbstractSyscall {
public void SyscallInputDialogString();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallRandIntRange
package mars.mips.instructions.syscalls;
public synchronized class SyscallRandIntRange extends AbstractSyscall {
public void SyscallRandIntRange();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallSleep
package mars.mips.instructions.syscalls;
public synchronized class SyscallSleep extends AbstractSyscall {
public void SyscallSleep();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallPrintIntUnsigned
package mars.mips.instructions.syscalls;
public synchronized class SyscallPrintIntUnsigned extends AbstractSyscall {
public void SyscallPrintIntUnsigned();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallPrintDouble
package mars.mips.instructions.syscalls;
public synchronized class SyscallPrintDouble extends AbstractSyscall {
public void SyscallPrintDouble();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall102GamePlaySound
package mars.mips.instructions.syscalls;
public synchronized class Syscall102GamePlaySound extends AbstractSyscall {
public void Syscall102GamePlaySound();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallPrintInt
package mars.mips.instructions.syscalls;
public synchronized class SyscallPrintInt extends AbstractSyscall {
public void SyscallPrintInt();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallRandSeed
package mars.mips.instructions.syscalls;
public synchronized class SyscallRandSeed extends AbstractSyscall {
public void SyscallRandSeed();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallGameHelper
package mars.mips.instructions.syscalls;
public final synchronized class SyscallGameHelper {
public void SyscallGameHelper();
public static String getStringFromMIPS(int);
public static int getIntFromMIPS(int, int);
public static int setIntToMIPS(int, int, int);
}
SyscallMessageDialogDouble
package mars.mips.instructions.syscalls;
public synchronized class SyscallMessageDialogDouble extends AbstractSyscall {
public void SyscallMessageDialogDouble();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall112EnemyShoot
package mars.mips.instructions.syscalls;
public synchronized class Syscall112EnemyShoot extends AbstractSyscall {
public void Syscall112EnemyShoot();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
public void bulletCrash(mars.ext.game.MazeGameObject, mars.ext.game.MazeGameObject);
static void
}
Syscall111HitEnemy
package mars.mips.instructions.syscalls;
public synchronized class Syscall111HitEnemy extends AbstractSyscall {
public void Syscall111HitEnemy();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallPrintFloat
package mars.mips.instructions.syscalls;
public synchronized class SyscallPrintFloat extends AbstractSyscall {
public void SyscallPrintFloat();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
ToneGenerator
package mars.mips.instructions.syscalls;
synchronized class ToneGenerator {
public static final byte DEFAULT_PITCH = 60;
public static final int DEFAULT_DURATION = 1000;
public static final byte DEFAULT_INSTRUMENT = 0;
public static final byte DEFAULT_VOLUME = 100;
private static java.util.concurrent.Executor threadPool;
void ToneGenerator();
public void generateTone(byte, int, byte, byte);
public void generateToneSynchronously(byte, int, byte, byte);
static void
}
RandomStreams
package mars.mips.instructions.syscalls;
public synchronized class RandomStreams {
static final java.util.HashMap randomStreams;
public void RandomStreams();
static void
}
SyscallExit
package mars.mips.instructions.syscalls;
public synchronized class SyscallExit extends AbstractSyscall {
public void SyscallExit();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall108CreateEnemies
package mars.mips.instructions.syscalls;
public synchronized class Syscall108CreateEnemies extends AbstractSyscall {
public void Syscall108CreateEnemies();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallExit2
package mars.mips.instructions.syscalls;
public synchronized class SyscallExit2 extends AbstractSyscall {
public void SyscallExit2();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallPrintIntHex
package mars.mips.instructions.syscalls;
public synchronized class SyscallPrintIntHex extends AbstractSyscall {
public void SyscallPrintIntHex();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall104GameSetObjLocation
package mars.mips.instructions.syscalls;
public synchronized class Syscall104GameSetObjLocation extends AbstractSyscall {
public void Syscall104GameSetObjLocation();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallMessageDialogInt
package mars.mips.instructions.syscalls;
public synchronized class SyscallMessageDialogInt extends AbstractSyscall {
public void SyscallMessageDialogInt();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallRandDouble
package mars.mips.instructions.syscalls;
public synchronized class SyscallRandDouble extends AbstractSyscall {
public void SyscallRandDouble();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
Syscall110HitBrick
package mars.mips.instructions.syscalls;
public synchronized class Syscall110HitBrick extends AbstractSyscall {
public void Syscall110HitBrick();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallOpen
package mars.mips.instructions.syscalls;
public synchronized class SyscallOpen extends AbstractSyscall {
public void SyscallOpen();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallMessageDialogFloat
package mars.mips.instructions.syscalls;
public synchronized class SyscallMessageDialogFloat extends AbstractSyscall {
public void SyscallMessageDialogFloat();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallPrintIntBinary
package mars.mips.instructions.syscalls;
public synchronized class SyscallPrintIntBinary extends AbstractSyscall {
public void SyscallPrintIntBinary();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallReadFloat
package mars.mips.instructions.syscalls;
public synchronized class SyscallReadFloat extends AbstractSyscall {
public void SyscallReadFloat();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallInputDialogInt
package mars.mips.instructions.syscalls;
public synchronized class SyscallInputDialogInt extends AbstractSyscall {
public void SyscallInputDialogInt();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallInputDialogFloat
package mars.mips.instructions.syscalls;
public synchronized class SyscallInputDialogFloat extends AbstractSyscall {
public void SyscallInputDialogFloat();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallRead
package mars.mips.instructions.syscalls;
public synchronized class SyscallRead extends AbstractSyscall {
public void SyscallRead();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
SyscallNumberOverride
package mars.mips.instructions.syscalls;
public synchronized class SyscallNumberOverride {
private String serviceName;
private int newServiceNumber;
public void SyscallNumberOverride(String, String);
public String getName();
public int getNumber();
}
Syscall109EnemyMove
package mars.mips.instructions.syscalls;
public synchronized class Syscall109EnemyMove extends AbstractSyscall {
public void Syscall109EnemyMove();
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$93
package mars.mips.instructions;
synchronized class InstructionSet$93 implements SimulationCode {
void InstructionSet$93(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$1
package mars.mips.instructions;
synchronized class InstructionSet$1 implements SimulationCode {
void InstructionSet$1(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$137
package mars.mips.instructions;
synchronized class InstructionSet$137 implements SimulationCode {
void InstructionSet$137(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$16
package mars.mips.instructions;
synchronized class InstructionSet$16 implements SimulationCode {
void InstructionSet$16(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
InstructionSet$53
package mars.mips.instructions;
synchronized class InstructionSet$53 implements SimulationCode {
void InstructionSet$53(InstructionSet);
public void simulate(mars.ProgramStatement) throws mars.ProcessingException;
}
AccessNotice
package mars.mips.hardware;
public abstract synchronized class AccessNotice {
public static final int READ = 0;
public static final int WRITE = 1;
private int accessType;
private Thread thread;
protected void AccessNotice(int);
public int getAccessType();
public Thread getThread();
public boolean accessIsFromGUI();
public boolean accessIsFromMIPS();
}
MemoryAccessNotice
package mars.mips.hardware;
public synchronized class MemoryAccessNotice extends AccessNotice {
private int address;
private int length;
private int value;
void MemoryAccessNotice(int, int, int, int);
public void MemoryAccessNotice(int, int, int);
public int getAddress();
public int getLength();
public int getValue();
public String toString();
}
Coprocessor0
package mars.mips.hardware;
public synchronized class Coprocessor0 {
public static final int VADDR = 8;
public static final int STATUS = 12;
public static final int CAUSE = 13;
public static final int EPC = 14;
public static final int EXCEPTION_LEVEL = 1;
public static final int DEFAULT_STATUS_VALUE = 65297;
private static Register[] registers;
public void Coprocessor0();
public static void showRegisters();
public static int updateRegister(String, int);
public static int updateRegister(int, int);
public static int getValue(int);
public static int getNumber(String);
public static Register[] getRegisters();
public static int getRegisterPosition(Register);
public static Register getRegister(String);
public static void resetRegisters();
public static void addRegistersObserver(java.util.Observer);
public static void deleteRegistersObserver(java.util.Observer);
static void
}
RegisterFile
package mars.mips.hardware;
public synchronized class RegisterFile {
public static final int GLOBAL_POINTER_REGISTER = 28;
public static final int STACK_POINTER_REGISTER = 29;
private static Register[] regFile;
private static Register programCounter;
private static Register hi;
private static Register lo;
public void RegisterFile();
public static void showRegisters();
public static int updateRegister(int, int);
public static void updateRegister(String, int);
public static int getValue(int);
public static int getNumber(String);
public static Register[] getRegisters();
public static Register getUserRegister(String);
public static void initializeProgramCounter(int);
public static void initializeProgramCounter(boolean);
public static int setProgramCounter(int);
public static int getProgramCounter();
public static Register getProgramCounterRegister();
public static int getInitialProgramCounter();
public static void resetRegisters();
public static void incrementPC();
public static void addRegistersObserver(java.util.Observer);
public static void deleteRegistersObserver(java.util.Observer);
static void
}
Register
package mars.mips.hardware;
public synchronized class Register extends java.util.Observable {
private String name;
private int number;
private int resetValue;
private volatile int value;
public void Register(String, int, int);
public String getName();
public synchronized int getValue();
public synchronized int getValueNoNotify();
public int getResetValue();
public int getNumber();
public synchronized int setValue(int);
public synchronized void resetValue();
public synchronized void changeResetValue(int);
private void notifyAnyObservers(int);
}
MemoryConfigurations
package mars.mips.hardware;
public synchronized class MemoryConfigurations {
private static java.util.ArrayList configurations;
private static MemoryConfiguration defaultConfiguration;
private static MemoryConfiguration currentConfiguration;
private static final String[] configurationItemNames;
private static int[] defaultConfigurationItemValues;
private static int[] dataBasedCompactConfigurationItemValues;
private static int[] textBasedCompactConfigurationItemValues;
public void MemoryConfigurations();
public static void buildConfigurationCollection();
public static java.util.Iterator getConfigurationsIterator();
public static MemoryConfiguration getConfigurationByName(String);
public static MemoryConfiguration getDefaultConfiguration();
public static MemoryConfiguration getCurrentConfiguration();
public static boolean setCurrentConfiguration(MemoryConfiguration);
public static int getDefaultTextBaseAddress();
public static int getDefaultDataSegmentBaseAddress();
public static int getDefaultExternBaseAddress();
public static int getDefaultGlobalPointer();
public static int getDefaultDataBaseAddress();
public static int getDefaultHeapBaseAddress();
public static int getDefaultStackPointer();
public static int getDefaultStackBaseAddress();
public static int getDefaultUserHighAddress();
public static int getDefaultKernelBaseAddress();
public static int getDefaultKernelTextBaseAddress();
public static int getDefaultExceptionHandlerAddress();
public static int getDefaultKernelDataBaseAddress();
public static int getDefaultMemoryMapBaseAddress();
public static int getDefaultKernelHighAddress();
public int getDefaultDataSegmentLimitAddress();
public int getDefaultTextLimitAddress();
public int getDefaultKernelDataSegmentLimitAddress();
public int getDefaultKernelTextLimitAddress();
public int getDefaultStackLimitAddress();
public int getMemoryMapLimitAddress();
static void
}
Coprocessor1
package mars.mips.hardware;
public synchronized class Coprocessor1 {
private static Register[] registers;
private static Register condition;
private static int numConditionFlags;
public void Coprocessor1();
public static void showRegisters();
public static void setRegisterToFloat(String, float);
public static void setRegisterToFloat(int, float);
public static void setRegisterToInt(String, int);
public static void setRegisterToInt(int, int);
public static void setRegisterPairToDouble(int, double) throws InvalidRegisterAccessException;
public static void setRegisterPairToDouble(String, double) throws InvalidRegisterAccessException;
public static void setRegisterPairToLong(int, long) throws InvalidRegisterAccessException;
public static void setRegisterPairToLong(String, long) throws InvalidRegisterAccessException;
public static float getFloatFromRegister(int);
public static float getFloatFromRegister(String);
public static int getIntFromRegister(int);
public static int getIntFromRegister(String);
public static double getDoubleFromRegisterPair(int) throws InvalidRegisterAccessException;
public static double getDoubleFromRegisterPair(String) throws InvalidRegisterAccessException;
public static long getLongFromRegisterPair(int) throws InvalidRegisterAccessException;
public static long getLongFromRegisterPair(String) throws InvalidRegisterAccessException;
public static int updateRegister(int, int);
public static int getValue(int);
public static int getRegisterNumber(String);
public static Register[] getRegisters();
public static Register getRegister(String);
public static void resetRegisters();
public static void addRegistersObserver(java.util.Observer);
public static void deleteRegistersObserver(java.util.Observer);
public static int setConditionFlag(int);
public static int clearConditionFlag(int);
public static int getConditionFlag(int);
public static int getConditionFlags();
public static void clearConditionFlags();
public static void setConditionFlags();
public static int getConditionFlagCount();
static void
}
InvalidRegisterAccessException
package mars.mips.hardware;
public synchronized class InvalidRegisterAccessException extends Exception {
private mars.ErrorList errs;
public void InvalidRegisterAccessException();
}
MemoryConfiguration
package mars.mips.hardware;
public synchronized class MemoryConfiguration {
private String configurationIdentifier;
private String configurationName;
private String[] configurationItemNames;
private int[] configurationItemValues;
public void MemoryConfiguration(String, String, String[], int[]);
public String getConfigurationIdentifier();
public String getConfigurationName();
public int[] getConfigurationItemValues();
public String[] getConfigurationItemNames();
public int getTextBaseAddress();
public int getDataSegmentBaseAddress();
public int getExternBaseAddress();
public int getGlobalPointer();
public int getDataBaseAddress();
public int getHeapBaseAddress();
public int getStackPointer();
public int getStackBaseAddress();
public int getUserHighAddress();
public int getKernelBaseAddress();
public int getKernelTextBaseAddress();
public int getExceptionHandlerAddress();
public int getKernelDataBaseAddress();
public int getMemoryMapBaseAddress();
public int getKernelHighAddress();
public int getDataSegmentLimitAddress();
public int getTextLimitAddress();
public int getKernelDataSegmentLimitAddress();
public int getKernelTextLimitAddress();
public int getStackLimitAddress();
public int getMemoryMapLimitAddress();
}
Memory
package mars.mips.hardware;
public synchronized class Memory extends java.util.Observable {
public static int textBaseAddress;
public static int dataSegmentBaseAddress;
public static int externBaseAddress;
public static int globalPointer;
public static int dataBaseAddress;
public static int heapBaseAddress;
public static int stackPointer;
public static int stackBaseAddress;
public static int userHighAddress;
public static int kernelBaseAddress;
public static int kernelTextBaseAddress;
public static int exceptionHandlerAddress;
public static int kernelDataBaseAddress;
public static int memoryMapBaseAddress;
public static int kernelHighAddress;
public static final int WORD_LENGTH_BYTES = 4;
public static final boolean LITTLE_ENDIAN = 1;
public static final boolean BIG_ENDIAN = 0;
private static boolean byteOrder;
public static int heapAddress;
java.util.Collection observables;
private static final int BLOCK_LENGTH_WORDS = 1024;
private static final int BLOCK_TABLE_LENGTH = 1024;
private int[][] dataBlockTable;
private int[][] kernelDataBlockTable;
private int[][] stackBlockTable;
private static final int MMIO_TABLE_LENGTH = 16;
private int[][] memoryMapBlockTable;
private static final int TEXT_BLOCK_LENGTH_WORDS = 1024;
private static final int TEXT_BLOCK_TABLE_LENGTH = 1024;
private mars.ProgramStatement[][] textBlockTable;
private mars.ProgramStatement[][] kernelTextBlockTable;
public static int dataSegmentLimitAddress;
public static int textLimitAddress;
public static int kernelDataSegmentLimitAddress;
public static int kernelTextLimitAddress;
public static int stackLimitAddress;
public static int memoryMapLimitAddress;
private static Memory uniqueMemoryInstance;
private static final boolean STORE = 1;
private static final boolean FETCH = 0;
private void Memory();
public static Memory getInstance();
public void clear();
public static void setConfiguration();
public boolean usingCompactMemoryConfiguration();
private void initialize();
public int allocateBytesFromHeap(int) throws IllegalArgumentException;
public void setByteOrder(boolean);
public boolean getByteOrder();
public int set(int, int, int) throws AddressErrorException;
public int setRawWord(int, int) throws AddressErrorException;
public int setWord(int, int) throws AddressErrorException;
public int setHalf(int, int) throws AddressErrorException;
public int setByte(int, int) throws AddressErrorException;
public double setDouble(int, double) throws AddressErrorException;
public void setStatement(int, mars.ProgramStatement) throws AddressErrorException;
public int get(int, int) throws AddressErrorException;
private int get(int, int, boolean) throws AddressErrorException;
public int getRawWord(int) throws AddressErrorException;
public Integer getRawWordOrNull(int) throws AddressErrorException;
public int getAddressOfFirstNull(int, int) throws AddressErrorException;
public int getWord(int) throws AddressErrorException;
public int getWordNoNotify(int) throws AddressErrorException;
public int getHalf(int) throws AddressErrorException;
public int getByte(int) throws AddressErrorException;
public mars.ProgramStatement getStatement(int) throws AddressErrorException;
public mars.ProgramStatement getStatementNoNotify(int) throws AddressErrorException;
private mars.ProgramStatement getStatement(int, boolean) throws AddressErrorException;
public static boolean wordAligned(int);
public static boolean doublewordAligned(int);
public static int alignToWordBoundary(int);
public static boolean inTextSegment(int);
public static boolean inKernelTextSegment(int);
public static boolean inDataSegment(int);
public static boolean inKernelDataSegment(int);
public static boolean inMemoryMapSegment(int);
public void addObserver(java.util.Observer);
public void addObserver(java.util.Observer, int) throws AddressErrorException;
public void addObserver(java.util.Observer, int, int) throws AddressErrorException;
public int countObservers();
public void deleteObserver(java.util.Observer);
public void deleteObservers();
public void notifyObservers();
public void notifyObservers(Object);
private java.util.Collection getNewMemoryObserversCollection();
private void notifyAnyObservers(int, int, int, int);
private int storeBytesInTable(int[][], int, int, int);
private int fetchBytesFromTable(int[][], int, int);
private synchronized int storeOrFetchBytesInTable(int[][], int, int, int, boolean);
private synchronized int storeWordInTable(int[][], int, int);
private synchronized int fetchWordFromTable(int[][], int);
private synchronized Integer fetchWordOrNullFromTable(int[][], int);
private int replaceByte(int, int, int, int);
private int reverseBytes(int);
private void storeProgramStatement(int, mars.ProgramStatement, int, mars.ProgramStatement[][]);
private mars.ProgramStatement readProgramStatement(int, int, mars.ProgramStatement[][], boolean);
static void
}
Memory$MemoryObservable
package mars.mips.hardware;
synchronized class Memory$MemoryObservable extends java.util.Observable implements Comparable {
private int lowAddress;
private int highAddress;
public void Memory$MemoryObservable(Memory, java.util.Observer, int, int);
public boolean match(int);
public void notifyObserver(MemoryAccessNotice);
public int compareTo(Object);
}
AddressErrorException
package mars.mips.hardware;
public synchronized class AddressErrorException extends Exception {
private int address;
private int type;
public void AddressErrorException(String, int, int);
public int getAddress();
public int getType();
}
RegisterAccessNotice
package mars.mips.hardware;
public synchronized class RegisterAccessNotice extends AccessNotice {
private String registerName;
void RegisterAccessNotice(int, String);
public String getRegisterName();
public String toString();
}
BinaryDumpFormat
package mars.mips.dump;
public synchronized class BinaryDumpFormat extends AbstractDumpFormat {
public void BinaryDumpFormat();
public void dumpMemoryRange(java.io.File, int, int) throws mars.mips.hardware.AddressErrorException, java.io.IOException;
}
AbstractDumpFormat
package mars.mips.dump;
public abstract synchronized class AbstractDumpFormat implements DumpFormat {
private String name;
private String commandDescriptor;
private String description;
private String extension;
public void AbstractDumpFormat(String, String, String, String);
public String getFileExtension();
public String getDescription();
public String toString();
public String getCommandDescriptor();
public abstract void dumpMemoryRange(java.io.File, int, int) throws mars.mips.hardware.AddressErrorException, java.io.IOException;
}
SegmentWindowDumpFormat
package mars.mips.dump;
public synchronized class SegmentWindowDumpFormat extends AbstractDumpFormat {
public void SegmentWindowDumpFormat();
public void dumpMemoryRange(java.io.File, int, int) throws mars.mips.hardware.AddressErrorException, java.io.IOException;
}
AsciiTextDumpFormat
package mars.mips.dump;
public synchronized class AsciiTextDumpFormat extends AbstractDumpFormat {
public void AsciiTextDumpFormat();
public void dumpMemoryRange(java.io.File, int, int) throws mars.mips.hardware.AddressErrorException, java.io.IOException;
}
HexTextDumpFormat
package mars.mips.dump;
public synchronized class HexTextDumpFormat extends AbstractDumpFormat {
public void HexTextDumpFormat();
public void dumpMemoryRange(java.io.File, int, int) throws mars.mips.hardware.AddressErrorException, java.io.IOException;
}
DumpFormat
package mars.mips.dump;
public abstract interface DumpFormat {
public abstract String getFileExtension();
public abstract String getDescription();
public abstract String getCommandDescriptor();
public abstract String toString();
public abstract void dumpMemoryRange(java.io.File, int, int) throws mars.mips.hardware.AddressErrorException, java.io.IOException;
}
BinaryTextDumpFormat
package mars.mips.dump;
public synchronized class BinaryTextDumpFormat extends AbstractDumpFormat {
public void BinaryTextDumpFormat();
public void dumpMemoryRange(java.io.File, int, int) throws mars.mips.hardware.AddressErrorException, java.io.IOException;
}
DumpFormatLoader
package mars.mips.dump;
public synchronized class DumpFormatLoader {
private static final String CLASS_PREFIX = mars.mips.dump.;
private static final String DUMP_DIRECTORY_PATH = mars/mips/dump;
private static final String SYSCALL_INTERFACE = DumpFormat.class;
private static final String CLASS_EXTENSION = class;
private static java.util.ArrayList formatList;
public void DumpFormatLoader();
public java.util.ArrayList loadDumpFormats();
public static DumpFormat findDumpFormatGivenCommandDescriptor(java.util.ArrayList, String);
static void
}
MIFDumpFormat
package mars.mips.dump;
public synchronized class MIFDumpFormat {
public void MIFDumpFormat();
public void dumpMemoryRange(java.io.File, int, int) throws mars.mips.hardware.AddressErrorException, java.io.IOException;
}
IntelHexDumpFormat
package mars.mips.dump;
public synchronized class IntelHexDumpFormat extends AbstractDumpFormat {
public void IntelHexDumpFormat();
public void dumpMemoryRange(java.io.File, int, int) throws mars.mips.hardware.AddressErrorException, java.io.IOException;
}
Globals
package mars;
public synchronized class Globals {
private static String configPropertiesFile;
private static String syscallPropertiesFile;
public static mips.instructions.InstructionSet instructionSet;
public static MIPSprogram program;
public static assembler.SymbolTable symbolTable;
public static mips.hardware.Memory memory;
public static Object memoryAndRegistersLock;
public static boolean debug;
static Settings settings;
public static String userInputAlert;
public static final String imagesPath = /images/;
public static final String helpPath = /help/;
private static boolean initialized;
static venus.VenusUI gui;
public static final String version = 4.5;
public static final java.util.ArrayList fileExtensions;
public static final int maximumMessageCharacters;
public static final int maximumErrorMessages;
public static final int maximumBacksteps;
public static final String copyrightYears;
public static final String copyrightHolders;
public static final String ASCII_NON_PRINT;
public static final String[] ASCII_TABLE;
public static int exitCode;
public static boolean runSpeedPanelExists;
public void Globals();
private static String getCopyrightYears();
private static String getCopyrightHolders();
public static void setGui(venus.VenusUI);
public static venus.VenusUI getGui();
public static Settings getSettings();
public static void initialize(boolean);
private static int getMessageLimit();
private static int getErrorLimit();
private static int getBackstepLimit();
public static String getAsciiNonPrint();
public static String[] getAsciiStrings();
private static int getIntegerProperty(String, String, int);
private static java.util.ArrayList getFileExtensions();
public static java.util.ArrayList getExternalTools();
public static String getPropertyEntry(String, String);
public java.util.ArrayList getSyscallOverrides();
static void
}
MarsSplashScreen$ImageBackgroundPanel
package mars;
synchronized class MarsSplashScreen$ImageBackgroundPanel extends javax.swing.JPanel {
java.awt.Image image;
public void MarsSplashScreen$ImageBackgroundPanel(MarsSplashScreen);
protected void paintComponent(java.awt.Graphics);
}
MIPSprogram
package mars;
public synchronized class MIPSprogram {
private boolean steppedExecution;
private String filename;
private java.util.ArrayList sourceList;
private java.util.ArrayList tokenList;
private java.util.ArrayList parsedList;
private java.util.ArrayList machineList;
private simulator.BackStepper backStepper;
private assembler.SymbolTable localSymbolTable;
private assembler.MacroPool macroPool;
private java.util.ArrayList sourceLineList;
private assembler.Tokenizer tokenizer;
public void MIPSprogram();
public java.util.ArrayList getSourceList();
public void setSourceLineList(java.util.ArrayList);
public java.util.ArrayList getSourceLineList();
public String getFilename();
public java.util.ArrayList getTokenList();
public assembler.Tokenizer getTokenizer();
public java.util.ArrayList createParsedList();
public java.util.ArrayList getParsedList();
public java.util.ArrayList getMachineList();
public simulator.BackStepper getBackStepper();
public assembler.SymbolTable getLocalSymbolTable();
public boolean backSteppingEnabled();
public String getSourceLine(int);
public void readSource(String) throws ProcessingException;
public void tokenize() throws ProcessingException;
public java.util.ArrayList prepareFilesForAssembly(java.util.ArrayList, String, String) throws ProcessingException;
public ErrorList assemble(java.util.ArrayList, boolean) throws ProcessingException;
public ErrorList assemble(java.util.ArrayList, boolean, boolean) throws ProcessingException;
public boolean simulate(int[]) throws ProcessingException;
public boolean simulate(int) throws ProcessingException;
public boolean simulateFromPC(int[], int, javax.swing.AbstractAction) throws ProcessingException;
public boolean simulateStepAtPC(javax.swing.AbstractAction) throws ProcessingException;
public boolean inSteppedExecution();
public assembler.MacroPool createMacroPool();
public assembler.MacroPool getLocalMacroPool();
public void setLocalMacroPool(assembler.MacroPool);
}
BackStepper
package mars.simulator;
public synchronized class BackStepper {
private static final int MEMORY_RESTORE_RAW_WORD = 0;
private static final int MEMORY_RESTORE_WORD = 1;
private static final int MEMORY_RESTORE_HALF = 2;
private static final int MEMORY_RESTORE_BYTE = 3;
private static final int REGISTER_RESTORE = 4;
private static final int PC_RESTORE = 5;
private static final int COPROC0_REGISTER_RESTORE = 6;
private static final int COPROC1_REGISTER_RESTORE = 7;
private static final int COPROC1_CONDITION_CLEAR = 8;
private static final int COPROC1_CONDITION_SET = 9;
private static final int DO_NOTHING = 10;
private static final int NOT_PC_VALUE = -1;
private boolean engaged;
private BackStepper$BackstepStack backSteps;
public void BackStepper();
public boolean enabled();
public void setEnabled(boolean);
public boolean empty();
public boolean inDelaySlot();
public void backStep();
private int pc();
public int addMemoryRestoreRawWord(int, int);
public int addMemoryRestoreWord(int, int);
public int addMemoryRestoreHalf(int, int);
public int addMemoryRestoreByte(int, int);
public int addRegisterFileRestore(int, int);
public int addPCRestore(int);
public int addCoprocessor0Restore(int, int);
public int addCoprocessor1Restore(int, int);
public int addConditionFlagSet(int);
public int addConditionFlagClear(int);
public int addDoNothing(int);
}
Simulator
package mars.simulator;
public synchronized class Simulator extends java.util.Observable {
private Simulator$SimThread simulatorThread;
private static Simulator simulator;
private static Runnable interactiveGUIUpdater;
public static final int NO_DEVICE = 0;
public static volatile int externalInterruptingDevice;
public static final int BREAKPOINT = 1;
public static final int EXCEPTION = 2;
public static final int MAX_STEPS = 3;
public static final int NORMAL_TERMINATION = 4;
public static final int CLIFF_TERMINATION = 5;
public static final int PAUSE_OR_STOP = 6;
private java.util.ArrayList stopListeners;
public static Simulator getInstance();
private void Simulator();
public static boolean inDelaySlot();
public boolean simulate(mars.MIPSprogram, int, int, int[], javax.swing.AbstractAction) throws mars.ProcessingException;
public void stopExecution(javax.swing.AbstractAction);
public void addStopListener(Simulator$StopListener);
public void removeStopListener(Simulator$StopListener);
private void notifyObserversOfExecutionStart(int, int);
private void notifyObserversOfExecutionStop(int, int);
static void
}
Simulator$SimThread
package mars.simulator;
synchronized class Simulator$SimThread extends SwingWorker {
private mars.MIPSprogram p;
private int pc;
private int maxSteps;
private int[] breakPoints;
private boolean done;
private mars.ProcessingException pe;
private volatile boolean stop;
private volatile javax.swing.AbstractAction stopper;
private javax.swing.AbstractAction starter;
private int constructReturnReason;
void Simulator$SimThread(Simulator, mars.MIPSprogram, int, int, int[], javax.swing.AbstractAction);
public void setStop(javax.swing.AbstractAction);
public Object construct();
public void finished();
}
Simulator$StopListener
package mars.simulator;
public abstract interface Simulator$StopListener {
public abstract void stopped(Simulator);
}
Simulator$1
package mars.simulator;
synchronized class Simulator$1 {
}
SwingWorker$2
package mars.simulator;
synchronized class SwingWorker$2 implements Runnable {
void SwingWorker$2(SwingWorker, boolean, Runnable);
public void run();
}
Exceptions
package mars.simulator;
public synchronized class Exceptions {
public static final int EXTERNAL_INTERRUPT_KEYBOARD = 64;
public static final int EXTERNAL_INTERRUPT_DISPLAY = 128;
public static final int ADDRESS_EXCEPTION_LOAD = 4;
public static final int ADDRESS_EXCEPTION_STORE = 5;
public static final int SYSCALL_EXCEPTION = 8;
public static final int BREAKPOINT_EXCEPTION = 9;
public static final int RESERVED_INSTRUCTION_EXCEPTION = 10;
public static final int ARITHMETIC_OVERFLOW_EXCEPTION = 12;
public static final int TRAP_EXCEPTION = 13;
public static final int DIVIDE_BY_ZERO_EXCEPTION = 15;
public static final int FLOATING_POINT_OVERFLOW = 16;
public static final int FLOATING_POINT_UNDERFLOW = 17;
public void Exceptions();
public static void setRegisters(int);
public static void setRegisters(int, int);
}
DelayedBranch
package mars.simulator;
public synchronized class DelayedBranch {
private static final int CLEARED = 0;
private static final int REGISTERED = 1;
private static final int TRIGGERED = 2;
private static int state;
private static int branchTargetAddress;
public void DelayedBranch();
public static void register(int);
static void trigger();
static void clear();
static boolean isRegistered();
static boolean isTriggered();
static int getBranchTargetAddress();
static void
}
BackStepper$BackstepStack
package mars.simulator;
synchronized class BackStepper$BackstepStack {
private int capacity;
private int size;
private int top;
private BackStepper$BackStep[] stack;
private void BackStepper$BackstepStack(BackStepper, int);
private synchronized boolean empty();
private synchronized void push(int, int, int, int);
private synchronized void push(int, int, int);
private synchronized void push(int, int);
private synchronized BackStepper$BackStep pop();
private synchronized BackStepper$BackStep peek();
}
BackStepper$1
package mars.simulator;
synchronized class BackStepper$1 {
}
SwingWorker$ThreadVar
package mars.simulator;
synchronized class SwingWorker$ThreadVar {
private Thread thread;
void SwingWorker$ThreadVar(Thread);
synchronized Thread get();
synchronized void clear();
}
SwingWorker$1
package mars.simulator;
synchronized class SwingWorker$1 implements Runnable {
void SwingWorker$1(SwingWorker);
public void run();
}
BackStepper$BackStep
package mars.simulator;
synchronized class BackStepper$BackStep {
private int action;
private int pc;
private mars.ProgramStatement ps;
private int param1;
private int param2;
private boolean inDelaySlot;
private void BackStepper$BackStep(BackStepper);
private void assign(int, int, int, int);
}
ProgramArgumentList
package mars.simulator;
public synchronized class ProgramArgumentList {
java.util.ArrayList programArgumentList;
public void ProgramArgumentList(String);
public void ProgramArgumentList(String[]);
public void ProgramArgumentList(String[], int);
public void ProgramArgumentList(java.util.ArrayList);
public void ProgramArgumentList(java.util.ArrayList, int);
public void storeProgramArguments();
}
SwingWorker
package mars.simulator;
public abstract synchronized class SwingWorker {
private Object value;
private SwingWorker$ThreadVar threadVar;
protected synchronized Object getValue();
private synchronized void setValue(Object);
public abstract Object construct();
public void finished();
public void interrupt();
public Object get();
public void SwingWorker(boolean);
public void start();
}
Simulator$UpdateGUI
package mars.simulator;
synchronized class Simulator$UpdateGUI implements Runnable {
private void Simulator$UpdateGUI(Simulator);
public void run();
}
SimulatorNotice
package mars.simulator;
public synchronized class SimulatorNotice {
private int action;
private int maxSteps;
private double runSpeed;
private int programCounter;
public static final int SIMULATOR_START = 0;
public static final int SIMULATOR_STOP = 1;
public void SimulatorNotice(int, int, double, int);
public int getAction();
public int getMaxSteps();
public double getRunSpeed();
public int getProgramCounter();
public String toString();
}
ErrorMessage
package mars;
public synchronized class ErrorMessage {
private boolean isWarning;
private String filename;
private int line;
private int position;
private String message;
private String macroExpansionHistory;
public static final boolean WARNING = 1;
public static final boolean ERROR = 0;
public void ErrorMessage(String, int, int, String);
public void ErrorMessage(String, int, int, String, String);
public void ErrorMessage(boolean, String, int, int, String, String);
public void ErrorMessage(MIPSprogram, int, int, String);
public void ErrorMessage(boolean, MIPSprogram, int, int, String);
public void ErrorMessage(ProgramStatement, String);
private java.util.ArrayList parseMacroHistory(String);
public String getFilename();
public int getLine();
public int getPosition();
public String getMessage();
public boolean isWarning();
public String getMacroExpansionHistory();
private static String getExpansionHistory(MIPSprogram);
}
ProcessingException
package mars;
public synchronized class ProcessingException extends Exception {
private ErrorList errs;
public void ProcessingException(ErrorList);
public void ProcessingException(ErrorList, mips.hardware.AddressErrorException);
public void ProcessingException(ProgramStatement, String);
public void ProcessingException(ProgramStatement, String, int);
public void ProcessingException(ProgramStatement, mips.hardware.AddressErrorException);
public void ProcessingException();
public ErrorList errors();
}
Settings
package mars;
public synchronized class Settings extends java.util.Observable {
private static String settingsFile;
public static final int EXTENDED_ASSEMBLER_ENABLED = 0;
public static final int BARE_MACHINE_ENABLED = 1;
public static final int ASSEMBLE_ON_OPEN_ENABLED = 2;
public static final int ASSEMBLE_ALL_ENABLED = 3;
public static final int LABEL_WINDOW_VISIBILITY = 4;
public static final int DISPLAY_ADDRESSES_IN_HEX = 5;
public static final int DISPLAY_VALUES_IN_HEX = 6;
public static final int EXCEPTION_HANDLER_ENABLED = 7;
public static final int DELAYED_BRANCHING_ENABLED = 8;
public static final int EDITOR_LINE_NUMBERS_DISPLAYED = 9;
public static final int WARNINGS_ARE_ERRORS = 10;
public static final int PROGRAM_ARGUMENTS = 11;
public static final int DATA_SEGMENT_HIGHLIGHTING = 12;
public static final int REGISTERS_HIGHLIGHTING = 13;
public static final int START_AT_MAIN = 14;
public static final int EDITOR_CURRENT_LINE_HIGHLIGHTING = 15;
public static final int POPUP_INSTRUCTION_GUIDANCE = 16;
public static final int POPUP_SYSCALL_INPUT = 17;
public static final int GENERIC_TEXT_EDITOR = 18;
public static final int AUTO_INDENT = 19;
public static final int SELF_MODIFYING_CODE_ENABLED = 20;
private static String[] booleanSettingsKeys;
public static boolean[] defaultBooleanSettingsValues;
public static final int EXCEPTION_HANDLER = 0;
public static final int TEXT_COLUMN_ORDER = 1;
public static final int LABEL_SORT_STATE = 2;
public static final int MEMORY_CONFIGURATION = 3;
public static final int CARET_BLINK_RATE = 4;
public static final int EDITOR_TAB_SIZE = 5;
public static final int EDITOR_POPUP_PREFIX_LENGTH = 6;
private static final String[] stringSettingsKeys;
private static String[] defaultStringSettingsValues;
public static final int EDITOR_FONT = 0;
public static final int EVEN_ROW_FONT = 1;
public static final int ODD_ROW_FONT = 2;
public static final int TEXTSEGMENT_HIGHLIGHT_FONT = 3;
public static final int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FONT = 4;
public static final int DATASEGMENT_HIGHLIGHT_FONT = 5;
public static final int REGISTER_HIGHLIGHT_FONT = 6;
private static final String[] fontFamilySettingsKeys;
private static final String[] fontStyleSettingsKeys;
private static final String[] fontSizeSettingsKeys;
private static final String[] defaultFontFamilySettingsValues;
private static final String[] defaultFontStyleSettingsValues;
private static final String[] defaultFontSizeSettingsValues;
public static final int EVEN_ROW_BACKGROUND = 0;
public static final int EVEN_ROW_FOREGROUND = 1;
public static final int ODD_ROW_BACKGROUND = 2;
public static final int ODD_ROW_FOREGROUND = 3;
public static final int TEXTSEGMENT_HIGHLIGHT_BACKGROUND = 4;
public static final int TEXTSEGMENT_HIGHLIGHT_FOREGROUND = 5;
public static final int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_BACKGROUND = 6;
public static final int TEXTSEGMENT_DELAYSLOT_HIGHLIGHT_FOREGROUND = 7;
public static final int DATASEGMENT_HIGHLIGHT_BACKGROUND = 8;
public static final int DATASEGMENT_HIGHLIGHT_FOREGROUND = 9;
public static final int REGISTER_HIGHLIGHT_BACKGROUND = 10;
public static final int REGISTER_HIGHLIGHT_FOREGROUND = 11;
private static final String[] colorSettingsKeys;
private static String[] defaultColorSettingsValues;
private boolean[] booleanSettingsValues;
private String[] stringSettingsValues;
private String[] fontFamilySettingsValues;
private String[] fontStyleSettingsValues;
private String[] fontSizeSettingsValues;
private String[] colorSettingsValues;
private java.util.prefs.Preferences preferences;
private String[] syntaxStyleColorSettingsValues;
private boolean[] syntaxStyleBoldSettingsValues;
private boolean[] syntaxStyleItalicSettingsValues;
private static final String SYNTAX_STYLE_COLOR_PREFIX = SyntaxStyleColor_;
private static final String SYNTAX_STYLE_BOLD_PREFIX = SyntaxStyleBold_;
private static final String SYNTAX_STYLE_ITALIC_PREFIX = SyntaxStyleItalic_;
private static String[] syntaxStyleColorSettingsKeys;
private static String[] syntaxStyleBoldSettingsKeys;
private static String[] syntaxStyleItalicSettingsKeys;
private static String[] defaultSyntaxStyleColorSettingsValues;
private static boolean[] defaultSyntaxStyleBoldSettingsValues;
private static boolean[] defaultSyntaxStyleItalicSettingsValues;
public void Settings();
public void Settings(boolean);
public boolean getBackSteppingEnabled();
public void reset(boolean);
public void setEditorSyntaxStyleByPosition(int, venus.editors.jeditsyntax.SyntaxStyle);
public venus.editors.jeditsyntax.SyntaxStyle getEditorSyntaxStyleByPosition(int);
public venus.editors.jeditsyntax.SyntaxStyle getDefaultEditorSyntaxStyleByPosition(int);
private void saveEditorSyntaxStyle(int);
private void initializeEditorSyntaxStyles();
private void getEditorSyntaxStyleSettingsFromPreferences();
public boolean getBooleanSetting(int);
public boolean getBareMachineEnabled();
public boolean getExtendedAssemblerEnabled();
public boolean getAssembleOnOpenEnabled();
public boolean getDisplayAddressesInHex();
public boolean getDisplayValuesInHex();
public boolean getAssembleAllEnabled();
public boolean getExceptionHandlerEnabled();
public boolean getDelayedBranchingEnabled();
public boolean getLabelWindowVisibility();
public boolean getEditorLineNumbersDisplayed();
public boolean getWarningsAreErrors();
public boolean getProgramArguments();
public boolean getDataSegmentHighlighting();
public boolean getRegistersHighlighting();
public boolean getStartAtMain();
public String getExceptionHandler();
public String getMemoryConfiguration();
public java.awt.Font getEditorFont();
public java.awt.Font getFontByPosition(int);
public java.awt.Font getDefaultFontByPosition(int);
public int[] getTextColumnOrder();
public int getCaretBlinkRate();
public int getEditorTabSize();
public int getEditorPopupPrefixLength();
public int getDefaultEditorTabSize();
public String getLabelSortState();
public java.awt.Color getColorSettingByKey(String);
public java.awt.Color getDefaultColorSettingByKey(String);
public java.awt.Color getColorSettingByPosition(int);
public java.awt.Color getDefaultColorSettingByPosition(int);
public void setBooleanSetting(int, boolean);
public void setExtendedAssemblerEnabled(boolean);
public void setAssembleOnOpenEnabled(boolean);
public void setAssembleAllEnabled(boolean);
public void setDisplayAddressesInHex(boolean);
public void setDisplayValuesInHex(boolean);
public void setLabelWindowVisibility(boolean);
public void setExceptionHandlerEnabled(boolean);
public void setDelayedBranchingEnabled(boolean);
public void setEditorLineNumbersDisplayed(boolean);
public void setWarningsAreErrors(boolean);
public void setProgramArguments(boolean);
public void setDataSegmentHighlighting(boolean);
public void setRegistersHighlighting(boolean);
public void setStartAtMain(boolean);
public void setBooleanSettingNonPersistent(int, boolean);
public void setDelayedBranchingEnabledNonPersistent(boolean);
public void setExceptionHandler(String);
public void setMemoryConfiguration(String);
public void setCaretBlinkRate(int);
public void setEditorTabSize(int);
public void setEditorPopupPrefixLength(int);
public void setEditorFont(java.awt.Font);
public void setFontByPosition(int, java.awt.Font);
public void setTextColumnOrder(int[]);
public void setLabelSortState(String);
public void setColorSettingByKey(String, java.awt.Color);
public void setColorSettingByPosition(int, java.awt.Color);
private void initialize();
private void applyDefaultSettings();
private void internalSetBooleanSetting(int, boolean);
private void setStringSetting(int, String);
private void setColorSetting(int, java.awt.Color);
private java.awt.Color getColorValueByKey(String, String[]);
private java.awt.Color getColorValueByPosition(int, String[]);
private int getIndexOfKey(String, String[]);
private boolean readSettingsFromPropertiesFile(String);
private void getSettingsFromPreferences();
private void saveBooleanSetting(int);
private void saveStringSetting(int);
private void saveFontSetting(int, String[], String[]);
private void saveColorSetting(int);
private int[] getTextSegmentColumnOrder(String);
static void
}
MarsLaunch$2
package mars;
synchronized class MarsLaunch$2 implements java.util.Observer {
private int lastAddress;
void MarsLaunch$2(MarsLaunch);
public void update(java.util.Observable, Object);
}
ProgramStatement
package mars;
public synchronized class ProgramStatement {
private MIPSprogram sourceMIPSprogram;
private String source;
private String basicAssemblyStatement;
private String machineStatement;
private assembler.TokenList originalTokenList;
private assembler.TokenList strippedTokenList;
private ProgramStatement$BasicStatementList basicStatementList;
private int[] operands;
private int numOperands;
private mips.instructions.Instruction instruction;
private int textAddress;
private int sourceLine;
private int binaryStatement;
private boolean altered;
private static final String invalidOperator =
public void ProgramStatement(MIPSprogram, String, assembler.TokenList, assembler.TokenList, mips.instructions.Instruction, int, int);
public void ProgramStatement(int, int);
public void buildBasicStatementFromBasicInstruction(ErrorList);
public void buildMachineStatementFromBasicStatement(ErrorList);
public String toString();
public void setBasicAssemblyStatement(String);
public void setMachineStatement(String);
public void setBinaryStatement(int);
public void setSource(String);
public MIPSprogram getSourceMIPSprogram();
public String getSourceFile();
public String getSource();
public int getSourceLine();
public String getBasicAssemblyStatement();
public String getPrintableBasicAssemblyStatement();
public String getMachineStatement();
public int getBinaryStatement();
public assembler.TokenList getOriginalTokenList();
public assembler.TokenList getStrippedTokenList();
public mips.instructions.Instruction getInstruction();
public int getAddress();
public int[] getOperands();
public int getOperand(int);
private void insertBinaryCode(int, char, ErrorList);
private ProgramStatement$BasicStatementList buildBasicStatementListFromBinaryCode(int, mips.instructions.BasicInstruction, int[], int);
}
ProgramStatement$BasicStatementList
package mars;
synchronized class ProgramStatement$BasicStatementList {
private java.util.ArrayList list;
void ProgramStatement$BasicStatementList(ProgramStatement);
void addString(String);
void addAddress(int);
void addValue(int);
public String toString();
}
MarsLaunch
package mars;
public synchronized class MarsLaunch {
private boolean simulate;
private int displayFormat;
private boolean verbose;
private boolean assembleProject;
private boolean pseudo;
private boolean delayedBranching;
private boolean warningsAreErrors;
private boolean startAtMain;
private boolean countInstructions;
private boolean selfModifyingCode;
private static final String rangeSeparator = -;
private static final int splashDuration = 2000;
private static final int memoryWordsPerLine = 4;
private static final int DECIMAL = 0;
private static final int HEXADECIMAL = 1;
private static final int ASCII = 2;
private java.util.ArrayList registerDisplayList;
private java.util.ArrayList memoryDisplayList;
private java.util.ArrayList filenameList;
private MIPSprogram code;
private int maxSteps;
private int instructionCount;
private java.io.PrintStream out;
private java.util.ArrayList dumpTriples;
private java.util.ArrayList programArgumentList;
private int assembleErrorExitCode;
private int simulateErrorExitCode;
public void MarsLaunch(String[]);
private void dumpSegments();
private void launchIDE();
private boolean parseCommandArgs(String[]);
private boolean runCommand();
private String[] checkMemoryAddressRange(String) throws NumberFormatException;
private void establishObserver();
private void displayMiscellaneousPostMortem();
private void displayRegistersPostMortem();
private String formatIntForDisplay(int);
private void displayMemoryPostMortem();
private void processDisplayMessagesToErrSwitch(String[], String);
private void displayCopyright(String[], String);
private void displayHelp();
}
MarsLaunch$1
package mars;
synchronized class MarsLaunch$1 implements Runnable {
void MarsLaunch$1(MarsLaunch);
public void run();
}
Macros in MARS
Writing and Using Macros
.macro, .end_macro,.eqv and .include directives are new in MARS 4.3
Introduction to macros
Patterson and Hennessy define a macro as a pattern-matching and replacement facility
that provides a simple mechanism to name a frequently used sequence of instructions [1].
This permits the programmer to specify the instruction sequence by invoking the macro. This requires
only one line of code for each use instead of repeatedly typing
in the instruction sequence each time. It follows the axiom “define once, use many times,” which
not only reduces the chance for error but also facilitates program maintenance.
Macros are like procedures (subroutines) in this sense but operate differently than procedures.
Procedures in MIPS assembly language follow particular protocols for procedure definition, call and return.
Macros operate by substituting the macro body for each use at the time of assembly. This substitution
is called macro expansion.. They do not require the protocols and execution overhead of procedures.
As a simple example, you may want to terminate your program from a number of locations. If you are running
from the MARS IDE, you will use system call 10, exit. The instruction sequence is pretty easy
li $v0,10
syscall
but still tedious. You can define a macro, let’s call it done, to represent this sequence
.macro done
li $v0,10
syscall
.end_macro
then invoke it whenever you wish with the statement
done
At assembly time, the assembler will replace each occurrence of the statement done with the two-statement
sequence
li $v0,10
syscall
This is the macro expansion. The runtime simulator is unaware of macros or macro expansion.
If running MARS from the command line, perhaps you want to return a termination value. This can be done
with syscall 17, exit2, which takes the termination value as an argument. An equivalent macro,
let’s call it terminate would be
.macro terminate (%termination_value)
li $a0, %termination_value
li $v0, 17
syscall
.end_macro
This macro defines a formal parameter to represent the termination value. You would invoke it
with the statement
terminate (1)
to terminate with value 1. Upon assembly,
the statement terminate (1) would be replaced by the three-statement sequence
li $a0, 1
li $v0, 17
syscall
The argument value, 1, is substituted wherever the formal parameter %termination_value appears
in the macro body.
This is a textual substitution. Note that in this example the argument value must be an integer, not a
register name or a label, because the parameter is used as the second operand in the Load Immediate operation.
In MARS, a macro is similar to an extended (pseudo) instruction. They are distinguished in that the expansion of
extended instructions is supported by an internally-defined specification language and mechanism which can manipulate argument values.
The macro facility can only substitute argument values as given, and it uses a separate mechanism from extended instructions.
Additional examples and details follow.
How to define macros
The first line begins with a .macro directive followed by an optional list of formal parameters.
Placing commas between parameters and parentheses around the list is optional.
Each formal parameter is an identifier that begins with a % character. For compatibility with
the SPIM preprocessor APP, it may alternatively begin with $.
The lines that follow define the body of the macro. Use the formal parameters as appropriate. The body
may contain data segments as well as text segments.
The macro definition finishes with a .end_macro directive.
See the Notes below for additional information.
How to use macros
To invoke a macro, form a statement consisting of the macro name and then one token for each argument
to be substituted for its corresponding formal parameter by the assembler.
The argument list may optionally be surrounded by parentheses.
Arguments may be separated either by spaces or commas.
Macro expansion is a pre-processing task for assemblers.
Notes
A macro definition must appear before its use. No forward references.
All macro definitions are local in each file and they cannot be global.
Nested macro definitions are not supported. No .macro directive should appear inside body of a macro definition.
A macro definition can contain a call to a previously-defined macro. Only backward references are allowed.
Labels placed in the body of a macro definition will not have same name after macro expansion.
During expansion, their name will be followed by “_M#” where # will be a unique number for each macro expansion.
Two macros with the same name but different number of parameters are considered different and both can be used.
A macro defined with the same name and same number of parameters as another macro defined before it will be ignored.
Each argument in a macro call can only be a single language element (token). For instance “4($t0)” cannot be an argument.
Macros are a part of the assembler, not the ISA. So the syntax might be different with other assemblers.
For compatibility with the SPIM simulator, SPIM-style macros are also supported in MARS. SPIM-style macros are same as MARS but formal parameters begin with “$” instead of “%”.
Examples
Printing an integer (argument may be either an immediate value or register name):
.macro print_int (%x)
li $v0, 1
add $a0, $zero, %x
syscall
.end_macro
print_int ($s0)
print_int (10)
Printing a string (macro will first assign a label to its parameter in data segment then print it):
.macro print_str (%str)
.data
myLabel: .asciiz %str
.text
li $v0, 4
la $a0, myLabel
syscall
.end_macro
print_str (“test1″) #”test1” will be labeled with name “myLabel_M0”
print_str (“test2″) #”test2” will be labeled with name “myLabel_M1”
Implementing a simple for-loop:
# generic looping mechanism
.macro for (%regIterator, %from, %to, %bodyMacroName)
add %regIterator, $zero, %from
Loop:
%bodyMacroName ()
add %regIterator, %regIterator, 1
ble %regIterator, %to, Loop
.end_macro
#print an integer
.macro body()
print_int $t0
print_str “\n”
.end_macro
#printing 1 to 10:
for ($t0, 1, 10, body)
The for macro has 4 parameters. %regIterator should be the name of a register which iterates from %from to %to and in each iteration %bodyMacroName will be expanded and run.
Arguments for
%from and %to can be either a register name or an immediate value, and %bodyMacroName should be name of a macro that has no parameters.
Macro source line numbers
For purpose of error messaging and Text Segment display, MARS attempts to display line numbers for both the definition and use of the pertinent
macro statement. If an error message shows the line number in the form “X->Y” (e.g. “20->4”), then X is the line number in the expansion
(use) where the error was detected and Y is the line number in the macro definition. In the Text Segment display
of source code, the macro definition
line number will be displayed within brackets, e.g. “<4>“, at the point of expansion. Line numbers should correspond to the
numbers you would see in the text editor.
The .eqv directive
The .eqv directive (short for “equivalence”) is also new in MARS 4.3. It is similar to #define in C or C++. It
is used to substitute an arbitrary string for an identifier. It is useful but much less powerful than macros.
It was developed independently of the macro facility.
Using .eqv, you can specify simple substitutions that provide “define once, use many times” capability at assembly
pre-processing time. For example, once you define
.eqv LIMIT 20
.eqv CTR $t2
.eqv CLEAR_CTR add CTR, $zero, 0
then you can refer to them in subsequent code:
li $v0,1
CLEAR_CTR
loop: move $a0, CTR
syscall
add CTR, CTR, 1
blt CTR, LIMIT, loop
CLEAR_CTR
During assembly pre-processing, the .eqv substitutions will be applied. The resulting code is
li $v0,1
add $t2, $zero, 0
loop: move $a0, $t2
syscall
add $t2, $t2, 1
blt $t2, 20, loop
add $t2, $zero, 0
which when run will display the values 0 through 19 on one line with no intervening spaces.
Note that the substitution string is not limited to a single token. Like .macro, .eqv is local to the file
in which it is defined, and must be defined prior to use. Macro bodies can contain references to .eqv directives.
The .include directive
The .include directive is also new in MARS 4.3. It has one operand, a quoted filename. When the
directive is carried out, the contents of the specified file are substituted for the directive. This occurs
during assembly preprocessing. It is like #include in C or C++.
.include is designed to make macro and equivalence (.eqv directive) use
more convenient. Both macro definitions and equivalence definitions are local, which means they can be used only
in the same file where defined. Without .include, you would have to repeat their definitions in every
file where you want to use them. Besides being tedious, this is poor programming practice; remember
“define once, use many times.” Now you can define macros and equivalences in a separate file, then include it
in any file where you want to use them.
The .include preprocessor will detect and flag any circular includes (file that includes itself, directly or
indirectly).
The use of .include presents some challenges for error messaging and for source code numbering in the Text
Segment display. If a file being included has any assembly errors, the filename and line number in the error
message should refer to the file being included, not the file it was substituted into. Similarly, the line number
given in the Text Segment source code display refers to the line in the file being included. Thus the displayed line numbers do not
monotonically increase – this is also the case when using the “assemble all” setting. Line numbers should correspond to the numbers
you would see in the text editor.
As a simple example, you could define the done macro (and others) in a separate file
then include it wherever you need it. Suppose “macros.asm” contains the following:
.macro done
li $v0,10
syscall
.end_macro
You could then include it in a different source file something like this:
.include “macros.asm”
.data
value: .word 13
.text
li $v0, 1
lw $a0, value
syscall
done
During assembly preprocessing, this would be expanded to
.macro done
li $v0,10
syscall
.end_macro
.data
value: .word 13
.text
li $v0, 1
lw $a0, value
syscall
done
The assembler will then perform the appropriate macro expansion.
Acknowledgements
The MARS macro facility was developed in 2012 by Mohammad Hossein Sekhavat, sekhavat17@gmail.com, while an engineering student at
Sharif University in Tehran. MARS creators Pete and Ken are incredibly grateful for his contribution! Pete developed .eqv
and .include at about the same time.
References
[1] Computer Organization and Design: The Hardware/Software Interface, Fourth Edition, Patterson and Hennessy,
Morgan Kauffman Publishers, 2009.
MARS 4.5 help contents
MARS – Mips Assembly and Runtime Simulator
Release 4.5
August 2014
Operating Requirements
MARS is written in Java and
requires at least Release 1.5 of the J2SE Java Runtime Environment (JRE) to work.
The graphical IDE is implemented using Swing. It has been
tested on Windows XP, Vista and 7; Mac OS X; and is also being used under Linux.
Some MARS Assembler and Simulator Limitations
Releases 3.0 and later assemble and simulate nearly all the MIPS32 instructions documented in the
textbook Computer Organization and Design, Fourth Edition by Patterson and Hennessy,
Elsevier – Morgan Kaufmann, 2009. All basic and pseudo instructions, directives,
and system services described in Appendix B are implemented.
Limitations of MARS as of Release 4.5 include:
Memory segments (text, data, stack, kernel text, kernel data) are limited to 4MB each starting at their
respective base addresses.
There is no pipelined mode (but delayed branching is supported).
If you open a file which is a link or shortcut to another file, MARS will not
open the target file. The file open dialog is implemented using Java Swing’s JFileChooser,
which does not support links.
Very few configuration changes, besides those in the Settings menu, are saved from one session to the next.
The editor settings, which include font settings and display of line numbers, are saved.
The IDE will work only with the MARS assembler. It cannot be used
with any other compiler, assembler, or simulator. The MARS assembler and simulator
can be used either through the IDE or from a command prompt.
Bug:The error message highlighter does not automatically select the code for the first assembly
error if the file containing the error is not open at the time of assembly (assemble-on-open, assemble-all).
Bug: The Screen Magnifier screen capture feature does not appear to work properly under Windows Vista.
Bug: There appears to be a memory leak in the Editor. Several different people have independently
reported the same behavior: severe slowdown in editor response during an extended interactive session.
If MARS is exited and restarted, this behavior disappears and the editor responds instantly to actions.
Not a bug, but documented here anyway: MIPS Branch instruction target addresses are represented by
the relative number of words to branch. With Release 3.4, this value reflects delayed branching,
regardless of whether the Delayed Branching setting is enabled or not.
The generated binary code for branches will now match that of examples in the Computer Organization
and Design textbook. This is a change from the past, and was made after extensive discussions
with several faculty adopters of MARS. Previously, the branch offset was 1 lower if the Delayed Branching setting
was enabled — the instruction label: beq $0,$0,label would generate 0x1000FFFF if
Delayed Branching was enabled and 0x10000000 if it was disabled. Now it will generate 0x1000FFFF in
either case. The simulator will always branch to the correct location; MARS does not allow assembly under one
setting and simulation under the other to occur.
This document is available for printing on the MARS home page
http://www.cs.missouristate.edu/MARS/.
MARS 4.5 help contents
MARS – Mips Assembly and Runtime Simulator
Release 4.5
August 2014
Configuration Settings
Releases 3.0 and later include a Settings menu. The Editor and Exception Handler items launch a dialog but the rest are each
controlled by a checkbox for selecting or deselecting it (checked means true, unchecked means false). Settings and their default
values are:
Display the Labels window in the Execute tab. Default value is false. If selected, the Labels window,
which shows the name and associated address for each label defined in the program, will be
displayed to the right of the Text Segment.
Provide program arguments to the MIPS program. Default value is false. New in Release 3.5.
If selected, a text field will appear at the top of the Text Segment Display. Any argument values in this
text field at the time of program execution will be stored in MIPS memory prior to execution. The argument
count (argc) will be placed in register $a0, and the address of an array of null-terminated strings containing
the arguments (argv) will be placed in register $a1. These values are also available on the runtime stack ($sp).
Popup Dialog for input syscalls (5,6,7,8,12). New in Release 4.0. Default value is false. If selected, runtime console
input will be entered using popup dialogs (this was the only option prior to Release 4.0). Otherwise, input is entered
directly into the Run I/O tab at the bottom of the screen.
Display memory addresses in hexadecimal. Default value is true. If deselected, addresses will be displayed in decimal.
This setting can also be toggled in a checkbox on the lower border of the Data Segment Window.
Display memory and register contents in hexadecimal. Default value is true. If deselected, vlaues will be displayed in decimal.
This setting can also be toggled in a checkbox on the lower border of the Data Segment Window.
Assemble a file automatically as soon as it is opened, and initialize the File Open dialog with the most-recently opened file.
Default value is false. This is convenient if you use an external editor for composing your programs.
Assemble applies to all files in directory. Default value is false.
If selected, the file currently open in the
editor will become the “main” program in a multi-file assemble-and-link operation involving all
assembly files (*.asm; *.s) in its directory. If successful, execution will begin with the currently open file.
Assembler warnings are considered errors. Default value is false. New in Release 3.5.
If selected, the assemble operation will fail if any warnings are produced. At this time, all assembler warnings
relate to unrecognized or ignored directives. MARS may be able to assemble code produced by compilers for other MIPS
assemblers if this setting is deselected.
Initialize Program Counter to global ‘main’ if defined. Default value is false. New in Release 3.8.
If selected, the Program Counter will be initialized to the address of the text segment statement with the global label ‘main’ if it
exists. If it does not exist or if the setting is not selected, the Program Counter will be initialized to the default text segment
starting address.
Permit programs to use extended (pseudo) instructions and formats. Default value is true. This includes all memory addressing
modes other than the MIPS native mode (16 bit constant offset added to register content).
Assemble and execute programs using delayed branching. Default value is false. MIPS processors use delayed branches
as part of the pipelined design, but it can be confusing to programmers. With delayed branching, the instruction
following a branch or jump instruction will always be executed even if the branch condition is true! Assemblers
and, failing that, programmers, often deal with this by following branches and jumps with a “nop” instruction. The MARS
assembler does not insert a nop. When delayed branching was introduced in Release 3.3, the machine code generated
for a branch instruction depended on this setting since
its target value is relative to the Program Counter (PC-relative addressing). Although technically correct, this led to
confusion in the MARS community because the generated code did not match textbook examples. Starting with Release 3.4, the relative branching
offset is always calculated as if delayed branching is enabled even when it is not. The runtime simulation adjusts accordingly.
Self-modifying code. Default value is false. New in Release 4.4.
If selected, a running MIPS program can write to a user text segment address and can branch/jump to a user data segment address.
These capabilities permit a program to dynamically generate and/or modify its binary code. Also permits interactive modification of
text segment contents through either the Data Segment or Text Segment windows.
The Editor dialog. Use it to view and modify editor font settings. New with Release 3.3.
The Highlighting dialog. Use it to modify color and font settings for the highlighting of table items in the
Text Segment window, Data Segment window, Registers window, Coprocessor0 window and Coprocessor1 window.
Highlighting occurs during timed, stepped, and backstepped simulation. Color and font for normal (non-highlighted)
display can also be set separately for even-numbered and odd-numbered display rows but not individually by windows.
New with Release 3.6.
The Exception Handler dialog. It has the setting: Include this
exception handler in all assemble operations. Default value is false. If selected, a button to browse to the desired
file is enabled. New with Release 3.2
The Memory Configuration dialog. Use it to select from among available MIPS address space configurations.
The default configuration is derived from SPIM; it was only one available from MARS 1.0 through MARS 3.6.
New with Release 3.7.
Beginning with Release 3.2, settings are retained from one interactive session to the next. Settings are stored in a system-dependent
way as specified by java.util.prefs.Preferences. Windows systems use the Registry.
These settings are independent of command options given when using MARS from a command line;
neither affects the other. We anticipate future releases will include additional settings and preferences.
This document is available for printing on the MARS home page
http://www.cs.missouristate.edu/MARS/.
Writing and Using MIPS exception handlers in MARS
Writing and Using MIPS exception handlers in MARS
Introduction
Exception handlers, also known as trap handlers or
interrupt handlers, can easily be incorporated into a MIPS program.
This guide is not intended to be comprehensive but provides the essential
information for writing and using exception handlers.
Although the same mechanism services all three, exceptions, traps
and interrupts are all distinct from each other.
Exceptions are caused by exceptional conditions that occur at runtime
such as invalid memory address references. Traps are caused by instructions
constructed especially for this purpose, listed below. Interrupts are
caused by external devices.
MARS partially but not completely implements the exception and interrupt
mechanism of SPIM.
Essential Facts
Some essential facts about writing and using exception handlers include:
MARS simulates basic elements of the MIPS32 exception mechanism.
The MIPS instruction set includes a number of instructions that
conditionally trigger a trap exception based on the relative values of two
registers or of a constant and a register:
teq, teqi (trap if equal),
tne, tnei (trap if not equal),
tge, tgeu,
tgei, tgeiu (trap if greater than or equal),
tlt, tltu,
tlti, tltiu (trap if less than)
When an exception occurs,
Coprocessor 0 register $12 (status) bit 1 is set
Coprocessor 0 register $13 (cause) bits 2-6 are set to the exception type (codes below)
Coprocessor 0 register $14 (epc) is set to the
address of the instruction that triggered the exception
If the exception was caused by an invalid memory address,
Coprocessor 0 register $8 (vaddr) is set to the invalid address.
Execution flow jumps to the MIPS
instruction at memory location 0x800000180. This address
in the kernel text segment (.ktext directive) is the
standard MIPS32 exception handler location. The only way to change
it in MARS is to change the MIPS memory configuration through
the Settings menu item Memory Configuration.
There are three ways to include an exception handler in a MIPS program
Write the exception handler in the same file as the regular
program. An example of this is presented below.
Write the exception handler in a separate file, store that file
in the same directory as the regular program, and select
the Settings menu item “Assemble all files in directory”
Write the exception handler in a separate file, store that file
in any directory, then open the “Exception Handler…” dialog
in the Settings menu, check the check box and browse to
that file.
If there is no instruction at location 0x800000180,
MARS will terminate the MIPS program with an appropriate error message.
The exception handler can return control to the program using
the eret instruction. This will place the EPC register $14 value into the
Program Counter, so be sure to increment $14 by 4 before returning
to skip over the instruction that caused the exception. The mfc0
and mtc0 instructions are used to read from and write to Coprocessor 0
registers.
Bits 8-15 of the Cause register $13 can also be used to indicate
pending interrupts. Currently this is used only by the Keyboard and
Display Simulator Tool, where bit 8 represents a keyboard interrupt
and bit 9 represents a display interrupt. For more details, see the
Help panel for that Tool.
Exception types declared in mars.simulator.Exceptions, but
not necessarily implemented, are ADDRESS_EXCEPTION_LOAD (4), ADDRESS_EXCEPTION_STORE (5),
SYSCALL_EXCEPTION (8),
BREAKPOINT_EXCEPTION (9),
RESERVED_INSTRUCTION_EXCEPTION (10),
ARITHMETIC_OVERFLOW_EXCEPTION (12),
TRAP_EXCEPTION(13),
DIVIDE_BY_ZERO_EXCEPTION (15),
FLOATING_POINT_OVERFLOW (16), and
FLOATING_POINT_UNDERFLOW (17).
When writing a non-trivial exception handler, your handler must first save
general purpose register contents, then restore them before returning.
Example of Trap Handler
The sample MIPS program below will immediately generate a trap exception because
the trap condition evaluates true, control jumps to the exception handler,
the exception handler returns control to the instruction following
the one that triggered the exception, then the program terminates normally.
.text
main:
teqi $t0,0 # immediately trap because $t0 contains 0
li $v0, 10 # After return from exception handler, specify exit service
syscall # terminate normally
# Trap handler in the standard MIPS32 kernel text segment
.ktext 0x80000180
move $k0,$v0 # Save $v0 value
move $k1,$a0 # Save $a0 value
la $a0, msg # address of string to print
li $v0, 4 # Print String service
syscall
move $v0,$k0 # Restore $v0
move $a0,$k1 # Restore $a0
mfc0 $k0,$14 # Coprocessor 0 register $14 has address of trapping instruction
addi $k0,$k0,4 # Add 4 to point to next instruction
mtc0 $k0,$14 # Store new address back into $14
eret # Error return; set PC to value in $14
.kdata
msg:
.asciiz “Trap generated”
Widely Used Exception Handler
The exception handler exceptions.s provided with
the SPIM simulator will assemble and run under MARS. The MARS
assembler will generate warnings because this program
contains directives that it does not
recognize, but as long as the setting “Assembler warnings are
considered errors” is not set this will not cause any
problems.
MARS 4.5 help contents
MARS – Mips Assembly and Runtime Simulator
Release 4.5
August 2014
Using MARS through its Integrated Development Environment (IDE)
The IDE is invoked when MARS is run with no command arguments, e.g. java -jar mars.jar.
It may also be launched from a graphical interface by double-clicking the mars.jar icon
that represents this executable JAR file.
The IDE provides basic editing, assembling and execution capabilities. Hopefully it
is intuitive to use. Here are comments on some features.
Menus and Toolbar: Most menu items have equivalent toolbar icons.
If the function of a toolbar icon is not obvious, just hover the mouse over it and
a tool tip will soon appear. Nearly all menu items also have keyboard shortcuts.
Any menu item not appropriate in a given situation is disabled.
Editor: MARS includes two integrated text editors. The default editor, new
in Release 4.0, features syntax-aware color highlighting of most MIPS language elements
and popup instruction guides. The original, generic, text editor without these features
is still available and can be selected in the Editor Settings dialog. It supports a single
font which can be modified in the Editor Settings dialog.
The bottom border of either editor includes the cursor line
and column position and there is a checkbox to display line numbers.
They are displayed outside the editing area. If you use an external editor, MARS provides
a convenience setting that will automatically assemble a file as soon as it is opened. See
the Settings menu.
Message Areas: There are two tabbed message areas at the
bottom of the screen. The Run I/O tab is used at runtime for
displaying console output and entering console input as program execution progresses.
You have the option of entering console input into a pop-up dialog then echoes to the message area.
The MARS Messages tab is used for other messages such as assembly or
runtime errors and informational messages. You can click on assembly error messages to
select the corresponding line of code in the editor.
MIPS Registers: MIPS registers are displayed at all times, even
when you are editing and not running a program. While writing your program,
this serves as a useful reference for register names and their conventional
uses (hover mouse over the register name to see tool tips). There are three
register tabs: the Register File (integer registers $0 through $31 plus LO,
HI and the Program Counter), selected Coprocesor 0 registers (exceptions and
interrupts), and Coprocessor 1 floating point registers.
Assembly: Select Assemble from the Run menu or the
corresponding toolbar icon to assemble the file currently in the Edit tab.
Prior to Release 3.1, only one file could be assembled and run at a time.
Releases 3.1 and later provide a primitive Project capability. To use it, go to the
Settings menu and check Assemble operation applies to all
files in current directory. Subsequently, the assembler will assemble
the current file as the “main” program and also assemble all other assembly
files (*.asm; *.s)
in the same directory. The results are linked and if all these
operations were successful the program can be executed. Labels that are
declared global with the “.globl” directive may be referenced in any of the
other files in the project. There is also a setting that permits
automatic loading and assembly of a selected exception handler file. MARS uses
the MIPS32 starting address for exception handlers: 0x80000180.
Execution: Once a MIPS program successfully assembles, the
registers are initialized and three windows
in the Execute tab are filled: Text Segment, Data Segment,
and Program Labels. The major execution-time features are described below.
Labels Window: Display of the Labels window (symbol table) is
controlled through the Settings menu. When displayed, you can click on any label
or its associated address to center and highlight the contents of that address
in the Text Segment window or Data Segment window as appropriate.
The assembler and simulator are invoked from the IDE
when you select the Assemble, Go,
or Step operations from the Run menu or their corresponding
toolbar icons or keyboard shortcuts. MARS messages are displayed on the
MARS Messages tab of the message area at the bottom of the screen.
Runtime console input and output is handled in the Run I/O tab.
This document is available for printing on the MARS home page
http://www.cs.missouristate.edu/MARS/.
MARS 4.5 help contents
MARS – Mips Assembly and Runtime Simulator
Release 4.5
August 2014
Introduction
MARS, the Mips Assembly and Runtime Simulator,
will assemble and simulate the execution of MIPS assembly language programs.
It can be used either from a command line or through its
integrated development environment (IDE). MARS is written in Java and
requires at least Release 1.5 of the J2SE Java Runtime Environment (JRE) to work.
It is distributed as an executable JAR file.
The MARS home page
is
http://www.cs.missouristate.edu/MARS/. This document is available for printing there.
As of Release 4.0, MARS assembles and simulates 155 basic instructions of the MIPS-32
instruction set, approximately 370 pseudo-instructions or instruction variations, the 17 syscall functions
mainly for console and file I/O defined by SPIM, and an additional 22 syscalls for other uses such as MIDI
output, random number generation and more. These are listed in separate help tabs. It supports seven
different memory addressing modes for load and store instructions: label, immed,
label+immed, ($reg), label($reg), immed($reg), and label+immed($reg), where immed
is an integer up to 32 bits. A setting is available to disallow use of pseudo-instructions
and extended instruction formats and memory addressing modes.
Our guiding reference in implementing the instruction set has been
Computer Organization and Design, Fourth Edition by Patterson and Hennessy,
Elsevier – Morgan Kaufmann, 2009. It summarizes the MIPS-32 instruction set
and pseudo-instructions in Figures 3.24 and 3.25 on pages 279-281, with details
provided in the text and in Appendix B. MARS Releases 3.2 and above implement all the instructions
in Appendix B and those figures except the delay branches from the left column of Figure 3.25.
It also implements all the system services (syscalls) and assembler directives
documented in Appendix B.
The MARS IDE provides program editing and assembling but its real
strength is its support for interactive debugging. The programmer can easily set and
remove execution breakpoints or step through execution forward or backward (undo) while
viewing and directly editing register and memory contents.
Questions and Comments
Send MARS questions and comments to
Dr. Pete Sanderson at PSanderson@otterbein.edu or
Dr. Ken Vollmar at KenVollmar@missouristate.edu.
We will respond as quickly as we can but as teaching professors do not have as much time to work on
this project as we would like during the school year. We presented papers
on MARS at the 2005 CCSC:MW conference and the 2006 SIGCSE Technical Symposium. We presented
a tutorial session on MARS at the 2007 CCSC:CP conference and the Tutorial handout is available
from the MARS homepage.
This document is available for printing on the MARS home page
http://www.cs.missouristate.edu/MARS/.
MARS 4.5 help contents
MARS – Mips Assembly and Runtime Simulator
Release 4.5
August 2014
Interactive Debugging Features
MARS provides many features for interactive debugging through its Execute pane.
Features include:
In Step mode, the next instruction to be simulated is highlighted and
memory content displays are updated at each step.
Select the Go option if you want to simulate continually.
It can also be used to continue simulation
from a paused (step, breakpoint, pause) state.
Breakpoints are easily set and reset using the check boxes next to each instruction displayed
in the Text Segment window. New in Release 3.8: You can temporarily suspend breakpoints
using Toggle Breakpoints in the Run menu or by clicking the “Bkpt” column header in the Text Segment
window. Repeat, to re-activate.
When running in the Go mode, you can select the simulation
speed using the Run Speed slider. Available speeds range
from .05 instructions per second (20 seconds between steps) up to 30
instructions per second, then above this offers an “unlimited” speed.
When using “unlimited” speed, code highlighting and memory display updating
are turned off while simulating (but it executes really fast!).
When a breakpoint is reached, highlighting and updating occur.
Run speed can be adjusted while the program is running.
When running in the Go mode, you can pause or stop
simulation at any time using the Pause or Stop features.
The former will pause execution and update the display, as if you
were stepping or at a breakpoint. The latter will terminate execution
and display final memory and register values. If running at “unlimited”
speed, the system may not respond immediately but it will respond.
You have the ability to interactively step “backward” through program execution
one instruction at a time to “undo” execution steps. It will buffer up to 2000 of the most
recent execution steps (this limit is stored in a properties file and can be changed).
It will undo changes made to MIPS memory, registers or condition flags,
but not console or file I/O. This should be a great debugging aid.
It is available anytime execution is paused and at termination (even if terminated due to
exception).
When program execution is paused or terminated, select Reset
to reset all memory cells and registers to their initial post-assembly values.
In fact, Reset is implemented by re-assembling the program.
Memory addresses and values, and register values, can be viewed in either decimal
or hexadecimal format. All data are stored in little-endian byte order (each
word consists of byte 3 followed by byte 2 then 1 then 0). Note that each word
can hold 4 characters of a string and those 4 characters will appear in the
reverse order from that of the string literal.
Data segment contents are displayed 512 bytes
at a time (with scrolling) starting with the data segment base address (0x10010000).
Navigation buttons are provided to change the display to the next
section of memory, the previous, or back to the initial (home) range. A combo box is
also provided to view memory contents in the vicinity of the stack pointer
(contents of MIPS $sp register), global pointer (contents of MIPS $gp register),
the heap base address (0x10040000), .extern globals (0x10000000),
the kernel data segment (0x90000000), or memory-mapped IO (MMIO, 0xFFFF0000).
Starting with Mars 4.4, raw text segment contents can also be displayed.
Contents of any data segment memory word and almost any MIPS register can be modified by
editing its displayed table cell. Double-click on a cell to edit it and press the Enter key
when finished typing the new value. If you
enter an invalid 32-bit integer, the word INVALID appears in the cell
and memory/register contents are not affected. Values can be entered
in either decimal or hexadecimal (leading “0x”). Negative hexadecimal
values can be entered in either two’s complement or signed format. Note
that three of the integer registers (zero, program counter, return address)
cannot be edited.
New in 4.4 If the setting for Self-Modifying Code is enabled
(disabled by default, look in the Settings menu), text segment binary
code can be modified using the same technique described above. It can also
be modified by double-clicking on a cell in the Text Segment display’s Code
column.
Contents of cells representing floating point registers can be edited
as described above and will accept valid hexadecimal or decimal floating point
values. Since each double-precision register overlays two single-precision
registers, any changes to a double-precision register will affect one or both
of the displayed contents of its corresponding single-precision registers.
Changes to a single-precision register will affect the display of its
corresponding double-precision register. Values entered in hexadecimal
need to conform to IEEE-754 format. Values entered in decimal are entered
using decimal points and E-notation (e.g. 12.5e3 is 12.5 times 10 cubed).
Cell contents can be edited during program execution and once accepted
will apply starting with the next instruction to be executed.
Clicking on a Labels window entry will cause the location associated with
that label to be centered and highlighted in the Text Segment or Data Segment
window as appropriate. Note the Labels window is not displayed by default but
can be by selecting it from the Settings menu.
This document is available for printing on the MARS home page
http://www.cs.missouristate.edu/MARS/.
Bug Reporting help contents
Bug Reporting and General Comments
The MARS web page is maintained at
http://www.cs.missouristate.edu/MARS/
and will contain updated releases, bug lists, etc.
For bug reporting and general comments, please send email to
Dr. Pete Sanderson at
PSanderson@otterbein.edu
with “MARS” in the
subject line. Please include sufficient information to recreate
the problem, and assembly programs if appropriate.
MARS 4.5 help contents
MARS – Mips Assembly and Runtime Simulator
Release 4.5
August 2014
Using MARS from a command line.
MARS can be run from a command interpreter to assemble and execute a MIPS program in
a batch fashion.
The format for running MARS from a command line is:
java -jar mars.jar [options] program.asm [more files…] [ pa arg1 [more args…]]
Items in [ ] are optional. Valid options (not case sensitive, separated by spaces) are:
Option Description Since
a assemble only, do not simulate 1.0
aen terminate MARS with integer exit code n if assembly error occurs 4.1
ascii display memory or register contents interpreted as ASCII codes. (alternatives are dec and hex) 4.1
b brief – do not display register/memory address along with contents 2.2
d display MARS debugging statements (of interest mainly to MARS developer) 1.0
db MIPS delayed branching is enabled. 3.3
dec display memory or register contents in decimal. (alternatives are ascii and hex) 2.2
dump dump memory contents to file.
Option has 3 arguments, e.g. dump
and .data. Also supports an address range (see m-n below). Current supported dump formats are Binary, HexText, BinaryText, AsciiText. See examples below. 3.4
hex display memory or register contents in hexadecimal – this is the default. (alternatives are ascii and dec) 2.2
h display this help. Use this option by itself and with no filename. 1.0
ic display instruction count; the number of MIPS basic instructions ‘executed’ 4.3
mc set memory configuration.
Option has 1 argument, e.g. mc
possible values are Default for the default 32-bit address space, CompactDataAtZero for
a 32KB address space with data segment at address 0, or CompactTextAtZero
for a 32KB address space with text segment at address 0. 3.7
me display MARS messages to standard err instead of standard out. Allows you to separate MARS messages from MIPS program output using redirection. 4.3
nc copyright notice will not be displayed. Useful if redirecting or piping program output. 3.5
np pseudo-instructions or extended instruction formats are not permitted. 3.0
p project option – will assemble the specified file and all other assembly files (*.asm; *.s) in its directory. 3.1
sen terminate MARS with exit code n if simulate (run) error occurs 4.1
sm start execution at statement having global label ‘main’ if defined 3.8
smc Self Modifying Code – Program can write and execute in either text or data segment 4.4
we assembler warnings will be considered errors. 3.5
n where n is an integer maximum count of execution steps to simulate.
If 0, negative or not specified, there is no maximum. 1.0
$reg where reg is number or name (e.g. 5, t3, f10) of register whose
content to display at end of run. Even-numbered float register displays both float and double. Option may be repeated.
NOTE: Depending on your command shell, you may need to escape the $, e.g. \$t3 2.2
reg_name where reg_name is the name (e.g. t3, f10) of register whose
content to display at end of run. Even-numbered float register displays both float and double. Option may be repeated. $ not required. 2.2
m-n memory address range from m to n whose contents to
display at end of run. m and n may be decimal or hexadecimal (starts with 0x),
m <= n, both must be on word boundary. Option may be repeated. 2.2
pa program arguments - all remaining space-separated items are argument values provided to the MIPS
program via $a0 (argc - argument count) and $a1 (argv - address of array containing pointers to null-terminated argument
strings). The count is also at the top of the runtime stack ($sp), followed by the array.This option and its arguments must be the last items in the command! 3.5
Example: java -jar mars.jar h
Displays command options and explanations.
Example: java -jar mars.jar $s0 $s1 0x10010000-0x10010010 fibonacci.asm
Assemble and run fibonacci.asm. At the end of the run, display the contents of registers $s0 and
$s1, and the contents of memory locations 0x10010000 through 0x10010010. The contents are displayed in
hexadecimal format.
Example: java -jar mars.jar a fibonacci.asm
Assemble fibonacci.asm. Does not attempt to run the program, and the assembled code is not saved.
Example: java -jar mars.jar 100000 infinite.asm
Assemble and run infinite.asm for a maximum of 100,000 execution steps.
Example: java -jar mars.jar p major.asm
Assemble major.asm and all other files in the same directory, link the assembled code, and run starting with the first instruction in major.asm.
Example: java -jar mars.jar major.asm minor.asm sub.asm
Assemble and link major.asm, minor.asm and sub.asm. If successful, execution
will begin with the first instruction in major.asm.
Example: java -jar mars.jar a dump .text HexText hexcode.txt fibonacci.asm
Assemble fibonacci.asm without simulating (note use of 'a' option). At end of assembly, dump the text segment (machine code) to
file hexcode.txt in hexadecimal text format with one instruction per line.
Example: java -jar mars.jar dump 0x10010000-0x10010020 HexText hexcode.txt fibonacci.asm
Assemble and simulate fibonacci.asm. At end of simulation, dump the contents of addresses 0x1001000 to
0x10010020 to file hexdata.txt in hexadecimal text format with one word per line.
Example: java -jar mars.jar t0 process.asm pa counter 10
Assemble and run process.asm with two program argument values, "counter" and "10". It may retrieve the
argument count (2) from $a0, and the address of an array containing pointers to the strings "count" and "10",
from $a1. At the
end of the run, display the contents of register $t0.
The ability to run MARS from the command line is useful if you want to develop
scripts (macros) to exercise a given MIPS program under multiple scenarios
or if you want to run a number of different MIPS programs
such as for grading purposes.
This document is available for printing on the MARS home page
http://www.cs.missouristate.edu/MARS/.
MARS 4.5 help contents
MARS - Mips Assembly and Runtime Simulator
Release 4.5
August 2014
Cool Capability: Plug-in Tools
Beginning with Release 2.0, MARS is capable of running externally-developed
software that interacts with an executing MIPS program and MIPS system
resources.
The requirements for such a program are:
It implements the mars.tools.MarsTool interface.
It is part of the mars.tools package.
It compiles cleanly into a ".class" file, stored in the mars/tools directory.
MARS will detect all qualifying tools upon startup and include them in
its Tools menu.
When a tool's menu item is selected, an instance of it will be created using its no-argument
constructor and its action() method will be invoked.
If no qualifying tools are found at MARS startup, the Tools menu will not
appear.
To use such a tool, load and assemble a MIPS program of interest then select the desired tool
from the Tools menu. The tool's window will open and depending on how it is written it will either
need to be "connected" to the MIPS program by clicking a button or will already be connected. Run
the MIPS program as you normally would, to initiate tool interaction with the executing program.
Beginning with Release 3.2, the abstract class mars.tools.AbstractMarsToolAndApplication
is included in the MARS distribution to provide
a substantial framework for implementing your own MARS Tool. A subclass that extends it by
implementing at least its two abstract methods can be run not only from the Tools menu but also
as a free-standing application that uses the MARS assembler and simulator in the background.
Several Tools developed by subclassing AbstractMarsToolAndApplication are included
with MARS: an Introduction to Tools, a Data Cache Simulator, a Memory Reference Visualizer, and
a Floating Point tool. The last one is quite useful even when not connected to a MIPS program
because it displays binary, hexadecimal and decimal representations for a 32 bit floating point
value; when any of them is modified the other two are updated as well.
Release 3.5 includes new tools, most notably a keyboard and display simulator that allows you
to perform memory-mapped I/O (MMIO) using polled and interrupt-driven techniques as described
in various references. Click its Help button for more details.
If you wish to develop your own MARS Tool, you will first need to extract the MARS distribution
from its JAR file if you have not already done so. All MARS tools must
be stored in the mars/tools directory.
Follow the Tutorial Materials link on the MARS homepage to find a tutorial
that covers development of MARS Tools.
Cool Capability: Extending the syscall set or reassigning syscall numbers
Beginning with Release 3.1, system calls (syscall instruction) are implemented using
a technique similar to that for tools. This permits anyone to add a new syscall by defining
a new class that meets these requirements:
It implements the mars.mips.instructions.syscalls.Syscall interface, or
extends the mars.mips.instructions.syscalls.AbstractSyscall class (which
provides default implementations of everything except the simulate() method).
It is part of the mars.mips.instructions.syscalls package.
It compiles cleanly into a ".class" file, stored in the
mars/mips/instructions/syscalls directory.
MARS will detect all qualifying syscall classes upon startup and the runtime simulator
will invoke them when the syscall instruction is simulated and register $v0
contains the corresponding integer service number.
Syscalls and syscall number assignments in MARs match those of SPIM for syscalls 1 through 17.
However if you wish to change syscall number assignments, you may do so by editing the
Syscall.properties file included in the release (this requires extraction from the JAR
file).
Follow the Tutorial Materials link on the MARS homepage to find a tutorial
that covers development of system calls.
Cool Capability: Extending the instruction set
You can add customized pseudo-instructions to the MIPS instruction set by editing
the PseudoOps.txt file included in the MARS distribution. Instruction
specification formats are explained in the file itself.
The specification of a pseudo-instruction is one line long. It consists of
an example of the instruction, constructed using
available instruction specification symbols, followed by a tab-separated
list of the basic MIPS instructions it will expand to. Each is an instruction template
constructed using
instruction specification symbols combined with special template
specification symbols. The latter permit substitution at program
assembly time of operands from the user's program into the expanded
pseudo-instruction.
PseudoOps.txt is read and processed at MARS startup, and error messages will
be produced if a specification is not correctly formatted. Note that if you wish to
edit it you first have to extract it from the JAR file.
Follow the Tutorial Materials link on the MARS homepage to find a tutorial
that covers modification of the pseudo-instruction set.
This document is available for printing on the MARS home page
http://www.cs.missouristate.edu/MARS/.
MARS Release History and Notes
MARS - Mips Assembly and Runtime Simulator
Release 4.5
August 2014
MARS Release History
Mars 4.5 was released in August 2014. Enhancements and bug fixes include:
The Keyboard and Display MMIO Simulator tool has been enhanced at the suggestion of Eric Wang at
Washington State University. Until now, all characters written to the display via the Data Transmitter
location (low order byte of memory word 0xFFFF000C) were simply streamed to the tools' display window.
Mr. Wang requested the ability to treat the display window as a virtual text-based terminal by
being able to programmatically clear the window or set the (x,y) position of a text cursor. Controlled
placement of the text cursor (which is not displayed) allows you to, among other things, develop
2D text-mode games.
To clear the window, place ASCII/Unicode 12 decimal in the Data Transmitter byte. This is the non-printing
Form Feed character.
To set the text cursor to a specified (x,y) position, where x is the column and y is the row,
place ASCII/Unicode 7 in the Data Transmitter byte, and place the (x,y) position in the unused
upper 24 bits of the Data Transmitter word. Place the X-position in bits 20-31 and the Y-position in bits 8-19.
Position (0,0) is the upper-left corner of the display.
You can resize the display window to desired dimensions prior to running your MIPS program.
Dimensions are dynamically displayed in the upper border. Note that the tool now contains a splitter between
the display window and the keyboard window. Once the program is running, changes to the display size
does not affect cursor positioning.
The Help window for this tool is no longer modal, so you can view it while working in other windows.
The Help window contains a lot of information so you
will find it useful to be able to refer to it while working on your program.
Installed the MIPS X-ray Tool developed by Marcio Roberto and colleagues at the Federal Center of
Technological Education of Minas Gerais in Brazil. This tool animates a display of the MIPS datapath.
The animation occurs while stepping through program execution. Search the Internet for "MIPS X-ray"
to find relevant publications and other information.
Context-sensitive help in the editor should now be easier to read. It was implemented as a menu of
disabled items, which caused their text to be dimmed. The items are now enabled for greater visibility
but clicking them will only make the list disappear.
Bug Fix: Fixed an editor problem that affects certain European keyboards. The syntax-highlighting editor
ignored the Alt key, which some European keyboards require to produce the # or $ characters in particular.
I had no means of testing this, but Torsten Maehne in France send me a solution and Umberto
Villano in Italy affirmed that it worked for him as well.
Bug Fix: Source code references to Coprocessor 1 floating point registers (e.g. $f12)
within macro definitions were erroneously flagged as syntax errors. MARS permits SPIM-style
macro parameters (which start with $ instead of %) and did not correctly distinguish them
from floating point register names. This has been fixed. Thanks to Rudolf Biczok in Germany for alerting
me to the bug.
Bug Fix: Corrected a bug that caused the Data Segment window to sometimes display incorrect values
at the upper boundary of simulated memory segments. Thanks to Yi-Yu (James) Liu from Taiwan for alerting
me to the bug, which was introduced in Mars 4.4.
Mars 4.4 was released in August 2013. Enhancements and bug fixes include:
A feature to support self-modifying code has been developed by Carl Burch
(Hendrix College) and Pete Sanderson. It is disabled by default
and can be enabled through a Settings menu option. A program can write to the
text segment and can also branch/jump to any user address in the data segments
within the limits of the simulated address space. Text segment contents
can also be edited interactively using the Data Segment window, and text
segment contents within the address range of existing code can be edited
interactively using the Text Segment window. In command mode, the smc option
permits a program to write and execute in both text and data segments.
Bug fix: An assembly error occurred when a line within a macro contained both
a macro parameter and an identifier defined to have an .eqv substitution.
Bug fix: If a macro name was used as a macro parameter, an assembly error occurred in some situations
when a macro being used as an argument was defined following the macro that
defined the parameter. The "for" macro described in the Macro help tab is
an example.
Mars 4.3 was released in January 2013. Enhancements and bug fixes include:
A macro facility has been developed by Mr. Mohammad Sekhavat. It is documented
in the MIPS help tab Macros.
A text substitution facility similar to #define has been developed using
the new .eqv directive. It is also documented in the MIPS help
tab Macros.
A text insertion facility similar to #include has been developed
using the new .include directive. It is also documented in the
MIPS help tab Macros. It permits a macro to be defined in one file and
included wherever needed.
Two new command mode options are now available: ic (Instruction Count) to
display a count of statements executed upon program termination, and me
(Messages to Error) to send MARS messages to System.err instead of System.out.
Allows you to separate MARS messages from MIPS output using redirection,
if desired. Redirect a stream in DOS with "1>” or “2>” for out and err,
respectively. To redirect both, use “> filename 2>&1”
Changed the default font family settings from Courier New to Monospaced.
This was in response to reports of Macs displaying left parentheses and vertical
bars incorrectly.
Changed the way operands for .byte and .half directives are range-checked.
It will now work like SPIM, which accepts any operand value but truncates high-end bits as
needed to fit the 1 (byte) or 2 (half) byte field. We’ll still issue a warning
but not an error.
For file reads, syscall 14, file descriptor 0 is always open for standard input. For file
writes, syscall 15, file descriptors 1 and 2 are always open for standard output and
standard error, respectively. This permits you to write I/O code that will
work either with files or standard I/O. When using the IDE, standard input and output
are performed in the Run I/O tab. File descriptors for regular files are
allocated starting with file descriptor 3.
Mars 4.2 was released in August 2011. Enhancements and bug fixes include:
Performing a Save operation on a new file will now use the file’s tab
label as the the default filename in the Save As dialog (e.g. mips1.asm).
Previously, it did not provide a default name.
When the “assemble all files in directory” setting is enabled (useful
for multi-file projects), you can now switch focus from one editor tab to another
without invalidating the current assemble operation. You can similarly open
additional project files. Previously, the open or tab selection would
invalidate the assemble operation and any paused execution state or
breakpoints would be lost.
The Read String syscall (syscall 8) has been fortified to prevent Java exceptions from occurring
when invalid values are placed in $a1.
Will now perform runtime test for unaligned doubleword address in
‘ldc1’ and ‘sdc1’ instructions and trap if not aligned.
Basic statements in the Text Segment display now renders immediates using
eight hex digits when displaying in hex. Previously it rendered only
four digits to conserve space. This led to confusing
results. For instance, -1 and 0xFFFF would both be displayed as 0xFFFF
but -1 expands to 0xFFFFFFFF and 0xFFFF expands to 0x0000FFFF.
Mars 4.1 was released in January 2011. Enhancements and bug fixes include:
The ability to view Data Segment contents interpreted as ASCII
characters has been added. You’ll find it on the bottom border of
the Data Segment Window as the checkbox “ASCII”. This overrides the
hexadecimal/decimal setting but only for the Data Segment display.
It does not persist across sessions. Cells cannot be edited in
ASCII format.
The Dump Memory feature in the File menu now provides an ASCII dump
format. Memory contents are interpreted as ASCII codes.
A command-mode option “ascii” has been added to display memory or
register contents interpreted as ASCII codes. It joins the existing
“dec” and “hex” options for displaying in decimal or hexadecimal,
respectively. Only one of the three may be specified.
The actual characters to display for all the ASCII display options
(data segment window, dump memory, command-mode option) are
specified in the config.properties file. This includes a “placeholder”
character to be displayed for all codes specified as non-printing.
ASCII codes 1-7, 14-31, and 127-255 are specified as
non-printing, but this can be changed in the properties file.
A new Help tab called Exceptions has been added. It explains the basics
of MIPS exceptions and interrupts as implemented in MARS. It also includes
tips for writing and using exception handlers.
A new Tool called Bitmap Display has been added. You can use it
to simulate a simple bitmap display. Each word of the specified address
space represents a 24 bit RGB color (red in bits 16-23, green in bits
8-15, blue in bits 0-7) and a word’s value will be displayed on the Tool’s
display area when the word is written to by the MIPS program. The base
address corresponds to the upper left corner of the display, and words are
displayed in row-major order. Version 1.0 is pretty basic, constructed
from the Memory Reference Visualization Tool code.
Additional operand formats
were added for the multiplication pseudo-instructions ‘mul’ and ‘mulu’.
The editor’s context-sensitive pop-up help will now appear below
the current line whenever possible. Originally it appeared either above,
centered to the side,
or below, depending on the current line’s vertical position in the editing
window. Displaying the pop-up above the current line tended to visually block
important information, since frequently a line of code uses the same operand
(especially registers) as the one immediately above it.
The editor will now auto-indent each new line when the Enter
key is pressed. Indentation of the new line will match that of the
line that precedes it. This feature can be disabled in the Editor settings dialog.
Two new command-mode options have been added. The “aeN” option, where
N is an integer, will terminate MARS with exit value N when an assemble error
occurs. The “seN” option will similarly terminate MARS with exit value
N when a simulation (MIPS runtime) error occurs. These options can be useful
when writing scripts for grading. Thanks to my Software
Engineering students Robert Anderson, Jonathan Barnes, Sean Pomeroy, and Melissa Tress
for designing and implementing these options.
An editor bug that affected Macintosh users has been fixed.
Command shortcuts, e.g. Command-s for save, did not
function and also inserted the character into the text.
A bug in Syscall 54 (InputDialogString) has been fixed. This syscall is
the GUI equivalent of Syscall 8 (ReadString), which follows the semantics
of UNIX ‘fgets’. Syscall 54 has been modified to also follow the ‘fgets’
semantics.
A bug in the Cache Simulator Tool has been fixed. The animator that
paints visualized blocks green or red (to show cache hit or miss) sometimes
paints the wrong block when set-associated caching is used. The underlying
caching algorithm is correct so the numeric results such as hit ratios
have always been correct. The animator has been corrected.
Thanks to Andreas Schafer and his student Carsten Demel for bringing this
to my attention.
Mars 4.0.1 was released in October 2010. It is a bug fix release to address three bugs.
The Edit and Execute tabs of the IDE, which were relocated in 4.0 from the top to the left edge and oriented vertically, have been
moved back to the top edge because Macintosh running Java 1.6 does not correctly render vertically-oriented tabs.
An exception may be thrown in multi-file assembles when the last file of the assembly is not the longest. This occurs
only when using the IDE, and has been corrected.
If an assemble operation fails due to a non-existing exception handler file (specified through the IDE Settings menu), unchecking
the exception handler setting does not prevent the same error from occuring on the next assemble. This has been corrected.
Mars 4.0 was released in August 2010. Enhancements and bug fixes include:
New Text Editor: Mars features an entirely new integrated text editor. It creates a new tab for each file
as it is opened. The editor now features language-aware
color highlighting of many MIPS assembly language elements with customizable
colors and styles. It also features automatic context-sensitive popup instruction
guides. There are two levels: one with help and autocompletion of instruction names
and a second with help information for operands. These and other new editor
features can be customized or disabled through
the expanded Editor Settings dialog. You can even revert to the previous
notepad-style editor if you wish (multi-file capability is retained).
The language-aware editor is based on
the open source jEdit Syntax Package (syntax.jedit.org). It is separate from
the assembler, so any syntax highlighting quirks will not affect assembly.
Improved Instruction Help: All the instruction examples in the help tabs (and new popup instruction guides)
now use realistic register names, e.g. $t1, $t2, instead of $1, $2. The instruction format
key displayed above the MIPS help tabs has been expanded to include explanations of the
various addressing modes for load and store instructions and pseudo-instructions.
Descriptions have been added to every example instruction and pseudo-instruction.
Improved Assembly Error Capability: If the assemble operation results in errors, the first error message
in the Mars Messages text area will be highighted and the corresponding erroneous instruction will be selected in the
text editor. In addition, you can click on any error message in the Mars Messages text area to select the corresponding
erroneous instruction in the text editor. The first feature does not select in every situation (such as when
assemble-on-open is set) but in the situations where it doesn’t work no harm is done plus
the second feature, clicking on error messages, can still be used.
Console input syscalls (5, 6, 7, 8, 12) executed in the IDE now receive input keystrokes directly in the Run I/O text
area instead of through a popup input dialog. Thanks to Ricardo Pascual for providing this feature!
If you prefer the popup dialogs, there is a setting to restore them.
The floor, ceil, trunc and round operations now all produce the MIPS default result 2^31-1 if the value is
infinity, NaN or out of 32-bit range. For consistency, the sqrt operations now produce the result NaN if the operand is negative
(instead of raising an exception). These cases are all consistent with FCSR (FPU Control and Status Register)
Invalid Operation flag being off. The ideal solution would be to simulate the FCSR register itself so all
MIPS specs for floating point instructions can be implemented, but that hasn’t happened yet.
The Basic column in the Text Segment Window now displays data and addresses in either decimal or
hexadecimal, depending on the current settings. Note that the “address” in branch instructions
is actually an offset relative to the PC, so is treated as data not address. Since data operands in
basic instructions are no more than 16 bits long, their hexadecimal display includes only 4 digits.
The Source column in the Text Segment Window now preserves tab spacing for a cleaner appearance (tab characters were previously not rendered).
Instruction mnemonics can now be used as labels, e.g. “b:”.
New syscall 36 will display an integer as an unsigned decimal.
A new tool, Digital Lab Sim, contributed by Didier Teifreto (dteifreto@lifc.univ-fcomte.fr). This tool
features two seven-segment displays, a hexadecimal keypad, and a counter. It uses MMIO to explore
interrupt-driven I/O in an engaging setting. More information is available from its Help feature. Many thanks!
MARS 4.0 requires Java 1.5 (5.0) instead of 1.4. If this is an issue for you, let me know.
Mars 3.8 was released in January 2010. Enhancements and bug fixes include:
A new feature to temporarily suspend breakpoints you have previously set. Use it
when you feel confident enough to run your program without the breakpoints but not
confident enough to clear them! Use the Toggle Breakpoints item in the Run menu, or
simply click on the “Bkpt” column header in the Text Segment window. Repeat, to re-activate.
Two new Tools contributed by Ingo Kofler of Klagenfurt University in Austria.
One generates instruction statistics and the other simulates branch prediction using
a Branch History Table.
Two new print syscalls. Syscall 34 prints an integer in hexadecimal format.
Syscall 35 prints an integer in binary format. Suggested by Bernardo Cunha of Portugal.
A new Setting to control whether or not the MIPS program counter will be
initialized to the statement with global label ‘main’ if such a statement exists. If
the setting is unchecked or if checked and there is no ‘main’, the program counter
will be initialized to the default starting address. Release 3.7 was programmed
to automatically initialize it to the statement labeled ‘main’. This led to
problems with programs that use the standard SPIM exception handler exceptions.s
because it includes a short statement sequence at the default starting address
to do some initialization then branch to ‘main’. Under 3.7 the initialization
sequence was being bypassed. By default this setting is unchecked. This
option can be specified in command mode using the ‘sm’ (Start at Main) option.
Mars Tools that exist outside of Mars can now be included in the Tools
menu by placing them in a JAR and including it in a command that launches
the Mars IDE. For example: java -cp plugin.jar;Mars.jar Mars
Thanks to Ingo Kofler for thinking of this technique and providing the
patch to implement it.
Corrections and general improvements to the MIDI syscalls. Thanks to Max Hailperin
of Gustavus Adolphus College for supplying them.
Correction to an assembler bug that flagged misidentified invalid MIPS instructions
as directives.
Mars 3.7 was released in August 2009. Enhancements and bug fixes include:
A new feature for changing the address space configuration of the
simulated MIPS machine. The 32-bit address space configuration used by
all previous releases remains the default. We have defined two
alternative configurations for a compact 32KB address space. One starts the
text segment at address 0 and the other starts the data segment at address 0.
A 32KB address space permits commonly-used load/store pseudo-instructions
using labels, such as lw $t0,increment, to expand to a single basic
instruction since the label’s full address will fit into the 16-bit address
offset field without sign-extending to a negative value. This was done in response to
several requests over the years for smaller addresses and simplified expansions
to make assembly programs easier to comprehend. This release does not
include the ability to define your own customized configuration, although we
anticipate adding it in the future. It is available both through the command
mode (option mc) and the IDE.
See Memory Configuration… at the bottom of the Settings menu.
Related to the previous item: load and store pseudo-instructions of the form
lw $t0,label and lw $t0,label($t1) will expand to a single
instruction (addi for these examples) if the current memory configuration assures the
label’s full address will fit into the low-order 15 bits. Instructions
for which this was implemented are: la, lw, lh, lb, lhu, lbu, lwl, lwr, ll,
lwc1, ldc1, l.s, l.d, sw, sh, sb, swl, swr, sc, swc1, sdc1,
s.s, and s.d.
If a file contains a global statement label “main” (without quotes, case-sensitive), then execution will
begin at that statement regardless of its address. Previously, program execution
always started at the base address of the text segment. This will be handy for
multi-file projects because you no longer need to have the “main file” opened in
the editor in order to run the project. Note that main has to be declared global
using the .globl directive.
We have added a Find/Replace feature to the editor. This has been another
frequent request. Access it through the Edit menu or Ctrl-F. Look for major
enhancements to the editor in 2010!
The syscalls for Open File (13), Read from File (14), and Write to File (15)
all now place their return value into register $v0 instead of $a0. The table
in Computer Organization and Design’s Appendix B on SPIM specifies
$a0 but SPIM itself consistently uses $v0 for the return values.
Pseudo-instructions for div, divu, mulo, mulou, rem, remu, seq, sne, sge,
sgeu, sgt, sgtu, sle, sleu now accept a 16- or 32-bit immediate as their third operand.
Previously the third operand had to be a register.
Existing Tools were tested using reconfigured memory address space (see first item). Made some
adaptations to the Keyboard and Display Simulator Tool that allow it to be used for
Memory Mapped I/O (MMIO) even under the compact memory model, where the MMIO base address
is 0x00007f00 instead of 0xffff0000. Highlighting is not perfect in this scenario.
Bug Fix: The syscall for Open File (13) reversed the meanings of the
terms mode and flag. Flags are used to indicate the intended
use of the file (read/write). Mode is used to set file permissions in specific situations.
MARS implements selected flags as supported by Java file streams,
and ignores the mode if specified. For more details, see the Syscalls
tab under Help. The file example in that tab has been corrected.
Bug Fix: The assembler incorrectly generated an
error on Jump instructions located in the kernel text segment.
Bug Fix: The project (p) option in the command interface worked incorrectly
when MARS was invoked within the directory containing the files to be assembled.
Acknowledgement: The development of Release 3.7 was supported by a SIGCSE
Special Projects Grant.
Mars 3.6 was released in January 2009. Enhancements and bug fixes include:
We’ve finally implemented the most requested new feature: memory and register cells will
be highlighted when written to during timed or stepped simulation! The
highlighted memory/register cell thus represents the result of the instruction just completed.
During timed or stepped execution, this is NOT the highlighted instruction. During back-stepping,
this IS the highlighted instruction. The highlighted instruction is the next one
to be executed in the normal (forward) execution sequence.
In conjunction with cell highlighting, we’ve added the ability to customize the highlighting
color scheme and font. Select Highlighting in the Settings menu. In the resulting dialog,
you can select highlight background color, text color, and font for the different runtime tables (Text segment,
Data segment, Registers). You can also select them for normal, not just
highlighted, display by even- and odd-numbered row but not by table.
Cool new Labels Window feature: the table can be sorted in either ascending or descending
order based on either the Label (alphanumeric) or the Address (numeric) column. Just click on
the column heading to select and toggle between ascending (upright triangle) or descending
(inverted triangle). Addresses are sorted based on unsigned 32 bit values.
The setting persists across sessions.
The Messages panel, which includes the Mars Messages and Run I/O tabs, now displays using
a mono-spaced (fixed character width) font. This facilitates text-based graphics when running
from the IDE.
The Mars.jar distribution file now contains all files needed to produce
a new jar file. This will make it easier for you to expand the jar, modify source files,
recompile and produce a new jar for local use. CreatMarsJar.bat contains the jar instruction.
The Help window now includes a tab for Acknowledgements. This recognizes MARS contributors
and correspondents.
We’ve added a new system call (syscall) for generating MIDI tones synchronously, syscall 33.
The original MIDI call returns immediately when the tone is generated. The new one will not return
until the tone output is complete regardless of its duration.
The Data Segment display now scrolls 8 rows (half a table) rather than 16 when the
arrow buttons are clicked. This makes it easier to view a sequence of related cells that
happen to cross a table boundary. Note you can hold down either button for rapid scrolling.
The combo box with various data address boundaries also works better now.
Bug Fix: Two corrections to the Keyboard and Display Simulator Tool. Transmitter Ready bit was
not being reset based on instruction count
when running in the kernel text segment, and the Status register’s Exception Level bit was not
tested before enabling the interrupt service routine (could lead to looping if interrupts occur
w/i the interrupt service routine). Thanks to Michael Clancy and Carl Hauser for bringing these
to my attention and suggesting solutions.
Bug Fix: Stack segment byte addresses not on word boundaries were not being processed
correctly. This applies to little-endian byte order (big-endian is not enabled or tested in MARS).
Thanks to Saul Spatz for recognizing the problem and providing a patch.
Minor Bug Fixes include: Correcting a fault leading to failure when launching MARS in command
mode, clarifying assembler error message for too-few or too-many operands error, and correcting the
description of lhu and lbu instructions from “unaligned” to “unsigned”.
Mars 3.5 was released in August 2008. Major enhancements and bug fixes include:
A new Tool, the Keyboard and Display MMIO Simulator, that supports polled and interrupt-driven
input and output operations through Memory-Mapped I/O (MMIO) memory. The MIPS program writes to
memory locations which serve as registers for simulated devices. Supports keyboard input and a
simulated character-oriented display. Click the tool’s Help button for more details.
A new Tool, the Instruction Counter, contributed by MARS user Felipe Lessa. It will count the
number of MIPS instructions executed along with percentages for R-format, I-format, and J-format
instructions. Thanks, Felipe!
Program arguments can now be provided to the MIPS program at runtime, through either an IDE setting or
command mode. See the command mode “pa” option for more details on command mode operation. The argument
count (argc) is placed in $a0 and the address of an array of null-terminated strings containing the
arguments (argv) is placed in $a1. They are also available on the runtime stack ($sp).
Two related changes permit MARS to assemble source code produced by certain compilers such as gcc.
One change is to issue warnings rather than errors for unrecognized directives. MARS implements a
limited number of directives. Ignore these warnings at your risk, but the assembly can continue.
The second change is to allow statement labels to contain, and specifically begin with, ‘$’.
In command mode, final register values are displayed by giving the register name as an option.
Register names begin with ‘$’, which is intercepted by certain OS command shells. The
convention for escaping it is not uniform across shells. We have enhanced the options so now you can
give the register name without the ‘$’. For instance, you can use t0 instead of $t0 as the option.
You cannot refer to registers by number in this manner, since an integer option is interpreted by
the command parser as an instruction execution limit. Thanks to Lucien Chaubert for reporting
this problem.
Minor enhancements: The command mode dump feature has been extended to permit memory address ranges as well
as segment names. If you enter a new file extension into the Open dialog, the extension will remain available throughout
the interactive session. The data segment value repetition operator ‘:’ now
works for all numeric directives (.word, .half, .byte, .float, .double).
This allows you to initialize multiple consecutive memory locations to the same value. For
example:
ones: .half 1 : 8 # Store the value 1 in 8 consecutive halfwords
Major change: Hexadecimal constants containing less than 8 digits will be interpreted as though the
leading digits are 0’s. For instance, 0xFFFF will be interpreted as 0x0000FFFF, not 0xFFFFFFFF as before.
This was causing problems with immediate operands in the range 32768 through 65535, which were
misinterpreted by the logical operations as signed 32 bit values rather than unsigned 16 bit values.
Signed and unsigned 16 bit values are now distinguished by the tokenizer based on the prototype
symbols -100 for signed and 100 for unsigned (mainly logical operations).
Many thanks to Eric Shade of Missouri State University and Greg Gibeling of UC Berkeley for
their extended efforts in helping me address this situation.
Minor Bug Fixes: round.w.s and round.w.d have been modified to correctly perform IEEE
rounding by default. Thanks to Eric Shade for pointing this out.
Syscall 12 (read character) has been changed to leave the character in $v0 rather then $a0. The
original was based on a misprint in Appendix A of Computer Organization and Design.
MARS would not execute from the executable Mars.jar file if it was stored in a directory
path those directory names contain any non-ASCII characters. This has been corrected. Thanks to
Felipe Lessa for pointing this out and offering a solution.
MARS will now correctly detect the EOF condition when reading from a file using syscall 14.
Thanks to David Reimann for bringing this to our attention.
Mars 3.4.1 was released on 23 January 2008. It is a bug fix release to address two bugs.
One bug shows up in pseudo-instructions in which the expansion includes branch instructions. The fixed branch
offsets were no longer correct due to changes in the calculation of branch offsets in Release 3.4.
At the same time, we addressed the issue of expanding such pseudo-instructions when
delayed branching is enabled. Such expansions will now include a nop instruction following the
branch.
We also addressed an off-by-one error that occurred in generating the lui instruction in the
expansion of conditional branch pseudo-instructions whose second operand is a 32 bit immediate.
The expansions for a number of pseudo-instructions were modified to eliminate internal branches.
These and other expansions were also optimized for sign-extended loading of 16-bit immediate operands
by replacing the lui/ori or lui/sra sequence with addi. Pseudo-instructions affected by one
or both of these modifications include: abs, bleu, bgtu, beq, bne, seq, sge, sgeu, sle, sleu, sne,
li, sub and subi. These modifications were suggested by Eric Shade of Missouri State University.
Mars 3.4 was released in January 2008. Major enhancements are:
A new syscall (32) to support pauses of specified length in milliseconds (sleep) during simulated execution.
Five new syscalls (40-44) to support the use of pseudo-random number generators. An unlimited number of these generators are available,
each identified by an integer value, and for each you have the ability to: set the seed value, generate a 32 bit integer value from the Java
int range, generate a 32 bit integer value between 0 (inclusive) and a specified upper bound (exclusive), generate a 32-bit float value between 0 (inclusive) and 1 (exclusive),
and generate a 64-bit double value between 0 (inclusive) and 1 (exclusive). All are based on the java.util.Random class.
Ten new syscalls (50-59) to support message dialog windows and data input dialog windows. The latter are distinguished from
the standard data input syscalls in that a prompting message is specified as a syscall argument and displayed in the input dialog.
All are based on the javax.swing.JOptionPane class.
The capability to dump .text or .data memory contents to file in various formats. The dump can be performed
before or after program execution from either the IDE (File menu and toolbar) or from command mode. It can also be performed
during an execution pause from the IDE. Look for the “Dump Memory” menu item in the File menu, or the “dump” option in command
mode. A .text dump will include only locations containing an instruction. A .data dump will include a multiple
of 4KB “pages” starting at the segment base address and ending with the last 4KB “page” to be referenced by the
program. Current dump formats include pure binary (java.io.PrintStream.write() method), hexadecimal text with one word (32 bits)
per line, and binary text with one word per line. An interface, abstract class, and format loader have been developed to facilitate
development and deployment of additional dump formats. This capability was prototyped by Greg Gibeling of UC Berkeley.
Changed the calculation of branch offsets when Delayed Branching setting is disabled.
Branch instruction target addresses are represented by
the relative number of words to branch. With Release 3.4, this value reflects delayed branching,
regardless of whether the Delayed Branching setting is enabled or not.
The generated binary code for branches will now match that of examples in the Computer Organization
and Design textbook. This is a change from the past, and was made after extensive discussions
with several MARS adopters. Previously, the branch offset was 1 lower if the Delayed Branching setting
was enabled — the instruction label: beq $0,$0,label would generate 0x1000FFFF if
Delayed Branching was enabled and 0x10000000 if it was disabled. Now it will generate 0x1000FFFF in
either case. The simulator will always branch to the correct location; MARS does not allow assembly under one
setting and simulation under the other.
Bug fix: The mars.jar executable JAR file can now be run from a different working directory. Fix was
suggested by Zachary Kurmas of Grand Valley State University.
Bug fix: The problem of MARS hanging while assembling a pseudo-instruction with a label operand that
contains the substring “lab”, has been fixed.
Bug fix: No Swing-related code will be executed when MARS is run in command mode. This fixes a problem that
occurred when MARS was run on a “headless” system (no monitor). Swing is the Java library to support
programming Graphical User Interfaces. Fix was provided by Greg Gibeling of UC Berkeley.
The ‘\0’ character is now recognized when it appears in string literals.
MARS 3.3 was released in July 2007. Major enhancements are:
Support for MIPS delayed branching. All MIPS computers implement this but it can be confusing for
programmers, so it is disabled by default. Under delayed branching, the next instruction after a branch
or jump instruction will always be executed, even if the branch or jump is taken! Many
programmers and assemblers deal with this by inserting a do-nothing “nop” instruction after every branch or jump.
The MARS assembler does not insert a “nop”. Certain pseudo-instructions expand to
a sequence that includes a branch; such instructions will not work correctly under delayed
branching.
Delayed branching is available in command mode with the “db” option.
A new tool of interest mainly to instructors. The Screen Magnifier tool, when selected from
the Tools menu, can be used to produce an enlarged static image of the pixels that lie beneath it.
The image can be annotated by dragging the mouse over it to produce a scribble line. It enlarges
up to 4 times original size.
You now have the ability to set and modify the text editor font family, style and size. Select
“Editor…” from the Settings menu to get the dialog. Click the Apply button to see the new
settings while the dialog is still open. Font settings are retained from one session to the next.
The font family list begins with 6 fonts commonly used across platforms (selected from lists
found at www.codestyle.org), followed by a complete list.
Two of the six are monospaced fonts, two are proportional serif, and two are proportional sans serif.
The Labels window on the Execute pane, which displays symbol table information, has been
enhanced. When you click on a label name or its address, the contents of that address are
centered and highlighted in the Text Segment window or Data Segment window as appropriate. This makes
it easier to set breakpoints based on text labels, or to find the value stored at a label’s address.
If you re-order the columns in the Text Segment window by dragging a column header,
the new ordering will be remembered and applied from that time forward, even from one MARS session to the next. The Text Segment
window is where source code, basic code, binary code, code addresses, and breakpoints are displayed.
If a MIPS program terminates by “running off the bottom” of the program, MARS terminates, as
before, without an exception, but now will display a more descriptive termination message in the
Messages window. Previously, the termination message was the same as that generated after executing an Exit syscall.
A new system call (syscall) to obtain the system time is now available. It is service
30 and is not available in SPIM. Its value is obtained from the java.util.Date.getTime() method.
See the Syscall tab in MIPS help for further information.
A new system call (syscall) to produce simulated MIDI sound through your sound card is now available.
It is service 31 and is not available in SPIM. Its implementation is based on the
javax.sound.midi package. It has been tested only under Windows.
See the Syscall tab in MIPS help for further information.
MARS 3.2.1 was released in January 2007. It is a bug fix release that addresses the
following bug in 3.2: a NullPointerException occurs when MIPS program execution terminates
by “dropping off the bottom” of the program rather than by using one of the Exit system
calls.
MARS 3.2 was released in December 2006. Major enhancements are:
It fixes several minor bugs, including one that
could cause incorrect file sequencing in the Project feature.
It includes the
AbstractMarsToolAndApplication abstract class to serve as a framework for easily
constructing “tools” and equivalent free-standing applications that use the MARS assembler
and simulator engines (kudos to the SIGCSE 2006 audience member who suggested this capability!).
A subclass of this abstract class can be used both ways (tool or application).
The floating
point and data cache tools were elaborated in this release and a new tool for animating and
visualizing memory references was developed. All are AbstractMarsToolAndApplication
subclasses.
This release includes support for exception handlers: the kernel data and text
segments (.kdata and .ktext directives), the MIPS trap-related instructions, and the ability
to automatically include a selected exception (trap) handler with each assemble operation.
Items in the Settings menu became persistent with this release.
Added default assembly file extensions “asm” and “s” to the Config.properties file and used
those not only to filter files for the File Open dialog but also to filter them for the “assemble all”
setting.
Implemented a limit to the amount of text scrollable in the Mars Messages and Run I/O message
tabs – default 1 MB is set in the Config.properties file.
For programmer convenience, labels can now be referenced in the operand field of integer
data directives (.word, .half, .byte). The assembler will substitute the label’s address (low order
half for .half, low order byte for .byte).
For programmer convenience, character literals (e.g. ‘b’, ‘\n’, ‘\377’) can be used anywhere that integer literals are
permitted. The assembler converts them directly to their equivalent 8 bit integer value. Unicode is not supported and
octal values must be exactly 3 digits ranging from ‘\000’ to ‘\377’.
Replaced buttons for selecting Data Segment display base addresses with a combo box and added more
base addresses: MMIO (0xFFFF0000), .kdata (0x90000000), .extern (0x10000000).
MARS 3.1 was released in October 2006. The major issues and features are listed here:
It addressed several minor limits (Tools menu items
could not be run from the JAR file, non-standard shortcuts for Mac users, inflexible and
sometimes inappropriate sizing of
GUI components).
It changed the way SYSCALLs are implemented, to allow anyone to define
new customized syscall services without modifying MARS.
It added a primitive
Project capability through the “Assemble operation applies to all files in current directory.”
setting (also available as “p” option in command mode). The command mode also allows you
to list several file names not necessarily in the same directory to be assembled and linked.
Multi-file assembly also required implementing the “.globl” and “.extern” directives.
And although “Mars tools” are not officially part of MARS releases, MARS 3.1 includes the
initial versions of two tools: one for learning about floating point representation and another
for simulating data caching capability.
MARS 3.0 was released in August 2006, with one bug fix and two major additions.
The bug fix was corrected instruction format for the slti and sltiu instructions.
One major addition is a greatly expanded MIPS-32 instruction
set (trap instructions are the only significant ones to remain unimplemented). This includes, via
pseudo-instructions, all reasonable memory addressing modes for the load/store instructions.
The
second major addition is ability to interactively step “backward” through program execution
one instruction at a time to “undo” execution steps. It will buffer up to 2000 of the most
recent execution steps (this limit is stored in a properties file and can be changed).
It will undo changes made to MIPS memory, registers or condition flags,
but not console or file I/O. This should be a great debugging aid.
It is available anytime execution is paused and at termination (even if terminated due to
exception).
A number of IDE settings, described
above, are now available through the Settings menu.
MARS 2.2 was released in March 2006 with additional bug fixes and implemented command
line options (run MARS from command line with h option for command line help). This also coincides with our
SIGCSE 2006 paper “MARS: An Education-Oriented MIPS Assembly Language Simulator”.
MARS 2.1 was released in October 2005 with some bug fixes.
MARS 2.0 was released in September 2005. It incorporated significant
modifications to both the GUI and the assembler, floating point registers and instructions
most notably.
MARS 1.0 was released in January 2005 and
publicized during a poster presentation at SIGCSE 2005.
Dr. Ken Vollmar initiated MARS development in 2002 at Missouri State University. In
2003, Dr. Pete Sanderson of Otterbein College and his student Jason Bumgarner continued
implementation. Sanderson implemented the assembler and simulator that summer, and
the basic GUI the following summer, 2004.
The development of Releases 3.1 and 3.2 in 2006 and 4.0 in 2010 were supported by the Otterbein College
sabbatical leave program. The development of Release 3.7 during summer 2009 was supported by
a SIGCSE Special Projects Grant.
This document is available for printing on the MARS home page
http://www.cs.missouristate.edu/MARS/.
The MIPS Instruction Set
The MIPS Instruction Set
Written by Walter Chang
Used by permission of the author. Copyright notice below.
Correct pronunciation is critical to get the cadence and beat to line
up; see the Pronunciation
Guide at the end of this document for how you should pronounce the various
assembler instructions.
To the tune of: The Major-General’s Song, from
Pirates of Penzance
Inspired by Tom Lehrer’s The Elements
There’s div and nor and mult and or and sllv sra
There’s xor and swl and beq and sll and bgezal jumps today
And multu, srav, and j combined with lhu and lui
And also slt and bne and instruction mthi
There’s sh and sb and lbu and blez and jal and then sltu
And of course there’s and and add and srl and sub and things to do
With the MIPS instructions I am very nimble on my feet
And though I sing assembler but I am really not a geek
There’s addu, ori, slti, swr, and bgez and jalr too
And loads of other fun instructions that were put in just for you
The MIPS instruction set is very simple to be memorized
Which will come in handy when you have your code to optimize!
There’s addi, divu, lh, rfe, and syscall, jr, mfcz
And mfc1, nop, and break, and bltzal with bczt
And srlv, xori, bltz, and lb, lwl, and addiu
andi, subu, lwr, and lwcz, mtcz, sltiu
There’s bczf, bgtz to branch if it’s greater than
And mflo and sw, these instructions are not any also-rans
There’s mtlo and swcz too, although I don’t know what they’re for
And lw – that’s obviously load word from mem bytes there are four
And now my song is through and I know all of my words by the heart
Which will come in handy when we have our projects multi-part
I live and breathe the MIPS instruction set on every night and day
Because the MIPS assembler will always try and work my way!
Pronunciation Guide
note: assembler is 4 syllables: ass-em-bell-er
The pronunciations suitable for this song are as follows:
div: div
nor: nor
mult: mult
or: or
sllv: s-l-l-v
sra: s-r-a
xor: zor
swl: swill
beq: beck
sll: sill
bgezal: beh-geezal
multu: mult-you
srav: srav (one syllable)
j: jay
lhu: l-h-u
lui: l-u-i
slt: slit
bne: b-n-e
mthi: m-t-high
sh: shih
sb: sib
lbu: l-b-u
blez: blez
jal: jal
sltu: slit-u
and: and
add: add
srl: srill
sub: sub
addu: add-u
ori: or-i
slti: slitty
swr: swir
bgez: beh-gez
jalr: jal-er
addi: addy
divu: div-u
lh: l-h
rfe: reef
syscall: sis-call
jr: junior
mfcz: miff-c-z
mfc1: m-f-c-one
nop: nopp
break: break
bltzal: blitz-al
bczt: b-c-z-t
srlv: s-r-l-v
xori: zorri
bltz: blitz
lb: l-b
lwl: lwill
addiu: addy-you
andi: andy
subu: sub-u
lwr: lwer
lwcz: lwiscz
mtcz: m-t-c-z
sltiu: slitty-u
bzcf: b-z-c-f
bgtz: b-g-t-z
mflo: em-flow
sw: swee
mtlo: m-t-low
swcz: swizzy
lw: lwee
http://www.cs.utexas.edu/users/walter/cs-songbook/instruction_set.html
Copyright Walter Chang. Permission granted for noncommercial use
as long as attribution is maintained. walter@cs.utexas.edu
Intro
Settings
Syscalls
IDE
Debugging
Command
Tools
History
Limitations
Exception Handlers
Macros
Acknowledgements
MARS home
MIPS/SPIM Reference Card
CORE INSTRUCTION SET (INCLUDING PSEUDO INSTRUCTIONS)
MNE- FOR- OPCODE/
MON- MAT FUNCT
NAME IC OPERATION (in Verilog) (Hex)
Add add R R[rd]=R[rs]+R[rt] (1) 0/20
Add Immediate addi I R[rt]=R[rs]+SignExtImm (1)(2) 8
Add Imm. Unsigned addiu I R[rt]=R[rs]+SignExtImm (2) 9
Add Unsigned addu R R[rd]=R[rs]+R[rt] (2) 0/21
Subtract sub R R[rd]=R[rs]-R[rt] (1) 0/22
Subtract Unsigned subu R R[rd]=R[rs]-R[rt] 0/23
And and R R[rd]=R[rs]&R[rt] 0/24
And Immediate andi I R[rt]=R[rs]&ZeroExtImm (3) c
Nor nor R R[rd]=∼(R[rs]|R[rt]) 0/27
Or or R R[rd]=R[rs]|R[rt] 0/25
Or Immediate ori I R[rt]=R[rs]|ZeroExtImm (3) d
Xor xor R R[rd]=R[rs]ˆR[rt] 0/26
Xor Immediate xori I R[rt]=R[rs]ˆZeroExtImm e
Shift Left Logical sll R R[rd]=R[rs]�shamt 0/00
Shift Right Logical srl R R[rd]=R[rs]�shamt 0/02
Shift Right Arithmetic sra R R[rd]=R[rs]�>shamt 0/03
Shift Left Logical Var. sllv R R[rd]=R[rs]�R[rt] 0/04
Shift Right Logical Var. srlv R R[rd]=R[rs]�R[rt] 0/06
Shift Right Arithmetic Var. srav R R[rd]=R[rs]�>R[rt] 0/07
Set Less Than slt R R[rd]=(R[rs]
Branch Less Than Or Equal ble P if(R[rs]<=R[rt]) PC=PC+4+BranchAddr
Branch Greater Than Or Equal bge P if(R[rs]>=R[rt]) PC=PC+4+BranchAddr
Jump j J PC=JumpAddr (5) 2
Jump And Link jal J R[31]=PC+4; (5) 2
PC=JumpAddr
Jump Register jr R PC=R[rs] 0/08
Jump And Link Register jalr R R[31]=PC+4; 0/09
PC=R[rs]
Move move P R[rd]=R[rs]
Load Byte lb I R[rt]={24’b0, M[R[rs]+ZeroExtImm](7:0)} (3) 20
Load Byte Unsigned lbu I R[rt]={24’b0, M[R[rs]+SignExtImm](7:0)} (2) 24
Load Halfword lh I R[rt]={16’b0, M[R[rs]+ZeroExtImm](15:0)} (3) 25
Load Halfword Unsigned lhu I R[rt]={16’b0, M[R[rs]+SignExtImm](15:0)} (2) 25
Load Upper Imm. lui I R[rt]={imm,16’b0} f
Load Word lw I R[rt]=M[R[rs]+SignExtImm] (2) 23
Load Immediate li P R[rd]=immediate
Load Address la P R[rd]=immediate
Store Byte sb I M[R[rs]+SignExtImm] (7:0)=R[rt](7:0) (2) 28
Store Halfword sh I M[R[rs]+SignExtImm] (15:0)=R[rt](15:0) (2) 29
Store Word sw I M[R[rs]+SignExtImm]=R[rt] (2) 2b
REGISTERS
NAME NMBR USE STORE?
$zero 0 The Constant Value 0 N.A.
$at 1 Assembler Temporary No
$v0-$v1 2-3 Values for Function Results and
Expression Evaluation
No
$a0-$a3 4-7 Arguments No
$t0-$t7 8-15 Temporaries No
$s0-$s7 16-23 Saved Temporaries Yes
$t8-$t9 24-25 Temporaries No
$k0-$k1 26-27 Reserved for OS Kernel No
$gp 28 Global Pointer Yes
$sp 29 Stack Pointer Yes
$fp 30 Frame Pointer Yes
$ra 31 Return Address Yes
$f0-$f31 0-31 Floating Point Registers Yes
(1) May cause overflow exception
(2) SignExtImm ={16{immediate[15]},immediate }
(3) ZeroExtImm ={16{1b’0},immediate }
(4) BranchAddr = {14{immediate[15]},immediate,2’b0 }
(4) JumpAddr = {PC[31:28], address, 2’b0 }
(6) Operands considered unsigned numbers (vs. 2 s comp.)
BASIC INSTRUCTION FORMATS,
FLOATING POINT INSTRUCTION FORMATS
R 31 opcode 2625 rs 2120 rt 1615 rd 1110 shamt 65 funct 0
I 31 opcode 2625 rs 2120 rt 1615 immediate 0
J 31 opcode 2625 immediate 0
FR 31 opcode 2625 fmt 2120 ft 1615 fs 1110 fd 65 funct 0
FI 31 opcode 2625 fmt 2120 rt 1615 immediate 0
Copyright c© 2007 Jan Wätzig, Staatliche Studienakademie Dresden (www.ba-dresden.de/∼jan)
This reference card may be used for educational purposes only.
http://www.ba-dresden.de/~jan
ARITHMETIC CORE INSTRUCTION SET
MNE- FOR- OPCODE/
MON- MAT FMT/FT/
NAME IC OPERATION (in Verilog) FUNCT
Divide div R Lo=R[rs]/R[rt]; 0/–/–/1a
Hi=R[rs]%R[rt]
Divide Unsigned divu R Lo=R[rs]/R[rt]; (6) 0/–/–/1b
Hi=R[rs]%R[rt]
Multiply mult R {Hi,Lo}=R[rs]∗R[rt] 0/–/–/18
Multiply Unsigned multu R {Hi,Lo}=R[rs]∗R[rt] (6) 0/–/–/19
Branch On FP True bc1t FI if(FPCond) PC=PC+4+BranchAddr (4) 11/8/1/–
Branch On FP False bc1f FR if(!FPCond) PC=PC+4+BranchAddr (4) 11/8/0/–
FP Compare Single c.x.s∗ FR FPCond=(F[fs] op F[ft])?1:0 11/10/–/y
FP Compare Double c.x.d∗ FR FPCond=({F[fs],F[fs+1]} op {F[ft],F[ft+1]})?1:0 11/11/–/y
∗(x is eq, lt or le) (op is ==, < or <=) (y is 32, 3c or 3e) FP Add Single add.s FR F[fd]=F[fs]+F[ft] 11/10/–/0 FP Divide Single div.s FR F[fd]=F[fs]/F[ft] 11/10/–/3 FP Multiply Single mul.s FR F[fd]=F[fs]∗F[ft] 11/10/–/2 FP Subtract Single sub.s FR F[fd]=F[fs]-F[ft] 11/10/–/1 FP Add Double add.d FR {F[fd],F[fd+1]}={F[fs],F[fs+1]}+{F[ft],F[ft+1]} 11/11/–/0 FP Divide Double div.d FR {F[fd],F[fd+1]}={F[fs],F[fs+1]}/{F[ft],F[ft+1]} 11/11/–/3 FP Multiply Double mul.d FR {F[fd],F[fd+1]}={F[fs],F[fs+1]}∗{F[ft],F[ft+1]} 11/11/–/2 FP Subtract Double sub.d FR {F[fd],F[fd+1]}={F[fs],F[fs+1]}-{F[ft],F[ft+1]} 11/11/–/1 Move From Hi mfhi R R[rd]=Hi 0/–/–/10 Move From Lo mflo R R[rd]=Lo 0/–/–/12 Move From Control mfc0 R R[rd]=CR[rs] 16/0/–/0 Load FP Single lwc1 I F[rt]=M[R[rs]+SignExtImm] (2) 31/–/–/– Load FP Double ldc1 I F[rt]=M[R[rs]+SignExtImm]; (2) 35/–/–/– F[rt+1]=M[R[rs]+SignExtImm+4] Store FP Single swc1 I M[R[rs]+SignExtImm]=F[rt] (2) 39/–/–/– Store FP Double sdc1 I M[R[rs]+SignExtImm]=F[rt]; (2) 3d/–/–/– M[R[rs]+SignExtImm+4]=F[rt+1] ASSEMBLER DIRECTIVES .data [addr]∗ Subsequent items are stored in the data segment .kdata [addr]∗ Subsequent items are stored in the kernel data segment .ktext [addr]∗ Subsequent items are stored in the kernel text segment .text [addr]∗ Subsequent items are stored in the text ∗ starting at [addr] if specified .ascii str Store string str in memory, but do not null-terminate it .asciiz str Store string str in memory and null-terminate it .byte b1, . . . , bn Store the n values in successive bytes of memory .double d1, . . . , dn Store the n floating-point double precision numbers in successive memory locations .float f1, . . . , f1 Store the n floating-point single precision numbers in successive memory locations .half h1, . . . , hn Store the n 16-bit quantities in successive memory halfwords .word w1, . . . , wn Store the n 32-bit quantities in successive memory words .space n Allocate n bytes of space in the current segment .extern symsize Declare that the datum stored at sym is size bytes large and is a global label .globl sym Declare that label sym is global and can be referenced from other files .align n Align the next datum on a 2n byte boundary, until the next .data or .kdata directive .set at Tells SPIM to complain if subsequent instructions use $at .set noat prevents SPIM from complaining if subsequent instructions use $at SYSCALLS SERVICE $v0 ARGS RESULT print_int 1 integer $a0 print_float 2 float $f12 print_double 3 double $f12/$f13 print_string 4 string $a0 read_int 5 integer (in $v0) read_float 6 float (in $f0) read_double 7 double (in $f0) read_string 8 buf $a0, buflen $a1 sbrk 9 amount $a address (in $v0) exit 10 EXCEPTION CODES Number Name Cause of Exception 0 Int Interrupt (hardware) 4 AdEL Address Error Exception (load or instruction fetch) 5 AdES Address Error Exception (store) 6 IBE Bus Error on Instruction Fetch 7 DBE Bus Error on Load or Store 8 Sys Syscall Exception 9 Bp Breakpoint Exception 10 RI Reserved Instruction Exception 11 CpU Coprocessor Unimplemented 12 Ov Arithmetic Overflow Exception 13 Tr Trap 15 FPE Floating Point Exception [1] Patterson, David A; Hennessy, John J.: Computer Organization and Design, 3rd Edition. Morgan Kaufmann Publishers. San Francisco, 2005. Copyright c© 2007 Jan Wätzig, Staatliche Studienakademie Dresden (www.ba-dresden.de/∼jan) This reference card may be used for educational purposes only. http://www.ba-dresden.de/~jan MIPS syscall functions available in MARS SYSCALL functions available in MARS Introduction A number of system services, mainly for input and output, are available for use by your MIPS program. They are described in the table below. MIPS register contents are not affected by a system call, except for result registers as specified in the table below. How to use SYSCALL system services Step 1. Load the service number in register $v0. Step 2. Load argument values, if any, in $a0, $a1, $a2, or $f12 as specified. Step 3. Issue the SYSCALL instruction. Step 4. Retrieve return values, if any, from result registers as specified. Example: display the value stored in $t0 on the console li $v0, 1 # service 1 is print integer add $a0, $t0, $zero # load desired value into argument register $a0, using pseudo-op syscall Table of Available Services Service Code in $v0 Arguments Result print integer 1 $a0 = integer to print print float 2 $f12 = float to print print double 3 $f12 = double to print print string 4 $a0 = address of null-terminated string to print read integer 5 $v0 contains integer read read float 6 $f0 contains float read read double 7 $f0 contains double read read string 8 $a0 = address of input buffer $a1 = maximum number of characters to read See note below table sbrk (allocate heap memory) 9 $a0 = number of bytes to allocate $v0 contains address of allocated memory exit (terminate execution) 10 print character 11 $a0 = character to print See note below table read character 12 $v0 contains character read open file 13 $a0 = address of null-terminated string containing filename $a1 = flags $a2 = mode $v0 contains file descriptor (negative if error). See note below table read from file 14 $a0 = file descriptor $a1 = address of input buffer $a2 = maximum number of characters to read $v0 contains number of characters read (0 if end-of-file, negative if error). See note below table write to file 15 $a0 = file descriptor $a1 = address of output buffer $a2 = number of characters to write $v0 contains number of characters written (negative if error). See note below table close file 16 $a0 = file descriptor exit2 (terminate with value) 17 $a0 = termination result See note below table Services 1 through 17 are compatible with the SPIM simulator, other than Open File (13) as described in the Notes below the table. Services 30 and higher are exclusive to MARS. time (system time) 30 $a0 = low order 32 bits of system time $a1 = high order 32 bits of system time. See note below table MIDI out 31 $a0 = pitch (0-127) $a1 = duration in milliseconds $a2 = instrument (0-127) $a3 = volume (0-127) Generate tone and return immediately. See note below table sleep 32 $a0 = the length of time to sleep in milliseconds. Causes the MARS Java thread to sleep for (at least) the specified number of milliseconds. This timing will not be precise, as the Java implementation will add some overhead. MIDI out synchronous 33 $a0 = pitch (0-127) $a1 = duration in milliseconds $a2 = instrument (0-127) $a3 = volume (0-127) Generate tone and return upon tone completion. See note below table print integer in hexadecimal 34 $a0 = integer to print Displayed value is 8 hexadecimal digits, left-padding with zeroes if necessary. print integer in binary 35 $a0 = integer to print Displayed value is 32 bits, left-padding with zeroes if necessary. print integer as unsigned 36 $a0 = integer to print Displayed as unsigned decimal value. (not used) 37-39 set seed 40 $a0 = i.d. of pseudorandom number generator (any int). $a1 = seed for corresponding pseudorandom number generator. No values are returned. Sets the seed of the corresponding underlying Java pseudorandom number generator (java.util.Random). See note below table random int 41 $a0 = i.d. of pseudorandom number generator (any int). $a0 contains the next pseudorandom, uniformly distributed int value from this random number generator's sequence. See note below table random int range 42 $a0 = i.d. of pseudorandom number generator (any int). $a1 = upper bound of range of returned values. $a0 contains pseudorandom, uniformly distributed int value in the range 0 See note below table random float 43 $a0 = i.d. of pseudorandom number generator (any int). $f0 contains the next pseudorandom, uniformly distributed float value in the range 0.0 See note below table random double 44 $a0 = i.d. of pseudorandom number generator (any int). $f0 contains the next pseudorandom, uniformly distributed double value in the range 0.0 See note below table (not used) 45-49 ConfirmDialog 50 $a0 = address of null-terminated string that is the message to user $a0 contains value of user-chosen option 0: Yes 1: No 2: Cancel InputDialogInt 51 $a0 = address of null-terminated string that is the message to user $a0 contains int read $a1 contains status value 0: OK status -1: input data cannot be correctly parsed -2: Cancel was chosen -3: OK was chosen but no data had been input into field InputDialogFloat 52 $a0 = address of null-terminated string that is the message to user $f0 contains float read $a1 contains status value 0: OK status -1: input data cannot be correctly parsed -2: Cancel was chosen -3: OK was chosen but no data had been input into field InputDialogDouble 53 $a0 = address of null-terminated string that is the message to user $f0 contains double read $a1 contains status value 0: OK status -1: input data cannot be correctly parsed -2: Cancel was chosen -3: OK was chosen but no data had been input into field InputDialogString 54 $a0 = address of null-terminated string that is the message to user $a1 = address of input buffer $a2 = maximum number of characters to read See Service 8 note below table $a1 contains status value 0: OK status. Buffer contains the input string. -2: Cancel was chosen. No change to buffer. -3: OK was chosen but no data had been input into field. No change to buffer. -4: length of the input string exceeded the specified maximum. Buffer contains the maximum allowable input string plus a terminating null. MessageDialog 55 $a0 = address of null-terminated string that is the message to user $a1 = the type of message to be displayed: 0: error message, indicated by Error icon 1: information message, indicated by Information icon 2: warning message, indicated by Warning icon 3: question message, indicated by Question icon other: plain message (no icon displayed) N/A MessageDialogInt 56 $a0 = address of null-terminated string that is an information-type message to user $a1 = int value to display in string form after the first string N/A MessageDialogFloat 57 $a0 = address of null-terminated string that is an information-type message to user $f12 = float value to display in string form after the first string N/A MessageDialogDouble 58 $a0 = address of null-terminated string that is an information-type message to user $f12 = double value to display in string form after the first string N/A MessageDialogString 59 $a0 = address of null-terminated string that is an information-type message to user $a1 = address of null-terminated string to display after the first string N/A NOTES: Services numbered 30 and higher are not provided by SPIM Service 8 - Follows semantics of UNIX 'fgets'. For specified length n, string can be no longer than n-1. If less than that, adds newline to end. In either case, then pads with null byte If n = 1, input is ignored and null byte placed at buffer address. If n < 1, input is ignored and nothing is written to the buffer. Service 11 - Prints ASCII character corresponding to contents of low-order byte. Service 13 - MARS implements three flag values: 0 for read-only, 1 for write-only with create, and 9 for write-only with create and append. It ignores mode. The returned file descriptor will be negative if the operation failed. The underlying file I/O implementation uses java.io.FileInputStream.read() to read and java.io.FileOutputStream.write() to write. MARS maintains file descriptors internally and allocates them starting with 3. File descriptors 0, 1 and 2 are always open for: reading from standard input, writing to standard output, and writing to standard error, respectively (new in release 4.3). Services 13,14,15 - In MARS 3.7, the result register was changed to $v0 for SPIM compatability. It was previously $a0 as erroneously printed in Appendix B of Computer Organization and Design,. Service 17 - If the MIPS program is run under control of the MARS graphical interface (GUI), the exit code in $a0 is ignored. Service 30 - System time comes from java.util.Date.getTime() as milliseconds since 1 January 1970. Services 31,33 - Simulate MIDI output through sound card. Details below. Services 40-44 use underlying Java pseudorandom number generators provided by the java.util.Random class. Each stream (identified by $a0 contents) is modeled by a different Random object. There are no default seed values, so use the Set Seed service (40) if replicated random sequences are desired. Example of File I/O The sample MIPS program below will open a new file for writing, write text to it from a memory buffer, then close it. The file will be created in the directory in which MARS was run. # Sample MIPS program that writes to a new file. # by Kenneth Vollmar and Pete Sanderson .data fout: .asciiz "testout.txt" # filename for output buffer: .asciiz "The quick brown fox jumps over the lazy dog." .text ############################################################### # Open (for writing) a file that does not exist li $v0, 13 # system call for open file la $a0, fout # output file name li $a1, 1 # Open for writing (flags are 0: read, 1: write) li $a2, 0 # mode is ignored syscall # open a file (file descriptor returned in $v0) move $s6, $v0 # save the file descriptor ############################################################### # Write to file just opened li $v0, 15 # system call for write to file move $a0, $s6 # file descriptor la $a1, buffer # address of buffer from which to write li $a2, 44 # hardcoded buffer length syscall # write to file ############################################################### # Close the file li $v0, 16 # system call for close file move $a0, $s6 # file descriptor to close syscall # close file ############################################################### Using SYSCALL system services 31 and 33: MIDI output These system services are unique to MARS, and provide a means of producing sound. MIDI output is simulated by your system sound card, and the simulation is provided by the javax.sound.midi package. Service 31 will generate the tone then immediately return. Service 33 will generate the tone then sleep for the tone's duration before returning. Thus it essentially combines services 31 and 32. This service requires four parameters as follows: pitch ($a0) Accepts a positive byte value (0-127) that denotes a pitch as it would be represented in MIDI Each number is one semitone / half-step in the chromatic scale. 0 represents a very low C and 127 represents a very high G (a standard 88 key piano begins at 9-A and ends at 108-C). If the parameter value is outside this range, it applies a default value 60 which is the same as middle C on a piano. From middle C, all other pitches in the octave are as follows: 61 = C# or Db 62 = D 63 = D# or Eb 64 = E or Fb 65 = E# or F 66 = F# or Gb 67 = G 68 = G# or Ab 69 = A 70 = A# or Bb 71 = B or Cb 72 = B# or C To produce these pitches in other octaves, add or subtract multiples of 12. duration in milliseconds ($a1) Accepts a positive integer value that is the length of the tone in milliseconds. If the parameter value is negative, it applies a default value of one second (1000 milliseconds). instrument ($a2) Accepts a positive byte value (0-127) that denotes the General MIDI "patch" used to play the tone. If the parameter is outside this range, it applies a default value 0 which is an Acoustic Grand Piano. General MIDI standardizes the number associated with each possible instrument (often referred to as program change numbers), however it does not determine how the tone will sound. This is determined by the synthesizer that is producing the sound. Thus a Tuba (patch 58) on one computer may sound different than that same patch on another computer. The 128 available patches are divided into instrument families of 8: 0-7 Piano 64-71 Reed 8-15 Chromatic Percussion 72-79 Pipe 16-23 Organ 80-87 Synth Lead 24-31 Guitar 88-95 Synth Pad 32-39 Bass 96-103 Synth Effects 40-47 Strings 104-111 Ethnic 48-55 Ensemble 112-119 Percussion 56-63 Brass 120-127 Sound Effects Note that outside of Java, General MIDI usually refers to patches 1-128. When referring to a list of General MIDI patches, 1 must be subtracted to play the correct patch. For a full list of General MIDI instruments, see www.midi.org/about-midi/gm/gm1sound.shtml. The General MIDI channel 10 percussion key map is not relevant to the toneGenerator method because it always defaults to MIDI channel 1. volume ($a3) Accepts a positive byte value (0-127) where 127 is the loudest and 0 is silent. This value denotes MIDI velocity which refers to the initial attack of the tone. If the parameter value is outside this range, it applies a default value 100. MIDI velocity measures how hard a note on (or note off) message is played, perhaps on a MIDI controller like a keyboard. Most MIDI synthesizers will translate this into volume on a logarithmic scale in which the difference in amplitude decreases as the velocity value increases. Note that velocity value on more sophisticated synthesizers can also affect the timbre of the tone (as most instruments sound different when they are played louder or softer). System service 31 was developed and documented by Otterbein student Tony Brock in July 2007. MARS Acknowledgements MARS Acknowledgements Updated 18 August 2014 Pete and Ken would like to acknowledge the many helpful contributors to MARS. It has succeeded beyond our wildest expectations and for this we are most grateful. Its success would not be possible without your feedback, suggestions and assistance! We are pleased to recognize these contributions to release 4.5: Torsten Mahne, Umberto Villano and others who took care of the bug with certain European keyboards that require an Alt key combo to form essential MIPS assembly characters like $ and #. I had no means of testing it. Eric Wang at Washington State University, who suggested adding cursor positioning to the Keyboard and Display MMIO Simulator tool. Marcio Roberto and everyone else involved in the development of MIPS X-Ray tool, which has been around for several years but only now added to the release. Sorry for the delay. We also appreciate the contributions others have made to previous releases: Carl Burch of Hendrix College, who developed the mechanism for simulating the execution of straight binary code. Previously, execution was based on ProgramStatement objects generated by the assembler. This, combined with the added capabilities to write to the text segment and branch/jump into the data segment at runtime, permits one to produce self-modifying programs, simulate buffer overflow attacks, and the like. Tom Bradford, Slava Pestov and others, who developed the jEdit Syntax Package (syntax.jedit.org) at the heart of the syntax-aware color highlighting editor. It was old but the licensing was right and it was written for embedding into Java applications. Mohammad Sekhavat from Sharif University in Tehran, who developed the macro capability. Greg Gibeling of UC Berkeley, who introduced capabilities into his customized version of MARS that have subsequently been expanded and integrated into our release. These include the ability to dump MIPS memory contents to file and parser improvements to distinguish signed from unsigned hexadecimal constants. Eric Shade of Missouri State University, who suggested several improvements to pseudo-instruction expansions such as elimination of internal branches and improvements to the sign-extended loading of 16-bit immediate operands. Saul Spatz of the University of Missouri Kansas City, who noticed and provided a solution for a flaw in the calculation of byte-oriented addresses in the simulated MIPS memory stack segment. He has also suggested several improvements that we have implemented. Zachary Kurmas of Grand Valley State University, who suggested several bug fixes and who encorporated MARS into his own successful JLSCircuitTester digital logic simulator software. Felipe Lessa, who contributed the Instruction Counter tool and suggested a solution for the problem of MARS inability to launch when stored in a directory whose name contained non-ASCII characters. Carl Hauser of Washington State University, who pointed out and provided a solution to a flaw in the Keyboard and Display Simulator Tool in how it used the Exception Level bit in the Coprocessor1 Status register. Also thanks to Michael Clancy of UC Berkeley for pointing out a flaw in the tool's mechanism for resetting the Transmit Ready bit when operating in kernel memory. Dave Poplawski of Michigan Technological University, for his assistance in working through some issues with signed/unsigned constants and with output redirection. Ingo Kofler of Klagenfurt University in Austria, who contributed two Tools: a tool to collect Instruction Statistics, and a tool to simulate branch prediction with a Branch History Table. Brad Richards and Steven Canfield from the University of Puget Sound, for providing a technique that improved file loading performance. Jan Schejbal and Jan-Peter Kleinhans of Darmstadt technical university in Germany, for suggesting and providing a patch to display Run I/O text in a constant-width font. Max Hailperin of Gustavus Adolphus College, who made several improvements to the MIDI syscalls. David Patterson of UC Berkeley, for making time in his busy schedule for Ken's demo of MARS. Denise Penrose and Nate McFadden of Morgan Kaufmann Publishers, for their assistance as editors of Computer Organization and Design. Ricardo Pascual of University of Murcia in Spain, who contributed the code to permit input syscall keystrokes to be typed directly into the Run I/O window instead of through a popup dialog. Didier Teifreto of Université de Franche-Comté in France, who contributed the Digital Lab Sim tool. Facundo Agriel of the University of Illinois at Chicago, who added font selection to the Keyboard and Display Simulator tool. Patrik Lundin for contributing the code to add scrolling to the keyboard and display simulator. Otterbein students Robert Anderson, Jonathan Barnes, Sean Pomeroy and Melissa Tress for contributing the new command-mode options for specifying MARS exit codes when assembly or simulation errors occur. This was sparked by a comment from Zheming Jim of the University of South Carolina. The unknown audience member at our SIGCSE 2006 conference presentation, who suggested that MARS would also be useful running in the background in support of an external application. This led directly to our development of the Tools framework and API that truly distinguishes MARS from all other MIPS simulators. We would also like to recognize many others who have contacted us to point out bugs, suggest improvements, or engaged us in interesting correspondence. The bugs have been addressed and the improvements either implemented or added to our wish list. Correspondents include: William Bai, Miguel Barao, James Baltimore, Jared Barneck, Bruce Barton, Rudolf Biczok, Battista Biggio, Carl Burch, Ram Busani, Gene Chase, Lucien Chaubert, David Chilson, Sangyeun Cho, Donald Cooley, Bernardo Cunha, John Donaldson, Abhik Ghosh, Michael Grant, Thomas Hain, John Ham, Kurtis Hardy, Justin Harlow, David Harris, Bill Hsu, Pierre von Kaenel, Amos Kittelson, klondike, Geoffrey Knauth, Sudheer Kumar, Yi-Yu Liu, Jeremie Lumbroso, Paul Lynch, Richard McKenna, William McQuain, Adam Megacz, Alessandro Montano, Judy Mullins, William Obermeyer, Ivor Page, Gustavo Patino, Christoph von Praun, Klaus Ramelow, David Reimann, Patricia Renault, André Rodrigues, Robert Roos, Joseph Roth, Marco Salinas, Peter Schulthess, Ofer Shaham, Scott Sigman, Sasha Solganik, Timothy Stanley, Gene Stark, Josh Steinhurst, Michelle Strout, Didier Teifreto, Mitchell Theys, Massimo Tivoli, Dwayne Towell, Duy Truong, Judah Veichselfish, Vineeth, Daniel Walker, Janyce Weibe, Ben West, and Armin Zundel. The Mars.jar file contains all source code and, starting with Release 3.6, the files necessary to generate a new jar file should you wish to make changes to the source and repackage it for your own use. Let us know if you do this, so we can consider your changes for the general release. Thanks to everyone who uses MARS. Keep those cards and letters coming! jar cmf mainclass.txt NewMars_source.jar PseudoOps.txt Config.properties Syscall.properties Settings.properties MARSlicense.txt mainclass.txt MipsXRayOpcode.xml registerDatapath.xml controlDatapath.xml ALUcontrolDatapath.xml CreateNewsMarsJar_200Syscalls.sh CreateNewMarsSourceJar.sh Mars.java Mars.class docs help images mars CompileGameJava.sh game $PROJECT_DIR$/out/artifacts/Tank1990_jar 1617886312690 1617886312690 Tank1990:jar No facets are configured com.alibaba:fastjson:1.2.55 1.8 Tank1990 1.8 # Copyright (c) 2003-2010, Pete Sanderson and Kenneth Vollmar # # Developed by Pete Sanderson (psanderson@otterbein.edu) # and Kenneth Vollmar (kenvollmar@missouristate.edu) # # Permission is hereby granted, free of charge, to any person obtaining # a copy of this software and associated documentation files (the # "Software"), to deal in the Software without restriction, including # without limitation the rights to use, copy, modify, merge, publish, # distribute, sublicense, and/or sell copies of the Software, and to # permit persons to whom the Software is furnished to do so, subject # to the following conditions: # # The above copyright notice and this permission notice shall be # included in all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. # IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR # ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF # CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # # (MIT license, http://www.opensource.org/licenses/mit-license.html) # File containing definitions of MIPS pseudo-ops # File format: # Each line contains specification for one pseudo-op, including optional description. # First item is source statement syntax, specified in same "example" parser format used for regular instructions. # Source statement specification ends with a tab. It is followed by a tab-separated list of basic instruction # templates to complete and substitute for the pseudo-op. # Format for specifying syntax of templates is different from specifying syntax of source statement: # (n=0,1,2,3,...) is token position in source statement (operator is token 0, parentheses are tokens but commas aren't) # RGn means substitute register found in n'th token of source statement # NRn means substitute next higher register than the one in n'th token of source code # OPn means substitute n'th token of source code as is # LLn means substitute low order 16-bits from label address in source token n. # LLnU means substitute low order 16-bits (unsigned) from label address in source token n. # LLnPm (m=1,2,3,4) means substitute low order 16-bits from label address in source token n, after adding m. # LHn means substitute high order 16-bits from label address in source token n. Must add 1 if address bit 15 is 1. # LHnPm (m=1,2,3,4) means substitute high order 16-bits from label address in source token n, after adding m. Must then add 1 if bit 15 is 1. # VLn means substitute low order 16-bits from 32-bit value in source token n. # VLnU means substitute low order 16-bits (unsigned) from 32-bit value in source token n. # VLnPm (m=1,2,3,4) means substitute low order 16-bits from 32-bit value in source token n, after adding m to value. # VLnPmU (m=1,2,3,4) means substitute low order 16-bits(unsigned) from 32-bit value in source token n, after adding m to value. # VHLn means substitute high order 16-bits from 32-bit value in source token n. Use this if later combined with low order 16-bits using "ori $1,$1,VLnU". See logical and branch operations. # VHn means substitute high order 16-bits from 32-bit value in source token n, then add 1 if value's bit 15 is 1. Use this only if later instruction uses VLn($1) to calculate 32-bit address. See loads and stores. # VHLnPm (m=1,2,3,4) means substitute high order 16-bits from 32-bit value in source token n, after adding m. See VHLn. # VHnPm (m=1,2,3,4) means substitute high order 16-bits from 32-bit value in source token n, after adding m. Must then add 1 if bit 15 is 1. See VHn. # LLP is similar to LLn, but is needed for "label+100000" address offset. Immediate is added before taking low order 16. # LLPU is similar to LLn, but is needed for "label+100000" address offset. Immediate is added before taking low order 16 (unsigned). # LLPPm (m=1,2,3,4) is similar to LLP except m is added along with immediate before taking low order 16. # LHPA is similar to LHn, but is needed for "label+100000" address offset. Immediate is added before taking high order 16. # LHPN is similar to LHPA, used only by "la" instruction. Address resolved by "ori" so do not add 1 if bit 15 is 1. # LHPAPm (m=1,2,3,4) is similar to LHPA except value m is added along with immediate before taking high order 16. # LHL means substitute high order 16-bits from label address in token 2 of "la" (load address) source statement. # LAB means substitute textual label from last token of source statement. Used for various branches. # S32 means substitute the result of subtracting the constant value in last token from 32. Used by "ror", "rol". # DBNOP means Delayed Branching NOP - generate a "nop" instruction but only if delayed branching is enabled. Added in 3.4.1 release. # BROFFnm means substitute n if delayed branching is NOT enabled otherwise substitute m. n and m are single digit numbers indicating constant branch offset (in words). Added in 3.4.1 release. # COMPACT is a marker to separate the default template from a second template optimized for 16-bit addresses. See loads and stores having (data) label operands. # Everything else is copied as is into the generated statement (you must use register numbers not mnemonics) # The list of basic instruction templates is optionally followed a description of the instruction for help purposes. # To add optional description, append a tab then the '#' character followed immediately (no spaces) by the description. # # See documentation for ExtendedInstruction.makeTemplateSubstitutions() for more details. # # Matching for a given instruction mnemonic is first-fit not best-fit. If an instruction has both 16 and 32-bit # immediate operand options, they should be listed in that order (16-bit version first). Otherwise the 16-bit # version will never be matched since the 32-bit version fits small immediate values first. # # The pseudo-op specification must start in the first column. If first column is blank, the line will be skipped! # # When specifying the example instruction (first item on line), the conventions I follow are: # - for a register operand, specify a numbered register (e.g. $t1 or $f1) to represent any register in the set. # The numerical value is not significant. This is NOT the case when writing the templates that follow! # In the templates, numbered registers are parsed as is (use only $0 and $1, which are $zero and $at). # - for an immediate operand, specify a positive value indicative of the expected range. I use 10 to represent # a 5 bit value, 100 to represent a 16-bit value, and 100000 to represent a 32-bit value. # - for a label operand, I use the string "label" (without the quotes). # The idea is to give the parser an example that will be parsed into the desired token sequence. Syntax checking # is done by comparing the source token sequence to list of token sequences generated from the examples. # IMPORTANT NOTE: The use of $t1,$t2, etc in the instruction sample means that any CPU register reference # can be used in that position. It is simply a placeholder. By contrast, when # $1 is used in the template specification, $1 ($at) is literally placed into the generated # instruction! If you want the generated code to echo the source register, use RG1,RG2, etc. ####################### arithmetic and branch pseudo-ops ##################### not $t1,$t2 nor RG1, RG2, $0 #Bitwise NOT (bit inversion) # Here are some "convenience" arithmetic pseduo-ops. But do they encourage sloppy programming? add $t1,$t2,-100 addi RG1, RG2, VL3 #ADDition : set $t1 to ($t2 plus 16-bit immediate) add $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U add RG1, RG2, $1 #ADDition : set $t1 to ($t2 plus 32-bit immediate) addu $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U addu RG1, RG2, $1 #ADDition Unsigned : set $t1 to ($t2 plus 32-bit immediate), no overflow addi $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U add RG1, RG2, $1 #ADDition Immediate : set $t1 to ($t2 plus 32-bit immediate) addiu $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U addu RG1, RG2, $1 #ADDition Immediate Unsigned: set $t1 to ($t2 plus 32-bit immediate), no overflow sub $t1,$t2,-100 addi $1, $0, VL3 sub RG1, RG2, $1 #SUBtraction : set $t1 to ($t2 minus 16-bit immediate) sub $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U sub RG1, RG2, $1 #SUBtraction : set $t1 to ($t2 minus 32-bit immediate) subu $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U subu RG1, RG2, $1 #SUBtraction Unsigned : set $t1 to ($t2 minus 32-bit immediate), no overflow subi $t1,$t2,-100 addi $1, $0, VL3 sub RG1, RG2, $1 #SUBtraction Immediate : set $t1 to ($t2 minus 16-bit immediate) subi $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U sub RG1, RG2, $1 #SUBtraction Immediate : set $t1 to ($t2 minus 32-bit immediate) subiu $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U subu RG1, RG2, $1 #SUBtraction Immediate Unsigned : set $t1 to ($t2 minus 32-bit immediate), no overflow # feel free to add more convenience arithmetic pseduo-ops. # convenience logical operations can be added too, andi $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U and RG1, RG2, $1 #AND Immediate : set $t1 to ($t2 bitwise-AND 32-bit immediate) ori $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U or RG1, RG2, $1 #OR Immediate : set $t1 to ($t2 bitwise-OR 32-bit immediate) xori $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U xor RG1, RG2, $1 #XOR Immediate : set $t1 to ($t2 bitwise-exclusive-OR 32-bit immediate) and $t1,$t2,100 andi RG1, RG2, VL3U #AND : set $t1 to ($t2 bitwise-AND 16-bit unsigned immediate) or $t1,$t2,100 ori RG1, RG2, VL3U #OR : set $t1 to ($t2 bitwise-OR 16-bit unsigned immediate) xor $t1,$t2,100 xori RG1, RG2, VL3U #XOR : set $t1 to ($t2 bitwise-exclusive-OR 16-bit unsigned immediate) and $t1,100 andi RG1, RG1, VL2U #AND : set $t1 to ($t1 bitwise-AND 16-bit unsigned immediate) or $t1,100 ori RG1, RG1, VL2U #OR : set $t1 to ($t1 bitwise-OR 16-bit unsigned immediate) xor $t1,100 xori RG1, RG1, VL2U #XOR : set $t1 to ($t1 bitwise-exclusive-OR 16-bit unsigned immediate) andi $t1,100 andi RG1, RG1, VL2U #AND Immediate : set $t1 to ($t1 bitwise-AND 16-bit unsigned immediate) ori $t1,100 ori RG1, RG1, VL2U #OR Immediate : set $t1 to ($t1 bitwise-OR 16-bit unsigned immediate) xori $t1,100 xori RG1, RG1, VL2U #XOR Immediate : set $t1 to ($t1 bitwise-exclusive-OR 16-bit unsigned immediate) andi $t1,100000 lui $1, VHL2 ori $1, $1, VL2U and RG1, RG1, $1 #AND Immediate : set $t1 to ($t1 bitwise-AND 32-bit immediate) ori $t1,100000 lui $1, VHL2 ori $1, $1, VL2U or RG1, RG1, $1 #OR Immediate : set $t1 to ($t1 bitwise-OR 32-bit immediate) xori $t1,100000 lui $1, VHL2 ori $1, $1, VL2U xor RG1, RG1, $1 #XOR Immediate : set $t1 to ($t1 bitwise-exclusive-OR 32-bit immediate) # Note: most of the expansions in this group were rewritten for Release 3.4.1 to remove internal branching. seq $t1,$t2,$t3 subu RG1, RG2, RG3 ori $1, $0, 1 sltu RG1, RG1, $1 #Set EQual : if $t2 equal to $t3 then set $t1 to 1 else 0 seq $t1,$t2,-100 addi $1, $0, VL3 subu RG1, RG2, $1 ori $1, $0, 1 sltu RG1, RG1, $1 #Set EQual : if $t2 equal to 16-bit immediate then set $t1 to 1 else 0 seq $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U subu RG1, RG2, $1 ori $1, $0, 1 sltu RG1, RG1, $1 #Set EQual : if $t2 equal to 32-bit immediate then set $t1 to 1 else 0 sne $t1,$t2,$t3 subu RG1, RG2, RG3 sltu RG1, $0, RG1 #Set Not Equal : if $t2 not equal to $t3 then set $t1 to 1 else 0 sne $t1,$t2,-100 addi $1, $0, VL3 subu RG1, RG2, $1 sltu RG1, $0, RG1 #Set Not Equal : if $t2 not equal to 16-bit immediate then set $t1 to 1 else 0 sne $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U subu RG1, RG2, $1 sltu RG1, $0, RG1 #Set Not Equal : if $t2 not equal to 32-bit immediate then set $t1 to 1 else 0 sge $t1,$t2,$t3 slt RG1, RG2, RG3 ori $1, $0, 1 subu RG1, $1, RG1 #Set Greater or Equal : if $t2 greater or equal to $t3 then set $t1 to 1 else 0 sge $t1,$t2,-100 addi $1, $0, VL3 slt RG1, RG2, $1 ori $1, $0, 1 subu RG1, $1, RG1 #Set Greater or Equal : if $t2 greater or equal to 16-bit immediate then set $t1 to 1 else 0 sge $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U slt RG1, RG2, $1 ori $1, $0, 1 subu RG1, $1, RG1 #Set Greater or Equal : if $t2 greater or equal to 32-bit immediate then set $t1 to 1 else 0 sgeu $t1,$t2,$t3 sltu RG1, RG2, RG3 ori $1, $0, 1 subu RG1, $1, RG1 #Set Greater or Equal Unsigned : if $t2 greater or equal to $t3 (unsigned compare) then set $t1 to 1 else 0 sgeu $t1,$t2,-100 addi $1, $0, VL3 sltu RG1, RG2, $1 ori $1, $0, 1 subu RG1, $1, RG1 #Set Greater or Equal Unsigned : if $t2 greater or equal to 16-bit immediate (unsigned compare) then set $t1 to 1 else 0 sgeu $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U sltu RG1, RG2, $1 ori $1, $0, 1 subu RG1, $1, RG1 #Set Greater or Equal Unsigned : if $t2 greater or equal to 32-bit immediate (unsigned compare) then set $t1 to 1 else 0 sgt $t1,$t2,$t3 slt RG1, RG3, RG2 #Set Greater Than : if $t2 greater than $t3 then set $t1 to 1 else 0 sgt $t1,$t2,-100 addi $1, $0, VL3 slt RG1, $1, RG2 #Set Greater Than : if $t2 greater than 16-bit immediate then set $t1 to 1 else 0 sgt $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U slt RG1, $1, RG2 #Set Greater Than : if $t2 greater than 32-bit immediate then set $t1 to 1 else 0 sgtu $t1,$t2,$t3 sltu RG1, RG3, RG2 #Set Greater Than Unsigned : if $t2 greater than $t3 (unsigned compare) then set $t1 to 1 else 0 sgtu $t1,$t2,-100 addi $1, $0, VL3 sltu RG1, $1, RG2 #Set Greater Than Unsigned : if $t2 greater than 16-bit immediate (unsigned compare) then set $t1 to 1 else 0 sgtu $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U sltu RG1, $1, RG2 #Set Greater Than Unsigned : if $t2 greater than 32-bit immediate (unsigned compare) then set $t1 to 1 else 0 sle $t1,$t2,$t3 slt RG1, RG3, RG2 ori $1, $0, 1 subu RG1, $1, RG1 #Set Less or Equal : if $t2 less or equal to $t3 then set $t1 to 1 else 0 sle $t1,$t2,-100 addi $1, $0, VL3 slt RG1, $1, RG2 ori $1, $0, 1 subu RG1, $1, RG1 #Set Less or Equal : if $t2 less or equal to 16-bit immediate then set $t1 to 1 else 0 sle $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U slt RG1, $1, RG2 ori $1, $0, 1 subu RG1, $1, RG1 #Set Less or Equal : if $t2 less or equal to 32-bit immediate then set $t1 to 1 else 0 sleu $t1,$t2,$t3 sltu RG1, RG3, RG2 ori $1, $0, 1 subu RG1, $1, RG1 #Set Less or Equal Unsigned: if $t2 less or equal to $t3 (unsigned compare) then set $t1 to 1 else 0 sleu $t1,$t2,-100 addi $1, $0, VL3 sltu RG1, $1, RG2 ori $1, $0, 1 subu RG1, $1, RG1 #Set Less or Equal Unsigned: if $t2 less or equal to 16-bit immediate (unsigned compare) then set $t1 to 1 else 0 sleu $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U sltu RG1, $1, RG2 ori $1, $0, 1 subu RG1, $1, RG1 #Set Less or Equal Unsigned: if $t2 less or equal to 32-bit immediate (unsigned compare) then set $t1 to 1 else 0 move $t1,$t2 addu RG1, $0, RG2 #MOVE : Set $t1 to contents of $t2 abs $t1,$t2 sra $1, RG2, 31 xor RG1, $1, RG2 subu RG1, RG1, $1 #ABSolute value : Set $t1 to absolute value of $t2 (algorithm from Hacker's Delight) neg $t1,$t2 sub RG1, $0, RG2 #NEGate : Set $t1 to negation of $t2 negu $t1,$t2 subu RG1, $0, RG2 #NEGate Unsigned : Set $t1 to negation of $t2, no overflow b label bgez $0, LAB #Branch : Branch to statement at label unconditionally beqz $t1,label beq RG1, $0, LAB #Branch if EQual Zero : Branch to statement at label if $t1 is equal to zero bnez $t1,label bne RG1, $0, LAB #Branch if Not Equal Zero : Branch to statement at label if $t1 is not equal to zero beq $t1,-100,label addi $1, $0, VL2 beq $1, RG1, LAB #Branch if EQual : Branch to statement at label if $t1 is equal to 16-bit immediate beq $t1,100000,label lui $1, VHL2 ori $1, $1, VL2U beq $1, RG1, LAB #Branch if EQual : Branch to statement at label if $t1 is equal to 32-bit immediate bne $t1,-100,label addi $1, $0, VL2 bne $1, RG1, LAB #Branch if Not Equal : Branch to statement at label if $t1 is not equal to 16-bit immediate bne $t1,100000,label lui $1, VHL2 ori $1, $1, VL2U bne $1, RG1, LAB #Branch if Not Equal : Branch to statement at label if $t1 is not equal to 32-bit immediate bge $t1,$t2,label slt $1, RG1, RG2 beq $1, $0, LAB #Branch if Greater or Equal : Branch to statement at label if $t1 is greater or equal to $t2 bge $t1,-100,label slti $1, RG1, VL2 beq $1, $0, LAB #Branch if Greater or Equal : Branch to statement at label if $t1 is greater or equal to 16-bit immediate bge $t1,100000,label lui $1, VHL2 ori $1, $1, VL2U slt $1, RG1, $1 beq $1, $0, LAB #Branch if Greater or Equal : Branch to statement at label if $t1 is greater or equal to 32-bit immediate bgeu $t1,$t2,label sltu $1, RG1, RG2 beq $1, $0, LAB #Branch if Greater or Equal Unsigned : Branch to statement at label if $t1 is greater or equal to $t2 (unsigned compare) bgeu $t1,-100,label sltiu $1, RG1, VL2 beq $1, $0, LAB #Branch if Greater or Equal Unsigned : Branch to statement at label if $t1 is greater or equal to 16-bit immediate (unsigned compare) bgeu $t1,100000,label lui $1, VHL2 ori $1, $1, VL2U sltu $1, RG1, $1 beq $1, $0, LAB #Branch if Greater or Equal Unsigned : Branch to statement at label if $t1 is greater or equal to 32-bit immediate (unsigned compare) bgt $t1,$t2,label slt $1, RG2, RG1 bne $1, $0, LAB #Branch if Greater Than : Branch to statement at label if $t1 is greater than $t2 bgt $t1,-100,label addi $1, $0, VL2 slt $1, $1, RG1 bne $1, $0, LAB #Branch if Greater Than : Branch to statement at label if $t1 is greater than 16-bit immediate bgt $t1,100000,label lui $1, VHL2P1 ori $1, $1, VL2P1U slt $1, RG1, $1 beq $1, $0, LAB #Branch if Greater Than : Branch to statement at label if $t1 is greater than 32-bit immediate bgtu $t1,$t2,label sltu $1, RG2, RG1 bne $1, $0, LAB #Branch if Greater Than Unsigned: Branch to statement at label if $t1 is greater than $t2 (unsigned compare) bgtu $t1,-100,label addi $1, $0, VL2 sltu $1, $1, RG1 bne $1, $0, LAB #Branch if Greater Than Unsigned: Branch to statement at label if $t1 is greater than 16-bit immediate (unsigned compare) bgtu $t1,100000,label lui $1, VHL2 ori $1, $1, VL2U sltu $1, $1, RG1 bne $1, $0, LAB #Branch if Greater Than Unsigned: Branch to statement at label if $t1 is greater than 16-bit immediate (unsigned compare) ble $t1,$t2,label slt $1, RG2, RG1 beq $1, $0, LAB #Branch if Less or Equal : Branch to statement at label if $t1 is less than or equal to $t2 ble $t1,-100,label addi $1, RG1, -1 slti $1, $1, VL2 bne $1, $0, LAB #Branch if Less or Equal : Branch to statement at label if $t1 is less than or equal to 16-bit immediate ble $t1,100000,label lui $1, VHL2P1 ori $1, $1, VL2P1U slt $1, RG1, $1 bne $1, $0, LAB #Branch if Less or Equal : Branch to statement at label if $t1 is less than or equal to 32-bit immediate bleu $t1,$t2,label sltu $1, RG2, RG1 beq $1, $0, LAB #Branch if Less or Equal Unsigned : Branch to statement at label if $t1 is less than or equal to $t2 (unsigned compare) bleu $t1,-100,label addi $1, $0, VL2 sltu $1, $1, RG1 beq $1, $0, LAB #Branch if Less or Equal Unsigned : Branch to statement at label if $t1 is less than or equal to 16-bit immediate (unsigned compare) bleu $t1,100000,label lui $1, VHL2 ori $1, $1, VL2U sltu $1, $1, RG1 beq $1, $0, LAB #Branch if Less or Equal Unsigned : Branch to statement at label if $t1 is less than or equal to 32-bit immediate (unsigned compare) blt $t1,$t2,label slt $1, RG1, RG2 bne $1, $0, LAB #Branch if Less Than : Branch to statement at label if $t1 is less than $t2 blt $t1,-100,label slti $1, RG1, VL2 bne $1, $0, LAB #Branch if Less Than : Branch to statement at label if $t1 is less than 16-bit immediate blt $t1,100000,label lui $1, VHL2 ori $1, $1, VL2U slt $1, RG1, $1 bne $1, $0, LAB #Branch if Less Than : Branch to statement at label if $t1 is less than 32-bit immediate bltu $t1,$t2,label sltu $1, RG1, RG2 bne $1, $0, LAB #Branch if Less Than Unsigned : Branch to statement at label if $t1 is less than $t2 bltu $t1,-100,label sltiu $1, RG1, VL2 bne $1, $0, LAB #Branch if Less Than Unsigned : Branch to statement at label if $t1 is less than 16-bit immediate bltu $t1,100000,label lui $1, VHL2 ori $1, $1, VL2U sltu $1, RG1, $1 bne $1, $0, LAB #Branch if Less Than Unsigned : Branch to statement at label if $t1 is less than 32-bit immediate rol $t1,$t2,$t3 subu $1, $0, RG3 srlv $1, RG2, $1 sllv RG1, RG2, RG3 or RG1, RG1, $1 #ROtate Left : Set $t1 to ($t2 rotated left by number of bit positions specified in $t3) rol $t1,$t2,10 srl $1, RG2, S32 sll RG1, RG2, OP3 or RG1, RG1, $1 #ROtate Left : Set $t1 to ($t2 rotated left by number of bit positions specified in 5-bit immediate) ror $t1,$t2,$t3 subu $1, $0, RG3 sllv $1, RG2, $1 srlv RG1, RG2, RG3 or RG1, RG1, $1 #ROtate Right : Set $t1 to ($t2 rotated right by number of bit positions specified in $t3) ror $t1,$t2,10 sll $1, RG2, S32 srl RG1, RG2, OP3 or RG1, RG1, $1 #ROtate Right : Set $t1 to ($t2 rotated right by number of bit positions specified in 5-bit immediate) mfc1.d $t1,$f2 mfc1 RG1, RG2 mfc1 NR1, NR2 #Move From Coprocessor 1 Double : Set $t1 to contents of $f2, set next higher register from $t1 to contents of next higher register from $f2 mtc1.d $t1,$f2 mtc1 RG1, RG2 mtc1 NR1, NR2 #Move To Coprocessor 1 Double : Set $f2 to contents of $t1, set next higher register from $f2 to contents of next higher register from $t1 mul $t1,$t2,-100 addi $1, $0, VL3 mul RG1, RG2, $1 #MULtiplication : Set HI to high-order 32 bits, LO and $t1 to low-order 32 bits of the product of $t2 and 16-bit signed immediate (use mfhi to access HI, mflo to access LO) mul $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U mul RG1, RG2, $1 #MULtiplication : Set HI to high-order 32 bits, LO and $t1 to low-order 32 bits of the product of $t2 and 32-bit immediate (use mfhi to access HI, mflo to access LO) mulu $t1,$t2,$t3 multu RG2, RG3 mflo RG1 #MULtiplication Unsigned : Set HI to high-order 32 bits, LO and $t1 to low-order 32 bits of ($t2 multiplied by $t3, unsigned multiplication) mulu $t1,$t2,-100 addi $1, $0, VL3 multu RG2, $1 mflo RG1 #MULtiplication Unsigned : Set HI to high-order 32 bits, LO and $t1 to low-order 32 bits of ($t2 multiplied by 16-bit immediate, unsigned multiplication) mulu $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U multu RG2, $1 mflo RG1 #MULtiplication Unsigned : Set HI to high-order 32 bits, LO and $t1 to low-order 32 bits of ($t2 multiplied by 32-bit immediate, unsigned multiplication) mulo $t1,$t2,$t3 mult RG2, RG3 mfhi $1 mflo RG1 sra RG1, RG1, 31 beq $1, RG1, BROFF12 DBNOP break mflo RG1 #MULtiplication with Overflow : Set $t1 to low-order 32 bits of the product of $t2 and $t3 mulo $t1,$t2,-100 addi $1, $0, VL3 mult RG2, $1 mfhi $1 mflo RG1 sra RG1, RG1, 31 beq $1, RG1, BROFF12 DBNOP break mflo RG1 #MULtiplication with Overflow : Set $t1 to low-order 32 bits of the product of $t2 and signed 16-bit immediate mulo $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U mult RG2, $1 mfhi $1 mflo RG1 sra RG1, RG1, 31 beq $1, RG1, BROFF12 DBNOP break mflo RG1 #MULtiplication with Overflow : Set $t1 to low-order 32 bits of the product of $t2 and 32-bit immediate mulou $t1,$t2,$t3 multu RG2, RG3 mfhi $1 beq $1,$0, BROFF12 DBNOP break mflo RG1 #MULtiplication with Overflow Unsigned : Set $t1 to low-order 32 bits of the product of $t2 and $t3 mulou $t1,$t2,-100 addi $1, $0, VL3 multu RG2, $1 mfhi $1 beq $1,$0, BROFF12 DBNOP break mflo RG1 #MULtiplication with Overflow Unsigned : Set $t1 to low-order 32 bits of the product of $t2 and signed 16-bit immediate mulou $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U multu RG2, $1 mfhi $1 beq $1,$0, BROFF12 DBNOP break mflo RG1 #MULtiplication with Overflow Unsigned : Set $t1 to low-order 32 bits of the product of $t2 and 32-bit immediate div $t1,$t2,$t3 bne RG3, $0, BROFF12 DBNOP break div RG2, RG3 mflo RG1 #DIVision : Set $t1 to ($t2 divided by $t3, integer division) div $t1,$t2,-100 addi $1, $0, VL3 div RG2, $1 mflo RG1 #DIVision : Set $t1 to ($t2 divided by 16-bit immediate, integer division) div $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U div RG2, $1 mflo RG1 #DIVision : Set $t1 to ($t2 divided by 32-bit immediate, integer division) divu $t1,$t2,$t3 bne RG3, $0, BROFF12 DBNOP break divu RG2, RG3 mflo RG1 #DIVision Unsigned : Set $t1 to ($t2 divided by $t3, unsigned integer division) divu $t1,$t2,-100 addi $1, $0, VL3 divu RG2, $1 mflo RG1 #DIVision Unsigned : Set $t1 to ($t2 divided by 16-bit immediate, unsigned integer division) divu $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U divu RG2, $1 mflo RG1 #DIVision Unsigned : Set $t1 to ($t2 divided by 32-bit immediate, unsigned integer division) rem $t1,$t2,$t3 bne RG3, $0, BROFF12 DBNOP break div RG2, RG3 mfhi RG1 #REMainder : Set $t1 to (remainder of $t2 divided by $t3) rem $t1,$t2,-100 addi $1, $0, VL3 div RG2, $1 mfhi RG1 #REMainder : Set $t1 to (remainder of $t2 divided by 16-bit immediate) rem $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U div RG2, $1 mfhi RG1 #REMainder : Set $t1 to (remainder of $t2 divided by 32-bit immediate) remu $t1,$t2,$t3 bne RG3, $0, BROFF12 DBNOP break divu RG2, RG3 mfhi RG1 #REMainder : Set $t1 to (remainder of $t2 divided by $t3, unsigned division) remu $t1,$t2,-100 addi $1, $0, VL3 divu RG2, $1 mfhi RG1 #REMainder : Set $t1 to (remainder of $t2 divided by 16-bit immediate, unsigned division) remu $t1,$t2,100000 lui $1, VHL3 ori $1, $1, VL3U divu RG2, $1 mfhi RG1 #REMainder : Set $t1 to (remainder of $t2 divided by 32-bit immediate, unsigned division) ######################### load/store pseudo-ops start here ########################## # # Most of these simply provide a variety of convenient memory addressing modes for # specifying load/store address. # li $t1,-100 addiu RG1, $0, VL2 #Load Immediate : Set $t1 to 16-bit immediate (sign-extended) li $t1,100 ori RG1, $0, VL2U #Load Immediate : Set $t1 to unsigned 16-bit immediate (zero-extended) li $t1,100000 lui $1, VHL2 ori RG1, $1, VL2U #Load Immediate : Set $t1 to 32-bit immediate la $t1,($t2) addi RG1, RG3, 0 #Load Address : Set $t1 to contents of $t2 la $t1,-100 addiu RG1, $0, VL2 #Load Address : Set $t1 to 16-bit immediate (sign-extended) la $t1,100 ori RG1, $0, VL2U #Load Address : Set $t1 to 16-bit immediate (zero-extended) la $t1,100000 lui $1, VHL2 ori RG1, $1, VL2U #Load Address : Set $t1 to 32-bit immediate la $t1,100($t2) ori $1, $0, VL2U add RG1, RG4, $1 #Load Address : Set $t1 to sum (of $t2 and 16-bit immediate) la $t1,100000($t2) lui $1, VHL2 ori $1, $1, VL2U add RG1, RG4, $1 #Load Address : Set $t1 to sum (of $t2 and 32-bit immediate) la $t1,label lui $1, LHL ori RG1, $1, LL2U COMPACT addi RG1, $0, LL2 #Load Address : Set $t1 to label's address la $t1,label($t2) lui $1, LHL ori $1, $1, LL2U add RG1, RG4, $1 COMPACT addi RG1, RG4, LL2 #Load Address : Set $t1 to sum (of $t2 and label's address) la $t1,label+100000 lui $1, LHPN ori RG1, $1, LLPU #Load Address : Set $t1 to sum (of label's address and 32-bit immediate) la $t1,label+100000($t2) lui $1, LHPN ori $1, $1, LLPU add RG1, RG6, $1 #Load Address : Set $t1 to sum (of label's address, 32-bit immediate, and $t2) lw $t1,($t2) lw RG1,0(RG3) #Load Word : Set $t1 to contents of effective memory word address lw $t1,-100 lw RG1, VL2($0) #Load Word : Set $t1 to contents of effective memory word address lw $t1,100 ori $1, $0, VL2U lw RG1, 0($1) #Load Word : Set $t1 to contents of effective memory word address lw $t1,100000 lui $1, VH2 lw RG1,VL2($1) #Load Word : Set $t1 to contents of effective memory word address lw $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 lw RG1, 0($1) #Load Word : Set $t1 to contents of effective memory word address lw $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 lw RG1, VL2($1) #Load Word : Set $t1 to contents of effective memory word address lw $t1,label lui $1, LH2 lw RG1, LL2($1) COMPACT lw RG1, LL2($0) #Load Word : Set $t1 to contents of memory word at label's address lw $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 lw RG1, LL2($1) COMPACT lw RG1, LL2(RG4) #Load Word : Set $t1 to contents of effective memory word address lw $t1,label+100000 lui $1, LHPA lw RG1, LLP($1) #Load Word : Set $t1 to contents of effective memory word address lw $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 lw RG1, LLP($1) #Load Word : Set $t1 to contents of effective memory word address sw $t1,($t2) sw RG1,0(RG3) #Store Word : Store $t1 contents into effective memory word address sw $t1,-100 sw RG1, VL2($0) #Store Word : Store $t1 contents into effective memory word address sw $t1,100 ori $1, $0, VL2U sw RG1, 0($1) #Store Word : Store $t1 contents into effective memory word address sw $t1,100000 lui $1, VH2 sw RG1,VL2($1) #Store Word : Store $t1 contents into effective memory word address sw $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 sw RG1, 0($1) #Store Word : Store $t1 contents into effective memory word address sw $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 sw RG1, VL2($1) #Store Word : Store $t1 contents into effective memory word address sw $t1,label lui $1, LH2 sw RG1, LL2($1) COMPACT sw RG1, LL2($0) #Store Word : Store $t1 contents into memory word at label's address sw $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 sw RG1, LL2($1) COMPACT sw RG1, LL2(RG4) #Store Word : Store $t1 contents into effective memory word address sw $t1,label+100000 lui $1, LHPA sw RG1, LLP($1) #Store Word : Store $t1 contents into effective memory word address sw $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 sw RG1, LLP($1) #Store Word : Store $t1 contents into effective memory word address lh $t1,($t2) lh RG1,0(RG3) #Load Halfword : Set $t1 to sign-extended 16-bit value from effective memory halfword address lh $t1,-100 lh RG1, VL2($0) #Load Halfword : Set $t1 to sign-extended 16-bit value from effective memory halfword address lh $t1,100 ori $1, $0, VL2U lh RG1, 0($1) #Load Halfword : Set $t1 to sign-extended 16-bit value from effective memory halfword address lh $t1,100000 lui $1, VH2 lh RG1,VL2($1) #Load Halfword : Set $t1 to sign-extended 16-bit value from effective memory halfword address lh $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 lh RG1, 0($1) #Load Halfword : Set $t1 to sign-extended 16-bit value from effective memory halfword address lh $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 lh RG1, VL2($1) #Load Halfword : Set $t1 to sign-extended 16-bit value from effective memory halfword address lh $t1,label lui $1, LH2 lh RG1, LL2($1) COMPACT lh RG1, LL2($0) #Load Halfword : Set $t1 to sign-extended 16-bit value from effective memory halfword address lh $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 lh RG1, LL2($1) COMPACT lh RG1, LL2(RG4) #Load Halfword : Set $t1 to sign-extended 16-bit value from effective memory halfword address lh $t1,label+100000 lui $1, LHPA lh RG1, LLP($1) #Load Halfword : Set $t1 to sign-extended 16-bit value from effective memory halfword address lh $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 lh RG1, LLP($1) #Load Halfword : Set $t1 to sign-extended 16-bit value from effective memory halfword address sh $t1,($t2) sh RG1,0(RG3) #Store Halfword : Store the low-order 16 bits of $t1 into the effective memory halfword address sh $t1,-100 sh RG1, VL2($0) #Store Halfword : Store the low-order 16 bits of $t1 into the effective memory halfword address sh $t1,100 ori $1, $0, VL2U sh RG1, 0($1) #Store Halfword : Store the low-order 16 bits of $t1 into the effective memory halfword address sh $t1,100000 lui $1, VH2 sh RG1,VL2($1) #Store Halfword : Store the low-order 16 bits of $t1 into the effective memory halfword address sh $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 sh RG1, 0($1) #Store Halfword : Store the low-order 16 bits of $t1 into the effective memory halfword address sh $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 sh RG1, VL2($1) #Store Halfword : Store the low-order 16 bits of $t1 into the effective memory halfword address sh $t1,label lui $1, LH2 sh RG1, LL2($1) COMPACT sh RG1, LL2($0) #Store Halfword : Store the low-order 16 bits of $t1 into the effective memory halfword address sh $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 sh RG1, LL2($1) COMPACT sh RG1, LL2(RG4) #Store Halfword : Store the low-order 16 bits of $t1 into the effective memory halfword address sh $t1,label+100000 lui $1, LHPA sh RG1, LLP($1) #Store Halfword : Store the low-order 16 bits of $t1 into the effective memory halfword address sh $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 sh RG1, LLP($1) #Store Halfword : Store the low-order 16 bits of $t1 into the effective memory halfword address lb $t1,($t2) lb RG1,0(RG3) #Load Byte : Set $t1 to sign-extended 8-bit value from effective memory byte address lb $t1,-100 lb RG1, VL2($0) #Load Byte : Set $t1 to sign-extended 8-bit value from effective memory byte address lb $t1,100 ori $1, $0, VL2U lb RG1, 0($1) #Load Byte : Set $t1 to sign-extended 8-bit value from effective memory byte address lb $t1,100000 lui $1, VH2 lb RG1,VL2($1) #Load Byte : Set $t1 to sign-extended 8-bit value from effective memory byte address lb $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 lb RG1, 0($1) #Load Byte : Set $t1 to sign-extended 8-bit value from effective memory byte address lb $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 lb RG1, VL2($1) #Load Byte : Set $t1 to sign-extended 8-bit value from effective memory byte address lb $t1,label lui $1, LH2 lb RG1, LL2($1) COMPACT lb RG1, LL2($0) #Load Byte : Set $t1 to sign-extended 8-bit value from effective memory byte address lb $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 lb RG1, LL2($1) COMPACT lb RG1, LL2(RG4) #Load Byte : Set $t1 to sign-extended 8-bit value from effective memory byte address lb $t1,label+100000 lui $1, LHPA lb RG1, LLP($1) #Load Byte : Set $t1 to sign-extended 8-bit value from effective memory byte address lb $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 lb RG1, LLP($1) #Load Byte : Set $t1 to sign-extended 8-bit value from effective memory byte address sb $t1,($t2) sb RG1,0(RG3) #Store Byte : Store the low-order 8 bits of $t1 into the effective memory byte address sb $t1,-100 sb RG1, VL2($0) #Store Byte : Store the low-order 8 bits of $t1 into the effective memory byte address sb $t1,100 ori $1, $0, VL2U sb RG1, 0($1) #Store Byte : Store the low-order 8 bits of $t1 into the effective memory byte address sb $t1,100000 lui $1, VH2 sb RG1,VL2($1) #Store Byte : Store the low-order 8 bits of $t1 into the effective memory byte address sb $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 sb RG1, 0($1) #Store Byte : Store the low-order 8 bits of $t1 into the effective memory byte address sb $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 sb RG1, VL2($1) #Store Byte : Store the low-order 8 bits of $t1 into the effective memory byte address sb $t1,label lui $1, LH2 sb RG1, LL2($1) COMPACT sb RG1, LL2($0) #Store Byte : Store the low-order 8 bits of $t1 into the effective memory byte address sb $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 sb RG1, LL2($1) COMPACT sb RG1, LL2(RG4) #Store Byte : Store the low-order 8 bits of $t1 into the effective memory byte address sb $t1,label+100000 lui $1, LHPA sb RG1, LLP($1) #Store Byte : Store the low-order 8 bits of $t1 into the effective memory byte address sb $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 sb RG1, LLP($1) #Store Byte : Store the low-order 8 bits of $t1 into the effective memory byte address lhu $t1,($t2) lhu RG1,0(RG3) #Load Halfword Unsigned : Set $t1 to zero-extended 16-bit value from effective memory halfword address lhu $t1,-100 lhu RG1,VL2($0) #Load Halfword Unsigned : Set $t1 to zero-extended 16-bit value from effective memory halfword address lhu $t1,100 ori $1, $0, VL2U lhu RG1, 0($1) #Load Halfword Unsigned : Set $t1 to zero-extended 16-bit value from effective memory halfword address lhu $t1,100000 lui $1, VH2 lhu RG1,VL2($1) #Load Halfword Unsigned : Set $t1 to zero-extended 16-bit value from effective memory halfword address lhu $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 lhu RG1, 0($1) #Load Halfword Unsigned : Set $t1 to zero-extended 16-bit value from effective memory halfword address lhu $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 lhu RG1, VL2($1) #Load Halfword Unsigned : Set $t1 to zero-extended 16-bit value from effective memory halfword address lhu $t1,label lui $1, LH2 lhu RG1, LL2($1) COMPACT lhu RG1, LL2($0) #Load Halfword Unsigned : Set $t1 to zero-extended 16-bit value from effective memory halfword address lhu $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 lhu RG1, LL2($1) COMPACT lhu RG1, LL2(RG4) #Load Halfword Unsigned : Set $t1 to zero-extended 16-bit value from effective memory halfword address lhu $t1,label+100000 lui $1, LHPA lhu RG1, LLP($1) #Load Halfword Unsigned : Set $t1 to zero-extended 16-bit value from effective memory halfword address lhu $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 lhu RG1, LLP($1) #Load Halfword Unsigned : Set $t1 to zero-extended 16-bit value from effective memory halfword address lbu $t1,($t2) lbu RG1,0(RG3) #Load Byte Unsigned : Set $t1 to zero-extended 8-bit value from effective memory byte address lbu $t1,-100 lbu RG1,VL2($0) #Load Byte Unsigned : Set $t1 to zero-extended 8-bit value from effective memory byte address lbu $t1,100 ori $1, $0, VL2U lbu RG1, 0($1) #Load Byte Unsigned : Set $t1 to zero-extended 8-bit value from effective memory byte address lbu $t1,100000 lui $1, VH2 lbu RG1,VL2($1) #Load Byte Unsigned : Set $t1 to zero-extended 8-bit value from effective memory byte address lbu $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 lbu RG1, 0($1) #Load Byte Unsigned : Set $t1 to zero-extended 8-bit value from effective memory byte address lbu $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 lbu RG1, VL2($1) #Load Byte Unsigned : Set $t1 to zero-extended 8-bit value from effective memory byte address lbu $t1,label lui $1, LH2 lbu RG1, LL2($1) COMPACT lbu RG1, LL2($0) #Load Byte Unsigned : Set $t1 to zero-extended 8-bit value from effective memory byte address lbu $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 lbu RG1, LL2($1) COMPACT lbu RG1, LL2(RG4) #Load Byte Unsigned : Set $t1 to zero-extended 8-bit value from effective memory byte address lbu $t1,label+100000 lui $1, LHPA lbu RG1, LLP($1) #Load Byte Unsigned : Set $t1 to zero-extended 8-bit value from effective memory byte address lbu $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 lbu RG1, LLP($1) #Load Byte Unsigned : Set $t1 to zero-extended 8-bit value from effective memory byte address lwl $t1,($t2) lwl RG1,0(RG3) #Load Word Left : Load from 1 to 4 bytes left-justified into $t1, starting with effective memory byte address and continuing through the low-order byte of its word lwl $t1,-100 lwl RG1,VL2($0) #Load Word Left : Load from 1 to 4 bytes left-justified into $t1, starting with effective memory byte address and continuing through the low-order byte of its word lwl $t1,100 ori $1, $0, VL2U lwl RG1, 0($1) #Load Word Left : Load from 1 to 4 bytes left-justified into $t1, starting with effective memory byte address and continuing through the low-order byte of its word lwl $t1,100000 lui $1, VH2 lwl RG1,VL2($1) #Load Word Left : Load from 1 to 4 bytes left-justified into $t1, starting with effective memory byte address and continuing through the low-order byte of its word lwl $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 lwl RG1, 0($1) #Load Word Left : Load from 1 to 4 bytes left-justified into $t1, starting with effective memory byte address and continuing through the low-order byte of its word lwl $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 lwl RG1, VL2($1) #Load Word Left : Load from 1 to 4 bytes left-justified into $t1, starting with effective memory byte address and continuing through the low-order byte of its word lwl $t1,label lui $1, LH2 lwl RG1, LL2($1) COMPACT lwl RG1, LL2($0) #Load Word Left : Load from 1 to 4 bytes left-justified into $t1, starting with effective memory byte address and continuing through the low-order byte of its word lwl $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 lwl RG1, LL2($1) COMPACT lwl RG1, LL2(RG4) #Load Word Left : Load from 1 to 4 bytes left-justified into $t1, starting with effective memory byte address and continuing through the low-order byte of its word lwl $t1,label+100000 lui $1, LHPA lwl RG1, LLP($1) #Load Word Left : Load from 1 to 4 bytes left-justified into $t1, starting with effective memory byte address and continuing through the low-order byte of its word lwl $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 lwl RG1, LLP($1) #Load Word Left : Load from 1 to 4 bytes left-justified into $t1, starting with effective memory byte address and continuing through the low-order byte of its word swl $t1,($t2) swl RG1,0(RG3) #Store Word Left : Store high-order 1 to 4 bytes of $t1 into memory, starting with effective memory byte address and continuing through the low-order byte of its word swl $t1,-100 swl RG1,VL2($0) #Store Word Left : Store high-order 1 to 4 bytes of $t1 into memory, starting with effective memory byte address and continuing through the low-order byte of its word swl $t1,100 ori $1, $0, VL2U swl RG1, 0($1) #Store Word Left : Store high-order 1 to 4 bytes of $t1 into memory, starting with effective memory byte address and continuing through the low-order byte of its word swl $t1,100000 lui $1, VH2 swl RG1,VL2($1) #Store Word Left : Store high-order 1 to 4 bytes of $t1 into memory, starting with effective memory byte address and continuing through the low-order byte of its word swl $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 swl RG1, 0($1) #Store Word Left : Store high-order 1 to 4 bytes of $t1 into memory, starting with effective memory byte address and continuing through the low-order byte of its word swl $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 swl RG1, VL2($1) #Store Word Left : Store high-order 1 to 4 bytes of $t1 into memory, starting with effective memory byte address and continuing through the low-order byte of its word swl $t1,label lui $1, LH2 swl RG1, LL2($1) COMPACT swl RG1, LL2($0) #Store Word Left : Store high-order 1 to 4 bytes of $t1 into memory, starting with effective memory byte address and continuing through the low-order byte of its word swl $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 swl RG1, LL2($1) COMPACT swl RG1, LL2(RG4) #Store Word Left : Store high-order 1 to 4 bytes of $t1 into memory, starting with effective memory byte address and continuing through the low-order byte of its word swl $t1,label+100000 lui $1, LHPA swl RG1, LLP($1) #Store Word Left : Store high-order 1 to 4 bytes of $t1 into memory, starting with effective memory byte address and continuing through the low-order byte of its word swl $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 swl RG1, LLP($1) #Store Word Left : Store high-order 1 to 4 bytes of $t1 into memory, starting with effective memory byte address and continuing through the low-order byte of its word lwr $t1,($t2) lwr RG1,0(RG3) #Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,-100 lwr RG1,VL2($0) #Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,100 ori $1, $0, VL2U lwr RG1, 0($1) #Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,100000 lui $1, VH2 lwr RG1,VL2($1) #Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 lwr RG1, 0($1) #Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 lwr RG1, VL2($1) #Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,label lui $1, LH2 lwr RG1, LL2($1) COMPACT lwr RG1, LL2($0) #Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 lwr RG1, LL2($1) COMPACT lwr RG1, LL2(RG4) #Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,label+100000 lui $1, LHPA lwr RG1, LLP($1) #Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 lwr RG1, LLP($1) #Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word swr $t1,($t2) swr RG1,0(RG3) #Store Word Right : Store low-order 1 to 4 bytes of $t1 into memory, starting with high-order byte of word containing effective memory byte address and continuing through that byte address swr $t1,-100 swr RG1,VL2($0) #Store Word Right : Store low-order 1 to 4 bytes of $t1 into memory, starting with high-order byte of word containing effective memory byte address and continuing through that byte address swr $t1,100 ori $1, $0, VL2U swr RG1, 0 #Store Word Right : Store low-order 1 to 4 bytes of $t1 into memory, starting with high-order byte of word containing effective memory byte address and continuing through that byte address swr $t1,100000 lui $1, VH2 swr RG1,VL2($1) #Store Word Right : Store low-order 1 to 4 bytes of $t1 into memory, starting with high-order byte of word containing effective memory byte address and continuing through that byte address swr $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 swr RG1, 0($1) #Store Word Right : Store low-order 1 to 4 bytes of $t1 into memory, starting with high-order byte of word containing effective memory byte address and continuing through that byte address swr $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 swr RG1, VL2($1) #Store Word Right : Store low-order 1 to 4 bytes of $t1 into memory, starting with high-order byte of word containing effective memory byte address and continuing through that byte address swr $t1,label lui $1, LH2 swr RG1, LL2($1) COMPACT swr RG1, LL2($0) #Store Word Right : Store low-order 1 to 4 bytes of $t1 into memory, starting with high-order byte of word containing effective memory byte address and continuing through that byte address swr $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 swr RG1, LL2($1) COMPACT swr RG1, LL2(RG4) #Store Word Right : Store low-order 1 to 4 bytes of $t1 into memory, starting with high-order byte of word containing effective memory byte address and continuing through that byte address swr $t1,label+100000 lui $1, LHPA swr RG1, LLP($1) #Store Word Right : Store low-order 1 to 4 bytes of $t1 into memory, starting with high-order byte of word containing effective memory byte address and continuing through that byte address swr $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 swr RG1, LLP($1) #Store Word Right : Store low-order 1 to 4 bytes of $t1 into memory, starting with high-order byte of word containing effective memory byte address and continuing through that byte address ll $t1,($t2) ll RG1,0(RG3) #Load Linked : Paired with Store Conditional (sc) to perform atomic read-modify-write. Treated as equivalent to Load Word (lw) because MARS does not simulate multiple processors. ll $t1,-100 ll RG1,VL2($0) #Load Linked : Paired with Store Conditional (sc) to perform atomic read-modify-write. Treated as equivalent to Load Word (lw) because MARS does not simulate multiple processors. ll $t1,100 ori $1, $0, VL2U ll RG1, 0($1) #Load Linked : Paired with Store Conditional (sc) to perform atomic read-modify-write. Treated as equivalent to Load Word (lw) because MARS does not simulate multiple processors. ll $t1,100000 lui $1, VH2 ll RG1,VL2($1) #Load Linked : Paired with Store Conditional (sc) to perform atomic read-modify-write. Treated as equivalent to Load Word (lw) because MARS does not simulate multiple processors. ll $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 ll RG1, 0($1) #Load Linked : Paired with Store Conditional (sc) to perform atomic read-modify-write. Treated as equivalent to Load Word (lw) because MARS does not simulate multiple processors. ll $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 ll RG1, VL2($1) #Load Linked : Paired with Store Conditional (sc) to perform atomic read-modify-write. Treated as equivalent to Load Word (lw) because MARS does not simulate multiple processors. ll $t1,label lui $1, LH2 ll RG1, LL2($1) COMPACT ll RG1, LL2($0) #Load Linked : Paired with Store Conditional (sc) to perform atomic read-modify-write. Treated as equivalent to Load Word (lw) because MARS does not simulate multiple processors. ll $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 ll RG1, LL2($1) COMPACT ll RG1, LL2(RG4) #Load Linked : Paired with Store Conditional (sc) to perform atomic read-modify-write. Treated as equivalent to Load Word (lw) because MARS does not simulate multiple processors. ll $t1,label+100000 lui $1, LHPA ll RG1, LLP($1) #Load Linked : Paired with Store Conditional (sc) to perform atomic read-modify-write. Treated as equivalent to Load Word (lw) because MARS does not simulate multiple processors. ll $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 ll RG1, LLP($1) #Load Linked : Paired with Store Conditional (sc) to perform atomic read-modify-write. Treated as equivalent to Load Word (lw) because MARS does not simulate multiple processors. sc $t1,($t2) sc RG1,0(RG3) #Store Conditional : Paired with Load Linked (ll) to perform atomic read-modify-write. Treated as equivalent to Store Word (sw) because MARS does not simulate multiple processors. sc $t1,-100 sc RG1,VL2($0) #Store Conditional : Paired with Load Linked (ll) to perform atomic read-modify-write. Treated as equivalent to Store Word (sw) because MARS does not simulate multiple processors. sc $t1,100 ori $1, $0, VL2U sc RG1, 0($1) #Store Conditional : Paired with Load Linked (ll) to perform atomic read-modify-write. Treated as equivalent to Store Word (sw) because MARS does not simulate multiple processors. sc $t1,100000 lui $1, VH2 sc RG1,VL2($1) #Store Conditional : Paired with Load Linked (ll) to perform atomic read-modify-write. Treated as equivalent to Store Word (sw) because MARS does not simulate multiple processors. sc $t1,100($t2) ori $1, $0, VL2U addu $1, $1, RG4 sc RG1, 0($1) #Store Conditional : Paired with Load Linked (ll) to perform atomic read-modify-write. Treated as equivalent to Store Word (sw) because MARS does not simulate multiple processors. sc $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 sc RG1, VL2($1) #Store Conditional : Paired with Load Linked (ll) to perform atomic read-modify-write. Treated as equivalent to Store Word (sw) because MARS does not simulate multiple processors. sc $t1,label lui $1, LH2 sc RG1, LL2($1) COMPACT sc RG1, LL2($0) #Store Conditional : Paired with Load Linked (ll) to perform atomic read-modify-write. Treated as equivalent to Store Word (sw) because MARS does not simulate multiple processors. sc $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 sc RG1, LL2($1) COMPACT sc RG1, LL2(RG4) #Store Conditional : Paired with Load Linked (ll) to perform atomic read-modify-write. Treated as equivalent to Store Word (sw) because MARS does not simulate multiple processors. sc $t1,label+100000 lui $1, LHPA sc RG1, LLP($1) #Store Conditional : Paired with Load Linked (ll) to perform atomic read-modify-write. Treated as equivalent to Store Word (sw) because MARS does not simulate multiple processors. sc $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 sc RG1, LLP($1) #Store Conditional : Paired with Load Linked (ll) to perform atomic read-modify-write. Treated as equivalent to Store Word (sw) because MARS does not simulate multiple processors. # Unaligned and double loads and stores. All the them require assembler to add a constant # byte offset (from 1 to 4 bytes) to the given or calculated address. # NOTE: I have abandoned the "accepted" expansion of immed16($reg) addressing form for the # unaligned and double load/store pseudo-instructions because they produce what I consider # incorrect results for immediate values at the upper edge of the signed 16-bit range # (32765 through 32767). The expansion of these pseudo's requires adding an additional # byte offset (from 1 to 4 bytes) to the immediate value, which overflows the signed 16 # bit range and results in a large negative offset with no counterbalancing increment # to the high order 16-bits. Thus if the two pieces of unaligned data end up in different # words, they are stored 64K bytes apart! For example, the normal expansion of # "usw $8,32767($9)" would be "swl $8,-32766($9)", "swr $8, 32767($9)" Both SPIM and # Britten's text do this but I consider it incorrect. My compromise is the following: # since each of the expansion calls for two calculated offsets, one of which can possibly # overflow due to the addition but the other will not (because there is no addition), # I'll code the expansion to treat the at-risk calculated offset as 32-bits (it will generate # the lui and addu, which is unnecessary in almost every case but is always correct) # and the second as 16-bits. I'll group all instructions for this addressing mode together. # ulw $t1,-100($t2) lwl RG1, VL2P3(RG4) lwr RG1, VL2(RG4) -- used by SPIM but not me. # usw $t1,-100($t2) swl RG1, VL2P3(RG4) swr RG1, VL2(RG4) -- used by SPIM but not me. ulw $t1,-100($t2) lui $1, VH2P3 addu $1, $1, RG4 lwl RG1, VL2P3($1) lwr RG1, VL2(RG4) #Unaligned Load Word : Set $t1 to the 32 bits starting at effective memory byte address ulh $t1,-100($t2) lui $1, VH2P1 addu $1, $1, RG4 lb RG1, VL2P1($1) lbu $1, VL2(RG4) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, sign-extended, starting at effective memory byte address ulhu $t1,-100($t2) lui $1, VH2P1 addu $1, $1, RG4 lbu RG1, VL2P1($1) lbu $1, VL2(RG4) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, zero-extended, starting at effective memory byte address ld $t1,-100($t2) lw RG1, VL2(RG4) lui $1, VH2P4 addu $1, $1, RG4 lw NR1, VL2P4($1) #Load Doubleword : Set $t1 and the next register to the 64 bits starting at effective memory byte address usw $t1,-100($t2) lui $1, VH2P3 addu $1, $1, RG4 swl RG1, VL2P3($1) swr RG1, VL2(RG4) #Unaligned Store Word : Store $t1 contents into the 32 bits starting at effective memory byte address ush $t1,-100($t2) sb RG1, VL2(RG4) sll $1, RG1, 24 srl RG1, RG1, 8 or RG1, RG1, $1 lui $1, VH2P1 addu $1, $1, RG4 sb RG1, VL2P1($1) srl $1, RG1, 24 sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Store Halfword: Store low-order halfword $t1 contents into the 16 bits starting at effective memory byte address sd $t1,-100($t2) sw RG1, VL2(RG4) lui $1, VH2P4 addu $1, $1, RG4 sw NR1, VL2P4($1) #Store Doubleword : Store contents of $t1 and the next register to the 64 bits starting at effective memory byte address # here are the remaining addressing modes, grouped by instruction. ulw $t1,100000 lui $1, VH2P3 lwl RG1, VL2P3($1) lui $1, VH2 lwr RG1, VL2($1) #Unaligned Load Word : Set $t1 to the 32 bits starting at effective memory byte address ulw $t1,label lui $1, LH2P3 lwl RG1, LL2P3($1) lui $1, LH2 lwr RG1, LL2($1) #Unaligned Load Word : Set $t1 to the 32 bits starting at effective memory byte address ulw $t1,label+100000 lui $1, LHPAP3 lwl RG1, LLPP3($1) lui $1, LHPA lwr RG1, LLP($1) #Unaligned Load Word : Set $t1 to the 32 bits starting at effective memory byte address ulw $t1,($t2) lwl RG1, 3(RG3) lwr RG1, 0(RG3) #Unaligned Load Word : Set $t1 to the 32 bits starting at effective memory byte address ulw $t1,100000($t2) lui $1, VH2P3 addu $1, $1, RG4 lwl RG1, VL2P3($1) lui $1, VH2 addu $1, $1, RG4 lwr RG1, VL2($1) #Unaligned Load Word : Set $t1 to the 32 bits starting at effective memory byte address ulw $t1,label($t2) lui $1, LH2P3 addu $1, $1, RG4 lwl RG1, LL2P3($1) lui $1, LH2 addu $1, $1, RG4 lwr RG1, LL2($1) #Unaligned Load Word : Set $t1 to the 32 bits starting at effective memory byte address ulw $t1,label+100000($t2) lui $1, LHPAP3 addu $1, $1, RG6 lwl RG1, LLPP3($1) lui $1, LHPA addu $1, $1, RG6 lwr RG1, LLP($1) #Unaligned Load Word : Set $t1 to the 32 bits starting at effective memory byte address ulh $t1,100000 lui $1, VH2P1 lb RG1, VL2P1($1) lui $1, VH2 lbu $1, VL2($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, sign-extended, starting at effective memory byte address ulh $t1,label lui $1, LH2P1 lb RG1, LL2P1($1) lui $1, LH2 lbu $1, LL2($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, sign-extended, starting at effective memory byte address ulh $t1,label+100000 lui $1, LHPAP1 lb RG1, LLPP1($1) lui $1, LHPA lbu $1, LLP($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, sign-extended, starting at effective memory byte address ulh $t1,($t2) lb RG1, 1(RG3) lbu $1, 0(RG3) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, sign-extended, starting at effective memory byte address ulh $t1,100000($t2) lui $1, VH2P1 addu $1, $1, RG4 lb RG1, VL2P1($1) lui $1, VH2 addu $1, $1, RG4 lbu $1, VL2($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, sign-extended, starting at effective memory byte address ulh $t1,label($t2) lui $1, LH2P1 addu $1, $1, RG4 lb RG1, LL2P1($1) lui $1, LH2 addu $1, $1, RG4 lbu $1, LL2($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, sign-extended, starting at effective memory byte address ulh $t1,label+100000($t2) lui $1, LHPAP1 addu $1, $1, RG6 lb RG1, LLPP1($1) lui $1, LHPA addu $1, $1, RG6 lbu $1, LLP($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, sign-extended, starting at effective memory byte address ulhu $t1,100000 lui $1, VH2P1 lbu RG1, VL2P1($1) lui $1, VH2 lbu $1, VL2($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, zero-extended, starting at effective memory byte address ulhu $t1,label lui $1, LH2P1 lbu RG1, LL2P1($1) lui $1, LH2 lbu $1, LL2($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, zero-extended, starting at effective memory byte address ulhu $t1,label+100000 lui $1, LHPAP1 lbu RG1, LLPP1($1) lui $1, LHPA lbu $1, LLP($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, zero-extended, starting at effective memory byte address ulhu $t1,($t2) lbu RG1, 1(RG3) lbu $1, 0(RG3) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, zero-extended, starting at effective memory byte address ulhu $t1,100000($t2) lui $1, VH2P1 addu $1, $1, RG4 lbu RG1, VL2P1($1) lui $1, VH2 addu $1, $1, RG4 lbu $1, VL2($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, zero-extended, starting at effective memory byte address ulhu $t1,label($t2) lui $1, LH2P1 addu $1, $1, RG4 lbu RG1, LL2P1($1) lui $1, LH2 addu $1, $1, RG4 lbu $1, LL2($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, zero-extended, starting at effective memory byte address ulhu $t1,label+100000($t2) lui $1, LHPAP1 addu $1, $1, RG6 lbu RG1, LLPP1($1) lui $1, LHPA addu $1, $1, RG6 lbu $1, LLP($1) sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Load Halfword : Set $t1 to the 16 bits, zero-extended, starting at effective memory byte address ld $t1,100000 lui $1, VH2 lw RG1, VL2($1) lui $1, VH2P4 lw NR1, VL2P4($1) #Load Doubleword : Set $t1 and the next register to the 64 bits starting at effective memory word address ld $t1,label lui $1, LH2 lw RG1, LL2($1) lui $1, LH2P4 lw NR1, LL2P4($1) #Load Doubleword : Set $t1 and the next register to the 64 bits starting at effective memory word address ld $t1,label+100000 lui $1, LHPA lw RG1, LLP($1) lui $1, LHPAP4 lw NR1, LLPP4($1) #Load Doubleword : Set $t1 and the next register to the 64 bits starting at effective memory word address ld $t1,($t2) lw RG1, 0(RG3) lw NR1, 4(RG3) #Load Doubleword : Set $t1 and the next register to the 64 bits starting at effective memory word address ld $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 lw RG1, VL2($1) lui $1, VH2P4 addu $1, $1, RG4 lw NR1, VL2P4($1) #Load Doubleword : Set $t1 and the next register to the 64 bits starting at effective memory word address ld $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 lw RG1, LL2($1) lui $1, LH2P4 addu $1, $1, RG4 lw NR1, LL2P4($1) #Load Doubleword : Set $t1 and the next register to the 64 bits starting at effective memory word address ld $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 lw RG1, LLP($1) lui $1, LHPAP4 addu $1, $1, RG6 lw NR1, LLPP4($1) #Load Doubleword : Set $t1 and the next register to the 64 bits starting at effective memory word address usw $t1,100000 lui $1, VH2P3 swl RG1, VL2P3($1) lui $1, VH2 swr RG1, VL2($1) #Unaligned Store Word : Store $t1 contents into the 32 bits starting at effective memory byte address usw $t1,label lui $1, LH2P3 swl RG1, LL2P3($1) lui $1, LH2 swr RG1, LL2($1) #Unaligned Store Word : Store $t1 contents into the 32 bits starting at effective memory byte address usw $t1,label+100000 lui $1, LHPAP3 swl RG1, LLPP3($1) lui $1, LHPA swr RG1, LLP($1) #Unaligned Store Word : Store $t1 contents into the 32 bits starting at effective memory byte address usw $t1,($t2) swl RG1, 3(RG3) swr RG1, 0(RG3) #Unaligned Store Word : Store $t1 contents into the 32 bits starting at effective memory byte address usw $t1,100000($t2) lui $1, VH2P3 addu $1, $1, RG4 swl RG1, VL2P3($1) lui $1, VH2 addu $1, $1, RG4 swr RG1, VL2($1) #Unaligned Store Word : Store $t1 contents into the 32 bits starting at effective memory byte address usw $t1,label($t2) lui $1, LH2P3 addu $1, $1, RG4 swl RG1, LL2P3($1) lui $1, LH2 addu $1, $1, RG4 swr RG1, LL2($1) #Unaligned Store Word : Store $t1 contents into the 32 bits starting at effective memory byte address usw $t1,label+100000($t2) lui $1, LHPAP3 addu $1, $1, RG6 swl RG1, LLPP3($1) lui $1, LHPA addu $1, $1, RG6 swr RG1, LLP($1) #Unaligned Store Word : Store $t1 contents into the 32 bits starting at effective memory byte address ush $t1,100000 lui $1, VH2 sb RG1, VL2($1) sll $1, RG1, 24 srl RG1, RG1, 8 or RG1, RG1, $1 lui $1, VH2P1 sb RG1, VL2P1($1) srl $1, RG1, 24 sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Store Halfword: Store low-order halfword $t1 contents into the 16 bits starting at effective memory byte address ush $t1,label lui $1, LH2 sb RG1, LL2($1) sll $1, RG1, 24 srl RG1, RG1, 8 or RG1, RG1, $1 lui $1, LH2P1 sb RG1, LL2P1($1) srl $1, RG1, 24 sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Store Halfword: Store low-order halfword $t1 contents into the 16 bits starting at effective memory byte address ush $t1,label+100000 lui $1, LHPA sb RG1, LLP($1) sll $1, RG1, 24 srl RG1, RG1, 8 or RG1, RG1, $1 lui $1, LHPAP1 sb RG1, LLPP1($1) srl $1, RG1, 24 sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Store Halfword: Store low-order halfword $t1 contents into the 16 bits starting at effective memory byte address ush $t1,($t2) sb RG1, 0(RG3) sll $1, RG1, 24 srl RG1, RG1, 8 or RG1, RG1, $1 sb RG1, 1(RG3) srl $1, RG1, 24 sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Store Halfword: Store low-order halfword $t1 contents into the 16 bits starting at effective memory byte address ush $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 sb RG1, VL2($1) sll $1, RG1, 24 srl RG1, RG1, 8 or RG1, RG1, $1 lui $1, VH2P1 addu $1, $1, RG4 sb RG1, VL2P1($1) srl $1, RG1, 24 sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Store Halfword: Store low-order halfword $t1 contents into the 16 bits starting at effective memory byte address ush $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 sb RG1, LL2($1) sll $1, RG1, 24 srl RG1, RG1, 8 or RG1, RG1, $1 lui $1, LH2P1 addu $1, $1, RG4 sb RG1, LL2P1($1) srl $1, RG1, 24 sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Store Halfword: Store low-order halfword $t1 contents into the 16 bits starting at effective memory byte address ush $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 sb RG1, LLP($1) sll $1, RG1, 24 srl RG1, RG1, 8 or RG1, RG1, $1 lui $1, LHPAP1 addu $1, $1, RG6 sb RG1, LLPP1($1) srl $1, RG1, 24 sll RG1, RG1, 8 or RG1, RG1, $1 #Unaligned Store Halfword: Store low-order halfword $t1 contents into the 16 bits starting at effective memory byte address sd $t1,100000 lui $1, VH2 sw RG1, VL2($1) lui $1, VH2P4 sw NR1, VL2P4($1) #Store Doubleword : Store contents of $t1 and the next register to the 64 bits starting at effective memory word address sd $t1,label lui $1, LH2 sw RG1, LL2($1) lui $1, LH2P4 sw NR1, LL2P4($1) #Store Doubleword : Store contents of $t1 and the next register to the 64 bits starting at effective memory word address sd $t1,label+100000 lui $1, LHPA sw RG1, LLP($1) lui $1, LHPAP4 sw NR1, LLPP4($1) #Store Doubleword : Store contents of $t1 and the next register to the 64 bits starting at effective memory word address sd $t1,($t2) sw RG1, 0(RG3) sw NR1, 4(RG3) #Store Doubleword : Store contents of $t1 and the next register to the 64 bits starting at effective memory word address sd $t1,100000($t2) lui $1, VH2 addu $1, $1, RG4 sw RG1, VL2($1) lui $1, VH2P4 addu $1, $1, RG4 sw NR1, VL2P4($1) #Store Doubleword : Store contents of $t1 and the next register to the 64 bits starting at effective memory word address sd $t1,label($t2) lui $1, LH2 addu $1, $1, RG4 sw RG1, LL2($1) lui $1, LH2P4 addu $1, $1, RG4 sw NR1, LL2P4($1) #Store Doubleword : Store contents of $t1 and the next register to the 64 bits starting at effective memory word address sd $t1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 sw RG1, LLP($1) lui $1, LHPAP4 addu $1, $1, RG6 sw NR1, LLPP4($1) #Store Doubleword : Store contents of $t1 and the next register to the 64 bits starting at effective memory word address # load and store pseudo-instructions for floating point (coprocessor 1) registers lwc1 $f1,($t2) lwc1 RG1,0(RG3) #Load Word Coprocessor 1 : Set $f1 to 32-bit value from effective memory word address lwc1 $f1,-100 lwc1 RG1,VL2($0) #Load Word Coprocessor 1 : Set $f1 to 32-bit value from effective memory word address lwc1 $f1,100000 lui $1, VH2 lwc1 RG1,VL2($1) #Load Word Coprocessor 1 : Set $f1 to 32-bit value from effective memory word address lwc1 $f1,100000($t2) lui $1, VH2 addu $1, $1, RG4 lwc1 RG1, VL2($1) #Load Word Coprocessor 1 : Set $f1 to 32-bit value from effective memory word address lwc1 $f1,label lui $1, LH2 lwc1 RG1, LL2($1) COMPACT lwc1 RG1, LL2($0) #Load Word Coprocessor 1 : Set $f1 to 32-bit value from effective memory word address lwc1 $f1,label($t2) lui $1, LH2 addu $1, $1, RG4 lwc1 RG1, LL2($1) COMPACT lwc1 RG1, LL2(RG4) #Load Word Coprocessor 1 : Set $f1 to 32-bit value from effective memory word address lwc1 $f1,label+100000 lui $1, LHPA lwc1 RG1, LLP($1) #Load Word Coprocessor 1 : Set $f1 to 32-bit value from effective memory word address lwc1 $f1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 lwc1 RG1, LLP($1) #Load Word Coprocessor 1 : Set $f1 to 32-bit value from effective memory word address ldc1 $f2,($t2) ldc1 RG1,0(RG3) #Load Doubleword Coprocessor 1 : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address ldc1 $f2,-100 ldc1 RG1,VL2($0) #Load Doubleword Coprocessor 1 : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address ldc1 $f2,100000 lui $1, VH2 ldc1 RG1,VL2($1) #Load Doubleword Coprocessor 1 : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address ldc1 $f2,100000($t2) lui $1, VH2 addu $1, $1, RG4 ldc1 RG1, VL2($1) #Load Doubleword Coprocessor 1 : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address ldc1 $f2,label lui $1, LH2 ldc1 RG1, LL2($1) COMPACT ldc1 RG1, LL2($0) #Load Doubleword Coprocessor 1 : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address ldc1 $f2,label($t2) lui $1, LH2 addu $1, $1, RG4 ldc1 RG1, LL2($1) COMPACT ldc1 RG1, LL2(RG4) #Load Doubleword Coprocessor 1 : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address ldc1 $f2,label+100000 lui $1, LHPA ldc1 RG1, LLP($1) #Load Doubleword Coprocessor 1 : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address ldc1 $f2,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 ldc1 RG1, LLP($1) #Load Doubleword Coprocessor 1 : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address swc1 $f1,($t2) swc1 RG1,0(RG3) #Store Word Coprocessor 1 : Store 32-bit value from $f1 to effective memory word address swc1 $f1,-100 swc1 RG1,VL2($0) #Store Word Coprocessor 1 : Store 32-bit value from $f1 to effective memory word address swc1 $f1,100000 lui $1, VH2 swc1 RG1,VL2($1) #Store Word Coprocessor 1 : Store 32-bit value from $f1 to effective memory word address swc1 $f1,100000($t2) lui $1, VH2 addu $1, $1, RG4 swc1 RG1, VL2($1) #Store Word Coprocessor 1 : Store 32-bit value from $f1 to effective memory word address swc1 $f1,label lui $1, LH2 swc1 RG1, LL2($1) COMPACT swc1 RG1, LL2($0) #Store Word Coprocessor 1 : Store 32-bit value from $f1 to effective memory word address swc1 $f1,label($t2) lui $1, LH2 addu $1, $1, RG4 swc1 RG1, LL2($1) COMPACT swc1 RG1, LL2(RG4) #Store Word Coprocessor 1 : Store 32-bit value from $f1 to effective memory word address swc1 $f1,label+100000 lui $1, LHPA swc1 RG1, LLP($1) #Store Word Coprocessor 1 : Store 32-bit value from $f1 to effective memory word address swc1 $f1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 swc1 RG1, LLP($1) #Store Word Coprocessor 1 : Store 32-bit value from $f1 to effective memory word address sdc1 $f2,($t2) sdc1 RG1,0(RG3) #Store Doubleword Coprocessor 1 : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address sdc1 $f2,-100 sdc1 RG1,VL2($0) #Store Doubleword Coprocessor 1 : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address sdc1 $f2,100000 lui $1, VH2 sdc1 RG1,VL2($1) #Store Doubleword Coprocessor 1 : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address sdc1 $f2,100000($t2) lui $1, VH2 addu $1, $1, RG4 sdc1 RG1, VL2($1) #Store Doubleword Coprocessor 1 : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address sdc1 $f2,label lui $1, LH2 sdc1 RG1, LL2($1) COMPACT sdc1 RG1, LL2($0) #Store Doubleword Coprocessor 1 : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address sdc1 $f2,label($t2) lui $1, LH2 addu $1, $1, RG4 sdc1 RG1, LL2($1) COMPACT sdc1 RG1, LL2(RG4) #Store Doubleword Coprocessor 1 : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address sdc1 $f2,label+100000 lui $1, LHPA sdc1 RG1, LLP($1) #Store Doubleword Coprocessor 1 : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address sdc1 $f2,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 sdc1 RG1, LLP($1) #Store Doubleword Coprocessor 1 : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address l.s $f1,($t2) lwc1 RG1,0(RG3) #Load floating point Single precision : Set $f1 to 32-bit value at effective memory word address l.s $f1,-100 lwc1 RG1,VL2($0) #Load floating point Single precision : Set $f1 to 32-bit value at effective memory word address l.s $f1,100000 lui $1, VH2 lwc1 RG1,VL2($1) #Load floating point Single precision : Set $f1 to 32-bit value at effective memory word address l.s $f1,100000($t2) lui $1, VH2 addu $1, $1, RG4 lwc1 RG1, VL2($1) #Load floating point Single precision : Set $f1 to 32-bit value at effective memory word address l.s $f1,label lui $1, LH2 lwc1 RG1, LL2($1) COMPACT lwc1 RG1, LL2($0) #Load floating point Single precision : Set $f1 to 32-bit value at effective memory word address l.s $f1,label($t2) lui $1, LH2 addu $1, $1, RG4 lwc1 RG1, LL2($1) COMPACT lwc1 RG1, LL2(RG4) #Load floating point Single precision : Set $f1 to 32-bit value at effective memory word address l.s $f1,label+100000 lui $1, LHPA lwc1 RG1, LLP($1) #Load floating point Single precision : Set $f1 to 32-bit value at effective memory word address l.s $f1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 lwc1 RG1, LLP($1) #Load floating point Single precision : Set $f1 to 32-bit value at effective memory word address s.s $f1,($t2) swc1 RG1,0(RG3) #Store floating point Single precision : Store 32-bit value from $f1 to effective memory word address s.s $f1,-100 swc1 RG1,VL2($0) #Store floating point Single precision : Store 32-bit value from $f1 to effective memory word address s.s $f1,100000 lui $1, VH2 swc1 RG1,VL2($1) #Store floating point Single precision : Store 32-bit value from $f1 to effective memory word address s.s $f1,100000($t2) lui $1, VH2 addu $1, $1, RG4 swc1 RG1, VL2($1) #Store floating point Single precision : Store 32-bit value from $f1 to effective memory word address s.s $f1,label lui $1, LH2 swc1 RG1, LL2($1) COMPACT swc1 RG1, LL2($0) #Store floating point Single precision : Store 32-bit value from $f1 to effective memory word address s.s $f1,label($t2) lui $1, LH2 addu $1, $1, RG4 swc1 RG1, LL2($1) COMPACT swc1 RG1, LL2(RG4) #Store floating point Single precision : Store 32-bit value from $f1 to effective memory word address s.s $f1,label+100000 lui $1, LHPA swc1 RG1, LLP($1) #Store floating point Single precision : Store 32-bit value from $f1 to effective memory word address s.s $f1,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 swc1 RG1, LLP($1) #Store floating point Single precision : Store 32-bit value from $f1 to effective memory word address l.d $f2,($t2) ldc1 RG1,0(RG3) #Load floating point Double precision : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address l.d $f2,-100 ldc1 RG1,VL2($0) #Load floating point Double precision : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address l.d $f2,100000 lui $1, VH2 ldc1 RG1,VL2($1) #Load floating point Double precision : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address l.d $f2,100000($t2) lui $1, VH2 addu $1, $1, RG4 ldc1 RG1, VL2($1) #Load floating point Double precision : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address l.d $f2,label lui $1, LH2 ldc1 RG1, LL2($1) COMPACT ldc1 RG1, LL2($0) #Load floating point Double precision : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address l.d $f2,label($t2) lui $1, LH2 addu $1, $1, RG4 ldc1 RG1, LL2($1) COMPACT ldc1 RG1, LL2(RG4) #Load floating point Double precision : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address l.d $f2,label+100000 lui $1, LHPA ldc1 RG1, LLP($1) #Load floating point Double precision : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address l.d $f2,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 ldc1 RG1, LLP($1) #Load floating point Double precision : Set $f2 and $f3 register pair to 64-bit value at effective memory doubleword address s.d $f2,($t2) sdc1 RG1,0(RG3) #Store floating point Double precision : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address s.d $f2,-100 sdc1 RG1,VL2($0) #Store floating point Double precision : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address s.d $f2,100000 lui $1, VH2 sdc1 RG1,VL2($1) #Store floating point Double precision : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address s.d $f2,100000($t2) lui $1, VH2 addu $1, $1, RG4 sdc1 RG1, VL2($1) #Store floating point Double precision : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address s.d $f2,label lui $1, LH2 sdc1 RG1, LL2($1) COMPACT sdc1 RG1, LL2($0) #Store floating point Double precision : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address s.d $f2,label($t2) lui $1, LH2 addu $1, $1, RG4 sdc1 RG1, LL2($1) COMPACT sdc1 RG1, LL2(RG4) #Store floating point Double precision : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address s.d $f2,label+100000 lui $1, LHPA sdc1 RG1, LLP($1) #Store floating point Double precision : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address s.d $f2,label+100000($t2) lui $1, LHPA addu $1, $1, RG6 sdc1 RG1, LLP($1) #Store floating point Double precision : Store 64 bits from $f2 and $f3 register pair to effective memory doubleword address