Case history: ASP.NET
This case history describes a simple use case for Sar-K. The purpose of the application was the development of a company intranet, based on SQL Server database and VB.NET code.
In this use case, there were a lot of pre-existent tables in the database, with many historic data.
A Sar-K template was generated in order to wrap just the database access layer. The template was kept as simple as possible, in order to concentrate the development effort in upper layers.
The result was a customized template which allows to easily manage all database-related code.
As an example, we show here some lines of code where load and store function are called.
Dim user as User user = User.LoadById(1) user.Username = "bob" user.LastAccess = DateTime.Now user.Save()
Create a new user and save it:
Dim user as New User user.Username = "mary" user.LastAccess = DateTime.Now user.Save()
