学生成绩管理系统英文翻译_第1页
学生成绩管理系统英文翻译_第2页
学生成绩管理系统英文翻译_第3页
学生成绩管理系统英文翻译_第4页
学生成绩管理系统英文翻译_第5页
已阅读5页,还剩2页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

1、文献翻译 题 目学生成绩管理系统地设计与实现 学生姓名 专业班级 院V系)软件学院 指导教师(职称 完成时间 文献翻译 书名:C#设计模式 作者姓名:V美)麦斯科vMetsker,S.J)著 出处:/ 2006-7-1 /中国电力出版社 主要内容: 针对日常地软件开发问题,设计模式提供了一种优雅地、通用地可重用解决 方案.程序员可以通过设计模式组织程序中地对象,使其更易于编写和修改本书 正是一本设计模式地实用指南,帮助你采用最常见地模式来编写 C#程序.C#设 计模式(附光盘由JamesW.Coope编著,首先简明扼要地介绍了 C#面向对 象编程、继承和UML图,然后分章描述了 23种设计模式

2、及各自地使用场合,并阐 明了模式在大型设计中地作用每种模式地用法都配有相应地示例程序演示,这 些程序收录在随书配套光盘中,可以直接运行、测试、编辑和使用.b5E2RGbCAP 简介C# C#编程语言是为开发微软公司地.NET框架上地程序而设计地.本章将简要 介绍.NET从何而来,以及它地基本架构.这只是为了确保你从正确地一步开始, 让我借此机会提醒你一件可能显面易见地事情:C #地发音为see sharp 1.1.120世纪90年代后期地 Windows编程 在20世纪90年代后期,使用微软平台地 Windows编程分化成许多分支.大 多数程序员在使用 Visual BasicvVB)、C或C

3、+ + .些C和C+程序员在使 用纯 Win32 APl,但大多数人在使用 MFCvMicrosoft Found撕on Classes微软基 础类库).其他人已经转向了 COMvComponent ObjectMdodel,组件对象模型). 所有这些技术都有自己地问题纯Win32 API不是面向对象地,而且使用它 地工作量比使用VIFC地更大.MFC是面向对象地,但是它却不一致,并逐渐变得 陈旧.COM虽然概念上简单,但它地实际代码复杂,并且需要很多丑陋地、不雅地 底层基础代码. 所有这些编程技术地另外一个缺点是它们主要针对桌面程序而不是In teme t地开发.那时,Web编程还是以后地事

4、情,而且看起来和桌面编程非常不同.plEan qFDPw .NET(C# 把attribute翻译成特性,用来标识类,把property翻译为属性,性质,用于存取类 地字段,把markup翻译成标记,tag还是翻译成标签比较好DXDiTa9E3d .NET(C#.NET Framework称为公共语言运行库CLR)或.NET运行库.它地核 心是其运行库地执行环境.通常将在CLR地控制下运行地代码称为托管代码 在CLR执行开发地源代码之前,需要编译它们为中间语言 ASP页面有时显示比较慢,因为服务器端代码是解释性地不是编译地. 由于ASP代码不是结构化地所以难于维护,加上ASP不支持错误处理和语

5、法检 查.而ASP.NET页面是结构化地.每个页面都是一个继承了 .NET类 System.Web.UI.Page地 类. 另外ASP.NET地后台编码功能允许进一步采用结构化地方式. 页面请求是和WEB服务器在编译后高速缓存ASP.NET页面.jLBHrnAILg .NET(C# 覆盖 voverride)和重载 voverload): 覆盖是指子类重新定义父类地虚函数地做法. 重载,是指允许存在多个同名函数,而这些函数地参数表不同 或许参数个数不同, 或许参数类型不同,或许两者都不同). 其实,重载地概念并不属于面向对象编程” 重载地实现是:编译器根据函数不同地参数表,对同名函数地名称做修

6、饰 然后这些同名函数就成了不同地函数 :i nteger。和 function func(p:string:integer。. 那么编译器做过修饰后地函数名称可能是这样地:int_func、str_func. 对于这两个函数地调用,在编译器间就已经确定了,是静态地 记住:是静态). 也就是说,它们地地址在编译期就绑定了 早绑定), 因此,重载和多态无关!真正和多态相关地是 覆盖”. 当子类重新定义了父类地虚函数后,父类指针根据赋给它地不同地子类指针,动态 记住:是动态!)地调用属于子类地该函数, 这样地函数调用在编译期间是无法确定地调用地子类地虚函数地地址无法给 出). 因此,这样地函数地址是

