免费咨询

  • 售前咨询: QQ
  • 售后服务: QQ
毕业设计(论文)团购更优惠,折扣多多
本站所有出售的 资料均严格保密无重复,出售过后会做详细的记录避免重复
QQ临时会话 可能会导致消息无法正常接收,咨询前请务必先加客服为好友
本站提供的资料 都是已经做好的,现成的作品都是审核过的,保证质量和规范

文献翻译--动态IT培训网站的设计与实现

编辑:admin  来源:未知  时间: 2018-08-14  浏览数:
动态IT培训网站的设计与实现
1 ASP.NET 概述
ASP.NET 是一个统一的 Web 开发模型,它包括您使用尽可能少的代码生成企业级 Web 应用程序所必需的各种服务。ASP.NET 作为 .NET Framework 的一部分提供。当您编写 ASP.NET 应用程序的代码时,可以访问 .NET Framework 中的类。您可以使用与公共语言运行库 (CLR) 兼容的任何语言来编写应用程序的代码,这些语言包括 Microsoft Visual Basic、C#、JScript .NET 和 J#。使用这些语言,可以开发利用公共语言运行库、类型安全、继承等方面的优点的 ASP.NET 应用程序。

1.1 ASP.NET系统的基本组成

  ASP.NET 包括:
·          页和控件框架
·          ASP.NET 编译器
·          安全基础结构
·          状态管理功能
·          应用程序配置
·          运行状况监视和性能功能
·          调试支持
·          XML Web services 框架
·          可扩展的宿主环境和应用程序生命周期管理
·          可扩展的设计器环境

1.2 ASP.NET的页和控件框架

ASP.NET 页和控件框架是一种编程框架,它在 Web 服务器上运行,可以动态地生成和呈现 ASP.NET 网页。可以从任何浏览器或客户端设备请ASP.NET 网页,ASP.NET 会向请求浏览器呈现标记(例如 HTML)。通常,您可以对多个浏览器使用相同的页,因为 ASP.NET 会为发出请求的浏览器呈现适当的标记。但是,您可以针对诸如 Microsoft Internet Explorer 6 的特定浏览器设计ASP.NET网页,并利用该浏览器的功能。ASP.NET 支持基于 Web 的设备(如移动电话、手持型计算机和个人数字助理 (PDA))的移动控件。
ASP.NET 网页是完全面向对象的。在 ASP.NET 网页中,可以使用属性、方法和事件来处理 HTML 元素。ASP.NET 页框架为响应在服务器上运行的代码中的客户端事件提供统一的模型,从而使您不必考虑基于 Web 的应用程序中固有的客户端和服务器隔离的实现细节。该框架还会在页处理生命周期中自动维护页及该页上控件的状态。
使用 ASP.NET 页和控件框架还可以将常用的 UI 功能封装成易于使用且可重用的控件。控件只需编写一次,即可用于许多页并集成到 ASP.NET 网页中。这些控件在呈现期间放入 ASP.NET 网页中。
ASP.NET 页和控件框架还提供各种功能,以便可以通过主题和外观来控制网站的整体外观和感觉。可以先定义主题和外观,然后在页面级或控件级应用这些主题和外观。
除了主题外,还可以定义母版页,以使应用程序中的页具有一致的布局。一个母版页可以定义您希望应用程序中的所有页(或一组页)所具有的布局和标准行为。然后可以创建包含要显示的页特定内容的各个内容页。当用户请求内容页时,这些内容页与母版页合并,产生将母版页的布局与内容页中的内容组合在一起的输出。

1.3 ASP.NET编译器

所有 ASP.NET 代码都经过了编译,可提供强类型、性能优化和早期绑定以及其他优点。代码一经编译,公共语言运行库会进一步将 ASP.NET 编译为本机代码,从而提供增强的性能。
ASP.NET 包括一个编译器,该编译器将包括页和控件在内的所有应用程序组件编译成一个程序集,之后 ASP.NET 宿主环境可以使用该程序集来处理用户请求。

1.4 ASP.NET的安全基础结构

