You are here: Web Apps with Visual LANSA > 1. An Introduction to Developing Web Applications using Visual LANSA > 1.4 Visual LANSA's Web Architecture

1.4 Visual LANSA's Web Architecture

The Component Pieces

A Web Page provides the starting point for the application and may also be the source of some of the User Interface functionality. For fairly simple requirements, a Web Page may be all that's required. However, applications are far easier to create and maintain if modular coding techniques are employed.

Modern applications often provide complex interfaces and functionality that changes as different items are selected. Trying to code such behaviors in a single source object, while possible, is not recommended. A better technique is to think of the screen as a patchwork of independently created pieces that work together to produce a coherent result.

Reusable Parts are used to build the many components of an application. Each part can contain its own processing and user interface, and can expose methods, events and properties to allow other parts of the application to interact with it. This modular approach allows complex screen interaction to be dissected and turned into modular pieces that greatly simplify both application development and maintenance.

The Mechanics

The compiled Web Page, Reusable Parts and LANSA runtime all execute within the browser, with the runtime providing the necessary features to communicate with the Web Server. The Web Page and Reusable Parts can independently make calls to the Application Server. This interprets the requests and executes SrvRoutines that typically interact with the database to serve up data and images.

The output from the SrvRoutine is stored in a single JSON document that is returned to the browser. On arrival, it is converted into fields and working lists, as defined for the routine, making for very straightforward processing.