test_class.declarator: grandExchangePlugin
test_class.modifier: @Inject
  	private
test_class.original_string: @Inject
  	private GrandExchangePlugin grandExchangePlugin;
test_class.type: GrandExchangePlugin
test_class.var_name: grandExchangePlugin
test_class.declarator: grandExchangeConfig
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private GrandExchangeConfig grandExchangeConfig;
test_class.type: GrandExchangeConfig
test_class.var_name: grandExchangeConfig
test_class.declarator: notifier
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private Notifier notifier;
test_class.type: Notifier
test_class.var_name: notifier
test_class.declarator: sessionManager
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private SessionManager sessionManager;
test_class.type: SessionManager
test_class.var_name: sessionManager
test_class.declarator: configManager
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private ConfigManager configManager;
test_class.type: ConfigManager
test_class.var_name: configManager
test_class.declarator: itemManager
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private ItemManager itemManager;
test_class.type: ItemManager
test_class.var_name: itemManager
test_class.declarator: keyManager
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private KeyManager keyManager;
test_class.type: KeyManager
test_class.var_name: keyManager
test_class.declarator: mouseManager
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private MouseManager mouseManager;
test_class.type: MouseManager
test_class.var_name: mouseManager
test_class.declarator: scheduledExecutorService
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private ScheduledExecutorService scheduledExecutorService;
test_class.type: ScheduledExecutorService
test_class.var_name: scheduledExecutorService
test_class.declarator: grandExchangeClient
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private GrandExchangeClient grandExchangeClient;
test_class.type: GrandExchangeClient
test_class.var_name: grandExchangeClient
test_class.declarator: osbGrandExchangeClient
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private OSBGrandExchangeClient osbGrandExchangeClient;
test_class.type: OSBGrandExchangeClient
test_class.var_name: osbGrandExchangeClient
test_class.declarator: client
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private Client client;
test_class.type: Client
test_class.var_name: client
test_class.declarator: runeLiteConfig
test_class.modifier: @Mock
  	@Bind
  	private
test_class.original_string: @Mock
  	@Bind
  	private RuneLiteConfig runeLiteConfig;
test_class.type: RuneLiteConfig
test_class.var_name: runeLiteConfig
test_class.file: runelite-client/src/test/java/net/runelite/client/plugins/grandexchange/GrandExchangePluginTest.java
test_class.identifier: GrandExchangePluginTest
test_case.body: @Test
  	public void testDuplicateTrade()
  	{
  		SavedOffer savedOffer = new SavedOffer();
  		savedOffer.setItemId(ItemID.ABYSSAL_WHIP);
  		savedOffer.setQuantitySold(1);
  		savedOffer.setTotalQuantity(10);
  		savedOffer.setPrice(1000);
  		savedOffer.setSpent(25);
  		savedOffer.setState(GrandExchangeOfferState.BUYING);
  		when(configManager.getConfiguration("geoffer.adam", "0")).thenReturn(GSON.toJson(savedOffer));
  
  		GrandExchangeOffer grandExchangeOffer = mock(GrandExchangeOffer.class);
  		when(grandExchangeOffer.getQuantitySold()).thenReturn(1);
  		when(grandExchangeOffer.getItemId()).thenReturn(ItemID.ABYSSAL_WHIP);
  		when(grandExchangeOffer.getTotalQuantity()).thenReturn(10);
  		when(grandExchangeOffer.getPrice()).thenReturn(1000);
  		lenient().when(grandExchangeOffer.getSpent()).thenReturn(25);
  		when(grandExchangeOffer.getState()).thenReturn(GrandExchangeOfferState.BUYING);
  		grandExchangePlugin.submitTrade(0, grandExchangeOffer);
  
  		verify(grandExchangeClient, never()).submit(any(GrandExchangeTrade.class));
  	}
