为了正常的体验网站,请在浏览器设置里面开启Javascript功能!
首页 > 基于VB和XML的个人资料编辑器的实现—毕业设计论文

基于VB和XML的个人资料编辑器的实现—毕业设计论文

2017-10-25 50页 doc 212KB 3阅读

用户头像

is_447713

暂无简介

举报
基于VB和XML的个人资料编辑器的实现—毕业设计论文基于VB和XML的个人资料编辑器的实现—毕业设计论文 毕业设计(论文) 基于VB和XML的个人资料编辑器的实现 论文作者姓名: 申请学位专业: 申请学位类别: 指导教师姓名,职称,: 论文提交日期: 基于VB和XML的个人资料编辑器的实现 摘 要 随着计算机技术的普及应用,整个人类社会已经成为一个信息化的学习型社会。信息作为生产力中的最活跃因素,在生活中发挥着巨大的作用,几乎每天都产生大量的文档资料,而对于这些资料的分类管理和利用,将直接影响到个人学习个工作的效率,资料管理也已经成为人们普遍关注的课题。 ...
基于VB和XML的个人资料编辑器的实现—毕业设计论文
基于VB和XML的个人资料编辑器的实现—毕业论文 毕业设计(论文) 基于VB和XML的个人资料编辑器的实现 论文作者姓名: 申请学位专业: 申请学位类别: 指导教师姓名,职称,: 论文提交日期: 基于VB和XML的个人资料编辑器的实现 摘 要 随着计算机技术的普及应用,整个人类社会已经成为一个信息化的学习型社会。信息作为生产力中的最活跃因素,在生活中发挥着巨大的作用,几乎每天都产生大量的文档资料,而对于这些资料的分类管理和利用,将直接影响到个人学习个工作的效率,资料管理也已经成为人们普遍关注的课。 为了更加便于人们对于收集到的信息资料的管理利用,笔者由此设计了基于VB和XML的个人资料编辑器,以VB作为开发语言,数据使用XML格式存储,实现了类似WINDOWS资源管理器的树状目录文档管理,文档信息按自己的分类节点显示,并具有搜索和编辑功能等。文中详细阐述了系统的开发背景,研究意义,理论依据和各模块的具体实现。 关键词:VB;XML;树型结构;节点 The Implementation of a Personal Material Editor Based on VB and XML Abstract With the popularization and application of the computer technology, the whole human society has already become an informational study type society. Information is playing a great role in life as the most active factor in productivity, producing a large number of file materials every day. As for the classification of management and use of information will directly affect individuals’ efficiency of work and study, information management has become a universal concern. To make it easier for people to make use of the gathered information, the author designed the Personal Material Editor based on VB and XML. Is development takes the VB language as the script, XML as the database, realized WINDOWS explore-like user interface which manages the document with tree structure and the information was demonstrated according to its own class node, and the search and the edition function are implemented too. The article elaborated in detail the development background of the system, the research significance, the theory basis and the concrete realization of various modules. Key words:VB; XML; Tree structure; Node 目 录 论文总页数:25页 1 引言 ........................................................................ 1 1.1 课题背景 ............................................................... 1 1.2 本课题研究的意义........................................................ 1 1.3 本课题的研究方法........................................................ 1 2 相关技术 .................................................................... 1 2.1 XML语言 ................................................................ 1 2.1.1 标识语言 ........................................................... 1 2.1.2 XML ................................................................ 2 2.1.3 XML文档及其分类 .................................................... 3 2.1.4 XML文档的解析 ...................................................... 4 2.1.5 文档对象模型 ....................................................... 5 2.2 XML与数据库 ........................................................... 10 2.2.1 技术比较 .......................................................... 10 2.2.2 XML数据库的发展趋势 .............................................. 11 3 需求分析 ................................................................... 12 3.1 系统概述 .............................................................. 12 3.2 功能需求分析 .......................................................... 12 4 主要模块编码实现 ........................................................... 14 4.1 程序主窗体界面 ........................................................ 14 4.2 文档管理模块程序....................................................... 16 4.3 通讯记录模块 .......................................................... 17 4.4 收入支出记录模块程序................................................... 19 4.5 备忘录模块 ............................................................ 20 5 软件测试 ................................................................... 21 结 论 ....................................................................... 22 参考文献 ....................................................................... 23 致 谢 ....................................................................... 24 声 明 ....................................................................... 25 1 引言 1.1 课题背景 现代社会是个知识信息爆炸的社会,每个人都十分注重不断的学习和充实,以求获取更多的信息量,从而产生大量的电子文档,为了提高办事效率和准确性,开发了这款个人资料编辑器,相信对于每个爱好需要“充电”和喜好搜集资料的人,使用起来都将有一定的帮助。 1.2 本课题研究的意义 本系统着力于解决日常生活或办公中个人资料的搜集,保存和管理问题。当下是数字化时代,PC机普及到了家庭,人们生活中都离不开电脑,大量对于个人相对宝贵的资料,都习惯于保存在个人电脑中,而对于这些文档的管理都相对不太重视,查找时费时费力,基于这种需要,设计出这个个人资料编辑系统,对于个人信息的管理更加细化和系统,使身边多一个智能化的“管家”。 除去软件本身的实用价值以外,在做系统的过程中,由于是采用XML来管理数据,对XML与数据库的优缺点做了一定的比较,他们的发展前景做了些初步探索:随着XML的逐步成熟,是否有一天将用XML替代数据库呢,有了数据库技术,还需要XML吗,在文中也进行了一定的探讨。 1.3 本课题的研究方法 通过对国内外文档资料管理类似课题的比较研究,透过网络与图书馆查阅相关资料后首先做出分析报告,根据社会现阶段实际情况,然后以WINDOWS系统下VB6.0做平台,通过Visual Basic语言和XML来进行开发。在设计中以需求分析为基础,写出系统开发计划、详细设计摘要及相关问题的实现方法,然后以此为指导进行编码开发。 2 相关技术 2.1 XML语言 2.1.1 标识语言 XML(Extensible Markup Language,开扩展的标识语言)是W3C(world Wide Web Consortium)工作组制定的可扩展标识语言。这是一重通过专门格式描述文本信息特征(例如格式或者逻辑结构)的方法。通常需要标记(由“<”和“>”符扩起来)来分隔文本片段,标记的内容提供位于标记之间的文本信息。 要理解发明XML的原因,必须从另外的两种标识语言谈起。HTML(超文本标识语言,Hyper Text Markup Language)通常用来编写网页,如果需要一种功能更丰富的语言,则可以用SGML(通用标识语言,Standard Generalized Markup Language),HTML就是从这一语言派生出来的。为什么又开发新语言,原因两点:一是HTML太不灵活,二是SGML对大多数用户来说又太复杂。前者只提供了 第 1 页 共 25 页 用于修饰浏览器画面的相对较小的标识工具集,而后者则几乎提供了无穷选择,使得开发一个文档也需要经过相当艰难的学习过程。 2.1.2 XML XML(Extensible Markup Language)语言是一种结构化描述语言,包含许多SGML语言的要素,但比SGML语言简单,是SGML语言的一个简化子集。它能使SGML语言像HTML语言那样,在互联络里得到广泛应用。如果说HTML是SGML衍生的一种文件格式那么XML则是SGML的简化版,所有XML文件也是合乎规范的SGML文件。所以XML也是一种元语言,可以用来定义其它新的标记语言。1996年底,万维网协会W3C推出了XML标准。XML的制定是为了弥补HTML的不足,使得在互联网络上可以传输、处理和共享各种结构复杂的文档。在继承SGML的同时,它又去除了SGML的复杂性,让使用者可以很容易地定义和使用属于自己的文档类型。 (1)设计目标: 在XML的正式规范中阐述了如下10个XML的设计目标。 1)XML应该可以直接应用于Internet网络。 2)XML应该支持大量的各种各样的应用口。 3)XML应该与SGML兼容。 4)处理XML文档的程序应该很容易编写。 5)XML中的可选项的数目应该尽可能地少,理想情况是一个也没有。 6)XML文档应该可读性强,条理清晰。 7)XML的设计应该迅速完成。 8)XML的设计应该正规且简洁。 9)XML文档应该易于生成。 10)XML的标记必须有明确的含义,不必过于简洁精炼以防含义模糊不清。 (2)主要特点: 1)简单性。XML语言有严格的定义,其语法包含一个比较小的规则集,使开发者很容易学会并能很快开始工作,而且人和机器都能很容易地阅读。由于XML文档是建立在一个基本嵌套结构的核心集的基础之上的,当一层又一层的文档内容被增加,从而使结构变得越来越复杂时,开发者只需要为内部结构的复杂性做出非常少的工作就可以满足复杂应用的需要。这些基本嵌套结构可以很容易地描述复杂的信息集合,而不需要改变结构自身。而且XML语言为程序员和文档开发者提供了一个友好的开发环境,其语法分析器也非常容易创建。 2)可扩展性。XML语言至少在两方面是可扩展的。首先,它允许开发者使用他们自己的标签和DTD,有效地创建可被用于特定应用的专业化的标记集。其次, 第 2 页 共 25 页 许多附加的标准对XML的能力进行了扩展。这些附加标准可以向核心的功能集增加样式、链接和引用能力。而且作为一个核心标准,XML为可能产生的其它标准提供了一个坚实的基础。 3)跨平台。XML语言是独立于特定平台的,而且支持世界上所有主要语言编写的混合文本,从而可在世界上各种平台的不同计算环境中使用。 4)开放性。XML标准是完全开放的,并且可以免费获得。XML文档本身也很开放,任何人都可以对一个结构良好的XML文档进行语法分析,如果提供了文档的DTD,还可以校验这个XML文档。 (3)基本概念。 标记是通过名叫分隔符(Delimiter)的专用字符与字符数据区别开来的1) XML文本。不太严格地讲,小于号(<)与大于号(>)之间的文本,以小于号开始和大于号结束的标记叫标注(tag)。 2)元素(Element)是组成XML文档的基本单元。一个元素包含一个起始标记和一个结束标记,在两个标记之间可以有数据内容。任何一个格式良好的XML文档都包含一个或多个元素,而且仅有一个称作根元素的顶级元素。元素之间可以存在树型的嵌套包含关系。被包含的元素叫子元素,相应地,包含子元素的元素称为这个子元素的父元素。 3)属性是元素包含的附加信息,用来描述元素的特征。 4)文档类型定义。文档类型定义(DTD)用来定义XML文档的合法语法。它通过列出可以在文档中使用的元素名字、指明元素之间的组合和嵌套关系、每个元素类型的可用属性等来定义XML文档的合法语法。 5)良好构的和有效的文档。每一种语言都具有说明语言用法正确与否的规则,在XML语言中也不例外。包含可以理解的标记的文档称为良构的文档,在这类文档中可以使用除了元素和属性的定义之外几乎全部的XML项,即没有DTD。有效的文档符合关于良构的文档的所有规则,但具有一个相关的定义文档的元素和属性的DTD。 2.1.3 XML文档及其分类 用XML语言书写的文档就是XML文档,它由元素、属性、实体引用、注释、CDATA和处理指令等部分组成。一个XML文档可以选择具有一个文档类型定义(DTD),它用来定义一个XML文档的结构。XML文档具有类似HTML的基于文本的格式,是一种标准化的可以在网络上表示数据的文档。XML文档通常以一个XML声明开始,通过XML元素组织XML数据。根据XML文档的内容、结构和用途的不同,可以将它分为如下三类: 第 3 页 共 25 页 (1) 以数据为中心的文档(Data Centric Documents)是将XML用作数据的传输载体,着重于文档中的数据,而非文档格式,通常是给机器用的,方便机器进行数据处理。例如销售订单、航班时刻表、科学计算结果及股市汇率。这类文档的特点是结构相当严谨,数据粒度精细(即最小的独立数据单位只存在于PCDATA元素或属性这一级别),很少或没有混合内容。除非在对文档进行验证的时候,同级元素或PCDATA的出现次序一般来说并不重要,交换两个同级元素并不会破坏文档的可读性。主要应用在电子商务、ERP, EAT等领域,集成不同数据源的数据,交换信息。 (2) 以文档为中心的文档(Document Centric Documents)将XML用作文本的传播载体,通常是给人阅读的。例如书籍、email、用户手册等。其特点是半结构化或非结构化的数据、数据粒度大,混合内容多。同级元素或PCDATA出现的次序一般来说非常重要。 (3) 混合型XML文档。在实际应用中,以数据为中心和以文档为中心的文档之间的差别不一定很明显。例如,一种以数据为中心的文档比如发票,可能含有大粒度的、结构不规则的数据比如零件说明;另一种以文档为中心的文档如用户手册,可能包含细粒度的结构规则的数据,比如作者和修订日期。其它例子包括法律和医学文书,虽然以松散的形式写成,但是却包含离散的数据块,例如日期、名称和操作程序,出于法规的原因通常要以完整的文件形式存储。此类文档同时具有面向数据和面向文档两种类型特征,称为混合型MXL文档。在混合型XML文档中,有结构化数据,也有非结构化数据。 2.1.4 XML文档的解析 对于一个现成的XML 文档,应用程序是不能直接使用或进行处理的,必须通过XML文档的解析器(XML Parser)把文档解析成可操作的形式。XML文档解析器实际上是一些程序,用来读取文档并分析文档的结构。解析XML文档是处理XML文档的第一步。一般来说 ,处理XML文档还要对XML文档中的数据进行处理,比如对文档进行添加、删除、修改等操作,这都要通过XML的解析器。解析器读取XML文档并检查文档的有效性。在多数情况下,会生成一棵解析树。目前,对于XML文档的解析主要有DOM解析和SAX解析两种方法,如图1所示。 第 4 页 共 25 页 图1 XML文档的解析 2.1.5 文档对象模型 (1)DOM简介 W3C文档对象模型(Document Object Model简称为:DOM)规范是一组基于树模型的平台和语言中立的应用程序编程接口(API),它能够描述如何访问和操纵存储在XML和HTML等文档中的信息。它是由万维网联盟(W3C)发布并维护的一个标准。DOM提供了文档的结构化视图,以及一个标准的可互操作的类和方法的集合,可以用于XML文档元素的添加、修改、删除和检索,以及文档内容的定位。DOM解析器读取整个文档,并通过在内存中构造一个对象树,提供文档的一个视图。文档的主要结构是通过对象树中的节点来表达的,并通过使用DOM接口来访问和处理对象树。目前DOM是处理XML文档时最常用的应用程序接口。依照W3C DOM规范,选用Document Object Model这个术语是因为DOM在传统的面向对象编程的意义上来看是一个对象模型。文档利用对象被模型化,模型用来描述文档的结构以及文档的行为和文档对象的行为。DOM规范是结构化文档处理技术的一次巨大的飞跃。这个规范为处理存储在XML,HTML和其它包含结构化信息的文档中的信息提供了一组标准编程接口。 DOM设计的基本原理规定,在DOM中“每个事物都是节点”,节点是DOM的一个基本概念,这是DOM的最大特点。除此之外,DOM还具有如下特点: ? 语言和平台的中立。DOM一开始就被设计成独立于各种平台和语言的。目前,几乎可以在每一种流行的平台上,使用任何一种常用的编程语言来使用DOM。如Java,JavaScript,Perl,C++等等。 第 5 页 共 25 页 ? 开放的并且是可扩展的。也就是说,一个供应商可以向DOM规范添加规范中没有定义的方法和属性,并且只要我们认为这些方法和属性是符合DOM基本规范的。比如Microsoft公司,它为了给开发人员带来便利,在不违反DOM规范的基础上,向DOMAPI提供了多个特定于Internet Explorer的扩展。 2)DOM树型结构 ( DOM在逻辑上用一棵树来表示文档。下面是一个XML文档的例子,DOM树表示其结构如图2所示。 例2.1一个典型的XML文档 chen 33 在图2中,双椭圆代表根节点,椭圆代表元素节点,菱形代表属性节点,矩形代表文本节点,箭头代表父子关系。在DOM术语中,图2中的每个椭圆或方框都称为一个“节点”。节点就是文档内容中的一个特定元素、属性和文本等等的对象表示。依据在文档树中的位置的不同,节点有特定的名称。所有的文档都有一个节点称为根节点,它是位于树型结构最顶部的节点。如图2所示,根节点就是表示标记的那个双椭圆。如果一个节点下面有一个或者多个节点,那么就把下面的节点称为这个节点的子节点,也就是说每个子节点都是其“父”节点的一个孩子节点。图中表示标记的节点就是节点的一个子节点,而它同时又是表示标记的节点的父节点。节点之间的这种父子关系在DOM中被广泛地使用。那些没有子节点的节点称为叶节点,它们是位于树的最远端的节点。把父子关系的比喻加以延伸,具有相同父节点的节点称为“兄弟”节点。如果两个节点都是从树型结构某处的同一个节点派生出来的,就说它们具有一个共同的祖先节点。 第 6 页 共 25 页 图2 文档树 节点的概念不仅限于元素,文档中的每个事物都可以表示为一个节点,包括注释、元素的属性、文本内容、XML处理指令、文档类型声明等等。只要是文档中的事物,就可以将它表示为一个节点。 (3)DOM的层 DOM被组织为分离的层,每一层都提供了自己的方法和定义。这些层可以定义本层用户所希望有的性能和服务。有时候您可能会忍不住把不同的DOM层看作不同“版本”的DOM,然而它们并不是真正意义上的版本。它们是专门定义的一个功能层,应用程序可以把这个特定的功能层提供给需要它的用户。比起DOM的Leve12层,正在用Level1层的开发人员可以期望更少的功能和特性。目前,有两个正式的DOM层:Level1和Levdl2。这两个层都是W3C所推荐的。最近出现的还是一个工作草案的层是Level3,也就是说,它目前还没有被W3C采纳为一个正式推荐的规范。另外还有第4个层,据说被认定为是Level0,它不是一个正式的DOM规范,也不是工作草案,它涉及了在DOMWorking Group成立之前,由早期的WEB浏览器(比如Netscape 3和Explorer3)所提供的DOM实现。随着时间的推移和技术的发展,这些层也在不断地完善之中。当然它的改进是以一般用户和DOM成员公司的需求为基础的。 在DOM规范中通常每个层都会被划分为两个或更多的模块,其中的Core模块是每个层都有的。Core模块具有处理结构化文档和对象所需要的核心方法。其余的模块则主要用来处理特定层的具体特性。DOM应用程序可以遵守一个特定DOM层的规范,也可以遵守一个DOM层中的一个特定模块的规范。 第 7 页 共 25 页 在1998年l0月,DOM的Level1层被采纳为W3C推荐标准(在2000年9月,发布了第2个版本的工作草案。它被划分为两个模块:Core模块和HTML模块。Core模块提供了一个标准的方法集合,用来访问和操纵任何结构化文档中的各种对象,并且还提供了一个扩展接口的集合,用来处理XML文档中的内容。在HTML模块中,设计了一个高级接口,这个接口可以和Core模块中的接口一起处理HTML文档中的内容。 DOM的Level2层是在2000年11月被采纳为W3C的推荐标准的。Level2层被划分为14个截然不同的模块,它们是Core,XML,HTML,Range,Traversal,CSS,CSS2,Views,Stylesheets,Events,User Interface Events,Mouse Events,MutationEvents和HTML Events。而且这14个模块被组织在Core,Views,Events,Style和Traversal/Range这5个部分中。 DOM的Level2层更新了由DOM的Level1层提供的Core模块中的附加命名空间支持,以及Level1层没有明确地支持的用于处理某些特定情况的方法。例如,DOM的Leve1层并没有包括创建空文档的方法,而DOM的Leve12层现在己经指定了处理这种常见问题的方法。除了提供处理结构化文档的基础接口外,DOM的Leve12层还增加了用于文档处理的其它功能,其中常用的如下所述: ? 范围(Range):为处理DOM中的范围操作指定方法。 ? 遍历(Traversal):为选择性遍历和过滤文档的内容而提供的编程接口。 ? 样式(CSS):为支持各种类型的样式表提供基础接口。 ? 视图:提供了允许文档具有多个视图的接口。 ? 事件:描述应用程序中的事件流,并为注册事件处理程序指定了一个统一的事件机制。除此之外还为每个事件的上下文提供了特定于事件的信息。 (4)DOM的数据类型 基本的、原子性的数据类型是编程接口内部工作方式所必需的,而DOM也不例外。DOM Working Group定义了一些基本的数据类型用来表示存储在文档中的信息,而且这些文档是可以通过多种语言和平台来使用和实现的。通常情况下可以从其它语言中借用现有的数据类型,但是对于更复杂的信息,DOMWorking Group创造了属于DOM自己的数据类型。从Leve12层起,DOM规范使用的基本数据类型是DOMString和DOMTimeStamp两种。 DOMString类型用来描述一个字符序列,其中的每个字符都用双字节的单元来表示。它在DOM规范中的定义方式如下: valuetype DOMString sequence; 第 8 页 共 25 页 根据DOM规范,DOMString使用UTF-16(在Unicode规范中有详细的定义)进行编码。选择UTF-16编码是因为这种编码方法支持世界各地的多种语言,并且在高科技行业中的应用十分广泛。 在所有的DOM规范中,无论哪里需要字符串,都会使用DOMString类型来表示。但在具体的使用过程中,经常需要把DOMString类型转换为一个本地平台支持的字符串类型。所以在某些DOM实现(比如Xerces)中,专门提供了把DOMString类型转换为本地字符串类型的方法。这样做完全是具体的DOM实现为编程提供的方便,但并不要求每一个DOM实现也提供类似的方法,而且在DOM规范中也没有定义这样的方法。 DOMTimeStamp数据类型在DOM规范中是按如下方式定义: Typedef unsigned long long DOMTimeStamp; 根据DOM规范,DOMTimeStamp类型是用来表示毫秒值的,但并没有指出对应0毫秒的基础日期。除了基本数据类型以外,DOM也有自己的节点类型。DOM本质上是节点的集合。由于一个文档中可能包含不同类型的信息,因此也要定义不同类型的节点。DOM规范定义了12种包含在文档中的节点类型。每种节点类型都有一组相同的属性和与之相关的方法。表1中列出了从DOM的Leve12层开始支持的各种节点类型,并且针对每种节点类型进行了简要的说明。 表1 DOM节点类型 HTML或者XML等文档中表示一个元素。如图2Element 所示, "" Then If Not fos.FileExists(CommonDialog1.fileName) Then MsgBox ("指定的文件不存在") Else absolutePathName=CommonDialog1.fileName extensionName=fos.GetExtensionName(absolutePathName) fileName=fos.GetBaseName(absolutePathName)&"."&extensionName Select Case extensionName 第 16 页 共 25 页 Case"bmp","dib","gif","jpg","wmf","emf","ico","cur": ImageWd.Picture=LoadPicture(absolutePathName) Case Else: ImageWd.Picture=Nothing End Select End If End If Set fos=Nothing End Sub 4.3 通讯记录模块 TxForm.frm生成新建通讯录功能界面如下图6: 图6 新建通讯录窗口 通讯录查找代码: Private Sub CmdTxCz_Click() Dim list As Collection '数据集 Dim else As IXMLDOMElement '当前结点 Dim count, i, j, length As Integer Dim query As String '查询条件 Dim name, group As String On Error GoTo Handle Me.MousePointer=11 Name=Trim(CmbTxXm.Text) group=Trim(CmbTxQz.Text) 第 17 页 共 25 页 query = "" If name <> "" Then query = "contains(name’"+name+"')" If group <> "" Then Query = query + "and group='" + group + "'" End If ElseIf group <> "" Then query = "group='" + group + "'" End If dbObj.openDatabase Set list = dbObj.query(TBL_ADDRESSLIST, query, True, False, "name") length = list.count If Op30Tx.value And length > DISPLAY_LENTGH Then length = DISPLAY_LENTGH End If MSFlexGrid_tx.Rows = 1 MSFlexGrid_tx.Rows = length + 1 MSFlexGrid_tx.TextMatrix(0, 0) = length & " " If length > 0 Then CmdTxSc.Enabled = True CmdTxXg.Enabled = True Else CmdTxSc.Enabled = False CmdTxXg.Enabled = False End If For count = 1 To length Set ele = list(count) MSFlexGrid_tx.RowData(count) = CLng(dbObj.GetAttribute(ele, "id").nodeValue) MSFlexGrid_tx.TextMatrix(count,1) = dbObj.GetNode(ele, "name").nodeTypedValue MSFlexGrid_tx.TextMatrix(count,2) = dbObj.GetNode(ele, "mobile").nodeTypedValue MSFlexGrid_tx.TextMatrix(count,3) = dbObj.GetNode(ele, "telphone").nodeTypedValue 第 18 页 共 25 页 MSFlexGrid_tx.TextMatrix(count,4) = dbObj.GetNode(ele, "oicq").nodeTypedValue MSFlexGrid_tx.TextMatrix(count,5) = dbObj.GetNode(ele, "msn").nodeTypedValue MSFlexGrid_tx.TextMatrix(count,6) = dbObj.GetNode(ele, "address").nodeTypedValue MSFlexGrid_tx.TextMatrix(count,7) = dbObj.GetNode(ele, "desc").nodeTypedValue MSFlexGrid_tx.TextMatrix(count,8) = dbObj.GetNode(ele, "group").nodeTypedValue MSFlexGrid_tx.TextMatrix(count,9) = dbObj.GetNode(ele, "logindate").nodeTypedValue Next dbObj.closeDatabase For i = 1 To MSFlexGrid_tx.Rows - 1 MSFlexGrid_tx.TextMatrix(i,0) = CStr(i) Next Me.MousePointer = 0 Exit Sub Handle: Me.MousePointer = 0 Call MsgBox(Err.Description, vbCritical) End Sub 4.4 收入支出记录模块程序 SzForm.frm生成修改功能界面如下图7: 图7 收入/支出文档修改窗口 修改收入开支记录段代码: Private Sub MSFlexGrid_sz_DblClick() Dim list As Collection 第 19 页 共 25 页 Dim ele As IXMLDOMElement '当前结点 Dim query On Error GoTo Handle If MSFlexGrid_sz.Row <> 0 Then dbObj.openDatabase query = "@id=" & MSFlexGrid_sz.RowData(MSFlexGrid_sz.Row) Set list = dbObj.query(TBL_SALARY, query) If list.count > 0 Then Set ele = list.Item(1) SzForm.TxtDl.Text = dbObj.GetNode(ele,"date").nodeTypedValue SzForm.TxtJe.Text = dbObj.GetNode(ele,"money").nodeTypedValue SzForm.CmbLq.Text = dbObj.GetNode(ele,"where").nodeTypedValue SzForm.RichTextBoxBz.Text = dbObj.GetNode(ele, "desc").nodeTypedValue SzForm.id = CLng(dbObj.GetAttribute(ele,"id").nodeValue) '设置更新模式 SzForm.updateFlag = False '排他模式显示窗口 SzForm.Show vbModal End If dbObj.closeDatabase End If Exit Sub Handle: Call MsgBox(Err.Description, vbCritical) End Sub 4.5 备忘录模块 BwForm.frm生成主界面如下图8: 图8 备忘录主窗口 删除备忘录功能页面代码: 第 20 页 共 25 页 Private Sub CmdTxSc_Click() On Error GoTo Handle Dim ret If MSFlexGrid_tx.Row <> 0 Then ret = MsgBox("确定要删除记录(ID=" & MSFlexGrid_tx.Row & ")?", vbYesNo) If (ret = vbYes) Then dbObj.openDatabase Call dbObj.deleteRecord(TBL_ADDRESSLIST, "@id=" & MSFlexGrid_tx.RowData(MSFlexGrid_tx.Row)) dbObj.closeDatabase '刷新备忘数据页面 Call CmdTxCz_Click End If Else MsgBox ("请选择要删除的记录") End If Exit Sub Handle: Call MsgBox(Err.Description, vbCritical) End Sub 5 软件测试 模块编程完结之后,编写测试文档,对界面外观和功能等进行检测。首先针对一个模块测试。模块测试时,检验模块每个功能是否都能正常使用,包括界面的按钮、线条、等的形状、大小、颜色是否符合规范;还有检测程序是否都能按预定要求正常工作,能按要求正确存入或者输出。测试过程中,发现BUG及时进行了修正。 模块测试完后,把各个模块整合成一个系统后,这过程中还可能会出现很多问题,由此继续进行集成测试。把模块按照设计要求组装起来的同时进行测试,主要目标是发现与类模块有关的问题,测试每个功能是否都能正常工作。这是一个“测试——修改——再测试——再修改”的过程,直到整个系统能正常运行,所有功能都能正常实现。 在测试过程中,出现过一些不符合标准和达不到功能要求的情况,经过修改及以后的调试,现在已已经基本能够完成正常的功能。 由于经验欠缺或其它某些原因,本次完成的软件不可能是完美无缺的。测试只能尽量避免错误的产生和消除已经产生的错误,使程序中的错误密度达到尽可能低的程度,减少错误的引入,但是不可能完全杜绝软件中的错误。经过测试,这款个人资料编辑软件基本能符合要求,也能实现各预期功能。 第 21 页 共 25 页 结 论 经过几个月时间的努力,通过图书馆查阅以及网上搜集相关资料,在导师的细心指导下,以VB为设计脚本语言,XML做小型数据库的个人资料编辑器的设计任务终于完成。本次毕业设计完成了系统的基本功能,能够通过本系统实现对文档信息的编辑、检索、保存、修改等文档管理功能;可以对生活中的收入支出的流水帐目做相关记录;完成了对学习或工作日程计划的备忘管理;实现了个人通讯录中联系人详细关信息的建立,可以对通讯录条目进行删除,查找等操作;同时还设计了初始管理员对系统用户的一个管理,让系统更加符合“个性化”。这款编辑器操作简单,性能良好,能够满足一般个体用户对资料管理的基本需求。 本次毕业设计由于时间和能力有限,系统功能上不够完善,查询时没有能用视图来优化速度便是其中之一,在以后的开发过程中,会可根据具体需要扩展系统功能,使系统更加具有实用性。 但总体说来,通过这次毕业设计,系统化了很多学过的知识,又把所学理论与实际应用联系了起来,为我今后走向社会打下了坚实的专业基础;其次,这几个月来,通过做毕业设计,也让自己初尝了去挑战一件事情的滋味,虽然有压力,但更多的是自我鼓励与导师督促,完成任务是美好的~四个字:受益匪浅~ 第 22 页 共 25 页 参考文献 [1]James Britt & Teun Duynstee著,高波 王琰 等译,VISUAL BASIC 6 XML专业技术[M].北京:人民邮电出版社,2000 [2]鲁荣江,王立丰编著,VISUALBASIC项目案例导航[M].北京:科学出版社,2002 [3]林锦雀编著,最新XML入门与应用[M].北京:中国铁道出版社,2001 [4] Elliotte Rusty Harold 著,徐罡 黄涛 译,Effective XML:有效使用XML的50种方法[M].北京:电子工业出版社,2006 [5]卢毅 编著,Visual Basic 实例教程[M].北京:科学出版社2005 [6]Chuck White, Liam Quin, Linam Burman 著,周生炳,宋浩,肖伟 等译,XML从入门到精通[M].北京:电子工业出版社,2005 [7]赛奎春 主编,Visual Basic信息系统开发实例精选[M].北京:机械工业出版社,2005 第 23 页 共 25 页 致 谢 本文是在王燚教授的热情关心和指导下完成的,他渊博的知识和严谨的治学作风使我受益匪浅,对顺利完成本课题起到了极大的作用。在此向他表示我最衷心的感谢~ 在论文完成过程中,本人还得到了其他老师和同学的热心帮助,本人向他们表示深深的谢意~ 最后向在百忙之中评审本文的各位专家、老师表示衷心的感谢~ 作者简介: 姓 名:陈宝献 性别: 男 出生年月:1983.5 民族: 汉 E-mail:chen_baoxian@126.com 第 24 页 共 25 页 声 明 本论文的工作是 2007年2月至2007年7月在成都信息工程学院网络工程系完成的。文中除了特别加以标注地方外,不包含他人已经发表或撰写过的研究成果,也不包含为获得成都信息工程学院或其他教学机构的学位或证书而使用过的材料。除非另有说明,本文的工作是原始性工作。 关于学位论文使用权和研究成果知识产权的说明: 本人完全了解成都信息工程学院有关保管使用学位论文的规定,其中包括: (1)学校有权保管并向有关部门递交学位论文的原件与复印件。 (2)学校可以采用影印、缩印或其他复制方式保存学位论文。 (3)学校可以学术交流为目的复制、赠送和交换学位论文。 (4)学校可允许学位论文被查阅或借阅。 (5)学校可以公布学位论文的全部或部分内容(保密学位论文在解密后遵守此规定)。 除非另有科研和其他法律文书的制约,本论文的科研成果属于成都信息工程学院。 特此声明~ 作者签名: 年 月 日 第 25 页 共 25 页 t was not until mid-afternoon that the inspector ambled up on his pony. My father pulled himself together, and went out to receive him; the effort to be even formally polite nearly strangled him. Even then the inspector was not brisk. He dismounted in a leisurely fashion, and strolled into the house, chatting about the weather. Father, red in the face, handed him over to Mary who took him along to mother's room. Then followed the worst wait of all. Mary said afterwards that he hummed and ha'd for an unconscionable time while he examined the baby in minutest detail. At last, however, he emerged, with an expressionless face. In the little-used sitting-room he sat down at the table and fussed for a while about getting a good point on his quill. At last he took a form from his pouch, and in a slow, deliberate hand wrote that he officially found the child to be a true female human being, free from any detectable form of deviation. He regarded that thoughtfully for some moments, as though not perfectly satisfied. He let his hand hesitate before he actually dated and signed it, then he sanded it carefully, and handed it to my enraged father, still with a faint air of uncertainty. He had, of course, no real doubt in his mind, or he would have called for another opinion; my father was perfectly well aware of that, too. At last Petra's existence could be admitted. I was formally told that I had a new sister, and presently I was taken to see her where she lay in a crib beside my mother's bed. She looked so pink and wrinkled to me that I did not see how the inspector could have been quite sure about her. However, there was nothing obviously wrong with her, so she had got her certificate. Nobody could blame the inspector for that; she did appear to be as normal as a new-born baby ever looks. ... While we were taking turns to look at her somebody started to ring the stable bell in the customary way. Everyone on the farm stopped work, and very soon we were all assembled in the kitchen for prayers of thanksgiving. Two, or it may have been three, days after Petra was born I happened upon a piece of my family's history that I would prefer not to have known. I was sitting quietly in the room next to my parents' bedroom where my mother still lay in bed. It was a matter of chance, and strategy, too. It was the latest place that I had found to stay hidden awhile after the midday meal until the coast was clear and I could slip away without being given an afternoon job; so far, nobody had thought of looking there for me. It was simply a matter of putting in half an hour or so. Normally the room was very convenient, though just at present its use required caution because the wattle wall between the rooms was cracked and I had to move very cautiously on tiptoe lest my mother should hear me. On that particular day I was just thinking that I had allowed nearly enough time for people to be busy again when a two-wheeled trap drove up. As it passed the window I had a glimpse of my Aunt Harriet holding the reins. I had only seen her some eight or nine times, for she lived fifteen miles away in the Kentak direction, but what I knew of her I liked. She was some three years younger than my mother. Superficially they were not dissimilar, and yet, in Aunt Harriet each feature had been a little softened, so that the effect of them all together was different. I used to feel when I looked at her that I was seeing my mother as she might have been — as, I thought, I would have liked her to be. She was easier to talk to, too; she did not have a somewhat damping manner of listening only to correct. I edged over carefully on stockinged feet to the window, watched her tether the horse, pick a white bundle out of the trap, and carry it into the house. She cannot have met anyone, for a few seconds later her steps passed the door, and the latch of the next room clicked. 'Why, Harriet!' my mother's voice exclaimed in surprise, and not altogether in approval. ' So soon! You don't mean to say you've brought a tiny baby all that way!' 'I know,' said Aunt Harriet's voice, accepting the reproof in my mother's tone, 'but I had to, Emily. I had to. I heard your baby had come early, so I — oh, there she is! Oh, she's lovely, Emily. She's a lovely baby.' There was a pause. Presently she added: ' Mine's lovely, too, isn't she? Isn't she a lovely darling?' There was a certain amount of mutual congratulation which did not interest me a lot. I didn't suppose the babies looked much different from other babies, really. My mother said: ' I am glad, my dear. Henry must be delighted.' 'Of course he is,' said Aunt Harriet, but there was something wrong about the way she said it. Even I knew that. She hurried on: 'She was born a week ago. I didn't know what to do. Then when I heard your baby had come early and was a girl, too, it was like God answering a prayer.' She paused, and then added with a casualness which somehow failed to be casual: 'You've got the certificate for her?' ' Of course.' My mother's tone was sharp, ready for offence. I knew the expression which went with the tone. When she spoke again there was a disturbing quality in her voice. 'Harriet!' she demanded sharply. 'Are you going to tell me that you have not got a certificate?' My aunt made no reply, but I thought I caught the sound of a suppressed sob. My mother said coldly, forcibly: 第 26 页 共 25 页 ' Harriet, let me see that child — properly.' For some seconds I could hear nothing but another sob or two from my aunt. Then she said, unsteadily: ' It's such a little thing, you see. It's nothing much.' 'Nothing much!' snapped my mother. 'You have the effrontery to bring your monster into my house, and tell me it's nothing much!' 'Monster!' Aunt Harriet's voice sounded as though she had been slapped. 'Oh! Oh! Oh! ...' She broke into little moanings. After a time my mother said: ' No wonder you didn't dare to call the inspector.' Aunt Harriet went on crying. My mother let the sobs almost die away before she said: ' I'd like to know why you have come here, Harriet? Why did you bring it here?' Aunt Harriet blew her nose. When she spoke it was in a dull, flat voice: ' When she came — when I saw her, I wanted to kill myself. I knew they would never approve her, although it's such a little thing. But I didn't, because I thought perhaps I could saAs spring came on, a new set of amusements became the fashion, and the lengthening days gave long afternoons for work and play of all sorts. The garden had to be put in order, and each sister had a quarter of the little plot to do what she liked with. Hannah used to say, "I'd know which each of them gardings belonged to, ef I see 'em in Chiny," and so she might, for the girls' tastes differed as much as their characters. Meg's had roses and heliotrope, myrtle, and a little orange tree in it. Jo's bed was never alike two seasons, for she was always trying experiments. This year it was to be a plantation of sun flowers, the seeds of which cheerful land aspiring plant were to feed Aunt Cockle-top and her family of chicks. Beth had old-fashioned fragrant flowers in her garden, sweet peas and mignonette, larkspur, pinks, pansies, and southernwood, with chickweed for the birds and catnip for the pussies. Amy had a bower in hers, rather small and earwiggy, but very pretty to look at, with honeysuckle and morning-glories hanging their colored horns and bells in graceful wreaths all over it, tall white lilies, delicate ferns, and as many brilliant, picturesque plants as would consent to blossom there. Gardening, walks, rows on the river, and flower hunts employed the fine days, and for rainy ones, they had house diversions, some old, some new, all more or less original. One of these was the `P.C', for as secret societies were the fashion,it was thought proper to have one, and as all of the girls admired Dickens, they called themselves the Pickwick Club. With a few interruptions, they had kept this up for a year, and met every Saturday evening in the big garret, on which occasions the ceremonies were as follows: Three chairs were arranged in a row before a table on which was a lamp, also four white badges, with a big `P.C.' in different colors on each, and the weekly newspaper called, The Pickwick Portfolio, to which all contributed something, while Jo, who reveled in pens and ink, was the editor. At seven o'clock, the four members ascended to the clubroom, tied their badges round their heads, and took their seats with great solemnity. Meg, as the eldest, was Samuel Pickwick, Jo, being of a literary turn, Augustus Snodgrass, Beth, because she was round and rosy, Tracy Tupman, and Amy, who was always trying to do what she couldn't, was Nathaniel Winkle. Pickwick, the president, read the paper, which was filled with original tales, poetry, local news, funny advertisements, and hints, in which they good-naturedly reminded each other of their faults and short comings. On one occasion, Mr. Pickwick put on a pair of spectacles without any glass, rapped upon the table, hemmed, and having stared hard at Mr. Snodgrass, who was tilting back in his chair, till he arranged himself properly, began to read: Jo was alone in the twilight, lying on the old sofa, looking at the fire, and thinking. It was her favorite way of spending the hour of dusk. No one disturbed her, and she used to lie there on Beth's little red pillow, planning stories, dreaming dreams, or thinking tender thoughts of the sister who never seemed far away. Her face looked tired, grave, and rather sad, for tomorrow was her birthday, and she was thinking how fast the years went by, how old she was getting, and how little she seemed to have accomplished. Almost twenty-five, and nothing to show for it. Jo was mistaken in that. There was a good deal to show, and by-and-by she saw, and was grateful for it. "An old maid, that's what I'm to be. A literary spinster, with a pen for a spouse, a family of stories for children, and twenty years hence a morsel of fame, perhaps, when, like poor Johnson, I'm old and can't enjoy it, solitary, and can't share it, independent, and don't need it. Well, I needn't be a sour saint nor a selfish sinner, and, I dare say, old maids are very comfortable when they get used to it, but..." And there Jo sighed, as if the prospect was not inviting. It seldom is, at first, and thirty seems the end of all things to five-and-twenty. But it's not as bad as it looks, and one can get on quite happily if one has something in one's self to fall back upon. At twenty-five, girls begin to talk about being old maids, but secretly resolve that they never will be. At thirty they say nothing about it, but quietly accept the fact, and if sensible, console themselves by remembering that they have twenty more useful, happy years, in which they may be learning to grow old gracefully. Don't laugh at the spinsters, dear girls, for often very tender, tragic romances are hidden away in the hearts that beat so quietly under the sober gowns, and many silent sacrifices of youth, health, ambition, love itself, make the faded faces beautiful in God's sight. Even the sad, sour sisters should be kindly dealt with, because they have missed the sweetest part of life, if for no other reason. And looking at them with compassion, not contempt, girls in their bloom should remember that they too may miss the blossom time. That rosy cheeks don't last forever, that silver threads will come in the bonnie brown hair, and that, by-and-by, kindness and respect will be as sweet as love and admiration now. Gentlemen, which means boys, be courteous to the old maids, no matter how poor and plain and prim, for the only chivalry worth having is that which is the readiest to pay deference to the old, protect the feeble, and serve womankind, regardless of rank, age, or color. Just recollect the good aunts who have not only lectured and fussed, but nursed and petted, too often without thanks, the scrapes they have helped you out of, the tips they have given you from their small store, the stitches the patient old fingers have set for you, the steps the willing old feet have taken, and gratefully pay the dear old ladies the little attentions that women love to receive as long as they live. The bright-eyed girls are quick to see such traits, and will like you all the better for them, and if death, almost the only power that can part 第 27 页 共 25 页 mother and son, should rob you of yours, you will be sure to find a tender welcome and maternal cherishing from some Aunt Priscilla, who has kept the warmest corner of her lonely old heart for `the best nevvy in the world'. Jo must have fallen asleep (as I dare say my reader has during this little homily), for suddenly Laurie's ghost seemed to stand before her, a substantial, lifelike ghost, leaning over her with the very look he used to wear when he felt a good deal and didn't like to show it. But, like Jenny in the ballad... She could not think it he, and lay staring up at him in startled silence, till he stooped and kissed her. Then she knew him, and flew up, crying joyfully . .. "Oh my Teddy! Oh my Teddy!" "Dear Jo, you are glad to see me, then?" "Glad! My blessed boy, words can't express my gladness. Where's Amy?" "Your mother has got her down at Meg's. We stopped there by the way, and there was no getting my wife out of their clutches." "Your what?" cried Jo, for Laurie uttered those two words with an unconscious pride and satisfaction which betrayed him. "Oh, the dickens! Now I've done it." And he looked so guilty that Jo was down on him like a flash. "You've gone and got married!" "Yes, please, but I never will again." And he went down upon his knees, with a penitent clasping of hands, and a face full of mischief, mirth, and triumph. "Actually married?" "Very much so, thank you." "Mercy on us. What dreadful thing will you do next?" And Jo fell into her seat with a gasp. "A characteristic, but not exactly complimentary, congratulation," returned Laurie, still in an abject attitude, but beaming with satisfaction. "What can you expect, when you take one's breath away, creeping in like a burglar, and letting cats out of bags like that? Get up, you ridiculous boy, and tell me all about it." "Not a word, unless you let me come in my old place, and promise not to barricade." Jo laughed at that as she had not done for many a long day, and patted the sofa invitingly, as she said in a cordial tone, "The old pillow is up garret, and we don't need it now. So, come and fess, Teddy." "How good it sounds to hear you say `Teddy'! No one ever calls me that but you." And Laurie sat down with an air of great content. "What does Amy call you?" "My lord." "That's like her. Well, you look it." And Jo's eye plainly betrayed that she found her boy comelier than ever. The pillow was gone, but there was a barricade, nevertheless, a natural one, raised by time absence, and change of heart. Both felt it, and for a minute looked at one another as if that invisible barrier cast a little shadow over them. It was gone directly however, for Laurie said, with a vain attempt at dignity... "Don't I look like a married man and the head of a family?" "Not a bit, and you never will. You've grown bigger and bonnier, but you are the same scapegrace as ever." "Now really, Jo, you ought to treat me with more respect," began Laurie, who enjoyed it all immensely. "How can I, when the mere idea of you, married and settled, is so irresistibly funny that I can't keep sober!" answered Jo, smiling all over her face, so infectiously that they had another laugh, and then settled down for a good talk, quite in the pleasant old fashion. "It's no use your going out in the cold to get Amy, for they are all coming up presently. I couldn't wait. I wanted to be the one to tell you the grand surprise, and have `first skim' as we used to say when we squabbled about the cream." "Of course you did, and spoiled your story by beginning at the wrong end. Now, start right, and tell me how it all happened. I'm pining to know." "Well, I did it to please Amy," began Laurie, with a twinkle that made Jo exclaim... "Fib number one. Amy did it to please you. Go on, and tell the truth, if you can, sir." "Now she's beginning to marm it. Isn't it jolly to hear her?" said Laurie to the fire, and the fire glowed and sparkled as if it quite agreed. "It's all the same, you know, she and I being one. We planned to come home with the Carrols, a month or more ago, but they suddenly changed their minds, and decided to pass another winter in Paris. But Grandpa wanted to come home. He went to please me, and I couldn't let him go along, neither could I leave Amy, and Mrs. Carrol had got English notions about chaperons and such nonsense, and wouldn't let Amy come with us. So I just settled the difficulty by saying, `Let's be married, and then we can do as we like'." "Of course you did. You always have things to suit you." "Not always." And something in Laurie's voice made Jo say hastily... 第 28 页 共 25 页 "How did you ever get Aunt to agree?" "It was hard work, but between us, we talked her over, for we had heaps of good reasons on our side. There wasn't time to write and ask leave, but you all liked it, had consented to it by-and-by, and it was only `taking time by the fetlock', as my wife says." "Aren't we proud of those two word, and don't we like to say them?" interrupted Jo, addressing the fire in her turn, and watching with delight the happy light it seemed to kindle in the eyes that had been so tragically gloomy when she saw them last. "A trifle, perhaps, she's such a captivating little woman I can't help being proud of her. Well, then Uncle and Aunt were there to play propriety. We were so absorbed in one another we were of no mortal use apart, and that charming arrangement woul make everything easy all round, so we did it." "When, where, how?" asked Jo, in a fever of feminine interest and curiosity, for she could not realize it a particle. "Six weeks ago, at the American consul's, in Paris, a very quiet wedding of course, for even in our happiness we didn't forget dear little Beth." Jo put her hand in his as he said that, and Laurie gently smoothed the little red pillow, which he remembered well. "Why didn't you let us know afterward?" asked Jo, in a quieter tone, when they had sat quite still a minute. "We wanted to surprise you. We thought we were coming directly home, at first, but the dear old gentleman, as soon as we were married, found he couldn't be ready under a month, at least, and sent us off to spend our honeymoon wherever we liked. Amy had once called Valrosa a regular honeymoon home, so we went there, and were as happy as people are but once in their lives. My faith! Wasn't it love among the roses!" Laurie seemed to forget Jo for a minute, and Jo was glad of it, for the fact that he told her these things so freely and so naturally assured her that he had quite forgiven and forgotten. She tried to draw away her hand, but as if he guessed the thought that prompted the half-involuntary impulse, Laurie held it fast, and said, with a manly gravity she had never seen in him before... "Jo, dear, I want to say one thing, and then we'll put it by forever. As I told you in my letter when I wrote that Amy had been so kind to me, I never shall stop loving you, but the love is altered, and I have learned to see that it is better as it is. Amy and you changed places in my heart, that's all. I think it was meant to be so, and would have come about naturally, if I had waited, as you tried to make me, but I never could be patient, and so I got a heartache. I was a boy then, headstrong and violent, and it took a hard lesson to show me my mistake. For it was one, Jo, as you said, and I found it out, after making a fool of myself. Upon my word, I was so tumbled up in my mind, at one time, that I didn't know which I loved best, you or Amy, and tried to love you both alike. But I couldn't, and when I saw her in Switzerland, everything seemed to clear up all at once. You both got into your right places, and I felt sure that it was well off with the old love before it was on with the new, that I could honestly share my heart between sister Jo and wife Amy, and love them dearly. Will you believe it, and go back to the happy old times when we first knew one another?" "I'll believe it, with all my heart, but, Teddy, we never can be boy and girl again. The happy old times can't come back, and we mustn't expect it. We are man and woman now, with sober work to do, for playtime is over, and we must give up frolicking. I'm sure you feel this. I see the change in you, and you'll find it in me. I shall miss my boy, but I shall love the man as much, and admire him more, because he means to be what I hoped he would. We can't be little playmates any longer, but we will be brother and sister, to love and help one another all our lives, won't we, Laurie?" He did not say a word, but took the hand she offered him, and laid his face down on it for a minute, feeling that out of the grave of a boyish passion, there had risen a beautiful, strong friendship to bless them both. Presently Jo said cheerfully, for she didn't the coming home to be a sad one, "I can't make it true that you children are really married and going to set up housekeeping. Why, it seems only yesterday that I was buttoning Amy's pinafore, and pulling your hair when you teased. Mercy me, how time does fly!" "As one of the children is older than yourself, you needn't talk so like a grandma. I flatter myself I'm a `gentleman growed' as Peggotty said of David, and when you see Amy, you'll find her rather a precocious infant," said Laurie, looking amused at her maternal air. "You may be a little older in years, but I'm ever so much older in feeling, Teddy. Women always are, and this last year has been such a hard one that I feel forty." "Poor Jo! We left you to bear it alone, while we went pleasuring. You are older. Here's a line, and there's another. Unless you smile, your eyes look sad, and when I touched the cushion, just now, I found a tear on it. You've had a great deal to bear, and had to bear it all alone. What a selfish beast I've been!" And Laurie pulled his own hair, with a remorseful look. But Jo only turned over the traitorous pillow, and answered, in a tone which she tried to make more cheerful, "No, I had Father and Mother to help me, and the dear babies to comfort me, and the thought that you and Amy were safe and happy, to make the troubles here easier to bear. I am lonely, sometimes, but I dare say it's good for me, and..." "You never shall be again," broke in Laurie, putting his arm about her, as if to fence out every human ill. "Amy and I can't get on without you, so you must come and teach `the children' to keep house, and go halves in everything, just as we used to do, and let us pet you, and all be blissfully happy and friendly together." "If I shouldn't be in the way, it would be very pleasant. I begin to feel quite young already, for somehow all my troubles seemed to fly away when you came. You always were a comfort, Teddy." And Jo leaned her head on his shoulder, just as she did years ago, when Beth lay ill and Laurie told her to hold on to him. He looked down at her, wondering if she remembered the time, but Jo was smiling to herself, as if in truth her troubles had all vanished at his coming. "You are the same Jo still, dropping tears about one minute, and laughing the next. You look a little wicked now. What is it, Grandma?" "I was wondering how you and Amy get on together." "Like angels!" "Yes, of course, but which rules?" "I don't mind telling you that she does now, at least I let her think so, it pleases her, you know. By-and-by we shall take turns, for marriage, they say, halves one's rights and doubles one's duties." 第 29 页 共 25 页 "You'll go on as you begin, and Amy will rule you all the days of your life." "Well, she does it so imperceptibly that I don't think I shall mind much. She is the sort of woman who knows how to rule well. In fact, I rather like it, for she winds one round her finger as softly and prettily as a skein of silk, and makes you feel as if she was doing you a favor all the while." "That ever I should live to see you a henpecked husband and enjoying it!" cried Jo, with uplifted hands. It was good to see Laurie square his shoulders, and smile with masculine scorn at that insinuation, as he replied, with his "high and mighty" air, "Amy is too well-bred for that, and I am not the sort of man to submit to it. My wife and I respect ourselves and one another too much ever to tyrannize or quarrel." Jo like that, and thought the new dignity very becoming, but the boy seemed changing very fast into the man, and regret mingled with her pleasure. "I am sure of that. Amy and you never did quarrel as we used to. She is the sun and I the wind, in the fable, and the sun managed the man best, you remember." "She can blow him up as well as shine on him," laughed Laurie. "such a lecture as I got at Nice! I give you my word it was a deal worse than any or your scoldings, a regular rouser. I'll tell you all about it sometime, she never will, because after telling me that she despised and was ashamed of me, she lost her heart to the despicable party and married the good-for-nothing." "What baseness! Well, if she abuses you, come to me, and I'll defend you." "I look as if I needed it, don't I?" said Laurie, getting up and striking an attitude which suddenly changed from the imposing to the rapturous, as Amy's voice was heard calling, "Where is she? Where's my dear old Jo?" 第 30 页 共 25 页
/
本文档为【基于VB和XML的个人资料编辑器的实现—毕业设计论文】,请使用软件OFFICE或WPS软件打开。作品中的文字与图均可以修改和编辑, 图片更改请在作品中右键图片并更换,文字修改请直接点击文字进行修改,也可以新增和删除文档中的内容。
[版权声明] 本站所有资料为用户分享产生,若发现您的权利被侵害,请联系客服邮件isharekefu@iask.cn,我们尽快处理。 本作品所展示的图片、画像、字体、音乐的版权可能需版权方额外授权,请谨慎使用。 网站提供的党政主题相关内容(国旗、国徽、党徽..)目的在于配合国家政策宣传,仅限个人学习分享使用,禁止用于任何广告和商用目的。

历史搜索

    清空历史搜索