7、在运行期绑定地 晚邦定). 结论就是:重载只是一种语言特性,与多态无关,与面向对象也无关!XHAQX74J0X .NET(C# C#中ref和out地区别: 方法参数上地out方法参数关键字使方法引用传递到方法地同一个变量 当控制传递回调用方法时,在方法中对参数所做地任何更改都将反映在该变量中. 当希望方法返回多个值时,声明out方法非常有用. 使用out参数地方法仍然可以返回一个值.一个方法可以有一个以上地 out参数. 若要使用out参数,必须将参数作为out参数显式传递到方法.out参数地值不会传 递到out参数. 不必初始化作为out参数传递地变量.然而,必须在方法返回之前为out参数

8、赋值. 属性不是变量,不能作为out参数传递.LDAYtRyKfE 方法参数上地ref方法参数关键字使方法引用传递到方法地同一个变量 当控制传递回调用方法时,在方法中对参数所做地任何更改都将反映在该变量中. 若要使用ref参数,必须将参数作为ref参数显式传递到方法. ref参数地值被传递到ref参数.传递到ref参数地参数必须最先初始化. 将此方法与out参数相比,后者地参数在传递到out参数之前不必显式初始化. 属性不是变量,不能作为ref参数传递.Zzz6ZB2Ltk 两者都是按地址传递地,使用后都将改变原来地数值. ref可以把参数地数值传递进函数,但是out是要把参数清空 就是说你无

9、法把一个数值从out传递进去地,out进去后,参数地数值为空,所以你 必须初始化一次.dvzfvkwMI1 Design and implementation of student achievement management system qyn14ZNXI Document translation Aiming at the problem of daily software development, design pattern provides an elega nt, gen eric and reusable soluti ons. Programmers can through

10、the object desig n pattern organization program, making it easier to write and modify. This book is a practical guide to the desig n patter ns, to help you with the most com mon pattern to write C# program. The C# desig n pattern (with CD-ROM by JamesW.Cooper, first of all be con cise and to the poi

11、nt in troduces C#, object-orie nted program ming, in herita nee and UML graph, and the n describes 23 kinds of desig n patter ns and applicati on occasi ons of each chapter, and expo unds the patter ns in large desig n fun cti on. Each kind of model usage are equipped with corresp onding example dem

12、 on strati on program, the program in cluded in the CD-ROM with book matchi ng, can be directly run, test, edit and usemxvxotoco In troducti on to c# C# program ming Ian guage is the.NET framework for the developme nt of the Microsoft Corp on the program design. This chapter will briefly introduce t

13、he.NET come from, and its basic architecture. Just to make sure you start from a step in the right direct ion, let me take this opport un ity to rem ind you of a possible sig nifica nt surface easy to see thi ngs: C, pronoun ced see sharp.2yxpq5 Win dows program ming in the late 90 cen tury 1.1.120

14、In the late nineteen ninties, using Microsoft platform Windows programming differentiation into many branches. Most programmers use Visual Basic (VB, C or C + +. Some of the C and C + + programmers in the use of pure Win32 to APl, but most people in the use of MFC (Microsoft Found on Classes tear, M

15、icrosoft Foundation Class Library. Other people have turned to the COM (Compo nent, ObjectMdodel, comp onent object model6ewMyirQFL All of these tech no logies have their own problems. Win32 APl is not a pure object orie nted, and use its workload is bigger tha n the use of VIFC. MFC is object orie

16、nted, but it is not consistent, and gradually become obsolete. Although COM is simple in con cept, but the actual code its complex, low-level code and n eed a lot of ugly, in dece nt.kavu42vRus Ano ther disadva ntage of all these program ming tech niq ues are mai nly for the desktop applicati on and

17、 developme nt is not In temet. Then, Web program ming or after thi ngs, and looks very differe nt from cod ing for the desktopy6v3ALoS89 .NET (C# Tran slate attribute into characteristic, used to ide ntify the class, methO2ub6vSTnP The property tran slated into property, property, used for field acc

18、ess classjjCfmUCw Tran slat ing markup tag, tag label or tran slated into bettUts8ZQVRd .NET (C# The core of.NET Framework is its run time executi on en viro nmen tsQsAEJkW5T Known as the com mon Ian guage run time (CLR or the.NET run timeGMsiasNXkA Usually will run un der the con trol of the CLR co

19、de known as man aged code (man aged codeTIrRGchYzg Before the CLR impleme ntati on of the developme nt of the source code, to compile them into in termediate Ian guage (IL, CLR and IL compiled into a platform specific Code7EqZcWLZNX The assembly (assembly is compiled, logic unit for the.NET Framewor

20、k Code.lzq7IGfO2E The executable code and database code using the same assembly strucZvnqJ1hk An importa nt characteristic of the assemblys metadata they contain describes the type and method defi niti ons corresp onding code.rpojac3v1 .NET (C# ASP pages are sometimes slower, because the server-side

21、 code is in terpreted not compiled.1nowfTG4KI Because the ASP code is not structured so difficult to maintain, and ASP does not support error han dli ng and grammar checknFLDa5Zo While the ASP.NET page is structured. Each page is a successor to the.NET System.Web.UI.Page clas.nNhnE6e5 In additi on t

22、o backgro und cod ing fun cti on ASP.NET to allow further using a structured wayHbmVN777sL The page request is compiled and WEB server in the ASP.NET cache pagejRBSHs .NET (C# Cover (overrideand heavy (overload: Coverage means that subclasses redefi ne the virtual fun ctio n of the pare nt class met

23、h0d.83lcPA59W9 Overload in g, refers to allow multiple fun cti ons with the same n ame, and the parameters of these fun cti ons are differe nt (perhaps the nu mber of parameters are differe nt, perhaps differe nt parameter types, maybe both are differe ntZkklkzaaP In fact, the con cept of heavy load

24、 does not bel ong to the object orie nted programmi ng,AVktR43bpw Heavy load: the compiler implementation is according to the parameter table function differe nt, the n ame of the functions with the same n ame as modificatioRjBnOwcEd Then these fun cti ons with the same n ame as the differe nt fun c

25、ti on (at least for the Compiler.2MiJTy0dTT For example, there are two fun cti ons with the same n ame: fun cti on func (p:i nteger: integer。and function func (p:string: integer。.gIiSpiue7A Then the compiler had modified the function n ame may be this: int_func, str_f un C.uEhU1Yfmh For the two func

26、tion calls, the compiler have been identified, is static (remember: StatiCAg9qLsgBX That is to say, their address is bound at compile time (early bindin gWwghWvvhPE Therefore, overload ing and polymorphism! The real and polymorphism is related to the cover.asfpsfpi4k When the class to defi ne virtual fun cti ons the pare nt class, the pare nt class poin ter according to assign it to the different sub class pointer, dynamic (remember: dyn a

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

最新文档

评论

0/150

提交评论