test_case.class_method_signature: GrandExchangePluginTest.testDuplicateTrade()
test_case.full_signature: @Test public void testDuplicateTrade()
test_case.identifier: testDuplicateTrade
test_case.invocations: setItemId setQuantitySold setTotalQuantity setPrice setSpent setState thenReturn when getConfiguration toJson mock thenReturn when getQuantitySold thenReturn when getItemId thenReturn when getTotalQuantity thenReturn when getPrice thenReturn when lenient getSpent thenReturn when getState submitTrade submit verify never any
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testDuplicateTrade()
focal_class.declarator: GE_SLOTS = 8
focal_class.modifier: private static final
focal_class.original_string: private static final int GE_SLOTS = 8;
focal_class.type: int
focal_class.var_name: GE_SLOTS
focal_class.declarator: OFFER_CONTAINER_ITEM = 21
focal_class.modifier: private static final
focal_class.original_string: private static final int OFFER_CONTAINER_ITEM = 21;
focal_class.type: int
focal_class.var_name: OFFER_CONTAINER_ITEM
focal_class.declarator: OFFER_DEFAULT_ITEM_ID = 6512
focal_class.modifier: private static final
focal_class.original_string: private static final int OFFER_DEFAULT_ITEM_ID = 6512;
focal_class.type: int
focal_class.var_name: OFFER_DEFAULT_ITEM_ID
focal_class.declarator: OSB_GE_TEXT = "<br>OSBuddy Actively traded price: "
focal_class.modifier: private static final
focal_class.original_string: private static final String OSB_GE_TEXT = "<br>OSBuddy Actively traded price: ";
focal_class.type: String
focal_class.var_name: OSB_GE_TEXT
focal_class.declarator: BUY_LIMIT_GE_TEXT = "<br>Buy limit: "
focal_class.modifier: private static final
focal_class.original_string: private static final String BUY_LIMIT_GE_TEXT = "<br>Buy limit: ";
focal_class.type: String
focal_class.var_name: BUY_LIMIT_GE_TEXT
focal_class.declarator: BUY_LIMIT_KEY = "buylimit_"
focal_class.modifier: private static final
focal_class.original_string: private static final String BUY_LIMIT_KEY = "buylimit_";
focal_class.type: String
focal_class.var_name: BUY_LIMIT_KEY
focal_class.declarator: GSON = new Gson()
focal_class.modifier: private static final
focal_class.original_string: private static final Gson GSON = new Gson();
focal_class.type: Gson
focal_class.var_name: GSON
focal_class.declarator: BUY_LIMIT_RESET = Duration.ofHours(4)
focal_class.modifier: private static final
focal_class.original_string: private static final Duration BUY_LIMIT_RESET = Duration.ofHours(4);
focal_class.type: Duration
focal_class.var_name: BUY_LIMIT_RESET
focal_class.declarator: SEARCH_GRAND_EXCHANGE = "Search Grand Exchange"
focal_class.modifier: static final
focal_class.original_string: static final String SEARCH_GRAND_EXCHANGE = "Search Grand Exchange";
focal_class.type: String
focal_class.var_name: SEARCH_GRAND_EXCHANGE
focal_class.declarator: MAX_RESULT_COUNT = 250
focal_class.modifier: private static final
focal_class.original_string: private static final int MAX_RESULT_COUNT = 250;
focal_class.type: int
focal_class.var_name: MAX_RESULT_COUNT
focal_class.declarator: FUZZY = new FuzzyScore(Locale.ENGLISH)
focal_class.modifier: private static final
focal_class.original_string: private static final FuzzyScore FUZZY = new FuzzyScore(Locale.ENGLISH);
focal_class.type: FuzzyScore
focal_class.var_name: FUZZY
focal_class.declarator: FUZZY_HIGHLIGHT_COLOR = new Color(0x800000)
focal_class.modifier: private static final
focal_class.original_string: private static final Color FUZZY_HIGHLIGHT_COLOR = new Color(0x800000);
focal_class.type: Color
focal_class.var_name: FUZZY_HIGHLIGHT_COLOR
focal_class.declarator: button
focal_class.modifier: @Getter(AccessLevel.PACKAGE)
  	private