除了 .NET 的安全功能外,ASP.NET 还提供了高级的安全基础结构,以便对用户进行身份验证和授权,并执行其他与安全相关的功能。您可以使用由 IIS 提供的 Windows 身份验证对用户进行身份验证,也可以通过您自己的用户数据库使用 ASP.NET Forms 身份验证和 ASP.NET 成员资格来管理身份验证。此外,可以使用 Windows 组或您自己的自定义角色数据库(使用 ASP.NET 角色)来管理 Web 应用程序的功能和信息方面的授权。您可以根据应用程序的需要方便地移除、添加或替换这些方案。
ASP.NET 始终使用特定的 Windows 标识运行,因此,您可以通过使用 Windows 功能(例如 NTFS 访问控制列表 (ACL)、数据库权限等等)来保护应用程序的安全。

1.5 ASP.NET的状态管理功能

ASP.NET 提供了内部状态管理功能,它使您能够存储页请求期间的信息,例如客户信息或购物车的内容。您可以保存和管理应用程序特定、会话特定、页特定、用户特定和开发人员定义的信息。此信息可以独立于页上的任何控件。
ASP.NET 提供了分布式状态功能,使您能够管理一台计算机或数台计算机上同一应用程序的多个实例的状态信息。

1.6 ASP.NET的应用程序配置

通过 ASP.NET 应用程序使用的配置系统,可以定义 Web 服务器、网站或单个应用程序的配置设置。您可以在部署 ASP.NET 应用程序时定义配置设置,并且可以随时添加或修订配置设置,且对运行的 Web 应用程序和服务器具有最小的影响。ASP.NET 配置设置存储在基于 XML 的文件中。由于这些 XML 文件是 ASCII 文本文件,因此对 Web 应用程序进行配置更改比较简单。您可以扩展配置方案,使其符合自己的要求。

1.7 ASP.NET的运行状况监视和性能功能

ASP.NET 包括可监视 ASP.NET 应用程序的运行状况和性能的功能。使用 ASP.NET 运行状况监视可以报告关键事件,这些关键事件提供有关应用程序的运行状况和错误情况的信息。这些事件显示诊断和监视特征的组合,并在记录哪些事件以及如何记录事件等方面提供了高度的灵活性。
ASP.NET 支持两组可供应用程序访问的性能计数器:
·          ASP.NET 系统性能计数器组
·          ASP.NET 应用程序性能计数器组

1.8 ASP.NET的调试支持

ASP.NET 利用运行库调试基础结构来提供跨语言和跨计算机调试支持。可以调试托管和非托管对象,以及公共语言运行库和脚本语言支持的所有语言。
此外,ASP.NET 页框架提供使您可以将检测消息插入 ASP.NET 网页的跟踪模式。

1.9 ASP.NET的XML Web services框架

ASP.NET 支持 XML Web services。XML Web services 是包含业务功能的组件,利用该业务功能,应用程序可以使用 HTTP 和 XML 消息等标准跨越防火墙交换信息。XML Web services 不用依靠特定的组件技术或对象调用约定。因此,用任何语言编写、使用任何组件模型并在任何操作系统上运行的程序,都可以访问 XML Web services。

1.10可扩展的宿主环境和应用程序生命周期管理

ASP.NET 包括一个可扩展的宿主环境,该环境控制应用程序的生命周期,即从用户首次访问此应用程序中的资源(例如页)到应用程序关闭这一期间。虽然 ASP.NET 依赖作为应用程序宿主的 Web 服务器 (IIS),但 ASP.NET 自身也提供了许多宿主功能。通过 ASP.NET 的基础结构,您可以响应应用程序事件并创建自定义 HTTP 处理程序和 HTTP 模块。

1.11可扩展的设计器环境

ASP.NET 中提供了对创建 Web 服务器控件设计器(用于可视化设计工具,例如 Visual Studio)的增强支持。使用设计器可以为控件生成设计时用户界面,这样开发人员可以在可视化设计工具中配置控件的属性和内容。
 
 
 
 
 
2 ASP.NET程序的执行

2.1 ASP.NET程序的执行过程

执行 ASP.NET 程序时,程序集将加载到 CLR 中,这可能会根据清单中的信息执行不同的操作。然后,如果符合安全要求,CLR 执行实时 (JIT) 编译以将 IL 代码转换为本机机器指令。CLR 还提供与自动垃圾回收、异常处理和资源管理有关的其他服务。由 CLR 执行的代码有时称为“托管代码”,它与编译为面向特定系统的本机机器语言的“非托管代码”相对应。下图演示了 ASP.NET 源代码文件、基类库、程序集和 CLR 的编译时与运行时的关系。

2.2 .NET Framework的功能

