Skip to content

Commit

Permalink
Improved: Allow updating the ‘Config’ object of the server instance
Browse files Browse the repository at this point in the history
(OFBIZ-11203)

When doing some informal tests, it is useful to be able to create
small programs using the OFBiz delegator without requiring every
components to be loaded as done by the ‘Start#main’ static method.

To achieve that with the current singleton based implementation, we
need to instantiate a custom ‘Config’ object and use it as the global
configuration.

Thanks: Samuel Trégouët for your contribution.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1867343 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
mthl committed Sep 22, 2019
1 parent daa1e61 commit 1fd1b03
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,15 @@ public Config getConfig() {
return this.config;
}

/**
* Updates the server's main configuration.
*
* @param c the new configuration
*/
public void setConfig(Config c) {
this.config = c;
}

/**
* Returns the server's current state.
*/
Expand Down

0 comments on commit 1fd1b03

Please sign in to comment.