focal_class.original_string: @Getter(AccessLevel.PACKAGE)
  	private NavigationButton button;
focal_class.type: NavigationButton
focal_class.var_name: button
focal_class.declarator: panel
focal_class.modifier: @Getter(AccessLevel.PACKAGE)
  	private
focal_class.original_string: @Getter(AccessLevel.PACKAGE)
  	private GrandExchangePanel panel;
focal_class.type: GrandExchangePanel
focal_class.var_name: panel
focal_class.declarator: hotKeyPressed
focal_class.modifier: @Getter(AccessLevel.PACKAGE)
  	@Setter(AccessLevel.PACKAGE)
  	private
focal_class.original_string: @Getter(AccessLevel.PACKAGE)
  	@Setter(AccessLevel.PACKAGE)
  	private boolean hotKeyPressed;
focal_class.type: boolean
focal_class.var_name: hotKeyPressed
focal_class.declarator: inputListener
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private GrandExchangeInputListener inputListener;
focal_class.type: GrandExchangeInputListener
focal_class.var_name: inputListener
focal_class.declarator: itemManager
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private ItemManager itemManager;
focal_class.type: ItemManager
focal_class.var_name: itemManager
focal_class.declarator: mouseManager
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private MouseManager mouseManager;
focal_class.type: MouseManager
focal_class.var_name: mouseManager
focal_class.declarator: keyManager
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private KeyManager keyManager;
focal_class.type: KeyManager
focal_class.var_name: keyManager
focal_class.declarator: client
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private Client client;
focal_class.type: Client
focal_class.var_name: client
focal_class.declarator: clientToolbar
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private ClientToolbar clientToolbar;
focal_class.type: ClientToolbar
focal_class.var_name: clientToolbar
focal_class.declarator: config
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private GrandExchangeConfig config;
focal_class.type: GrandExchangeConfig
focal_class.var_name: config
focal_class.declarator: notifier
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private Notifier notifier;
focal_class.type: Notifier
focal_class.var_name: notifier
focal_class.declarator: executorService
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private ScheduledExecutorService executorService;
focal_class.type: ScheduledExecutorService
focal_class.var_name: executorService
focal_class.declarator: sessionManager
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private SessionManager sessionManager;
focal_class.type: SessionManager
focal_class.var_name: sessionManager
focal_class.declarator: configManager
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private ConfigManager configManager;
focal_class.type: ConfigManager
focal_class.var_name: configManager
focal_class.declarator: grandExchangeText
focal_class.modifier: private
focal_class.original_string: private Widget grandExchangeText;
focal_class.type: Widget
focal_class.var_name: grandExchangeText
focal_class.declarator: grandExchangeItem
focal_class.modifier: private
focal_class.original_string: private Widget grandExchangeItem;
focal_class.type: Widget
focal_class.var_name: grandExchangeItem
focal_class.declarator: grandExchangeExamine
focal_class.modifier: private
focal_class.original_string: private String grandExchangeExamine;
focal_class.type: String
focal_class.var_name: grandExchangeExamine
focal_class.declarator: osbItem
focal_class.modifier: private
focal_class.original_string: private int osbItem;
focal_class.type: int
focal_class.var_name: osbItem
focal_class.declarator: osbGrandExchangeResult
focal_class.modifier: private
focal_class.original_string: private OSBGrandExchangeResult osbGrandExchangeResult;
focal_class.type: OSBGrandExchangeResult
focal_class.var_name: osbGrandExchangeResult
focal_class.declarator: grandExchangeClient
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private GrandExchangeClient grandExchangeClient;
focal_class.type: GrandExchangeClient
focal_class.var_name: grandExchangeClient
focal_class.declarator: loginBurstGeUpdates
focal_class.modifier: private
focal_class.original_string: private boolean loginBurstGeUpdates;
focal_class.type: boolean
focal_class.var_name: loginBurstGeUpdates
focal_class.declarator: osbGrandExchangeClient
focal_class.modifier: @Inject
  	private