语言互操作性是 .NET Framework 的一个关键功能。因为由 C# 编译器生成的 IL 代码符合公共类型规范 (CTS),因此从 C# 生成的 IL 代码可以与从 Visual Basic、Visual C++、Visual J# 的 .NET 版本或者其他 20 多种符合 CTS 的语言中的任何一种生成的代码进行交互。单一程序集可能包含用不同 .NET 语言编写的多个模块,并且类型可以相互引用,就像它们是用同一种语言编写的。
除了运行时服务,.NET Framework 还包含一个由 4000 多个类组成的内容详尽的库,这些类被组织为命名空间,为从文件输入和输出到字符串操作、到 XML 分析、到 Windows 窗体控件的所有内容提供多种有用的功能。典型的 C# 应用程序使用 .NET Framework 类库广泛地处理常见的“日常”任务。
1 ASP.NET Overview
ASP.NET is a unified Web development model that includes the services necessary for you to build enterprise-class Web applications with a minimum of coding. ASP.NET is part of the .NET Framework, and when coding ASP.NET applications you have access to classes in the .NET Framework. You can code your applications in any language compatible with the common language runtime (CLR), including Microsoft Visual Basic, C#, JScript .NET, and J#. These languages enable you to develop ASP.NET applications that benefit from the common language runtime, type safety, inheritance, and so on.
1.1 ASP.NET system’s  basic composition
ASP.NET includes:
·          A page and controls framework
·          The ASP.NET compiler
·          Security infrastructure
·          State-management facilities
·          Application configuration
·          Health monitoring and performance features
·          Debugging support
·          An XML Web services framework
·          Extensible hosting environment and application life cycle management
·          An extensible designer environment
1.2 A page and controls framework
    The ASP.NET page and controls framework is a programming framework that runs on a Web server to dynamically produce and render ASP.NET Web pages. ASP.NET Web pages can be requested from any browser or client device, and ASP.NET renders markup (such as HTML) to the requesting browser. As a rule, you can use the same page for multiple browsers, because ASP.NET renders the appropriate markup for the browser making the request. However, you can design your ASP.NET Web page to target a specific browser, such as Microsoft Internet Explorer 6, and take advantage of the features of that browser. ASP.NET supports mobile controls for Web-enabled devices such as cellular phones, handheld computers, and personal digital assistants (PDAs).
