Skip to content

Commit

Permalink
Merge pull request #767 from spoerri/patch-1
Browse files Browse the repository at this point in the history
increase banzai's OCP a little
  • Loading branch information
chrjohn authored Feb 17, 2024
2 parents 24d836b + 0a4ace5 commit 91e0911
Showing 1 changed file with 15 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,9 @@ public Banzai(String[] args) throws Exception {

boolean logHeartbeats = Boolean.valueOf(System.getProperty("logHeartbeats", "true"));

OrderTableModel orderTableModel = new OrderTableModel();
ExecutionTableModel executionTableModel = new ExecutionTableModel();
BanzaiApplication application = new BanzaiApplication(orderTableModel, executionTableModel);
OrderTableModel orderTableModel = orderTableModel();
ExecutionTableModel executionTableModel = executionTableModel();
BanzaiApplication application = application(orderTableModel, executionTableModel);
MessageStoreFactory messageStoreFactory = new FileStoreFactory(settings);
LogFactory logFactory = new ScreenLogFactory(true, true, true, logHeartbeats);
MessageFactory messageFactory = new DefaultMessageFactory();
Expand All @@ -88,6 +88,18 @@ public Banzai(String[] args) throws Exception {
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}

protected OrderTableModel orderTableModel() {
return new OrderTableModel();
}

protected ExecutionTableModel executionTableModel() {
return new ExecutionTableModel();
}

protected BanzaiApplication application(OrderTableModel orderTableModel, ExecutionTableModel executionTableModel) {
return new BanzaiApplication(orderTableModel, executionTableModel);
}

public synchronized void logon() {
if (!initiatorStarted) {
try {
Expand Down

0 comments on commit 91e0911

Please sign in to comment.