TAILIEUCHUNG - Professional ASP.NET 3.5 in C# and Visual Basic Part 115

Professional in C# and Visual Basic Part 115. Building on the revolutionary release, adds several key new developer features including AJAX, LINQ, and a new CSS designer in Visual Web Developer 2008. The dramatic reduction in code that developers realized from the more than 50 new server controls in now allows developers the time to make their applications more interactive with AJAX, to work with data in their preferred language with LINQ, and to build visually attractive and consistent standards-based sites with CSS. . | Chapter 23 Caching SqlConnection AppConnectionString1 .ConnectionString SqlDataAdapter da new SqlDataAdapter Select from Customers conn myCustomers new DataSet myCustomers SqlCacheDependency myDependency new SqlCacheDependency Northwind Customers firmCustomers myCustomers myDependency Produced from database. else Produced from Cache object. myCustomers script In this example the SqlCacheDependency class associated itself to the Customers table in the Northwind database as before. This time however you use the Cache object to insert the retrieved dataset along with a reference to the SqlCacheDependency object. The Insert method of the Cache class is constructed as follows key As String value As Object dependencies As You can also insert more information about the dependency using the following construct key As String value As Object dependencies As absoluteExpiration As Date slidingExpiration As And finally key As String value As Object dependencies As absoluteExpiration As Date slidingExpiration As priority As onRemoveCallback As The SQL Server cache dependency created comes into action and does the same polling as it would have done otherwise. If any of the data in the Customers table has changed the SqlCacheDependency class invalidates what is stored in the cache. When the next request is made the Cache firmCustomers is found to be empty and a new request is made to SQL Server. The Cache object again repopulates the cache with the new results generated. When the page from Listing 23-8 is called for the first time the results generated are shown in Figure 23-8. 1099 Chapter 23 .

TỪ KHÓA LIÊN QUAN
TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.