
Distributed Data Applications with ASP.NET, Second Edition ALEX HOMER AND DAVID SUSSMAN APress Media, LLC Distributed Data Applications with ASP.NET, Second Edition Copyright © 2004 by Alex Homer and David Sussman Originally published by Apress in 2004 AlI rights reserved. No part of this work may be reproduced or transmitted in any form or by any means, electronic or mechanical, including photocopying, recording, or by any information storage or retrieval system, without the prior written permission of the copyright owner and the publisher. ISBN 978-1-59059-318-9 ISBN 978-1-4302-0661-3 (eBook) DOI 10.1007/978-1-4302-0661-3 Trademarked names may appear in this book. Rather than use a trademark symbol with every occurrence of a trademarked name, we use the names only in an editorial fashion and to the benefit of the trademark owner, with no intention of infringement of the trademark. Technical Reviewers: Dan Green, John Godfrey, Maxime Bombardier, Christian Holm, Jeffrey Hasan, Paul Churchill, Phil Powers-De George, Fredrik Normen, Christophe Nasarre, Andrew Stopford, Larry Schoeneman, Sophie McQueen, David Schultz, Johan Normen Editorial Board: Steve Anglin, Dan Appleman, Gary Cornell, James Cox, Tony Davis, John Franklin, Chris Mills, Steven Rycroft, Dominic Shakeshaft, Julian Skinner, Martin Streicher, Iim Sumser, Karen Watterson, Gavin Wray, John Zukowski Assistant Publisher: Grace Wong Project Manager: Beth Christmas Copy Editor: Kim Wimpsett Production Manager: Kari Brooks Production Editor: JanetVail Proofreader: Linda Seifert Compositor: Diana Van Winkle, Van Winkle Design Indexer: Valerie Robbins Cover Designer: Kurt Krames Manufacturing Manager: Tom Debo1ski In the United States: phone 1-800-SPRINGER, email [email protected]. or visit http://www.springer-ny . corn. Outside the United States: fax +49 6221 345229, email [email protected], or visit http://www.springer.de. For information on translations, please contact Apress directly at 2560 Ninth Street, Suite 219, Berkeley, CA 94710. Phone 510-549-5930, fax 510-549-5939, email [email protected], or visit http://www.apress.com. The information in this book is distributed on an "as is" basis, without warranty. Although every precaution has been taken in the preparation of this work, neither the author(s) nor Apress shall have any liability to any person or entity with respect to any 10ss or damage caused or alleged to be caused directly or indirectly by the information contained in this work. The source code for this book is avai1able to readers at http://www.apress.comin the Downloads section. Contents at a Glance About the Authors ............................................................................................ xiii Introduction ........................................................................................................ xv Chapter 1 The Distributed Application .............................................. 1 Chapter 2 Components and Data Access .............................................. 53 Chapter 3 Accessing XML Documents ................................................... 109 Chapter 4 The Application Plumbing ................................................ 143 Chapter 5 Working with Down-Level Clients ................................. 199 Chapter 6 Working with Rich Clients .............................................. 261 Chapter 7 Remoting to .NET Clients ................................................ 347 Chapter 8 Updating Data in Down-Level Clients ........................ 391 Chapter 9 Updating Remote Cached Data ........................................ .475 Chapter 10 Components for Updating Data ........................................ 527 Chapter 11 Rich Client Update Applications ................................. 583 Chapter 12 Reconciling Update Errors .............................................. 647 Chapter 13 Updating Data from Remote .NET Applications ....... 715 Index ...................................................................................................................... 765 iii Contents About the Authors ............................................................................................ xiii Introduction ........................................................................................................ xv Chapter 1 The Distributed Application ................................... 1 What Are Distributed Data Applications? ............................................... 2 Our Definition .................................................................................................... 2 Why Do You Need to Distribute? ....................................................................... 3 How Can You Do ((Distributed}) on the Internet? .................................. 5 Internet Protocols ............................................................................................... 5 Internet Clients ................................................................................................... 6 The Elements of a Distributed Application ........................................... 8 Client Devices and Client Applications ........................................................ .. 10 Server-Side Data Stores .................................................................................... 12 Processing and Presenting Information ......................................................... 14 Data Access Techniques Overview .............................................................. .20 About "Relational" Data Access ....................................................................... 21 The ADO. NET Data Access Classes ................................................................. 22 Understanding System.Xml .............................................................................. 32 Representing Data and Information ............................................................... 33 The System.XrnI Classes ................................................................................... 37 Data Access and the n- Tier Model ............................................................ .41 What Is the Data Being Used For? ................................................................... 41 Some n -Tier Data Access Scenarios ............................................................... .44 Summary ................................................................................................................... 51 Chapter 2 Components and Data Access .................................... 53 Different Types of ((Component}) ................................................................. 54 .NET Components ............................................................................................ 54 COM and COM+ Components ........................................................................ 58 User Controls .................................................................................................... 59 Include Files ...................................................................................................... 63 Server Controls ................................................................................................. 64 Accessing and Exposing Data ........................................................................ 64 Delivering Data to Rich Clients ....................................................................... 64 Managing Data for Down-Level Clients ......................................................... 65 Displaying XML Data ....................................................................................... 65 v Contents Working with the DataSet Object ............................................................... 66 The Structure of the DataSet Object ............................................................... 66 When Should You Use a DataSet? .................................................................... 69 Relational Data Access Component Examples ........................................ 70 Setting Up the Examples .................................................................................. 70 Accessing and Returning Relational Data ...................................................... 72 Summary .............................................................................................................. .. 107 Chapter 3 Accessing XML Documents .......................................... 109 Introducing the XML Data Access Component Examples .................. 109 Accessing and Returning Relational Data .......................................... 110 Using the SupplierListXml Data Access Component .................................. 111 Returning an XmITextReader Reference ....................................................... 112 Returning an XmlValidatingReader Reference ............................................ 11 8 Returning a DataSet Object ........................................................................... 123 Returning a Custom Array Reference ........................................................... 126 Returning an ArrayList Reference ................................................................. 130 Returning an XML String ............................................................................... 133 Returning an XmIDocument Object ............................................................. 135 Returning anXPathDocument Object .......................................................... 137 Summary ...............................................................................................................
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages18 Page
-
File Size-