... | ... | @@ -134,7 +134,7 @@ cameopy.This.init(sys.argv) |
|
|
```
|
|
|
|
|
|
Once *This* is initialized it can be used for example to get a reference to the Cameo server that started it. When *This* is initialized with the *arguments* variable, there are two cases:
|
|
|
* **Registered application**: If the application is registered in the configuration file, then *info_arg* must be set to *yes* which is the default value. Otherwise the application will not start.
|
|
|
* **Registered application**: If the application is registered in the configuration file, then *info_arg* must be *yes* which is the default value so it is not necessary to specify it. Otherwise the application will not start.
|
|
|
* **Not registered application**: If the application is not registered in the configuration file, it is possible to start directly the app by adding a last argument that contains the Cameo server reference and its name. For instance:
|
|
|
```
|
|
|
$ /users/ics/app1 "{\"name\":\"App1\", \"server\":\"tcp://localhost:10000\"}"
|
... | ... | @@ -157,4 +157,6 @@ In Python: |
|
|
cameopy.This.init("App1", "tcp://localhost:10000")
|
|
|
```
|
|
|
|
|
|
## *This* not initialized
|
|
|
|
|
|
If you have a black box application i.e. that you cannot compile or modify, then you cannot initialize *This* inside but you still can register the application in the configuration file. However it is recommended in that special case to set *info_arg* to *no*. Indeed otherwise the additional argument may not be supported by the app when it parses the arguments. |