@Test public void testAddBlock() throws Exception { command = new AddMemoryBlockCmd(".test", "A Test", "new block", getNotepadAddr(0x100), 100, true, true, true, false, (byte) 0xa, MemoryBlockType.DEFAULT, null, true); assertTrue(applyCmd(notepad, command)); MemoryBlock block = notepad.getMemory().getBlock(getNotepadAddr(0x100)); assertNotNull(block); byte b = block.getByte(getNotepadAddr(0x100)); assertEquals((byte) 0xa, b); Listing listing = notepad.getListing(); String[] treeNames = listing.getTreeNames(); ProgramFragment f = listing.getFragment(treeNames[0], getNotepadAddr(0x100)); assertNotNull(f); assertEquals(block.getName(), f.getName()); }
@Override public String getName() { return "Add Memory Block"; }
AddMemoryBlockCmd implements Command { @Override public String getName() { return "Add Memory Block"; } }
AddMemoryBlockCmd implements Command { @Override public String getName() { return "Add Memory Block"; } AddMemoryBlockCmd(String name, String comment, String source, Address start, int length,
			boolean read, boolean write, boolean execute, boolean isVolatile, byte initialValue,
			MemoryBlockType blockType, Address baseAddr, boolean isInitialized); }
AddMemoryBlockCmd implements Command { @Override public String getName() { return "Add Memory Block"; } AddMemoryBlockCmd(String name, String comment, String source, Address start, int length,
			boolean read, boolean write, boolean execute, boolean isVolatile, byte initialValue,
			MemoryBlockType blockType, Address baseAddr, boolean isInitialized); @Override boolean applyTo(DomainObject obj); @Override String getName(); @Override String getStatusMsg(); }
AddMemoryBlockCmd implements Command { @Override public String getName() { return "Add Memory Block"; } AddMemoryBlockCmd(String name, String comment, String source, Address start, int length,
			boolean read, boolean write, boolean execute, boolean isVolatile, byte initialValue,
			MemoryBlockType blockType, Address baseAddr, boolean isInitialized); @Override boolean applyTo(DomainObject obj); @Override String getName(); @Override String getStatusMsg();  }