public void setState(OperandState state, boolean update) {
		this.state = state;

		switch (state) {
			case MASKED:
				backgroundColor =
					isInstruction ? BG_COLOR_MASKED_INSTRUCTION : BG_COLOR_MASKED_NON_INSTRUCTION;
				border = BorderFactory.createLoweredSoftBevelBorder();
				break;
			case NOT_MASKED:
				backgroundColor = isInstruction ? BG_COLOR_NOT_MASKED_INSTRUCTION
						: BG_COLOR_NOT_MASKED_NON_INSTRUCTION;
				border = BorderFactory.createRaisedSoftBevelBorder();
				break;
			case NA:
				backgroundColor = BG_COLOR_DEFAULT;
				break;
			case PREVIEW:
				backgroundColor =
					isInstruction ? BG_COLOR_MASKED_INSTRUCTION : BG_COLOR_MASKED_NON_INSTRUCTION;
				break;
		}

		if (update) {
			notifySubscribers();
		}
	}
Changes the state of the operand or mnemonic.

@param state the new operand state
@param update if true, a notification is issued to subscribers
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/instructionsearch/model/InstructionTableDataObject.java