ASP.NET Web pages are completely object-oriented. Within ASP.NET Web pages you can work with HTML elements using properties, methods, and events. The ASP.NET page framework removes the implementation details of the separation of client and server inherent in Web-based applications by presenting a unified model for responding to client events in code that runs at the server. The framework also automatically maintains the state of a page and the controls on that page during the page processing life cycle.
The ASP.NET page and controls framework also enables you to encapsulate common UI functionality in easy-to-use, reusable controls. Controls are written once, can be used in many pages, and are integrated into the ASP.NET Web page that they are placed in during rendering.
The ASP.NET page and controls framework also provides features to control the overall look and feel of your Web site via themes and skins. You can define themes and skins and then apply them at a page level or at a control level.
In addition to themes, you can define master pages that you use to create a consistent layout for the pages in your application. A single master page defines the layout and standard behavior that you want for all the pages (or a group of pages) in your application. You can then create individual content pages that contain the page-specific content you want to display. When users request the content pages, they merge with the master page to produce output that combines the layout of the master page with the content from the content page.
1.3 The ASP.NET compiler
All ASP.NET code is compiled, which enables strong typing, performance optimizations, and early binding, among other benefits. Once the code has been compiled, the common language runtime further compiles ASP.NET code to native code, providing improved performance.
ASP.NET includes a compiler that will compile all your application components including pages and controls into an assembly that the ASP.NET hosting environment can then use to service user requests.
1.4 Security infrastructure
In addition to the security features of .NET, ASP.NET provides an advanced security infrastructure for authenticating and authorizing user access as well as performing other security-related tasks. You can authenticate users using Windows authentication supplied by IIS, or you can manage authentication using your own user database using ASP.NET forms authentication and ASP.NET membership. Additionally, you can manage the authorization to the capabilities and information of your Web application using Windows groups or your own custom role database using ASP.NET roles. You can easily remove, add to, or replace these schemes depending upon the needs of your application.
ASP.NET always runs with a particular Windows identity so you can secure your application using Windows capabilities such as NTFS Access Control Lists (ACLs), database permissions, and so on. For more information on the identity of ASP.NET,
1.5 State-management facilities
ASP.NET provides intrinsic state management functionality that enables you to store information between page requests, such as customer information or the contents of a shopping cart. You can save and manage application-specific, session-specific, page-specific, user-specific, and developer-defined information. This information can be independent of any controls on the page.
ASP.NET offers distributed state facilities, which enable you to manage state information across multiple instances of the same application on one computer or on several computers.
1.6 Application configuration
ASP.NET applications use a configuration system that enables you to define configuration settings for your Web server, for a Web site, or for individual applications. You can make configuration settings at the time your ASP.NET applications are deployed and can add or revise configuration settings at any time with minimal impact on operational Web applications and servers. ASP.NET configuration settings are stored in XML-based files. Because these XML files are ASCII text files, it is simple to make configuration changes to your Web applications. You can extend the configuration scheme to suit your requirements.
1.7 Health monitoring and performance features
ASP.NET includes features that enable you to monitor health and performance of your ASP.NET application. ASP.NET health monitoring enables reporting of key events that provide information about the health of an application and about error conditions. These events show a combination of diagnostics and monitoring characteristics and offer a high degree of flexibility in terms of what is logged and how it is logged.
ASP.NET supports two groups of performance counters accessible to your applications:
·          The ASP.NET system performance counter group
·          The ASP.NET application performance counter group
1.8 Debugging support
ASP.NET takes advantage of the run-time debugging infrastructure to provide cross-language and cross-computer debugging support. You can debug both managed and unmanaged objects, as well as all languages supported by the common language runtime and script languages.
In addition, the ASP.NET page framework provides a trace mode that enables you to insert instrumentation messages into your ASP.NET Web pages.
1.9 An XML Web services framework
ASP.NET supports XML Web services. An XML Web service is a component containing business functionality that enables applications to exchange information across firewalls using standards like HTTP and XML messaging. XML Web services are not tied to a particular component technology or object-calling convention. As a result, programs written in any language, using any component model, and running on any operating system can access XML Web services.
1.10 Extensible hosting environment and application life cycle management
ASP.NET includes an extensible hosting environment that controls the life cycle of an application from when a user first accesses a resource (such as a page) in the application to the point at which the application is shut down. While ASP.NET relies on a Web server (IIS) as an application host, ASP.NET provides much of the hosting functionality itself. The architecture of ASP.NET enables you to respond to application events and create custom HTTP handlers and HTTP modules.
1.11 An extensible designer environment
ASP.NET includes enhanced support for creating designers for Web server controls for use with a visual design tool such as Visual Studio. Designers enable you to build a design-time user interface for a control, so that developers can configure your control's properties and content in the visual design tool.
2 The execution of the ASP.NET programe
2.1 The execution process of the ASP.NET programe 
When the ASP.NET program is executed, the assembly is loaded into the CLR, which might take various actions based on the information in the manifest. Then, if the security requirements are met, the CLR performs just in time (JIT) compilation to convert the IL code into native machine instructions. The CLR also provides other services related to automatic garbage collection, exception handling, and resource management. Code that is executed by the CLR is sometimes referred to as "managed code," in contrast to "unmanaged code" which is compiled into native machine language that targets a specific system. The following diagram illustrates the compile-time and run time relationships of ASP.NET source code files, the base class libraries, assemblies, and the CLR.

2.2 The function of  .NET Framework
Language interoperability is a key feature of the .NET Framework. Because the IL code produced by the C# compiler conforms to the Common Type Specification (CTS), IL code generated from C# can interact with code that was generated from the .NET versions of Visual Basic, Visual C++, Visual J#, or any of more than 20 other CTS-compliant languages. A single assembly may contain multiple modules written in different .NET languages, and the types can reference each other just as if they were written in the same language.
In addition to the run time services, the .NET Framework also includes an extensive library of over 4000 classes organized into namespaces that provide a wide variety of useful functionality for everything from file input and output to string manipulation to XML parsing, to Windows Forms controls. The typical C# application uses the .NET Framework class library extensively to handle common "plumbing" chores.
 

  • 关于资料
    本站提供的资料属原创,内容严格把关,均审核通过的,保证质量和规范.
  • 关于发货
    提供下载链接或发送至您的邮箱,资料可重复发送,确保您收到为止.
  • 疑难解答
    收到资料后若有任何疑难问题,均可通过本站客服提供帮助解决.
  • 售后服务
    我们确保发送的资料完整无损,如核实为不合格资料,可以申请退换.