diff --git a/dist/r3.js b/dist/r3.js index 64db8ed..76cd8de 100644 --- a/dist/r3.js +++ b/dist/r3.js @@ -1,11 +1,12 @@ class R3 { - static version = '2.0.136'; - static compileDate = '2021 Sep 06 - 09:13:00 am'; + static version = '2.0.145'; + static compileDate = '2021 Sep 06 - 09:38:21 am'; } /** Started=false + Subscriptions=[] **/ @@ -22,6 +23,9 @@ class System { if (typeof options.started === 'undefined') { options.started = false; } + if (typeof options.subscriptions === 'undefined') { + options.subscriptions = []; + } Object.assign(this, options); @@ -31,7 +35,7 @@ class System { /** * start() - * - Just calls System.Start() + * - Starts a transient system by registering subscriptions to events */ start() { @@ -42,7 +46,7 @@ class System { /** * stop() - * - Just calls System.Stop() + * - Starts a transient by registering subscriptions to events */ stop() { @@ -53,7 +57,7 @@ class System { /** * Start() - * - Starts the system by registering subscriptions to events + * - Starts the global system by registering subscriptions to events */ static Start() { @@ -69,7 +73,7 @@ class System { /** * Stop() - * - Stops the system by removing these subscriptions to events + * - Stops the global system by removing these subscriptions to events */ static Stop() { @@ -84,6 +88,7 @@ class System { } System.Started = false; +System.Subscriptions = []; class Event { @@ -1620,9 +1625,41 @@ class Utils { Class R3.System.Input [Inherited from System] - Properties: + Inherited Properties: - started (Default value false) + - subscriptions (Default value []) + + Inherited Static Properties: + + - Started (Default value false) + - Subscriptions (Default value []) + + Inherited Methods: + + - start() + Starts a transient system by registering subscriptions to events + + - stop() + Starts a transient by registering subscriptions to events + + Inherited Static Methods: + + - Start() + Starts the global system by registering subscriptions to events + + - Stop() + Stops the global system by removing these subscriptions to events + + [Belonging to SystemInput] + + Properties: + + + + Static Properties: + + Methods: @@ -1640,28 +1677,6 @@ class Utils { - Stop() Stops the system by removing these subscriptions to events - [Belonging to SystemInput] - - Properties: - - - - Methods: - - - start() - Overrides for R3.System.start() - - - stop() - Overrides for R3.System.stop() - - Static Methods: - - - Start() - Overrides for R3.System.Start() - - - Stop() - Overrides for R3.System.Stop() - **/ class SystemInput extends System { @@ -2002,30 +2017,40 @@ class SystemInput extends System { Class R3.System.Linking [Inherited from System] - Properties: + Inherited Properties: - started (Default value false) + - subscriptions (Default value []) - Methods: + Inherited Static Properties: + + - Started (Default value false) + - Subscriptions (Default value []) + + Inherited Methods: - start() - Just calls System.Start() + Starts a transient system by registering subscriptions to events - stop() - Just calls System.Stop() + Starts a transient by registering subscriptions to events - Static Methods: + Inherited Static Methods: - Start() - Starts the system by registering subscriptions to events + Starts the global system by registering subscriptions to events - Stop() - Stops the system by removing these subscriptions to events + Stops the global system by removing these subscriptions to events [Belonging to SystemLinking] Properties: + + + Static Properties: + Methods: @@ -2180,30 +2205,40 @@ class SystemLinking extends System { Class R3.System.Socket [Inherited from System] - Properties: + Inherited Properties: - started (Default value false) + - subscriptions (Default value []) - Methods: + Inherited Static Properties: + + - Started (Default value false) + - Subscriptions (Default value []) + + Inherited Methods: - start() - Just calls System.Start() + Starts a transient system by registering subscriptions to events - stop() - Just calls System.Stop() + Starts a transient by registering subscriptions to events - Static Methods: + Inherited Static Methods: - Start() - Starts the system by registering subscriptions to events + Starts the global system by registering subscriptions to events - Stop() - Stops the system by removing these subscriptions to events + Stops the global system by removing these subscriptions to events [Belonging to SystemSocket] Properties: + + + Static Properties: + Methods: @@ -2309,30 +2344,40 @@ class SystemSocket extends System { Class R3.System.Test [Inherited from System] - Properties: + Inherited Properties: - started (Default value false) + - subscriptions (Default value []) - Methods: + Inherited Static Properties: + + - Started (Default value false) + - Subscriptions (Default value []) + + Inherited Methods: - start() - Just calls System.Start() + Starts a transient system by registering subscriptions to events - stop() - Just calls System.Stop() + Starts a transient by registering subscriptions to events - Static Methods: + Inherited Static Methods: - Start() - Starts the system by registering subscriptions to events + Starts the global system by registering subscriptions to events - Stop() - Stops the system by removing these subscriptions to events + Stops the global system by removing these subscriptions to events [Belonging to SystemTest] Properties: + + + Static Properties: + Methods: @@ -2434,11 +2479,15 @@ class SystemTest extends System { Class R3.Event.Object [Inherited from Event] - Properties: + Inherited Properties: - Methods: + Inherited Static Properties: + + + + Inherited Methods: - async(eventId, data, clientCallback, clientErrorCallback) Simply calls 'Async()' passing it the arguments @@ -2449,7 +2498,7 @@ class SystemTest extends System { - subscribe(eventId, callback) Simply calls 'Subscribe()' passing it the arguments - Static Methods: + Inherited Static Methods: - Async(eventId, data, clientCallback, clientErrorCallback) Calls all subscription functions registered to eventId with data, clientCallback and clientErrorCallback as @@ -2470,6 +2519,10 @@ class SystemTest extends System { - register (Default value true) + Static Properties: + + + Methods: @@ -2513,11 +2566,15 @@ class R3Object extends Event { Class R3.Event.Runtime [Inherited from Event] - Properties: + Inherited Properties: - Methods: + Inherited Static Properties: + + + + Inherited Methods: - async(eventId, data, clientCallback, clientErrorCallback) Simply calls 'Async()' passing it the arguments @@ -2528,7 +2585,7 @@ class R3Object extends Event { - subscribe(eventId, callback) Simply calls 'Subscribe()' passing it the arguments - Static Methods: + Inherited Static Methods: - Async(eventId, data, clientCallback, clientErrorCallback) Calls all subscription functions registered to eventId with data, clientCallback and clientErrorCallback as @@ -2547,6 +2604,10 @@ class R3Object extends Event { Properties: + + + Static Properties: + Methods: @@ -2591,11 +2652,15 @@ Runtime.GRAPHICS = 0x2; Class R3.Event.Object.Component [Inherited from Event] - Properties: + Inherited Properties: - Methods: + Inherited Static Properties: + + + + Inherited Methods: - async(eventId, data, clientCallback, clientErrorCallback) Simply calls 'Async()' passing it the arguments @@ -2606,7 +2671,7 @@ Runtime.GRAPHICS = 0x2; - subscribe(eventId, callback) Simply calls 'Subscribe()' passing it the arguments - Static Methods: + Inherited Static Methods: - Async(eventId, data, clientCallback, clientErrorCallback) Calls all subscription functions registered to eventId with data, clientCallback and clientErrorCallback as @@ -2623,15 +2688,19 @@ Runtime.GRAPHICS = 0x2; [Inherited from R3Object] - Properties: + Inherited Properties: - register (Default value true) - Methods: + Inherited Static Properties: + + + + Inherited Methods: - Static Methods: + Inherited Static Methods: @@ -2641,6 +2710,10 @@ Runtime.GRAPHICS = 0x2; - runtime (Default value R3.Runtime.DEFAULT) + Static Properties: + + + Methods: - createInstance() @@ -2759,11 +2832,15 @@ class Component extends R3Object { Class R3.Event.Object.Project [Inherited from Event] - Properties: + Inherited Properties: - Methods: + Inherited Static Properties: + + + + Inherited Methods: - async(eventId, data, clientCallback, clientErrorCallback) Simply calls 'Async()' passing it the arguments @@ -2774,7 +2851,7 @@ class Component extends R3Object { - subscribe(eventId, callback) Simply calls 'Subscribe()' passing it the arguments - Static Methods: + Inherited Static Methods: - Async(eventId, data, clientCallback, clientErrorCallback) Calls all subscription functions registered to eventId with data, clientCallback and clientErrorCallback as @@ -2791,15 +2868,19 @@ class Component extends R3Object { [Inherited from R3Object] - Properties: + Inherited Properties: - register (Default value true) - Methods: + Inherited Static Properties: + + + + Inherited Methods: - Static Methods: + Inherited Static Methods: @@ -2807,6 +2888,10 @@ class Component extends R3Object { Properties: + + + Static Properties: + Methods: @@ -2848,11 +2933,15 @@ class Project extends R3Object { Class R3.Event.Object.Component.Image [Inherited from Event] - Properties: + Inherited Properties: - Methods: + Inherited Static Properties: + + + + Inherited Methods: - async(eventId, data, clientCallback, clientErrorCallback) Simply calls 'Async()' passing it the arguments @@ -2863,7 +2952,7 @@ class Project extends R3Object { - subscribe(eventId, callback) Simply calls 'Subscribe()' passing it the arguments - Static Methods: + Inherited Static Methods: - Async(eventId, data, clientCallback, clientErrorCallback) Calls all subscription functions registered to eventId with data, clientCallback and clientErrorCallback as @@ -2880,25 +2969,33 @@ class Project extends R3Object { [Inherited from R3Object] - Properties: + Inherited Properties: - register (Default value true) - Methods: + Inherited Static Properties: + + + + Inherited Methods: - Static Methods: + Inherited Static Methods: [Inherited from Component] - Properties: + Inherited Properties: - runtime (Default value R3.Runtime.DEFAULT) - Methods: + Inherited Static Properties: + + + + Inherited Methods: - createInstance() No comment @@ -2912,7 +3009,7 @@ class Project extends R3Object { - getRuntime() No comment - Static Methods: + Inherited Static Methods: @@ -2920,6 +3017,10 @@ class Project extends R3Object { Properties: + + + Static Properties: + Methods: diff --git a/package.json b/package.json index 8ec0d96..9b51c73 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "r3", - "version" : "2.0.136", + "version" : "2.0.145", "description": "", "private": true, "dependencies": { diff --git a/r3.php b/r3.php index d693eb3..a3424ba 100755 --- a/r3.php +++ b/r3.php @@ -309,7 +309,7 @@ function doGetInheritedTemplateUpdates($node, $restoreTokens, $inherited = true, if ($inherited) { $PROPERTY_LIST = ''; } else { - $PROPERTY_LIST = ''; + $PROPERTY_LIST = ''; } } else { $propertyListItems = getPropertyListItems($store); @@ -317,6 +317,20 @@ function doGetInheritedTemplateUpdates($node, $restoreTokens, $inherited = true, } $PROPERTY_LIST = trim($PROPERTY_LIST); + $token = 'CUSTOM_STATIC_OPTIONS'; + $store = getTokenStore($token, $tokens); + if (sizeof($store) <= 0) { + if ($inherited) { + $STATIC_PROPERTY_LIST = ''; + } else { + $STATIC_PROPERTY_LIST = ''; + } + } else { + $propertyListItems = getPropertyListItems($store); + $STATIC_PROPERTY_LIST = implode("\n ", $propertyListItems); + } + $STATIC_PROPERTY_LIST = trim($STATIC_PROPERTY_LIST); + $token = 'CUSTOM_METHODS'; $store = getTokenStore($token, $tokens); $parentStore = getTokenStore($token, $parentTokens); @@ -361,9 +375,17 @@ function doGetInheritedTemplateUpdates($node, $restoreTokens, $inherited = true, $updated = preg_replace('/^.*?FIRST_TEMPLATE.*\n/m', "", $template); } + if ($inherited) { + $INHERITED = 'Inherited '; + } else { + $INHERITED = ''; + } + + $updated = str_replace('INHERITED', $INHERITED, $updated); $updated = str_replace('DESCRIPTION', $description, $updated); $updated = str_replace('CLASS_NAME', $CLASS_NAME, $updated); - $updated = str_replace('PROPERTY_LIST', $PROPERTY_LIST, $updated); + $updated = preg_replace('/\bPROPERTY_LIST\b/', $PROPERTY_LIST, $updated); + $updated = preg_replace('/\bSTATIC_PROPERTY_LIST\b/', $STATIC_PROPERTY_LIST, $updated); $updated = str_replace('STATIC_METHOD_LIST', $STATIC_METHOD_LIST, $updated); $updated = str_replace('METHOD_LIST', $METHOD_LIST, $updated); $updates .= $updated; diff --git a/src/r3/r3-component/r3-component.js b/src/r3/r3-component/r3-component.js index f563cc0..073f0f5 100644 --- a/src/r3/r3-component/r3-component.js +++ b/src/r3/r3-component/r3-component.js @@ -9,11 +9,15 @@ const R3Object = require('.././r3-r3-object.js'); Class R3.Event.Object.Component [Inherited from Event] - Properties: + Inherited Properties: - Methods: + Inherited Static Properties: + + + + Inherited Methods: - async(eventId, data, clientCallback, clientErrorCallback) Simply calls 'Async()' passing it the arguments @@ -24,7 +28,7 @@ const R3Object = require('.././r3-r3-object.js'); - subscribe(eventId, callback) Simply calls 'Subscribe()' passing it the arguments - Static Methods: + Inherited Static Methods: - Async(eventId, data, clientCallback, clientErrorCallback) Calls all subscription functions registered to eventId with data, clientCallback and clientErrorCallback as @@ -41,15 +45,19 @@ const R3Object = require('.././r3-r3-object.js'); [Inherited from R3Object] - Properties: + Inherited Properties: - register (Default value true) - Methods: + Inherited Static Properties: + + + + Inherited Methods: - Static Methods: + Inherited Static Methods: @@ -59,6 +67,10 @@ const R3Object = require('.././r3-r3-object.js'); - runtime (Default value R3.Runtime.DEFAULT) + Static Properties: + + + Methods: - createInstance() diff --git a/src/r3/r3-component/r3-image.js b/src/r3/r3-component/r3-image.js index 76eeff2..300df46 100644 --- a/src/r3/r3-component/r3-image.js +++ b/src/r3/r3-component/r3-image.js @@ -9,11 +9,15 @@ const Component = require('.././r3-component.js'); Class R3.Event.Object.Component.Image [Inherited from Event] - Properties: + Inherited Properties: - Methods: + Inherited Static Properties: + + + + Inherited Methods: - async(eventId, data, clientCallback, clientErrorCallback) Simply calls 'Async()' passing it the arguments @@ -24,7 +28,7 @@ const Component = require('.././r3-component.js'); - subscribe(eventId, callback) Simply calls 'Subscribe()' passing it the arguments - Static Methods: + Inherited Static Methods: - Async(eventId, data, clientCallback, clientErrorCallback) Calls all subscription functions registered to eventId with data, clientCallback and clientErrorCallback as @@ -41,25 +45,33 @@ const Component = require('.././r3-component.js'); [Inherited from R3Object] - Properties: + Inherited Properties: - register (Default value true) - Methods: + Inherited Static Properties: + + + + Inherited Methods: - Static Methods: + Inherited Static Methods: [Inherited from Component] - Properties: + Inherited Properties: - runtime (Default value R3.Runtime.DEFAULT) - Methods: + Inherited Static Properties: + + + + Inherited Methods: - createInstance() No comment @@ -73,7 +85,7 @@ const Component = require('.././r3-component.js'); - getRuntime() No comment - Static Methods: + Inherited Static Methods: @@ -81,6 +93,10 @@ const Component = require('.././r3-component.js'); Properties: + + + Static Properties: + Methods: diff --git a/src/r3/r3-project.js b/src/r3/r3-project.js index 7216f74..22e0553 100644 --- a/src/r3/r3-project.js +++ b/src/r3/r3-project.js @@ -9,11 +9,15 @@ const R3Object = require('./r3-r3-object.js'); Class R3.Event.Object.Project [Inherited from Event] - Properties: + Inherited Properties: - Methods: + Inherited Static Properties: + + + + Inherited Methods: - async(eventId, data, clientCallback, clientErrorCallback) Simply calls 'Async()' passing it the arguments @@ -24,7 +28,7 @@ const R3Object = require('./r3-r3-object.js'); - subscribe(eventId, callback) Simply calls 'Subscribe()' passing it the arguments - Static Methods: + Inherited Static Methods: - Async(eventId, data, clientCallback, clientErrorCallback) Calls all subscription functions registered to eventId with data, clientCallback and clientErrorCallback as @@ -41,15 +45,19 @@ const R3Object = require('./r3-r3-object.js'); [Inherited from R3Object] - Properties: + Inherited Properties: - register (Default value true) - Methods: + Inherited Static Properties: + + + + Inherited Methods: - Static Methods: + Inherited Static Methods: @@ -57,6 +65,10 @@ const R3Object = require('./r3-r3-object.js'); Properties: + + + Static Properties: + Methods: diff --git a/src/r3/r3-r3-object.js b/src/r3/r3-r3-object.js index d5a59de..02c1547 100644 --- a/src/r3/r3-r3-object.js +++ b/src/r3/r3-r3-object.js @@ -8,11 +8,15 @@ const Event = require('./r3-event.js'); Class R3.Event.Object [Inherited from Event] - Properties: + Inherited Properties: - Methods: + Inherited Static Properties: + + + + Inherited Methods: - async(eventId, data, clientCallback, clientErrorCallback) Simply calls 'Async()' passing it the arguments @@ -23,7 +27,7 @@ const Event = require('./r3-event.js'); - subscribe(eventId, callback) Simply calls 'Subscribe()' passing it the arguments - Static Methods: + Inherited Static Methods: - Async(eventId, data, clientCallback, clientErrorCallback) Calls all subscription functions registered to eventId with data, clientCallback and clientErrorCallback as @@ -44,6 +48,10 @@ const Event = require('./r3-event.js'); - register (Default value true) + Static Properties: + + + Methods: diff --git a/src/r3/r3-r3.js b/src/r3/r3-r3.js index 73b3d5c..180db83 100644 --- a/src/r3/r3-r3.js +++ b/src/r3/r3-r3.js @@ -1,6 +1,6 @@ class R3 { - static version = '2.0.136'; - static compileDate = '2021 Sep 06 - 09:13:00 am'; + static version = '2.0.145'; + static compileDate = '2021 Sep 06 - 09:38:21 am'; } //GENERATED_IMPORTS_START diff --git a/src/r3/r3-runtime.js b/src/r3/r3-runtime.js index 83f1a3a..bf16cb3 100644 --- a/src/r3/r3-runtime.js +++ b/src/r3/r3-runtime.js @@ -8,11 +8,15 @@ const Event = require('./r3-event.js'); Class R3.Event.Runtime [Inherited from Event] - Properties: + Inherited Properties: - Methods: + Inherited Static Properties: + + + + Inherited Methods: - async(eventId, data, clientCallback, clientErrorCallback) Simply calls 'Async()' passing it the arguments @@ -23,7 +27,7 @@ const Event = require('./r3-event.js'); - subscribe(eventId, callback) Simply calls 'Subscribe()' passing it the arguments - Static Methods: + Inherited Static Methods: - Async(eventId, data, clientCallback, clientErrorCallback) Calls all subscription functions registered to eventId with data, clientCallback and clientErrorCallback as @@ -42,6 +46,10 @@ const Event = require('./r3-event.js'); Properties: + + + Static Properties: + Methods: diff --git a/src/r3/r3-system/r3-system-input.js b/src/r3/r3-system/r3-system-input.js index 7d35a4b..2f68a10 100644 --- a/src/r3/r3-system/r3-system-input.js +++ b/src/r3/r3-system/r3-system-input.js @@ -9,9 +9,41 @@ const System = require('./r3-system.js'); Class R3.System.Input [Inherited from System] - Properties: + Inherited Properties: - started (Default value false) + - subscriptions (Default value []) + + Inherited Static Properties: + + - Started (Default value false) + - Subscriptions (Default value []) + + Inherited Methods: + + - start() + Starts a transient system by registering subscriptions to events + + - stop() + Starts a transient by registering subscriptions to events + + Inherited Static Methods: + + - Start() + Starts the global system by registering subscriptions to events + + - Stop() + Stops the global system by removing these subscriptions to events + + [Belonging to SystemInput] + + Properties: + + + + Static Properties: + + Methods: @@ -29,28 +61,6 @@ const System = require('./r3-system.js'); - Stop() Stops the system by removing these subscriptions to events - [Belonging to SystemInput] - - Properties: - - - - Methods: - - - start() - Overrides for R3.System.start() - - - stop() - Overrides for R3.System.stop() - - Static Methods: - - - Start() - Overrides for R3.System.Start() - - - Stop() - Overrides for R3.System.Stop() - GENERATED_INHERITED_END CUSTOM_OPTIONS_START diff --git a/src/r3/r3-system/r3-system-linking.js b/src/r3/r3-system/r3-system-linking.js index cc74f8c..210b393 100644 --- a/src/r3/r3-system/r3-system-linking.js +++ b/src/r3/r3-system/r3-system-linking.js @@ -9,30 +9,40 @@ const System = require('./r3-system.js'); Class R3.System.Linking [Inherited from System] - Properties: + Inherited Properties: - started (Default value false) + - subscriptions (Default value []) - Methods: + Inherited Static Properties: + + - Started (Default value false) + - Subscriptions (Default value []) + + Inherited Methods: - start() - Just calls System.Start() + Starts a transient system by registering subscriptions to events - stop() - Just calls System.Stop() + Starts a transient by registering subscriptions to events - Static Methods: + Inherited Static Methods: - Start() - Starts the system by registering subscriptions to events + Starts the global system by registering subscriptions to events - Stop() - Stops the system by removing these subscriptions to events + Stops the global system by removing these subscriptions to events [Belonging to SystemLinking] Properties: + + + Static Properties: + Methods: diff --git a/src/r3/r3-system/r3-system-socket.js b/src/r3/r3-system/r3-system-socket.js index 2832840..c2d37e1 100644 --- a/src/r3/r3-system/r3-system-socket.js +++ b/src/r3/r3-system/r3-system-socket.js @@ -9,30 +9,40 @@ const System = require('./r3-system.js'); Class R3.System.Socket [Inherited from System] - Properties: + Inherited Properties: - started (Default value false) + - subscriptions (Default value []) - Methods: + Inherited Static Properties: + + - Started (Default value false) + - Subscriptions (Default value []) + + Inherited Methods: - start() - Just calls System.Start() + Starts a transient system by registering subscriptions to events - stop() - Just calls System.Stop() + Starts a transient by registering subscriptions to events - Static Methods: + Inherited Static Methods: - Start() - Starts the system by registering subscriptions to events + Starts the global system by registering subscriptions to events - Stop() - Stops the system by removing these subscriptions to events + Stops the global system by removing these subscriptions to events [Belonging to SystemSocket] Properties: + + + Static Properties: + Methods: diff --git a/src/r3/r3-system/r3-system-test.js b/src/r3/r3-system/r3-system-test.js index 4b484c6..9b04676 100644 --- a/src/r3/r3-system/r3-system-test.js +++ b/src/r3/r3-system/r3-system-test.js @@ -9,30 +9,40 @@ const System = require('./r3-system.js'); Class R3.System.Test [Inherited from System] - Properties: + Inherited Properties: - started (Default value false) + - subscriptions (Default value []) - Methods: + Inherited Static Properties: + + - Started (Default value false) + - Subscriptions (Default value []) + + Inherited Methods: - start() - Just calls System.Start() + Starts a transient system by registering subscriptions to events - stop() - Just calls System.Stop() + Starts a transient by registering subscriptions to events - Static Methods: + Inherited Static Methods: - Start() - Starts the system by registering subscriptions to events + Starts the global system by registering subscriptions to events - Stop() - Stops the system by removing these subscriptions to events + Stops the global system by removing these subscriptions to events [Belonging to SystemTest] Properties: + + + Static Properties: + Methods: diff --git a/src/r3/r3-system/r3-system.js b/src/r3/r3-system/r3-system.js index 069f249..17dfa3d 100644 --- a/src/r3/r3-system/r3-system.js +++ b/src/r3/r3-system/r3-system.js @@ -5,20 +5,22 @@ const Utils = require('.././r3-utils'); CUSTOM_OPTIONS_START started=false + subscriptions=[] CUSTOM_OPTIONS_END CUSTOM_STATIC_OPTIONS_START Started=false + Subscriptions=[] CUSTOM_STATIC_OPTIONS_END CUSTOM_METHODS_START - start() - Just calls System.Start() - stop() - Just calls System.Stop() + start() - Starts a transient system by registering subscriptions to events + stop() - Starts a transient by registering subscriptions to events CUSTOM_METHODS_END CUSTOM_STATIC_METHODS_START - Start() - Starts the system by registering subscriptions to events - Stop() - Stops the system by removing these subscriptions to events + Start() - Starts the global system by registering subscriptions to events + Stop() - Stops the global system by removing these subscriptions to events CUSTOM_STATIC_METHODS_END **/ @@ -38,6 +40,9 @@ class System { if (typeof options.started === 'undefined') { options.started = false; } + if (typeof options.subscriptions === 'undefined') { + options.subscriptions = []; + } //GENERATED_OPTIONS_INIT_END //CUSTOM_OPTIONS_INIT_START @@ -59,7 +64,7 @@ class System { /** * start() - * - Just calls System.Start() + * - Starts a transient system by registering subscriptions to events */ start() { @@ -75,7 +80,7 @@ class System { /** * stop() - * - Just calls System.Stop() + * - Starts a transient by registering subscriptions to events */ stop() { @@ -94,7 +99,7 @@ class System { /** * Start() - * - Starts the system by registering subscriptions to events + * - Starts the global system by registering subscriptions to events */ static Start() { @@ -120,7 +125,7 @@ class System { /** * Stop() - * - Stops the system by removing these subscriptions to events + * - Stops the global system by removing these subscriptions to events */ static Stop() { @@ -150,6 +155,7 @@ class System { //GENERATED_STATIC_OPTIONS_INIT_START System.Started = false; +System.Subscriptions = []; //GENERATED_STATIC_OPTIONS_INIT_END //CUSTOM_OUT_OF_CLASS_IMPLEMENTATION_START diff --git a/src/templates/generated_custom_static_options_init.template b/src/templates/generated_custom_static_options_init.template index 2867e77..3255d94 100644 --- a/src/templates/generated_custom_static_options_init.template +++ b/src/templates/generated_custom_static_options_init.template @@ -1 +1 @@ -CLASS_NAME.KEY = VALUE; \ No newline at end of file +CLASS_NAME.KEY = VALUE; diff --git a/src/templates/generated_inherited.template b/src/templates/generated_inherited.template index 62c56a7..698956a 100644 --- a/src/templates/generated_inherited.template +++ b/src/templates/generated_inherited.template @@ -2,15 +2,19 @@ FIRST_TEMPLATE [DESCRIPTION CLASS_NAME] - Properties: + INHERITEDProperties: PROPERTY_LIST - Methods: + INHERITEDStatic Properties: + + STATIC_PROPERTY_LIST + + INHERITEDMethods: METHOD_LIST - Static Methods: + INHERITEDStatic Methods: STATIC_METHOD_LIST diff --git a/src/templates/system-base.template b/src/templates/system-base.template index ae449b4..01ed82a 100644 --- a/src/templates/system-base.template +++ b/src/templates/system-base.template @@ -4,21 +4,15 @@ const Utils = require('INCLUDE_PATH/r3-utils'); /** CUSTOM_OPTIONS_START - started=false CUSTOM_OPTIONS_END CUSTOM_STATIC_OPTIONS_START - Started=false CUSTOM_STATIC_OPTIONS_END CUSTOM_METHODS_START - start() - Just calls System.Start() - stop() - Just calls System.Stop() CUSTOM_METHODS_END CUSTOM_STATIC_METHODS_START - Start() - Starts the system by registering subscriptions to events - Stop() - Stops the system by removing these subscriptions to events CUSTOM_STATIC_METHODS_END **/ diff --git a/version b/version index ff4939c..9576870 100644 --- a/version +++ b/version @@ -1 +1 @@ -2.0.136 \ No newline at end of file +2.0.145 \ No newline at end of file