focal_class.original_string: @Inject
  	private OSBGrandExchangeClient osbGrandExchangeClient;
focal_class.type: OSBGrandExchangeClient
focal_class.var_name: osbGrandExchangeClient
focal_class.declarator: wasFuzzySearch
focal_class.modifier: private
focal_class.original_string: private boolean wasFuzzySearch;
focal_class.type: boolean
focal_class.var_name: wasFuzzySearch
focal_class.declarator: machineUuid
focal_class.modifier: private
focal_class.original_string: private String machineUuid;
focal_class.type: String
focal_class.var_name: machineUuid
focal_class.declarator: lastUsername
focal_class.modifier: private
focal_class.original_string: private String lastUsername;
focal_class.type: String
focal_class.var_name: lastUsername
focal_class.file: runelite-client/src/main/java/net/runelite/client/plugins/grandexchange/GrandExchangePlugin.java
focal_class.identifier: GrandExchangePlugin
focal_class.class_method_signature: GrandExchangePlugin.findFuzzyIndices(String term, String query)
focal_class.full_signature: @VisibleForTesting static List<Integer> findFuzzyIndices(String term, String query)
focal_class.identifier: findFuzzyIndices
focal_class.modifiers: @VisibleForTesting static
focal_class.parameters: (String term, String query)
focal_class.return: List<Integer>
focal_class.signature: List<Integer> findFuzzyIndices(String term, String query)
focal_class.class_method_signature: GrandExchangePlugin.getOffer(int slot)
focal_class.full_signature: private SavedOffer getOffer(int slot)
focal_class.identifier: getOffer
focal_class.modifiers: private
focal_class.parameters: (int slot)
focal_class.return: SavedOffer
focal_class.signature: SavedOffer getOffer(int slot)
focal_class.class_method_signature: GrandExchangePlugin.setOffer(int slot, SavedOffer offer)
focal_class.full_signature: private void setOffer(int slot, SavedOffer offer)
focal_class.identifier: setOffer
focal_class.modifiers: private
focal_class.parameters: (int slot, SavedOffer offer)
focal_class.return: void
focal_class.signature: void setOffer(int slot, SavedOffer offer)
focal_class.class_method_signature: GrandExchangePlugin.deleteOffer(int slot)
focal_class.full_signature: private void deleteOffer(int slot)
focal_class.identifier: deleteOffer
focal_class.modifiers: private
focal_class.parameters: (int slot)
focal_class.return: void
focal_class.signature: void deleteOffer(int slot)
focal_class.class_method_signature: GrandExchangePlugin.provideConfig(ConfigManager configManager)
focal_class.full_signature: @Provides GrandExchangeConfig provideConfig(ConfigManager configManager)
focal_class.identifier: provideConfig
focal_class.modifiers: @Provides
focal_class.parameters: (ConfigManager configManager)
focal_class.return: GrandExchangeConfig
focal_class.signature: GrandExchangeConfig provideConfig(ConfigManager configManager)
focal_class.class_method_signature: GrandExchangePlugin.provideOsbGrandExchangeClient(OkHttpClient okHttpClient)
focal_class.full_signature: @Provides OSBGrandExchangeClient provideOsbGrandExchangeClient(OkHttpClient okHttpClient)
focal_class.identifier: provideOsbGrandExchangeClient
focal_class.modifiers: @Provides
focal_class.parameters: (OkHttpClient okHttpClient)
focal_class.return: OSBGrandExchangeClient
focal_class.signature: OSBGrandExchangeClient provideOsbGrandExchangeClient(OkHttpClient okHttpClient)
focal_class.class_method_signature: GrandExchangePlugin.provideGrandExchangeClient(OkHttpClient okHttpClient)
focal_class.full_signature: @Provides GrandExchangeClient provideGrandExchangeClient(OkHttpClient okHttpClient)
focal_class.identifier: provideGrandExchangeClient
focal_class.modifiers: @Provides
focal_class.parameters: (OkHttpClient okHttpClient)
focal_class.return: GrandExchangeClient
focal_class.signature: GrandExchangeClient provideGrandExchangeClient(OkHttpClient okHttpClient)
focal_class.class_method_signature: GrandExchangePlugin.startUp()
focal_class.full_signature: @Override protected void startUp()
focal_class.identifier: startUp
focal_class.modifiers: @Override protected
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void startUp()
focal_class.class_method_signature: GrandExchangePlugin.shutDown()
focal_class.full_signature: @Override protected void shutDown()
focal_class.identifier: shutDown
focal_class.modifiers: @Override protected
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void shutDown()
focal_class.class_method_signature: GrandExchangePlugin.onSessionOpen(SessionOpen sessionOpen)
focal_class.full_signature: @Subscribe public void onSessionOpen(SessionOpen sessionOpen)
focal_class.identifier: onSessionOpen
focal_class.modifiers: @Subscribe public
focal_class.parameters: (SessionOpen sessionOpen)
focal_class.return: void
focal_class.signature: void onSessionOpen(SessionOpen sessionOpen)
focal_class.class_method_signature: GrandExchangePlugin.onSessionClose(SessionClose sessionClose)
focal_class.full_signature: @Subscribe public void onSessionClose(SessionClose sessionClose)
focal_class.identifier: onSessionClose
focal_class.modifiers: @Subscribe public
focal_class.parameters: (SessionClose sessionClose)
focal_class.return: void
focal_class.signature: void onSessionClose(SessionClose sessionClose)
focal_class.class_method_signature: GrandExchangePlugin.onConfigChanged(ConfigChanged event)
focal_class.full_signature: @Subscribe public void onConfigChanged(ConfigChanged event)
focal_class.identifier: onConfigChanged
focal_class.modifiers: @Subscribe public
focal_class.parameters: (ConfigChanged event)
focal_class.return: void
focal_class.signature: void onConfigChanged(ConfigChanged event)
focal_class.class_method_signature: GrandExchangePlugin.onGrandExchangeOfferChanged(GrandExchangeOfferChanged offerEvent)
focal_class.full_signature: @Subscribe public void onGrandExchangeOfferChanged(GrandExchangeOfferChanged offerEvent)
focal_class.identifier: onGrandExchangeOfferChanged
focal_class.modifiers: @Subscribe public
focal_class.parameters: (GrandExchangeOfferChanged offerEvent)
focal_class.return: void
focal_class.signature: void onGrandExchangeOfferChanged(GrandExchangeOfferChanged offerEvent)
focal_class.class_method_signature: GrandExchangePlugin.submitTrade(int slot, GrandExchangeOffer offer)
focal_class.full_signature: @VisibleForTesting void submitTrade(int slot, GrandExchangeOffer offer)
focal_class.identifier: submitTrade
focal_class.modifiers: @VisibleForTesting
focal_class.parameters: (int slot, GrandExchangeOffer offer)
focal_class.return: void
focal_class.signature: void submitTrade(int slot, GrandExchangeOffer offer)
focal_class.class_method_signature: GrandExchangePlugin.getGeWorldType()
focal_class.full_signature: private WorldType getGeWorldType()
focal_class.identifier: getGeWorldType
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: WorldType
focal_class.signature: WorldType getGeWorldType()
focal_class.class_method_signature: GrandExchangePlugin.updateConfig(int slot, GrandExchangeOffer offer)
focal_class.full_signature: private void updateConfig(int slot, GrandExchangeOffer offer)
focal_class.identifier: updateConfig
focal_class.modifiers: private
focal_class.parameters: (int slot, GrandExchangeOffer offer)
focal_class.return: void
focal_class.signature: void updateConfig(int slot, GrandExchangeOffer offer)
focal_class.class_method_signature: GrandExchangePlugin.onChatMessage(ChatMessage event)
focal_class.full_signature: @Subscribe public void onChatMessage(ChatMessage event)
focal_class.identifier: onChatMessage
focal_class.modifiers: @Subscribe public
focal_class.parameters: (ChatMessage event)
focal_class.return: void
focal_class.signature: void onChatMessage(ChatMessage event)
focal_class.class_method_signature: GrandExchangePlugin.onGameStateChanged(GameStateChanged gameStateChanged)
focal_class.full_signature: @Subscribe public void onGameStateChanged(GameStateChanged gameStateChanged)
focal_class.identifier: onGameStateChanged
focal_class.modifiers: @Subscribe public
focal_class.parameters: (GameStateChanged gameStateChanged)
focal_class.return: void
focal_class.signature: void onGameStateChanged(GameStateChanged gameStateChanged)
focal_class.class_method_signature: GrandExchangePlugin.onMenuEntryAdded(MenuEntryAdded event)
focal_class.full_signature: @Subscribe public void onMenuEntryAdded(MenuEntryAdded event)
focal_class.identifier: onMenuEntryAdded
focal_class.modifiers: @Subscribe public
focal_class.parameters: (MenuEntryAdded event)
focal_class.return: void
focal_class.signature: void onMenuEntryAdded(MenuEntryAdded event)
focal_class.class_method_signature: GrandExchangePlugin.onFocusChanged(FocusChanged focusChanged)
focal_class.full_signature: @Subscribe public void onFocusChanged(FocusChanged focusChanged)
focal_class.identifier: onFocusChanged
focal_class.modifiers: @Subscribe public
focal_class.parameters: (FocusChanged focusChanged)
focal_class.return: void
focal_class.signature: void onFocusChanged(FocusChanged focusChanged)
focal_class.class_method_signature: GrandExchangePlugin.onWidgetLoaded(WidgetLoaded event)
focal_class.full_signature: @Subscribe public void onWidgetLoaded(WidgetLoaded event)
focal_class.identifier: onWidgetLoaded
focal_class.modifiers: @Subscribe public
focal_class.parameters: (WidgetLoaded event)
focal_class.return: void
focal_class.signature: void onWidgetLoaded(WidgetLoaded event)
focal_class.class_method_signature: GrandExchangePlugin.onScriptPostFired(ScriptPostFired event)
focal_class.full_signature: @Subscribe public void onScriptPostFired(ScriptPostFired event)
focal_class.identifier: onScriptPostFired
focal_class.modifiers: @Subscribe public
focal_class.parameters: (ScriptPostFired event)
focal_class.return: void
focal_class.signature: void onScriptPostFired(ScriptPostFired event)
focal_class.class_method_signature: GrandExchangePlugin.highlightSearchMatches()
focal_class.full_signature: private void highlightSearchMatches()
focal_class.identifier: highlightSearchMatches
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void highlightSearchMatches()
focal_class.class_method_signature: GrandExchangePlugin.onGrandExchangeSearched(GrandExchangeSearched event)
focal_class.full_signature: @Subscribe public void onGrandExchangeSearched(GrandExchangeSearched event)
focal_class.identifier: onGrandExchangeSearched
focal_class.modifiers: @Subscribe public
focal_class.parameters: (GrandExchangeSearched event)
focal_class.return: void
focal_class.signature: void onGrandExchangeSearched(GrandExchangeSearched event)
focal_class.class_method_signature: GrandExchangePlugin.onScriptCallbackEvent(ScriptCallbackEvent event)
focal_class.full_signature: @Subscribe public void onScriptCallbackEvent(ScriptCallbackEvent event)
focal_class.identifier: onScriptCallbackEvent
focal_class.modifiers: @Subscribe public
focal_class.parameters: (ScriptCallbackEvent event)
focal_class.return: void
focal_class.signature: void onScriptCallbackEvent(ScriptCallbackEvent event)
focal_class.class_method_signature: GrandExchangePlugin.setLimitResetTime(int itemId)
focal_class.full_signature: private void setLimitResetTime(int itemId)
focal_class.identifier: setLimitResetTime
focal_class.modifiers: private
focal_class.parameters: (int itemId)
focal_class.return: void
focal_class.signature: void setLimitResetTime(int itemId)
focal_class.class_method_signature: GrandExchangePlugin.getLimitResetTime(int itemId)
focal_class.full_signature: private Instant getLimitResetTime(int itemId)
focal_class.identifier: getLimitResetTime
focal_class.modifiers: private
focal_class.parameters: (int itemId)
focal_class.return: Instant
focal_class.signature: Instant getLimitResetTime(int itemId)
focal_class.class_method_signature: GrandExchangePlugin.updateLimitTimer(GrandExchangeOffer offer)
focal_class.full_signature: private void updateLimitTimer(GrandExchangeOffer offer)
focal_class.identifier: updateLimitTimer
focal_class.modifiers: private
focal_class.parameters: (GrandExchangeOffer offer)
focal_class.return: void
focal_class.signature: void updateLimitTimer(GrandExchangeOffer offer)
focal_class.class_method_signature: GrandExchangePlugin.rebuildGeText()
focal_class.full_signature: private void rebuildGeText()
focal_class.identifier: rebuildGeText
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void rebuildGeText()
focal_class.class_method_signature: GrandExchangePlugin.openGeLink(String name, int itemId)
focal_class.full_signature: static void openGeLink(String name, int itemId)
focal_class.identifier: openGeLink
focal_class.modifiers: static
focal_class.parameters: (String name, int itemId)
focal_class.return: void
focal_class.signature: void openGeLink(String name, int itemId)
focal_class.class_method_signature: GrandExchangePlugin.getMachineUuid()
focal_class.full_signature: private String getMachineUuid()
focal_class.identifier: getMachineUuid
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getMachineUuid()
focal_class.superclass: extends Plugin
focal_method.body: @VisibleForTesting
  	void submitTrade(int slot, GrandExchangeOffer offer)
  	{
  		GrandExchangeOfferState state = offer.getState();
  
  		if (state != GrandExchangeOfferState.CANCELLED_BUY && state != GrandExchangeOfferState.CANCELLED_SELL && state != GrandExchangeOfferState.BUYING && state != GrandExchangeOfferState.SELLING)
  		{
  			return;
  		}
  
  		SavedOffer savedOffer = getOffer(slot);
  		if (savedOffer == null && (state == GrandExchangeOfferState.BUYING || state == GrandExchangeOfferState.SELLING) && offer.getQuantitySold() == 0)
  		{
  			// new offer
  			GrandExchangeTrade grandExchangeTrade = new GrandExchangeTrade();
  			grandExchangeTrade.setBuy(state == GrandExchangeOfferState.BUYING);
  			grandExchangeTrade.setItemId(offer.getItemId());
  			grandExchangeTrade.setTotal(offer.getTotalQuantity());
  			grandExchangeTrade.setOffer(offer.getPrice());
  			grandExchangeTrade.setSlot(slot);
  			grandExchangeTrade.setWorldType(getGeWorldType());
  			grandExchangeTrade.setLogin(loginBurstGeUpdates);
  
  			log.debug("Submitting new trade: {}", grandExchangeTrade);
  			grandExchangeClient.submit(grandExchangeTrade);
  			return;
  		}
  
  		if (savedOffer == null || savedOffer.getItemId() != offer.getItemId() || savedOffer.getPrice() != offer.getPrice() || savedOffer.getTotalQuantity() != offer.getTotalQuantity())
  		{
  			// desync
  			return;
  		}
  
  		if (savedOffer.getState() == offer.getState() && savedOffer.getQuantitySold() == offer.getQuantitySold())
  		{
  			// no change
  			return;
  		}
  
  		if (state == GrandExchangeOfferState.CANCELLED_BUY || state == GrandExchangeOfferState.CANCELLED_SELL)
  		{
  			GrandExchangeTrade grandExchangeTrade = new GrandExchangeTrade();
  			grandExchangeTrade.setBuy(state == GrandExchangeOfferState.CANCELLED_BUY);
  			grandExchangeTrade.setCancel(true);
  			grandExchangeTrade.setItemId(offer.getItemId());
  			grandExchangeTrade.setQty(offer.getQuantitySold());
  			grandExchangeTrade.setTotal(offer.getTotalQuantity());
  			grandExchangeTrade.setSpent(offer.getSpent());
  			grandExchangeTrade.setOffer(offer.getPrice());
  			grandExchangeTrade.setSlot(slot);
  			grandExchangeTrade.setWorldType(getGeWorldType());
  			grandExchangeTrade.setLogin(loginBurstGeUpdates);
  
  			log.debug("Submitting cancelled: {}", grandExchangeTrade);
  			grandExchangeClient.submit(grandExchangeTrade);
  			return;
  		}
  
  		final int qty = offer.getQuantitySold() - savedOffer.getQuantitySold();
  		final int dspent = offer.getSpent() - savedOffer.getSpent();
  		if (qty <= 0 || dspent <= 0)
  		{
  			return;
  		}
  
  		GrandExchangeTrade grandExchangeTrade = new GrandExchangeTrade();
  		grandExchangeTrade.setBuy(state == GrandExchangeOfferState.BUYING);
  		grandExchangeTrade.setItemId(offer.getItemId());
  		grandExchangeTrade.setQty(offer.getQuantitySold());
  		grandExchangeTrade.setDqty(qty);
  		grandExchangeTrade.setTotal(offer.getTotalQuantity());
  		grandExchangeTrade.setDspent(dspent);
  		grandExchangeTrade.setSpent(offer.getSpent());
  		grandExchangeTrade.setOffer(offer.getPrice());
  		grandExchangeTrade.setSlot(slot);
  		grandExchangeTrade.setWorldType(getGeWorldType());
  		grandExchangeTrade.setLogin(loginBurstGeUpdates);
  
  		log.debug("Submitting trade: {}", grandExchangeTrade);
  		grandExchangeClient.submit(grandExchangeTrade);
  	}
focal_method.class_method_signature: GrandExchangePlugin.submitTrade(int slot, GrandExchangeOffer offer)
focal_method.full_signature: @VisibleForTesting void submitTrade(int slot, GrandExchangeOffer offer)
focal_method.identifier: submitTrade
focal_method.invocations: getState getOffer getQuantitySold setBuy setItemId getItemId setTotal getTotalQuantity setOffer getPrice setSlot setWorldType getGeWorldType setLogin debug submit getItemId getItemId getPrice getPrice getTotalQuantity getTotalQuantity getState getState getQuantitySold getQuantitySold setBuy setCancel setItemId getItemId setQty getQuantitySold setTotal getTotalQuantity setSpent getSpent setOffer getPrice setSlot setWorldType getGeWorldType setLogin debug submit getQuantitySold getQuantitySold getSpent getSpent setBuy setItemId getItemId setQty getQuantitySold setDqty setTotal getTotalQuantity setDspent setSpent getSpent setOffer getPrice setSlot setWorldType getGeWorldType setLogin debug submit
focal_method.modifiers: @VisibleForTesting
focal_method.parameters: (int slot, GrandExchangeOffer offer)
focal_method.return: void
focal_method.signature: void submitTrade(int slot, GrandExchangeOffer offer)