N-tier architecture: Difference between revisions
Jump to navigation
Jump to search
m (1 revision) |
No edit summary |
||
Line 1: | Line 1: | ||
= Client/Server Architecture = | |||
== Glue between Server and Client == | == Glue between Server and Client == | ||
* the code for interfaces and instantiators is generated | * the code for interfaces and instantiators is generated |
Revision as of 11:24, 21 July 2009
Client/Server Architecture
Glue between Server and Client
- the code for interfaces and instantiators is generated
- first edit file csharp/ICT/Petra/Definitions/NamespaceHierarchy.xml (TODO?: change to yml for easier readability)
- then run nant generateGlue for the first time
- then you can create a UIConnector .cs file; the constructor will be added to the Instantiator and to the interface the next time you run nant generateGlue
- a method that should not be added to the interface, should either be private, or have comment [NO-REMOTING] (with 3 slashes)
- you can also add a method to the instantiator, and put its codeblock in a ManualCode region; next time you generateGlue, the method will be added to the interface
different ways of accessing data on the server
- UIConnectors: only used for screens; keep an object on the server for each screen
- LogicConnectors: keeps an object on the server side; needed for progress bar; eg. Report Calculation
- ServerLookup: used for static methods; no object is held on the server; eg. Verify Partner in ExperimentingClient; UserDefaults uses ServerLookups internally
- Cacheable: also static methods; they are not called by the developer, but by the Cachemanager on the server and the client side, when you are accessing a cached table
- Todo: something special about UIConnectors; extra things are generated for UIConnectors
- the others are implemented manually at the moment
- TODO: progress bar; need different threads; keep the connection; prevent the object from being garbage collected
- need extra object on server for progress and cancel option (eg FReportingGenerator.AsyncExecProgress)
- keep the main object (eg. FReportingGenerator) alive by registering it
- Table Maintance: use UIConnector