TWI220035B - XML document editor - Google Patents

XML document editor Download PDF

Info

Publication number
TWI220035B
TWI220035B TW92117067A TW92117067A TWI220035B TW I220035 B TWI220035 B TW I220035B TW 92117067 A TW92117067 A TW 92117067A TW 92117067 A TW92117067 A TW 92117067A TW I220035 B TWI220035 B TW I220035B
Authority
TW
Taiwan
Prior art keywords
file
reachable
xml
editor
component
Prior art date
Application number
TW92117067A
Other languages
Chinese (zh)
Other versions
TW200500889A (en
Inventor
Yue-Sun Kuo
Jaspher Wang
Nai-Cheng Shih
Original Assignee
Academia Sinica
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Academia Sinica filed Critical Academia Sinica
Priority to TW92117067A priority Critical patent/TWI220035B/en
Application granted granted Critical
Publication of TWI220035B publication Critical patent/TWI220035B/en
Publication of TW200500889A publication Critical patent/TW200500889A/en

Links

Landscapes

  • Document Processing Apparatus (AREA)

Abstract

A DTD-compliant XML document editor is disclosed. The XML document editor generates hints for required elements and required element slots automatically in the process of document creation and edition so as to guide the user to produce a valid document, while syntactic violations are avoided at the same time. The editor also suggests optional elements that may be added into the document to be edited. The user requires no knowledge about XML and DTD to edit DTD-compliant XML documents. The editing process is user-interface-neutral, being able to support user interfaces based on tree views, presentation views and forms. By combining the DTD-compliant editing process with the simplicity of forms, a simple XML document editor with forms as its user interface is developed.

Description

1220035 玖、發明說明: 一、 【發明所屬之技術領域】 特別是關於—種可以產生符合文件格 文件的文件編輯器。 本發明是關於一種xml文件編輯器, 式定義(Document Type Definition -DTD) 二、 【先前技術】 (Γ-ensive Mar,llp LangUage.XML) . 件的原型(ge暖)表現方式。最近以來XML已經成為網路上資訊交換的剔 ^ (D〇cumentType De«〇n-DTD) (schema) ^χΜΜ^ (v〇c^^^ 以將各種資料及文件以XML方式表示,供商用套裝軟體處理。顺對於這些」 用層面’也帶來重大影響。 XML在制上喊本料,线在XML文㈣產域編輯上面。這只要1 各種«用及公用狐文件編輯器如雨後春筍般議來即可明睁。胤幻1220035 (1) Description of the invention: [Technical field to which the invention belongs] In particular, it relates to a file editor that can generate files that conform to the file format. The present invention relates to an XML file editor, Document Type Definition (DTD). 2. [Previous Technology] (Γ-ensive Mar, llp LangUage.XML). The prototype (ge warm) representation of the pieces. Recently, XML has become the choice of information exchange on the Internet ^ (D〇cumentType De «〇n-DTD) (schema) ^ χΜΜ ^ (v〇c ^^^) to represent various data and documents in XML for commercial packages Software processing. This also has a significant impact on these "utilization levels". XML is the basic material in the production system, the line is edited on the XML production domain. This only requires that various «use and public fox file editors» have sprung up. Come and open your eyes.

編輯器(以下簡稱「X紙編輯器」)的功用乃在供使用者用以產生具有形態正1 (we,M〇rmed) (syntaxvalld) ,xml 〇 ^tXML 通常可以使-讀讀'特符合職M,並錢財要料,提供語法檢查; 能。在編輯樹,㈣娜姆請。權她輯之樹合咐 定的語法’使时必須檢蚊制綱合於語法,並針對語法咖所細 語法錯誤,修改文_容。制者修改語法時,必須賤敎件之細或格式 .之知識。否則無法完成正確之修正。另—種作法岐對特定的观^ 語彙提供-财f化的朗者介面,使用者在應㈣不需有語法上之顧忌。不 過’對特定的XML語相發—套«化的制者介面,•純術«才能完The function of the editor (hereinafter referred to as the "X-paper editor") is for users to generate morphological positive 1 (we, M〇rmed) (syntaxvalld), xml 〇 ^ tXML can usually make-read-read special features M, and financial requirements, provide grammar check; Yes. In the edit tree, Naam please. The right grammar of the compilation of the right tree is necessary to check the mosquito system in the grammar, and to correct the grammatical errors in the grammar, modify the text. When modifying the grammar, the manufacturer must have knowledge of the details or format of the file. Otherwise, correct correction cannot be completed. Another kind of practice is that Qiqi provides a rich-language interface for a specific vocabulary. Users do not need to worry about grammar in response. However, it ’s about sending a specific XML language—a set of «ized producer interface, pure art»

目前市面上可見的XML 編輯器基本上均核所謂的「跟隨文脈 (context-sensitive)」編輯方式。當使用者在編輯 平耳文件%,編輯器可依上下文語關 係,提供指示或提示,以使讀者暸解之後所能進行 ^ 丁的編輯動作,稭此產生符合語 法的文件。這種作法對使用者而言’相當有用。不過在可見的xml編輯器技術 中’所提供的指示或料财、,紐確_完成敎件技符合語法。這也 是為何大部分XML編輯器需使用額外的語法檢查器的主要原因。 主要的區別乃在其使用者介面; 最近以來,各種應運而生的XML編輯器 XML編輯器可分為四大 其背後的編輯原理則大同小異。依使用者介面的不同 類:即文字顯示型(咖則)、樹狀結構型(treeview)、呈現型(pr_^ 及表單型(f_ base)。大部分的編輯器支援二種以上的使用者介面型態。其中, 文字顯示型XML編輯器’可使使用者如使用文件(文字)編輯器一般之方式 編輯標簽(tag)。雛頭型祕㈣將狐請謂料構⑽露丨偏 structure)顯示成樹狀,在樹狀結射可以增加^騎狀節點(⑽把)。而呈現 型編輯器則運用各種不同的轉換技術,包括則..、咖及其他彼之轉換方法, 以將XML文件顯示成「WYSIWYG」(—,败㈣⑽卿㈣)之使用者介 面’以供使时顧。崎_於狀語彙(幫—丨㈣需由技術專家 加以客製化及提供支援。 至於表單型XML編輯器則等於是一個表單產生器,其表單是依據特定之資 料模式(—^她1)而產生,資料模式則是以特定之}(胤格式方案(咖職) 或XML文件格式定義所描述。現有之表單型xml編輯器,由於不夠嚴謹,因 此在處理_般的XML眘+ ^•,尚有困難,而要在資料輸入時隨時避免語法上的 錯誤,則更非易事。 上述的習知XML編輯器在文件建立的過程中,對於語法的規定,並未嚴格 =。編輯_也提供跟隨文_警告、提核導引信息,包括更正語法錯誤°之 縣或提邱息’㈣常㈤並非嚴謹。各該xml編輯騎常只提供使用者在 早編幸耳模態下’依需要建立及編輯具形態正常的⑽ 語法正確的XML文件。 二、【發明内容】 本發明的目的乃在提供—種新穎的xml文件編輯器,該文件編輯器可用以 建立符合料DTD想叙XML文件。 本發明的目的也在提供一德紅 杈仏種新禎的XML文件編輯器,以避免所編輯的文件 不合所_之勵想式之規定。 本务明的目的也在提供一種新穎的麗文件編輯器,該文件編輯器可在使 用者建立及編敎叙過財,自動產生正叙料及提示。 月的目的也在提供一種新穎的XML文件編輯器,以簡化使用者建立及 編輯文件之程序。 使用者不需具備特殊 該文件編輯器可支援 本I明的目的也在提供—種新穎的文件編輯器 專業知識即可利用該文件編輯器建立及編輯XML文件。 本^月的目的也在提供一種新穎的皿文件編輯器 不同型式之使用者介面。 本發明的目的也在提供一 種新穎的XML文件編輯器 該文件編輯器可支援 表單型式之使用者介面。 本發明揭示一種可使文件符合_之XML文件編輯器。該XML文件編輯 器在文件建立及編輯過程中自動產生必要元件的提示及必要元件槽;在編輯過程 中文件不會延反語法規範。本發明之XML文件編輯器並能依使用者要求,產生 l用兀件之建4,使使用者得知可以加人之元件為何。在建立及編輯符合如〕 之XML文件時,使用者並不需要有皿或師之專業知識。本發明並不依附 於特定使用者介面㈣,可以支援樹狀結構型、呈現型或表單型之使用者介面。 結合本發明之符合DTD編輯方式及表單,本發明另提供一種簡單的表單型綱 文件編輯器。 四、【實施方法】 本發明之目的乃在提供一種使新建置及編輯之文件無論何時均符合文件型式 描述(DTD-complian〇的XML文件編輯器。為達成此效果,本發明之屬文 件編輯器(以下稱「XML編輯器」)具有下列功能·· 百先,該文件編輯器需使使用者在使用該編輯器建置及編輯文件時,工作文 DT〇 ( A D〇cument Defin.i〇n) ^ 方案(schema)之規定。 其次,該文件編輯n在偵期使財之王敎件巾需加人某些元件才能使工 作文件合於語法規定(valid)時’可自動產生必要元件之提示或含有適當選用元 件之必要元件槽(slot,可容使用者加入元件之空格)。 再者,該文件編輯ϋ在使用者請求時,可產生翻元件槽及適當的選用元 提示。 ' 1220035 ’使用者不需具備 語彙(vocabulary) 再次,該可產生符合DTD文件之文件編輯器,使用容易 專業知識,即可使用。在使用時,使用者只需知悉特定職 中之元件及屬性(attnbute)在應用上之意義即可加以使用。 由XML文件之定義可知,任一魏文件均具有一個巢狀(咖⑷多層階 層'結構。在判敎件Μ合於縣時,可於各元件及其子請之語練 乾刀別考慮。通常’在XML文件中,元件之内容型態(⑽㈣咖)是利用一 (regular expression ^ 0 子元件之合法出現順序。以下’將以「⑽」所制的符號表示正規表達式。 1 ·_幽级Y—自動機(如迦迪^ 雖不願以任何理論限制本發明之範圍,但本發明的XI編輯器可以自動機 (aut01^^ ^ ·...··. 疋義於Σ之正規表達式Ε稱為—簡單正規式,若Ε中之符號〜均只出現一 斤决疋之σσ 3 L可以一確定性有限自動機(此化⑽丨丨也如finjte aut〇mat〇n)(), 亦P 4又所知之自動機(aut〇mat⑽)加以辨識,定義如下: L在E中之每一符號均為G之狀態(state)。G另含二狀態,即s與f,各表 開I狀悲及結束狀態(如L包含空符號串,則s也是結束狀態)◦ 2.轉換函式δ (Xi,Xj) =Xj,對任一 χ'ς且X|e follow (Xi);亦即在l中某 些符號串中X」緊隨在Χι之後。 5 (s,Xj) =Xj,對任一 Xj e first (E);亦即Xj為L中某些符號串之第1符 號。 5 Ui,$ )二f,對任一 Xie last (E);亦即\為L中某些符號串之最後符 9 1220035 唬,其中$為對於每一符號•所加之特別結束符號。 注意,函式fim⑻、lasUE)及fcUow U)可以透過遍歷⑴,之樹 狀結構,計算得到。以—簡單正規式E=(綱*,以例,其中,⑽⑻卞上 c} ^ last (E ) -{〇},i〇ll〇w(a)=follow(bh{ai b, c} 〇 ^ 1oi,〇w(c)={} 〇 E ^ Glushkov automaton (G)示於第 i 圖。 在Glushkov automaton G中之鄰邊(edgc)包括數種型態:如E1與κ為η 之二個前後子表達式,亦即(E1删為Ε之子表達式,則對每—個…㈣㈤) first (E2) ^ G ( sequence edge} j (l,v)o(^^ 正規表達式E具有一自然樹狀表述(treerepresen她爪)。E之子表達式則對應於 E之树狀表奴子樹狀表述。)鱗鄰邊與出自開始狀態$之_邊,以及入於最 、、冬狀悲f之鄰邊,合稱為「向前鄰邊(f〇rwardedge)」。如^广為F之子表達式, S U ( ldSt(El )及母一 v C first(E1)’G 包括-1 反覆鄰邊(iteration edge)」 (u,v)。通$而言一個鄰邊可能同時為順序鄰邊且為反覆鄰邊。一反覆鄰邊如不 蜀順序鄰k則稱為「向後鄰邊(backward edge)」。以第1圖所示之DFA G為 '讲匕"(’ C)及(b,c)為順序鄰邊’且為向前鄰邊;鄰邊(s, a)、( s,b )、( s, c)及(C,f)則為向前鄰邊;鄰邊(a,a)、(a,b)、(b,a)及(b,b)則為反覆鄰 邊且為向後鄰邊。 •皆—子表達式E1 ’令A (E1)表示Σ中為E1所含蓋之符號。例如,當 E1化…日寸’ A (El )二。令·hable(u)表在G中可由狀態(state) u「到 達」(reath)之狀態之集合,亦即reachable(u)二{z|G中存在由u到z之路徑}。定 義向如路仫為僅包括向前鄰邊之路徑。令卜reachable(u)表G中可自u經由向前鄰 10 邊到達之狀 態之集合’亦即卜G中存在由u到z之向前路徑丨。依 月1J述定義,可以觀察如下: _友理1 :旦夕之向前鄰邊不形*jj^Xeycle> 證明:對E中之符號可以給予編號,使各編號由左至右遞增。則向前鄰邊 表不自編號較小的符號至編號較大的符號。因此向前鄰邊不形成循環。 何 xCA(El),必然存在某些 u€ 如以且 V e f-reachable(x) 〇 證明:如El為符號,則本補助定理為不證自明。因此只需基於m之子盘· 逢式已符合本補助定理,證明E1亦符合本補助定理即可。 可能之情形有3 :The XML editors currently on the market are basically all about the so-called "context-sensitive" editing method. When the user is editing the flat ear file%, the editor can provide instructions or prompts according to the context, so that the reader can understand the editing actions that can be performed afterwards, thereby generating a grammatical file. This approach is quite useful for the user. However, in the visible xml editor technology, the instructions or materials provided by ’, Niu _ completed file technology conforms to the syntax. This is the main reason why most XML editors need an extra syntax checker. The main difference is in its user interface. Recently, various XML editors have emerged. XML editors can be divided into four major categories. The editing principles behind them are similar. According to different types of user interfaces: text display (tree), treeview (treeview), presentation (pr_ ^, and f_base). Most editors support more than two users Interface type. Among them, the text display type XML editor 'allows users to edit tags in the same way as using a document (text) editor. ) Is displayed as a tree. Shooting in the tree can increase the ^ riding node (⑽ 手). The presentation editor uses a variety of different conversion technologies, including: .., coffee, and other conversion methods to display the XML file as the user interface of "WYSIWYG" (—, defeated ㈣ 清 ㈣) for the user interface. Make time. Qi_Yu adverbial vocabulary (help — 丨 ㈣ needs to be customized and supported by technical experts. As for the form-based XML editor is equivalent to a form generator, the form is based on a specific data model (— ^ She1) The data pattern is described by a specific} (胤 format scheme (service) or XML file format definition. The existing form-type xml editor is not careful enough, so it is processing _like XML with care + ^ • There are still difficulties, and it is even more difficult to avoid grammatical errors at any time when inputting data. The above-mentioned conventional XML editor did not strictly enforce the grammar requirements during the file creation process. Edit_ Follow-up text_warnings, review guidance information, including correction of grammatical errors, or mention of Qiu Xi '㈣ 常 ㈤ is not rigorous. Each xml editor often only provides users in early editing mode.' Create and edit XML files with normal grammar and correct syntax as required. 2. [Summary of the Invention] The object of the present invention is to provide a novel xml file editor, which can be used to create a DTD that matches the material. XML file. The object of the present invention is also to provide a new XML file editor that can prevent the edited files from being inconsistent. The purpose of the present invention is also to provide a novel The beautiful document editor, which can create and edit the wealth in the user, automatically generate positive materials and prompts. The purpose of the month is also to provide a novel XML document editor to simplify the creation and editing of users Document procedures. Users do not need to have a special document editor to support the purpose of this document. A novel document editor expertise can also be used to create and edit XML documents using this document editor. The object is also to provide a novel user interface for different types of document editors. The object of the present invention is also to provide a novel XML document editor, which can support form-type user interfaces. XML file editor to make files conform to _. The XML file editor automatically generates the necessary components and necessary instructions during the file creation and editing process. In the editing process, the file will not delay the grammar specification. The XML file editor of the present invention can also generate the built-in components according to user requirements, so that the user knows what components can be added. When creating and editing XML documents conforming to], users do not need to have the expertise of a dish or a teacher. The present invention does not depend on a specific user interface, and can support tree-structured, presentation-based or form-based User interface. Combined with the DTD-compliant editing methods and forms of the present invention, the present invention also provides a simple form-based outline file editor. [Implementation method] The purpose of the present invention is to provide a newly created and edited file. It always conforms to the file type description (DTD-complian) XML file editor. In order to achieve this effect, the file editor (hereinafter referred to as "XML editor") of the present invention has the following functions: Baixian, the file editor The editor needs to enable the user to use the editor to build and edit documents, and the working text DT〇 (AD〇cument Defin. I〇n) ^ scheme requirements. Secondly, the editor of the document, during the investigation period, will need to add some elements to the King of Wealth. In order to make the working document comply with the grammatical requirements (valid), it can automatically generate the prompts for necessary components or contain the necessary components for proper selection. Slot (a slot that allows users to add components to the space). In addition, the document editor can generate component turning slots and appropriate selection hints when requested by the user. '1220035 ’Users do n’t need to have a vocabulary. Again, this file editor can generate DTD files, easy to use, professional knowledge, and ready to use. In use, the user only needs to know the application meaning of the components and attributes (attnbute) in a specific job. From the definition of the XML file, it can be known that any Wei file has a nested (cooked multi-level hierarchy) structure. When judging the document M in the county, you can practice it in the language of each component and its subordinates. Generally, 'in an XML file, the content type of a component (⑽㈣ coffee) is a legal appearance order of regular expression ^ 0 subcomponents. The following' will use a symbol made of "⑽" to represent a regular expression. 1 · _ Y-level automaton (such as Gadi ^ Although not willing to limit the scope of the present invention by any theory, the XI editor of the present invention can be an automaton (aut01 ^^^ ... The regular expression Ε is called a simple regular expression. If the symbols ~ in E only show σσ 3 L for one pound, it can be a deterministic finite automaton (this ⑽ 丨 丨 also like fijte aut〇mat〇n) (), Also known by the automaton (automat) known to P 4 and defined as follows: Each symbol of L in E is the state of G. G also contains two states, namely s and f , Each table shows the I state and the end state (if L contains an empty symbol string, s is also the end state). 2. Conversion function δ (Xi, Xj) = Xj For any χ'ς and X | e follow (Xi); that is, X "immediately follows Xι in some symbol strings in l. 5 (s, Xj) = Xj, for any Xj e first (E ); That is, Xj is the first symbol of some symbol strings in L. 5 Ui, $) 2 f, for any Xie last (E); that is, \ is the last symbol of some symbol strings in L 9 1220035 , Where $ is a special ending symbol added for each symbol. Note that the functions fim⑻, lasUE) and fcUow U) can be calculated by traversing the tree structure of ⑴, with-simple normal formula E = (gang * Take, for example, where c} ^ last (E)-{〇}, i〇ll〇w (a) = follow (bh {ai b, c} 〇 ^ 1oi, 〇w (c) = { } 〇E ^ Glushkov automaton (G) is shown in Figure i. The adjacent edges (edgc) in Glushkov automaton G include several types: if E1 and κ are two pre- and sub-expressions of η, that is, (E1 Deleted as a child expression of E, then for each one ... ㈣㈤) first (E2) ^ G (sequence edge) j (l, v) o (^^ The regular expression E has a natural tree representation (treerepresen her claw) The child expression of E corresponds to the tree-like representation of the tree-like slaves of E.) The _ edge from the starting state $ and the adjacent edge that entered the most, winter-like sadness f are collectively referred to as the "forward edge" (f0rwardedge). For example, ^ is a child expression of F. SU (ldSt (El) and mother-v C first (E1) 'G include -1 iteration edge) (u, v). In terms of $, an adjacent edge It may be both sequential adjacent edges and repeated adjacent edges. A repeated adjacent edge such as a sequential adjacent k is called a "backward edge". The DFA G shown in Figure 1 is used as a "backward edge". ('C) and (b, c) are sequential adjacent edges' and are forward adjacent edges; adjacent edges (s, a), (s, b), (s, c), and (C, f) are Adjacent edges; adjacent edges (a, a), (a, b), (b, a), and (b, b) are repeated adjacent edges and backward neighbors. • All—Subexpression E1 'Let A (E1) represents the symbol in Σ that is covered by E1. For example, when E1 is transformed ... 寸 inch 'A (El) II. Let hable (u) table be in G from state (state) u "reach" (reath) ), That is reachable (u) two {the path from u to z exists in z | G}. Defining the direction of the road as a path that includes only the forward neighbors. Let reach (u) table G The set of states that can be reached from u via the neighboring 10 sides forward ', that is, there is a forward path from u to z in Bu G 丨. Month 1J The definition can be observed as follows: _Youli 1: The forward neighbor of the day is not shaped * jj ^ Xeycle > Proof: The symbols in E can be numbered so that each number increases from left to right. The forward neighbor table is not From the lower-numbered symbol to the higher-numbered symbol. Therefore, no loop is formed on the adjacent edges. There must be some uCA such as and V e f-reachable (x) 〇 Prove: such as El As a symbol, the subsidy theorem is self-evident. Therefore, it is only necessary to prove that E1 also conforms to the subsidy theorem based on the sub-disc · Fengshi of m. It may be 3:

Hast(E2)aEl亦符合補助定理2。Hast (E2) aEl also conforms to the subsidy theorem 2.

3 last ( E2 ) 且 last ( E1 ) Hast ( E2 ) U iast ( E3 )〕 f-reachable(u)a ν ε (Ε3 ) 3 first ( Ε2 ), El滿足補助定理$ (3) El 為一 順序表達式 ’亦即 El二(E2,E3), 其中E2及E3滿足補助 1220035 定理2。對任一 χ G1 A ( p 1、 一1 ),可以仔到 >;e Λ ( E2 )或 x C Λ ( F3 ) 9又X C A(L2)( X c A(E3)之情形與此對稱),由於E2滿足補助定理^ ^^ - U C flrSt(2)^ ^ ^ ,ast(E2). χ C f-reachab.e(u)i f-reachable(x)。由於 flm 广 、 () g iirst ( El ),故得 L1 f flrst ( p j )。 又因為E3滿足補助定评? 刀叱理2,必然存在某些wefirst(E3)及Μ、!叫3 last (E2) and last (E1) Hast (E2) U iast (E3)] f-reachable (u) a ν ε (Ε3) 3 first (Ε2), El satisfies the subsidy theorem $ (3) El is a sequence The expression 'is El two (E2, E3), where E2 and E3 satisfy the subsidy 1220035 Theorem 2. For any χ G1 A (p 1, a 1), we can go to> e Λ (E2) or x C Λ (F3) 9 and XCA (L2) (X c A (E3) ), Since E2 satisfies the subsidy theorem ^ ^^-UC flrSt (2) ^ ^ ^, ast (E2). Χ C f-reachab.e (u) i f-reachable (x). Since flm is wide and () g iirst (El), L1 f flrst (p j) is obtained. And because E3 meets the subsidy evaluation? Swordsmanship 2, there must be some wefirst (E3) and M ,! call

(E3 ) g lasf(El),使得 S 于 v t i-reachable(w)。因為 Ei 二(拉 F3 ) 與w形成一順序鄰邊。P ’ ' 找到一向前路徑由X到z,Z到w,最後 到veiast(E1)。證明補助定理2。 阳 補助定理3 :若ΕΓ為E夕子齐:太v l_y e reachable(u)及 u e regj^ahkl^) 〇 、' 證明··由補助定理2可知,在A , 在 xl, x2 C first ( El )及 zl, Z2 C last ( ρι ), 使得 u e f-reachable ( xl )、zl e ^ ’、 c hable(u)、v (? l-reachable(x2)且 7:2 (;、 f-reachable(v)。另一方面,亦存在— 子任由z2到xl之反覆鄰邊,及一由zi到χ2鲈 反覆鄰邊。因此,由χ1連到u表 7 連至j zl,連到χ2,連到v,連到z2,而回到χ! 形成一循環。證明補助定理3。 Χ , 以上是對簡單表達式所為之證明。如為多重(誦_之一般正規表達式 (表達式中所含之至少一 σ ^ 、〜I表達式中出現二次或以上)時,亦可以相似之方 、卜。例如,對一個多重表 運式= 广,α;)而言,可將第二個a,以c 、之狀恶c表c或a,在計曾中 丨w甲亚不重要(significant),只有當該狀態出現在使 者介面時,才有加以區別的必要。 、以、 月本七明之XML編輯器確可透過Glushkov automaton之計算, 12 1220035 找到與特定元件有關係之元件。 設e,為由符號集合Σ,:{yi, y2,.....,ym}中之 付唬所組成之正規表逵々, 為其相對應之簡單表達式,由符號集合z X η^ ’2’ Χη}之符號所組成。八 G h 別為 Ε 及 Ε 之 Glushk〇v automata,—如 U。饭没E’為一元件型態 — 模式,則顯M符她恤繼她彳-_ s到⑽中之心谷 之亦然。也就是說,找到一個由s到丨、之〇 — " 5 、 路徑,就可以建立一個符合語g 的有效文件。 σ / 一個XML編輯器雖在最後結果產生 〇去的文件,但並不意味在該文件 建立及編輯過程巾,文件必鱗時歧合 。 古的狀悲下。依據本發明XML編 輯器之設計,乃是在文件建立及編輯過程中 M XML編㈣永遠賴工作文件保 持「符合DTD」之狀態。所謂「符合dtd 、 iU」,疋指一母元件之子元件形成—個合 於浯法之子兀件序列之子序列◦以一個正 兄衣建式d為例,一個(E3) g lasf (El) such that S is in v t i-reachable (w). Because Ei II (pulling F3) and w form a sequential adjacent edge. P ′ 'find a forward path from X to z, Z to w, and finally to veiast (E1). Prove the subsidy theorem 2. Positive subsidy theorem 3: If ΕΓ is E Xiziqi: Too v l_y e reachable (u) and ue regj ^ ahkl ^) 〇, 'Prove · From the auxiliary theorem 2, we can know that in A, in xl, x2 C first (El ) And zl, Z2 C last (ρι), such that ue f-reachable (xl), zl e ^ ', c hable (u), v (? L-reachable (x2), and 7: 2 (;, f-reachable (v). On the other hand, it also exists—the child is allowed to overlap adjacent edges from z2 to xl, and one is repeated adjacent edges from zi to χ2. Therefore, from χ1 to u, Table 7 is connected to j zl, and χ2 , Connected to v, connected to z2, and returned to χ! To form a cycle. Prove the auxiliary theorem 3. χ, The above is the proof for simple expressions. If it is multiple (General regular expression of __ (in the expression When at least one of the expressions σ ^ and ~ I appears twice or more), similar formulas can also be used. For example, for a multiple expression = Canton, α;), the second Each a, in the form of c and c, c or a, is not significant in the plan. Only when this state appears in the messenger interface, it is necessary to distinguish. Ben Qiming's XML The editor can indeed use Glushkov automaton's calculations to find the components that are related to specific components. Let e be composed of the symbols in the symbol set Σ: {yi, y2, ....., ym} The normal expression 逵 々 is its corresponding simple expression, which is composed of the symbols of the symbol set z X η ^ '2' χη}. Eight G h are not Glushkov automata of E and E, such as U. Fan Mi E 'is a component type — pattern, then it shows that M symbolizes her shirt and follows her 彳 -_ s to the heart valley of zhongzhong. That is to say, find a s to 丨, 〇— " 5. Path, you can create a valid file that conforms to the language g. Σ / Although an XML editor produces a file of 0 in the final result, it does not mean that during the file creation and editing process, the files must be inconsistent. The ancient state of sorrow. According to the design of the XML editor of the present invention, the M XML editing in the process of document creation and editing always depends on the working document to maintain the status of "compliant with DTD". The so-called "compliant with dtd, iU", 疋Refers to the formation of child elements of a mother element-a sequence of child elements that fit into the law ◦ sequences to build a positive brother clothing style d, for example, a

元件串acdde並不符合語法,但卻是合於D 、DTD,因為acdde乃是合於語法的元件 串abcdcde的一子序列。 在本發明之XML文件編輯器編輯符合DTD文件時,使用者以一空白文件開 始編輯’並在文賴㈣管财在“文射“猶,以確紅作文件符合 使用者。r以在工作文件中刪除arbitrary元件,而刪除後之文件顯然仍可符 D DTD。使用者重複加人’刪除讀之步驟,即可建立或編輯所需之符合語法之 xml文件。The element string acdde does not conform to the syntax, but it is compatible with D and DTD, because acdde is a subsequence of the element string abcdcde which is syntactic. When the XML file editor of the present invention compiles a DTD-compliant file, the user starts editing with a blank file 'and manages the property in Wen Lai's "Wen Shooting" to make sure that the red file matches the user. r to delete the arbitrary element in the working file, and the deleted file obviously still conforms to D DTD. The user repeats the steps of adding and deleting, and can create or edit the required xml file in accordance with the syntax.

一個符合DTD之文件應對應於一 G 中之狀態序列{Z|, z2, ··..,zp} ,其中 13 1220035 z!二s、Zp二ί ’ Zj+i e reachable(Zj) ’ 1 $ i Sp-l。 由使用者角度言’使用者所看到的文件乃是序列{〇n㈣Z2_ iginal(ZH)}。在此,主要課題乃是當使时想在相連的二狀態之…例如&與 u之間)插入一元件時’ XM丨观器應如何找到一個候選元件之集合,使使用 者可在其中選用所需之元件,加入編輯文件中,使文件符人DT[) 在此情形下,本發明在XML文件編輯過程中,主要針對使用者在相連二— 件間如何加入一符合DTD之元件,進行判斷盥處评.x 处理。亚不意味在文件編輯過程 中,不斷對文件中所有元件是否符合DTD進行檢杳 Η双鱼也不意味在編輯過程中, 或編輯的結果,文件中所有元件均必須符合^丁^。 3.決定狀態選單^ 設C為可插入於狀態u與ν間之候選狀態所形成之集合,v e reac_u)。 候選狀態表示由U到V之「可能」路線。且—狀態z存在於u與v間之必要條件 為zereachable⑻且vereachable⑵。不過,此條件並非充分。設一⑽划⑽ aut⑽福G代表正規表達式E= ,如第2圖所示。由於e之外 部反覆(〇Utei. itemiGn) ’任—狀態均為其他任—狀態之耽(除s與「外)。 如果C中之狀態只需献該必要條件,則c將永遠包含所有的狀態。這種必要條 件太過寬鬆,無法產生正確的提示。在本發明中,细-個「最小候選狀態集合」 之技術’以排除循環(⑽)及繞道(d_.)(例如不必要的向後鄰邊),得到 有意義的狀_單。在本發明之最小__合代表由u到v _「直接路徑」 (dircCtpath(S))’ 在少數情形下,才容許出現钱選狀態集合中。 哥找直接路fe的方法如下: 14 1220035 ⑻。假設 v g 紐^幽处响麵^補助定理4 建立-個非彳卿❿聯結_。(如子表達如選為包括♦之最少子 表達式,該路徑p則稱為最少向後路徑。) 證明·’令E2為B中包含u與v之最少子表達式。並假設E2及其所有上位 ⑽ce_«狀敍好錢t持料料子錢核騎时表 令E3為E2之上位錢式m糾㈣左方子表達式至其右 之向前鄰邊。然而_v均包含在其一子表達式中。因此,E 達式 將與V是否為U之(向前)reachable無關。換言之’ V 之向則郝邊 狀態,是由E2決定。 以為U之(向前)—le 如E2為選擇性子表達式,則因u與v分別包含 广L2之子表達式中A DTD-compliant file should correspond to the state sequence {Z |, z2, ·· .., zp} in a G, where 13 1220035 z! Two s, Zp two ί 'Zj + ie reachable (Zj)' 1 $ i Sp-l. From the perspective of the user, the file that the user sees is the sequence {〇n㈣Z2_ iginal (ZH)}. Here, the main issue is how to find a set of candidate components when the user wants to insert a component in the connected two states ... (for example, between & and u). The required components are selected and added to the editing file so that the file corresponds to DT [). In this case, in the process of editing the XML file, the present invention mainly aims at how to add a DTD-compliant component between the two connected users. Carry out judgement review.x treatment. Asia does not mean that during the file editing process, all components in the file are continuously checked for compliance with DTD. Η Pisces does not mean that during the editing process or the result of editing, all components in the file must comply with Ding ^. 3. Determine the status menu ^ Let C be a set of candidate states that can be inserted between states u and ν, v re reac_u). The candidate states represent "possible" routes from U to V. And, the necessary condition for the state z to exist between u and v is zereachable⑻ and vereachable⑵. However, this condition is not sufficient. Suppose that ⑽⑽aut⑽G represents the regular expression E =, as shown in Figure 2. Due to the external iteration of e (〇Utei. ItemiGn) 'any-state is the delay of any other-state (except s and "). If the state in C only needs to provide the necessary condition, c will always contain all State. This necessary condition is too loose to produce a correct prompt. In the present invention, a thin "minimum candidate state set" technique is used to exclude loops (⑽) and detours (d_.) (Such as unnecessary Backward neighbors) to get meaningful shape_single. In the present invention, the minimum __combination from u to v _ "direct path" (dircCtpath (S)) 'is only allowed to appear in the money selection state set in a few cases. Brother finds the direct way fe as follows: 14 1220035 ⑻. Suppose v g ^ 幽 处 响 面 ^ 补助 subsidy theorem 4 to establish a non- 彳 ❿ ❿ connection_. (If the subexpression is selected as the least subexpression that includes ♦, the path p is called the least backward path.) Prove · ′ Let E2 be the least subexpression in B that contains u and v. And suppose that E2 and all of its superiors ⑽ce_ «state the good money t hold the material and money and the core riding time table. Let E3 be E2 above E2 and correct the left sub-expression to its right forward neighbor. However, _v is included in one of its subexpressions. Therefore, the E expression does not matter whether V is U (forward) reachable. In other words, the direction of V is Hao Bian's state, which is determined by E2. Think of U (forward) -le If E2 is a selective subexpression, then u and v are included in the subexpression of L2

不此到達V,顯然矛盾。另一方面,如 由II ^ 貝序表達式,E2二(E3.E4),則右Not reaching V, obviously contradictory. On the other hand, if the expression in II ^ order, E2 two (E3.E4), then the right

種可能:如u e E4且v e E3,則u不能到達v 、I π 马矛盾。反之,如UGE3 9 然在所有情形均為矛盾,因此必然存在-反覆子表達式ΕΓ,勺人盾。既 由補助定理2可知,存在…㈣㈤)使得州1 ’而包含。再 #rvrf 1 Kl reachabMu)及 Z e first ( p 丨 使z)為一向後鄰邊,故可找到連接·、 。且明P為非循壞:假設路徑p 呆狀怨P之次數大於卜 w之子路徑與連結z到v之子路徑為向前路徑 ,〜u到 因連結u·之路徑鱗結之路麵成—牡4子路徑中出現1次。現 成連結u到V之路徑,其結果與前 15 面之假設M keaehable⑻矛盾。因此p為非循環。 器所 在找尋符合DTD文件之2元件間可能的路徑時,本發明之XML編輯 使用的方法,包括兩種:One possibility: if u e E4 and v e E3, u cannot reach v and I π. Conversely, if UGE3 9 is contradictory in all cases, it must exist-the reciprocal expression EΓ, the human shield. As can be seen from the subsidy theorem 2, existence ... ㈣㈤) makes state 1 ′ included. Then #rvrf 1 Kl reachabMu) and Z e first (p 丨 make z) a back-adjacent edge, so a connection can be found. And it is clear that P is non-cyclical: Suppose that the number of times of path p dullness P is greater than the path of p and the sub path connecting w to z are forward paths, and the road surface from u to the scale of the path connecting u · is formed. Occurs once in 4 sub-paths. The result of the path from u to V is inconsistent with the previous 15 assumptions M keaehable⑻. Therefore p is acyclic. When searching for a possible path between two components conforming to the DTD file, the method used by the present invention for XML editing includes two methods:

Ull V) gH 時) A.i土屋法 ^ " U ^ V C f-reaChable(^ ^ V ) ' H 4 0 r, 之华人,^。以補助定理4算得由u至v之「非循環」路捏上所有狀態所組成 表不。C所包含的狀態表示可插八於❿間之元件。(如使用者 二。贿路徑上的狀態,則先求得非循環路徑,再以下述循環路徑法計 作法如下: 1)如v e Γ-隊祕le(L0,則令 c={x e ΣΙ x e Γ術hable⑻且 π f-reachable(x)}。 !)如否’設El*為包含之表達心之最小反覆子表達式,八 ^ ^ { X G A^E1)I - e f-reachable(u) v e f_reachable(x)} 〇 ^ 以在使文件1 個可祕人元件的最小年八 ,^ 〇 … 〜,e)滿足6一£⑻。因“"痛2圖。、 言,a不是由㉙由向前路徑可職驗;由^,.對狀態對(以)而 a)而言,c={d,e}。 —或'。因此,(c,Ull V) gH) A.i Tsuchiya method ^ " U ^ V C f-reaChable (^ ^ V) 'H 4 0 r, Chinese, ^. Calculating by the subsidy theorem 4 is composed of all states on the "non-circular" path from u to v. The status contained in C indicates components that can be inserted in between. (Such as user two. The state on the bribe path, first find the non-circular path, and then use the following circular path method to calculate as follows: 1) If ve Γ-team secret le (L0, then let c = {xe ΣΙ xe Γ 术 hable⑻ and π f-reachable (x)}.!) If not 'Let El * be the minimum iterator expression of the included expression mind, 八 ^ {XGA ^ E1) I-e f-reachable (u) ve f_reachable (x)} 〇 ^ In order to make the document a secretable element for a minimum of eight years, ^ 〇 ... ~, e) satisfies 6 a £ ⑻. Because "" pain 2 picture., Say, a is not a valid test of the forward path; by ^ ,. For the state pair (with) and a), c = {d, e}. Or- . Therefore, (c,

Β·_|^£法 “u,v)eH 1220035 紇疋2狀態u與V,其中v (、rcachablc(u)且(u,v ) c丨丨。循環路徑法在Ll與 ""間找尋所有可能的路徑及路徑所包含之狀態,組成集合〇如C不是空集合, 則表不可於1丨與v間加入一元件,r'於此,(u,v)可為向前鄰邊、反覆鄰邊,或 兩者白是。如(u,v)為向前鄰邊,則先以「最小候選狀態集合法」計算。另一 方面,如u為一反覆(iterati〇n)之最終狀態或v為一反覆之最初狀態,或(W幻 為向後鄰邊時,則在u,v之間可插入一新反覆,即將其中所含之符號,加入到c 中。 作法如下: 、 ) 如(u,v)為向如鄰邊’則令 C = { X € Σ| X e f-reachable(u)且 v f f-reachable(x)},且 i) 如對某些E之反覆子表達式ΕΓ,u C last(El*),設El為其中最大 者,則令 Cl 二{ X e A(E1)| V e r-reachable(x)},並令 c = c U C卜 ii) 如對某些E之反覆子表達式E2*,vefirst(E2*),設E2為其中最 大者,則令 C2 = {x e A(E2)| X e f-reachable(u)},且令 c = c 1] C2。 Π } 如否((u,v)為向後鄰邊),則設E3*為C中最大之反覆子表達式,而 滿足 u C last(E3)且 v e first(E3),令 C二A(E3)。 仍以第2圖之Glushkov automaton說明。對狀態對(a,b )而言,c二丨j, 意指在a與b間無元件可插入。而對狀態對(b,d)而言,則可得到C:={c}。對狀 〜對(’ C)因c e firsi(c ),故得C = {c} ’意指使用者可重複c。而對狀蘇對(c c)而言,因其為向後鄰邊,因此可得C二丨。使用者可在兩個反覆之間加入另 反復C °對狀態列(e,f)而言,因為e e last(e )且e C last(E)而E為外部反豐 17 1220035 表達式,因此可得C = {a,b^e}。於此,使用者可以加入該内部反覆多^ 加入-外部反覆。本發^ XML編邮可细财可能力从的元件。 為減少使用者在加入元件時的工作負擔,本發明篇編輯器則在使用者加 入一元件後,即峨她自跑—「必娜」啦,崎用者選擇 加入。在此’输「必糾」技:顧包恤取有繼語法文 件中均在的元件。該定義也適用在起始階段之空白文件。舉-正規表達式·Ύ_ w為例。細·,個必細。術物明心)之後, c (或b)則成為必要元件。 如賴述,「必要元件」是指在包含目前編輯文件之所有文件中’均存在之 元件。因此’-個在♦之間存在之必要元件對應於—狀態z,將滿足「所有 由U到V之路徑均經過z」之條件。這種狀態元件一般稱為戴點 (~tlonpojn〇〇a^^p1^^^ , Γ,^ :件二狀態。尋找節點的方法’對此行業人士而言,為已知技術。任何適合以電 腦計异,找職咖紐,物轉發日㈠彳如:彻—獅「最大流讀 ^^(maximumflow,ikealgorithm), u 與v間的必要元件。如關節點超過一個,則可重複執行該計算而得到正確結果。 β本發明之观[編輯器不只產生可加人元件之提示,同時也產生「元件槽」 从不’以供使用者填入元件。例如,在工作文件中如有二相鄰(副㈣) 兀件_ ^所有包括本工作文#之有效(符合語法)文件均包含至少-個介於該二 相鄰元件間之⑽時’本發明之XML編輯_自動產生—提示,顯示—元件槽, 1220035 ί、使用者填入可填入之元件。這種元件槽即稱為「必要元件槽」。因為要使現所 編輯之文件合於語法’使用者必須在該元件槽的空格内,輸入適當之元件。在產 生一元件槽時,本發明之編輯器也產生一相應之元件選單。因此,使用者可以自 選單中選擇-所需元件,填人元件槽中,完成加人元件之程序。 、另正規表達式(a,(b/c))為例。當系統產生必要元件a時,也同時產生 ik方、a後之必要兀件槽’以及一顯示b&c之選單。因此使用者可在&與。中選 擇其一,填入必要元件槽即可。 值侍提的疋,本發明之XML編輯器,是在工作文件尚未符合語法時,才肇 產生必要元件槽。當所有欠缺之必要元件均已填入,而系統不再產生必要元件槽 時,文件即符合語法。 除自動產生上述必要元件提示及必要元件槽外,本發明之編輯器更可 在使用者要料’產生_元件讀料「制顿槽」。在本㈣观l編輯器 的設計下,當個者希望加人—元件時,鮮必標移至要力认元件之確切位 置。使用者只要歡-已存在之元件做林考·(例如反白),而向系統請求 產生對在财相細近之元件,所材能加蚊元件之。«明之皿 編輯器即谢傷爾你。觸咐㈣㈣「翻元件槽」, 而在_中可以加入的元件,則稱為「選用元件」。本發明之編輯器也產生一選 Z陳佩·。㈣爛W f件槽中’ 元成加入元件。其方式與在必要蝴曹_。_轉符合語法。 給定一正規«式㈣|。於初亀,狐物產生a綱為必要 19 1220035 7 ’文件即為sab卜在利用循環路徑法計算之後,產生-候選狀態集合c ’對 、、' )而S ’ C-(} ’對狀悲對“ 而言,卜而對狀態對(b 〇 而言,cu}。因此,本發明之XML編輯器在狀態s與a之間,及在b與「 之間可產生一選用元件槽,但在a與b之間則無。 口 9航意的是’元件槽只是元件的框架’而不是真的元件。也就是說,元件憎 只是呈現物細峨,㈣恤作樹崎。觀編輯器可 以應使用者要求,將元件槽自使用者介面中移除。 本發明之XML編輯器產生必要元件之提示及選用元件槽之方法,如第3圖 所示。第3圖顯示本發明XML編輯器產生必要元件提示及選用元件槽之方法、: 程圖。如_示,在⑽)時,XML編輯器取得存在工作文件中—對相連狀^ u及V。在(302)計算而得到uAv之相鄰關係(edge)(u,v)。在⑶3)將所 得之相鄰關係(u,v)與Η比較後’(HM中之相鄰關係之集合),決定(u ^ 是否Η中之元素。如(U,V),H,則在(3〇4)找出由所形成的路徑中’ 所存在的節點,而在(3〇5)顯示該節點所代表之狀態,成為選單。於(3〇6)使孀 用者在顯示之狀態選單中選擇而輸人—必要元件,而在⑽)XML編輯器將2 必要元件加入該文件中,並在相對應之G|ushk〇va咖咖η中,間加入气 狀態’回到步驟⑽)。反之,如在⑽)之結果為u v) e h,則_編 1 器在⑽者是料求__元賴。如制者有此請求,則編輯耳 器在謂尋找可能的選用元件。如找到可能_元件,則在⑶g)顯= 用元件槽及可能的賴元件,以供使用者填人。如個者於(川)麵示之^ 20 1220035 用文件槽中填入選用元件,則編輯器在(312)將該元件填入工作文件中之適當 位置。於(313) XML編輯器再度判斷使用者有無請求顯示其他選用元件槽,如 是’則回到步驟(309),否則於(314)完成操作。如在(311)使用者拒絕所有 建議之元件,則操作移至(313)。如在步驟(309)中找不到選用文件,則在(3 15) 顯不「無選用元件」或相對應之提示,移至(313)。而在步驟( 308)如無使用 者可選用兀件之請求,則操作移至(314),結束操作。 在上述過轾中,如表達式E為一多重表達式,亦即E中所包含之狀態在前 後順序中重複出現,則可將出現在後的狀態,以其他狀態取代。在本發明之XMl g 編輯為產生介於狀態間之元件槽過程中,同時也計算—狀態集合c,^ Σ 可以對照到一候選元件列C,£Z,,為元件射之取代,其巾 Σ |y origmal(x) ’對某些xe c卜亦即,y取代X,存在c,中。而當使用者選擇 c中之兀件,例如y,則本發明之XML編輯器將乂π對照到π。,而在工作 文件中加入X。 本七月之4 σ DTD之XML文件編輯II可以作為—個泛用於各種使用者介 面的文件職[置於使时介_的下層,不受使用者介_魏所限制。因 系先廠商可以在本發明XML文件編輯器上,設計各種不同的使用者介面,不 論是樹狀魏、呈現鶴、絲單鄕。以下喊單做时介面為例,說明本 發明XML文件編輯器在應用卜女 …用上之作法。本發明之專利範圍不限於此實例之作 法,自不待言。 在本發明之實施例中,可以一醫療用⑶A之⑽為例。利用本發明之狐 21 牛扁輯叩及其表單型使用者介面,產生一符合丁[)之文件。第4圖即表 丁乂本^月XML文件編m建立—文件時,其使用者介面之頂層表單示意圖。 如圖所示,在表單中顯示兩層之元件,levek)ne含有2必要子元件dinica卜 headu 及 body。而 cimiCaj —d〇cument_header 則含有 5 個必要子元件。 body則3 _ 1必要兀件槽’作為其子層,使用者可在讀槽中加人元件。上述必 要元件提及必要兀件槽疋由編輯器自動產生。在系統中使用—參數lFh — ΜΠ践〜在喊不—表單時’應顯示之元件層數。在—表單内,位在最底 層的兀件貞Μ超連結(hypedmk)之型式呈現,以連結至其子元件(如子元件 存幻。當使用者選擇該元件時,即可顯示—子表單,在其上顯示其子層之元件 (以及孫層元件,以下_)。而子表單仍可能有其子表單,因此該子表單可以 無限延展。 應注意的是’如LEVEL —LIMIT值較大時,所顯示之表單基本上形成一樹 狀結構。對-般使时㈣,形歧„脈纟_,不㈣解其輸人或檢視元 件之位置’在視覺上也顯得混亂。因此一般建議將LEVELUMi丁設定為一小 數值’以使畫面較接近於―表單,而非樹狀結構。當然任㈣於斯藝之人士均可 將LEVEL-L謝之值設為—適當值,而破其表單齡之層數。職單型魏 文件編輯^言’相當重要,因表單型式不易同時· xml文件之全貌。 為顯示所有選用元件槽之按鈕, 如第4圖所示,每一表單均附有二按鈕, -為隱藏已顯示之元件槽之餘。另—種方式則可只顯示位在選定元件附近之選 用元件槽。當制者將游標移至—元件時,XML編輯㈣出現—小「⑽聊从」 圖標(_),顯示於該谢後(同—列),如第4圖所示。如使用者按下該圖標,」 22 1220035 則在該元件附近之遠用元件槽即行出現,如第5圖所示。在此鄰近範圍設定為2 因此在指定元件之前及之後所顯示之選用元件槽最多為2。反之,如使用者未按 下「OPTIONAL」圖標’而將指標移至其他位置,則該「〇pTI〇NAL」圖標即行 消失。 另如第5圖所示,使用者可以在XMU輯器自動產生之候選^件表單中, 選擇-元件填人該Tt件射。假設使用者在本圖中選擇其中之「_㈤」·, 則產生一 section元件,再按下該「secti〇n」元件,而產生一子表單,而使用者即 可在此子表單編輯「section」之子元件及孫元件。第6圖顯示使用者在此子表單鲁 中加入某些屬性及子元件後之表單示意圖。,屬性顯示在子元件之前。 士同第6圖所示’吾使用者將指標移至一元件或一屬性時,三個小圖標 「C)P™NAL」'「DELETE」$「C_GE」即行產生,顯示在就件或屬性之 同-列位置。其中’「DE咖」(刪除)與「CHA職」(修改)只在該元件容 許刪除或修改時,才會出現。 本I月之XML文件編輯器提供—表單型使用者介面,支援限定層數的樹狀 、 斤、扁輯文件之可調的、動態的結構。本發明之XML·文件編輯器可φ 、、顧慮文件之語法問題,而在使用者需要時產生元件槽,以供使用者 填入^^件,這種罕开 又早i XML編輯器也可作為一基於XML資料模型之表單產生 器。 本發明之;XML 以支援各種不依附於Β · _ | ^ £ Method "u, v) eH 1220035 纥 疋 2 states u and V, where v (, rcachablc (u) and (u, v) c 丨 丨. The circular path method is in Ll and " " To find all possible paths and the states contained in the path, forming a set. If C is not an empty set, the table cannot add an element between 1 and v, r 'here, (u, v) can be a forward neighbor Edges, repeated adjacent edges, or both. If (u, v) is a forward adjacent edge, then the "least candidate state set method" is used to calculate it. On the other hand, if u is an iterati (n) The final state or v is a repeated initial state, or (w when W is a backward neighbor, a new iteration can be inserted between u and v, that is, the symbol contained in it is added to c. The method is as follows: ,) If (u, v) is a neighbor edge, then let C = {X € Σ | X e f-reachable (u) and vf f-reachable (x)}, and i) as for some E Iterative sub-expression Γ, u C last (El *), letting El be the largest one, then let Cl be {X e A (E1) | V e r-reachable (x)}, and let c = c UC. ii) If E2 *, vefirst (E2 *) is an iterative expression for some E, let E2 be Are the largest, then let C2 = {x e A (E2) | X e f-reachable (u)}, and let c = c 1] C2. Π} If no ((u, v) is the backward neighbor), then let E3 * be the largest iterative subexpression in C, and satisfy u C last (E3) and ve first (E3), let C two A ( E3). Glushkov automaton illustrated in Figure 2 is still used. For the state pair (a, b), c = j means that no element can be inserted between a and b. For the state pair (b, d), we get C: = {c}. Paired state ~ paired (’C) because c e firsi (c), so C = {c} ′ means that the user can repeat c. For the pair of pairs of su (c c), since it is the back neighbor, we can get C 2 丨. The user can add another iteration C ° between the two iterations. For the status column (e, f), because ee last (e) and e C last (E) and E is an external anti-fungal expression 17 1220035, This gives C = {a, b ^ e}. Here, the user can add the internal iteration ^ join-external iteration. This post ^ XML Zip can be a fine-tuned component. In order to reduce the user's workload when adding components, the editor of the present invention, after the user adds a component, is Eta running-"Bina", and the user chooses to join. Here's the "must-correct" technique: Gu Baoshou takes the elements that are present in the grammar file. The definition also applies to blank documents at the initial stage. Take the -regular expression Ύ_ w as an example. Fine, one must be fine. C (or b) becomes a necessary element after the object is conscious. As stated, "essential components" are components that are present 'in all documents containing the currently edited document. Therefore, a necessary element existing between ♦ corresponds to the state z, which will satisfy the condition that "all paths from U to V pass z". This state element is generally called a wearing point (~ tlonpojn〇〇a ^^ p1 ^^^, Γ, ^: two states. The method of finding nodes is a known technology to those in the industry. Any suitable method The computer calculates the difference, finds a job, and forwards the day. For example: Che-Lion "maximum flow ^^ (maximumflow, ikealgorithm), a necessary element between u and v. If there is more than one joint point, you can repeat this Calculated to get correct results. Β View of the invention [The editor not only generates prompts for adding components, but also generates "component slots" that are never 'for users to fill in components. For example, if there are two Adjacent (auxiliary) elements_ ^ All valid (syntactically) documents including this working paper # contain at least one time between the two adjacent elements' XML editing of the present invention _ automatic generation-prompt , Display—component slot, 1220035 ί, the user fills in a component that can be filled in. This component slot is called a "essential component slot". Because the document being edited now conforms to the grammar, the user must be in the component In the space of the slot, enter the appropriate component. When the component slot is created, the editor of the present invention also generates a corresponding component menu. Therefore, the user can select the required component from the menu, fill it in the component slot, and complete the process of adding components. Another regular expression ( a, (b / c)) as an example. When the system generates the necessary component a, it also generates the ik square, the necessary component slot after a ', and a menu showing b & c. Therefore, the user can choose between & and You can choose one of them and fill in the necessary component slots. The value editor, the XML editor of the present invention generates the necessary component slots only when the working file does not conform to the grammar. When all the necessary components that are missing are When it is filled in, and the system no longer generates the necessary component slots, the file will comply with the syntax. In addition to the above-mentioned necessary component prompts and necessary component slots are automatically generated, the editor of the present invention can generate _component readings when the user wants them "Stop slot". In the design of this editor, when an individual wants to add a component, it must be marked to the exact position where the component must be recognized. Users only need to create existing components. Lin Kao (for example, highlighting), and Ask the system to generate components that are close to the wealth, and you can add mosquito components. «Ming Dish Editor is Xie Shanger. Touch" ㈣㈣turn the component slot ", and you can add components in _, It is called "optional components". The editor of the present invention also generates a selection of Z Chen Pei. The element is added to the element in the slot. The method is the same as necessary. Define a regular «style㈣ |. At the beginning of the year, the fox is necessary to produce a class 19 1220035 7 'The file is sab. After calculation using the circular path method, a set of candidate states c' pair ,, ') and S 'C- ()' For the state of sadness, "For the state of (b 0, cu). Therefore, the XML editor of the present invention is between states s and a, and between b and" An optional component slot can be created between them, but not between a and b. The idea of port 9 is that the component slot is just the frame of the component, not the real component. In other words, the element hate is just a small piece of presents. The View Editor can remove component slots from the user interface at the user's request. The XML editor of the present invention generates prompts for necessary components and a method for selecting component slots, as shown in FIG. 3. FIG. 3 shows a method for generating necessary component prompts and selecting component slots by an XML editor according to the present invention, and a flowchart. As shown in _, at ⑽), the XML editor gets stored in the working file-paired states ^ u and V. Calculate at (302) to get the adjacent relationship (u, v) of uAv. (3) After comparing the obtained adjacent relationship (u, v) with Η '(a set of adjacent relationships in HM), decide whether (u ^ is an element in Η. If (U, V), H, then Find the existing node in the path formed by (304), and display the status represented by the node in (305), and become a menu. In (306), make the user display Select in the status menu and input the necessary components, and in ⑽) the XML editor adds 2 necessary components to the file, and in the corresponding G | ushkavava coffee, add the gas state 'back Step ⑽). Conversely, if the result in u) is u v) e h, then the _ editor 1 is expected to find __yuanlai. If the producer has this request, the editor is presumably looking for possible optional components. If a possible component is found, it is displayed in ⑶g) = using the component slot and possible components for the user to fill in. If the individual shows ^ 20 1220035 on the (Sichuan) surface to fill the optional component with the file slot, the editor fills the component in the appropriate position in the working file at (312). At (313), the XML editor judges again whether the user has requested to display other optional component slots. If yes, it returns to step (309), otherwise it completes the operation at (314). If the user rejects all suggested components at (311), the operation moves to (313). If the optional file cannot be found in step (309), then "No optional component" or the corresponding prompt is displayed in (3 15), and go to (313). However, if there is no request for the user to select a component in step (308), the operation moves to (314), and the operation ends. In the above process, if the expression E is a multiple expression, that is, the states contained in E repeatedly appear in the order, then the states appearing later can be replaced by other states. In the process of editing the XMl g of the present invention to generate a component slot between states, it is also calculated-the state set c, ^ Σ can be compared to a candidate component row C, £ Z, which is replaced by the component shot, and its towel Σ | y origmal (x) 'For some xe c, that is, y replaces X, and exists in c ,. When the user selects a component in c, such as y, the XML editor of the present invention compares 乂 π to π. And add X to the working file. The 4 σ DTD XML Document Editor II of this July can be used as a document for a variety of user interfaces [placed in the lower layer of Shishijie_, not subject to user_Wei restrictions. Because the first manufacturers can design a variety of user interfaces on the XML file editor of the present invention, whether they are tree-like Wei, presenting cranes, and silk bills. The following interface is used as an example to illustrate the application of the XML file editor in the present invention. It is needless to say that the patent scope of the present invention is not limited to the method of this example. In the embodiment of the present invention, a case of a medical CDA can be taken as an example. Utilizing the fox 21 of the present invention and its form-type user interface, a document conforming to Ding [) is generated. Figure 4 is the diagram of the top-level form of the user interface when the XML file is created and created in this month. As shown in the figure, two layers of elements are shown in the form. Levekne contains 2 necessary sub-elements dinica, headu, and body. The cimiCaj —d〇cument_header contains 5 required child elements. The body is 3 _ 1 necessary element slot ′ as its sublayer, and users can add components to the slot. The necessary components mentioned above mentioned necessary element slots are automatically generated by the editor. Used in the system-parameter lFh-ΜΠ practice ~ when shouting no-form number of component layers that should be displayed. In the—form, the bottom-most element of the HyperMk (hypedmk) is presented to link to its child components (such as sub-components are magic. When the user selects the component, it can be displayed—the sub-form , On which the components of its child layer (and grandchildren's components, below_) are displayed. However, the child form may still have its child form, so the child form can be infinitely extended. It should be noted that 'such as LEVEL —LIMIT value is larger At the same time, the displayed form basically forms a tree-like structure. Right-to-time, distorted „pulse__, without comprehending the position of the input or viewing components' also seems confusing visually. Therefore it is generally recommended to LEVELUMi Ding is set to a small value 'to make the picture closer to the form, rather than a tree structure. Of course, anyone who is a Siyi can set the value of LEVEL-L Xie to an appropriate value, and break the form The number of layers in the age. The job document type Wei file editor is very important, because the form type is not easy at the same time. The full picture of the xml file. In order to show all the buttons of the optional component slot, as shown in Figure 4, each form is attached Two buttons,-to hide the displayed element In addition to the slot. Another way is to display only the selected component slot located near the selected component. When the producer moves the cursor to—the component, the XML editing window appears—the small “⑽Talk from” icon (_) displays After the thank you (same column), as shown in Figure 4. If the user presses the icon, "22 1220035" will appear in the remote component slot near the component, as shown in Figure 5. Here The proximity range is set to 2 so the maximum number of optional component slots displayed before and after the specified component is 2. Conversely, if the user moves the pointer to another position without pressing the "OPTIONAL" icon, the "〇pTI〇NAL "The icon disappears. As shown in Figure 5, the user can select the-component to fill in the Tt piece in the candidate form automatically generated by the XMU editor. Suppose the user selects one of the" _㈤ "·, a section component is generated, and the" secti0n "component is clicked to generate a subform, and the user can edit the subcomponents and grandchild components of the" section "in this subform. Figure 6 shows User adds some attributes to this subform Schematic diagram of the form after the child component. The attributes are displayed before the child component. As shown in Figure 6, "When my user moves the pointer to a component or an attribute, three small icons" C) P ™ NAL " "DELETE" $ "C_GE" is generated in a row and displayed in the same row as the item or attribute. Among them, "DE DE" (deleted) and "CHA position" (modified) only appear when the component is allowed to be deleted or modified. This month's XML document editor provides a form-based user interface that supports the adjustable, dynamic structure of tree-shaped, simple, and flat files with a limited number of layers. The XML · document editor of the present invention can worry about the grammatical problems of the file, and generates component slots when the user needs it, so that the user can fill in the ^^ files. As a form generator based on XML data model. The invention; XML to support a variety of non-dependent

文件編輯器’對使用者介面之型式而言,係屬中立,因而可 文件結構之介面佈置型式。 23 本發明之XML文件編龍使得使用者可以在無須顧慮違反語法的情形下, 建立及編~合於DTD之文件。在文件建立及編_程巾,本發明之文件編 \可以自動產生必要儿件之提示及必要元件槽’用以料使用者產生合於語法 史有效文件。該編輯器並可依使用者之請求產生選用元件槽。其結果,使用者主 要的工作只是在㈣所產生的選單中選擇咖之元件,填人元件射。使用者不 而具備胤之專門知識,也不需瞭解文件之細,即可建立並編輯符合_ 之文件。 本發明之XML編輯器不受使用者介面之型態限制,可以支援各種型態的使 用者介面’包括樹狀型、呈現型及表單型’特別是結合本發明之符合_處理 方式與表單的簡單,可以提供—個簡㈣具有表單型使用者介面的州匕編輯 器。本發明的表單型XML文件編輯器並可作為基於xml資料模型之表單產生 器使用。 使用本發明XML文件編輯器時,使用者的行為基本上是受系統控管,但系 統對使用棚接予過錄制。制者可在㈣讀選單帽胁何元件·加? 元件之糊㈣。「符合咖」㈣並娜糊卿。另一方面, 由於使用者的操作是在控管之下,耻使用者所編輯敝件,不會違反語法。七 用者即不需顧慮任何文件違反語法的問題。 以上是對本發明XML文件編輯器之說明,習於斯藝之人士不難由上述之言 明,明瞭本發明之精神進而作出不同的㈣與變化,唯只要不超出本發明之升 神,均應包含於其申請專利範圍内。 五、【圖式之簡要說明】 24 1220035 第1圖表示一個正規表達式(expression) E,) *,c )之 Glushkov 自動機。 第2圖表不一個正規表達式) ε,‘ε=~,纹〆力*之Giushk〇v 自動機。 乐3圖表不本發明XML文件編輯器產生「必要元件」提示及「選用元件槽」 之流程圖。 第圖表不本發明XML文件編輯器一實例中之使用者介面之頂層表單畫面。 第5圖表示其選用元件槽之晝面。 第6圖表示其多層巢狀表單之顯示晝面。 拾、申請專利範圍: 種XML文件編輯為,提供使用者在一工作文件中加入或刪除文件元件, 而將σ亥工作文件儲存為一 XML文件檔;其特徵在於,該文件編輯器可 就符合該文件格式定義之相鄰兩元件㉔^產生一第三元件之選單,作為 使用者之提示;該元件選單所包括之第三元件2,若加入該兩元件讀 之間,疏兀件對Z|與z以及元件對z與Ζι+丨之關係皆符合該文件格式定義。 2.如申請專利範圍第W所示之XML文件編輯器,其中該麗文件編輯器係 以下式判斷該相鄰兩元件之關係是否符合所定之文件格式定義: 設G為該工作文件之-元件所對應之正規表達式E之㈤細自動機, z2,…,zp}表示該元件之子元件對應於G中之狀態序列,的,s表g中之開 始狀悲,ζρ-ί,f表G中之結束狀態;為相鄰之兩狀態,丄沾卜卜 p CN ;若:The document editor 'is neutral to the type of user interface, so it can arrange the type of interface of the document structure. 23 The XML file editor of the present invention enables users to create and compile files that are compatible with DTDs without worrying about grammatical violations. In the document creation and editing process, the document editing of the present invention can automatically generate the necessary children's prompts and necessary component slots' for the user to generate valid documents suitable for grammar history. The editor can also generate optional component slots at the request of the user. As a result, the user's main task is to select the components of the coffee in the menu generated by the player, and fill in the components to shoot. Users not only have the specialized knowledge of _, but also do not need to know the details of the files, they can create and edit the files matching _. The XML editor of the present invention is not limited by the type of the user interface, and can support various types of user interfaces 'including tree type, presentation type and form type', especially in combination with the conformance_processing method and form of the present invention. Simple, can provide-a simple state knife editor with a form-based user interface. The form-type XML file editor of the present invention can also be used as a form generator based on the xml data model. When using the XML file editor of the present invention, the user's behavior is basically controlled by the system, but the system has recorded the use of the studio. Manufacturers can read the menu caps about the components and add the components. "Meet the coffee" ㈣ and Na paste Qing. On the other hand, since the user's operation is under control, the files edited by the user will not violate the grammar. Seven users do not need to worry about any file violation of syntax. The above is the description of the XML file editor of the present invention. It is not difficult for those who are accustomed to Siyi to understand the spirit of the present invention and make different changes and changes. As long as it does not exceed the ascension of the present invention, it should include Within the scope of its patent application. V. [Brief Description of the Schema] 24 1220035 Figure 1 shows a Glushkov automaton of a regular expression (expression) E,) *, c). The second graph is not a regular expression) ε, ‘ε = ~, Giushkov automaton of 〆〆 力 *. The Le 3 chart is not a flowchart of the "essential component" prompt and "select component slot" generated by the XML file editor of the present invention. The first diagram is a top-level form screen of the user interface in an example of the XML document editor of the present invention. Fig. 5 shows the day face of the component slot. Fig. 6 shows the daylight display of its multilayer nested form. Scope of patent application: This kind of XML file editing is to provide users with the ability to add or delete file elements in a working file, and to save the σ Hai working file as an XML file. It is characterized in that the file editor can comply with The adjacent two components defined in the file format ㉔ ^ generate a third component menu as a user's prompt; the third component 2 included in the component menu, if added between the two component reading, the sparse component will be Z The relationship between | and z and the component pair z and Zι + 丨 conform to the file format definition. 2. The XML file editor as shown in the W of the patent application scope, wherein the Li file editor judges whether the relationship between the two adjacent components meets the defined file format definition by the following formula: Let G be the-component of the working file Corresponding regular automaton of the regular expression E, z2, ..., zp} indicates that the sub-elements of this element correspond to the sequence of states in G, where s is the initial state in g, ζρ-ί, f is G The end state in the middle; for the two adjacent states, 丄 janb p CN; if:

Zl+1 G reachable(z,),reachable(z,)^^ G t ^ , ^ 〇 25Zl + 1 G reachable (z,), reachable (z,) ^^ G t ^, ^ 〇 25

Claims (1)

1220035 第1圖表示一個正規表達式(expression) E,) *,c )之 Glushkov 自動機。 第2圖表不一個正規表達式) ε,‘ε=~,纹〆力*之Giushk〇v 自動機。 乐3圖表不本發明XML文件編輯器產生「必要元件」提示及「選用元件槽」 之流程圖。 第圖表不本發明XML文件編輯器一實例中之使用者介面之頂層表單畫面。 第5圖表示其選用元件槽之晝面。 第6圖表示其多層巢狀表單之顯示晝面。 拾、申請專利範圍: 種XML文件編輯為,提供使用者在一工作文件中加入或刪除文件元件, 而將σ亥工作文件儲存為一 XML文件檔;其特徵在於,該文件編輯器可 就符合該文件格式定義之相鄰兩元件㉔^產生一第三元件之選單,作為 使用者之提示;該元件選單所包括之第三元件2,若加入該兩元件讀 之間,疏兀件對Z|與z以及元件對z與Ζι+丨之關係皆符合該文件格式定義。 2.如申請專利範圍第W所示之XML文件編輯器,其中該麗文件編輯器係 以下式判斷該相鄰兩元件之關係是否符合所定之文件格式定義: 設G為該工作文件之-元件所對應之正規表達式E之㈤細自動機, z2,…,zp}表示該元件之子元件對應於G中之狀態序列,的,s表g中之開 始狀悲,ζρ-ί,f表G中之結束狀態;為相鄰之兩狀態,丄沾卜卜 p CN ;若: Zl+1 G reachable(z,),reachable(z,)^^ G t ^ , ^ 〇 25 1220035 達(reach)之狀態之集合; 則為為邊7G件對々與Z| —I之關係符合所定之文件格式定義。 3 士申明專利範圍第1項所示之XML·文件編輯器,其中,該XML·文件編輯器 可以下式產生一包含該第三元件z之集合C,而以選單表示: 。' 1+1) $ Η,Η為&lt;3中之所有鄰邊之集合,G為該工作文件之一元件所對 C之正規表達式Ε之Glushkov自動機; 設Σ表G中對應於所有元件之狀態之集合;A(E1)表子表達式ei所含狀態之 亦a ’ i leachable(Zj)表在G中可由狀態z,依向前鄰邊到達之狀態之集合,則·鲁 如 e f-reachable(Zj),則令 C { z € Σ 丨 z G f-reachable(Zi)且 zi+1 e f-reachable(z)}; 如z1+丨g f-reachabie(Zi),設已丨*為表達反覆子表達式且包含&amp;與&amp; 之最小者,令 c—{ z e A(E1) | z c f:reachable(z,)或 zi f i e i:reachable⑵ j。 4·如申請專利範圍第1項所示之XML文件編輯器,其中,該XML文件編輯器 可以下式產生一包含該第三元件z之集合C,而以選單表示: φ 當(心21+1)^:11,Η為G中之所有鄰邊之集合,G為該工作文件之一元件所對 應之正規表達式Ε之Glushkov自動機; 設Σ表G中對應於所有元件之狀態之集合;A(E1)表子表達式£1所含狀態之 集合;Reachable(z,)表在G中可由狀態2|依向前鄰邊到達之狀態之集合,則: 如(4, zi+1)為向前鄰邊,則令 C = { z C Σ| z C f-reachable(z〇i ζ,+ι £ f-reachable(z)},且 26 如對某些E之反覆子表達式El*,z, C last(El*),設El為其中最 大者,則令 Cl 二{ zC A(E1)| zi+! e i:reachable(z)},並令 C = CU Cl ; U) 如對某些E之反覆子表達式E2*,zlH C first(E2*),設E2為其中最 大者,則令 C2二{z e A(E2)| z e f-reachable(Zi)},且令 C = CUC2 ; (ζι’ζΗ)為向後鄰邊,則設E3*為E中最大之反覆子表達式,而滿足Zie laSt(E3)且 Z1+1 e first(E3),令 C = A〇S3)。 如申凊專利範圍第丨項所示之XML文件編輯器,其中,當加入一第三元件z 一牛對Zl與Ζμι之間後’該ΧΜΙ^文件編輯器可在元件對ζ;與z之間以及元 件對z與ζ1+ι之間自動產生必要之元件,而使該工作文件符合所適用之語法; 其Ψ^ Ζι Λ z (z與Zi+1)間之必要元件係包括Glushkov自動機G中,7。與z (z 與4+1)之間的關節點, ’即從z,到z (從2到Zi+!)之間所有路徑均通過之狀態。1220035 Figure 1 shows a Glushkov automaton of a regular expression E,) *, c). The second graph is not a regular expression) ε, ‘ε = ~, Giushkov automaton of 〆〆 力 *. The Le 3 chart is not a flowchart of the "essential component" prompt and "select component slot" generated by the XML file editor of the present invention. The first diagram is a top-level form screen of the user interface in an example of the XML document editor of the present invention. Fig. 5 shows the day face of the component slot. Fig. 6 shows the daylight display of its multilayer nested form. Scope of patent application: This kind of XML file editing is to provide users with the ability to add or delete file elements in a working file, and to save the σ Hai working file as an XML file. It is characterized in that the file editor can comply with The adjacent two components defined in the file format ㉔ ^ generate a third component menu as a user's prompt; the third component 2 included in the component menu, if added between the two component reading, the sparse component will be Z The relationship between | and z and the component pair z and Zι + 丨 conform to the file format definition. 2. The XML file editor as shown in the W of the patent application scope, wherein the Li file editor judges whether the relationship between the two adjacent components meets the defined file format definition by the following formula: Let G be the-component of the working file Corresponding regular automaton of the regular expression E, z2, ..., zp} indicates that the sub-elements of this element correspond to the sequence of states in G, where s is the initial state in g, ζρ-ί, f is G The end state in the middle; for the two adjacent states, 丄 丄 卜 p CN; if: Zl + 1 G reachable (z,), reachable (z,) ^^ G t ^, ^ 〇25 1220035 reach (reach) The set of states; is the relationship between the 7G edge confrontation and Z | —I in accordance with the defined file format definition. 3. The XML · document editor shown in Item 1 of the Patent Scope, wherein the XML · file editor can generate a set C containing the third element z and express it as a menu:. '1 + 1) $ Η, Η is the set of all adjacent edges in <3, G is the Glushkov automaton of the regular expression E of C for one element of the working file; Let Σ table G correspond to all The set of states of the component; the state contained in the subexpression ei of the A (E1) table is also a 'i leachable (Zj), which is the set of states in G that can be reached by the state z, according to the forward neighbor, then Lu Ru e f-reachable (Zj), then let C {z € Σ 丨 z G f-reachable (Zi) and zi + 1 e f-reachable (z)}; such as z1 + 丨 g f-reachabie (Zi), let丨 * is the minimum expression of iterative subexpressions and contains &amp; and &amp;, let c— {ze A (E1) | zcf: reachable (z,) or zi fiei: reachable⑵ j. 4. The XML file editor as shown in item 1 of the scope of patent application, wherein the XML file editor can generate a set C containing the third element z as follows, and is expressed by a menu: φ 当 (心 21+ 1) ^: 11, Η is the set of all neighboring edges in G, G is the Glushkov automaton of the regular expression E corresponding to one element of the working file; Let Σ table G be the set of states corresponding to all elements ; A (E1) is a set of states contained in the subexpression £ 1; Reachable (z,) is a set of states in G that can be reached by state 2 | according to the forward neighbor, then: as (4, zi + 1 ) Is the forward neighboring edge, then let C = {z C Σ | z C f-reachable (z〇i ζ, + ι £ f-reachable (z)}, and 26 as the iterator expression for some E El *, z, C last (El *). Let El be the largest one, then let Cl be {zC A (E1) | zi +! Ei: reachable (z)}, and let C = CU Cl; U) as For some E sub-expressions E2 *, zlH C first (E2 *), let E2 be the largest one, then let C2 {ze A (E2) | ze f-reachable (Zi)}, and let C = CUC2; (ζι'ζΗ) is the backward neighbor, then let E3 * be the largest repeater expression in E And satisfy Zie laSt (E3) and Z1 + 1 e first (E3), let C = A0S3). For example, the XML file editor shown in item 丨 of the patent application scope, wherein when a third element z is added between a pair Z1 and Zμι, the XM1 ^ file editor can be in the element pair ζ; and z Necessary components between z and ζ1 + ι are automatically generated, so that the working document conforms to the applicable grammar; the necessary components between Ψ ^ Zι Λ z (z and Zi + 1) include the Glushkov automaton G, 7. The joint point with z (z and 4 + 1), that is, the state where all paths from z, to z (from 2 to Zi +!) Pass. 件,而將該工作文件儲存為一 Xml 用以在使用者在—讀文件巾加人酬除文件元 ML文件檔,其特徵在於,該XML文件編輯 27 1220035 方法包括在使用者編輯文件時,可就符合該文件格式定義之相鄰兩元件讀 /糾產生1二兀件之選單,作為使用者之提示;該嫌選單所包括之第三元 件7」,右加入或兩兀件4與?例之間,能使元件對&amp;與z以及元件對z與〜1 之關係皆符合該文件格式定義。 8. 如申請專利範圍第7項所示之觀文件編輯方法,其中判斷該相鄰兩元件 之關係衫符合所定之文件格式定義之方法包括: 《G為缸作文件之一凡件所對應之正規表達式£之〇㈣⑽自動機卞卜 Up}表示該元件之子元件對應於G中之狀態序列,z丨二s,5表〇中之開 始狀態;zp=f,f表G中之結束狀態;Z|和Ζμι為相鄰之兩狀態,, ρ εΝ,若: Z,+ I ereachable(Z|) ’ reachaWe㈤表在G中可由狀態Ζι,依G中之鄰邊關係到 達(reach)之狀態之集合; 則涊為該元件對々與Zj+l之關係符合所定之文件格式定義。 9. 如申請專利範圍第7項所示之XML·文件編輯方法,其中,該第三元件z之 集合C係依下式產生,而以選單表示: 當(z,,zi+丨)g Η,Η為G中之所有鄰邊之集合,G為該工作文件之一元件所對 應之正規表達式Ε之Glushkov自動機; 設Σ表G中對應於所有元件之狀態之集合;Α(Ει)表子表達式ρ】所含狀態之 集合,f-reachable(Zi)表在G中可由狀態4依向前鄰邊到達之狀雜之梦、八,則· 如 zi+1 € f-reachable(Zi),則令 C { z G Σ | z e i-reachable(Zj)且 Zj+i C f-reachable(z)}; 28 如〜❿ach敵⑹’設w為表達式E之反覆子表達式且包含… 之最小者,令 、1 C={ z e A(E1) I z e f-reachable(z,)^ z,+ I e f-reachable(z)} 〇 該第三元件z之 10.如申請專利範圍第7項所示之XML文件編輯方法,其中 集合C係依下式產生,而以選單表示: 當心+l)eη ’ η為G中之所有鄰邊之f合,g為該讀文件之—元件所對 應之正規表達式E之Glushkov自動機; 设Σ表G中對應於所有元件狀熊 狀心之木合,A(E1)表子表達式E1所含狀態之 集合如_叫,)表在G中可由狀態破向前丨達之狀態之集合,則: , P^C=izGl|zCf,eacl^ f-reachable(z)},且 U1)如對某些E之反覆子表達式,ζ (:峰Γ),設為其中最 者則々 Cl —tzeACElVhCf-reachablea)},並令。二〔。 C1 ; 如對某些E之反覆子表達式E2*,〜e耐㈣,設e2為其中最# 大者’則令 C2二{z e A(E2)| z e f_reachable(Z|)},且令 pc uC2; (…)為向物邊,則設F3為E巾最大之反覆子表達式,而滿足e laSt(E3)且 Ζί+1 e flrst(E3),令 C = A(E3)。 專j乾圍第7項所示之XML文件編輯方法,另包括—步驟,即在加 —— 一〈叶 Z方、7L件對Zi與Zi+1之間後,在元件對。與Z之間以及元件對z 29 11. 1220035 人 ]自動產生必要之元件,而使該工作文件符合所適用之語法;其中, d、2(2與4+!)間之必要元件係包括Giushk〇v自動機G中 '與與心1)之 間的關即點’即從到樣Z到zl+l)之間所有路徑均通過之狀態。 12. 如申清專利範圍第i項所示之狐文件編輯方法,另包括一步驟,即在加 入一第二凡件Z於元件對4與zl+丨之間後,若在元件對Ζι與z (z與Ζ|+ι)之間 、 、、要元件’且(zi,z) 0 Η ((乙ζιΗ) ί Η),Η為G中之所有鄰邊之集合, 則在兀件對Zl與Ζ(Ζ與7別)之間自動產生一元件槽,供使用者加入元件;其 人(z舁zi+丨)間之必要元件係包括Giushk〇v自動機G中,&amp;與z &amp;與馨 Z,+丨)之間的關節點,即從z』z(從z到知|)之間所有路徑均通過之狀態。 13. —種XML文株地&amp;叩 ^ 又仟、、扁輯為,包括一使用者介面,以提供使用者在一工作文件中 加入或刪除文件元件,而將該工作文件儲存為一 XML文件標;其特徵在於, 4 XML文件編輯器可就符合該文件格式定義之相鄰兩元件^與“I產生一第 一兀件之解,作為使用者之提示;該元件選單所包括之第三元件z,若加 純凡件㈣Z,+1之間,能使元件對々與z以及元件對z與Zlfl之關係皆符 合該文件格式定義。 14. 如申請專利範圊笛 一 乂 、 項所不之XML文件編輯器,其中該XML文件編輯器 係下式判斷讀相鄰兩元件之關係是否符合所定之文件格式定義: 设G為該工作々彳生 一 又件之-元件所對應之正規表達式E之Glushk〇v自動機’ &amp; &quot;t, z,s, s ' pl i表G中之結東狀態;M〇z…為相鄰之兩狀態,⑸, p CN ;若: 30 1220035 h eteachableh) ’ reachable⑹表在G中可由狀態&amp;,依g中之鄰 達(reach)之狀態之集合; 則認為該元件對Ζι與Ζμ|之關係符合所定之文件格式定義。 15·如申請專利範,13 示之舰文件編輯器,其中,該觀文件編輯 杰可以下式產生一包含該第三元件z之集合c,而以選單表示·· 當(Z,,Zl+|) g Η,η為G中之所有鄰邊之集合,G為該工作文件之一元件所對 應之正規表達式E之Glushkov自動機; 設Σ表G中對應於所有元件之狀態之集合;八㈣表子表達式f謂含狀態之鲁 集合’ f-reachable(Zi)表在G中可由狀態Zi依向前鄰邊到達之狀態之集合,則: 如 zi+1 e f-reachable(Zi),則令 C-{ z e Σ I z e i:reachable(z〇 且 zw e i:reachable(z)}; 如zi+1 d、-reachabie(Z|·),設Ei*為表達式£之反覆子表達式且包含&amp;與&amp; 之最小者,令 C=={ Z e A(E1) | Z e f-reachable(Zi)或 zi+| e f-reachable(z)}。 16·如申請專利範圍第η項所示之XML文件編輯器,其中,該文件編輯_ 器可以下式產生一包含該第三元件z之集合C,而以選單表示: 當(zi,Z1+1) e Η,Η為G中之所有鄰邊之集合,(]為該工作文件之一元件所對 應之正規表達式 Ε之Glushkov自動機; 設Σ表G中對應於所有元件之狀態之集合;a(E1)表子表達式E1所含狀態之 集合;f-reachable(z〇表在G中可由狀態Zi依向前鄰邊到達之狀態之集合,則: 如(4, Ζμ丨)為向前鄰邊’則令 C: { z C Σ| z C f-reachable(Zj)且 ζ·— c 31The working file is stored as an Xml file for the user to read the file and add the compensation element to the ML file. The feature is that the XML file editing method 27 1220035 includes when the user edits the file. Can read / correct the adjacent two elements that meet the definition of the file format to generate a list of 12 elements as a user's prompt; the third element 7 "included in the suspect list, right or two elements 4 and? Between the examples, the relationship between the element pair &amp; and z and the element pair z and ~ 1 can all conform to the file format definition. 8. The document editing method as shown in item 7 of the scope of the patent application, wherein the method for judging that the relationship between the two adjacent elements conforms to the defined file format definition includes: "G is the corresponding one of the cylinder-made documents. The regular expression £ の ㈣⑽automaton 卞 Up} indicates that the child element of this element corresponds to the sequence of states in G, z 丨 two s, 5 the starting state in table 0; zp = f, f represents the ending state in G ; Z | and Zμι are two adjacent states, ρ εΝ, if: Z, + I ereachable (Z |) 'reachaWe㈤ table can be reached from state Zι in G, according to the neighbor relationship in G集合 is the set; the relationship between the component pair and Zj + 1 meets the defined file format definition. 9. The XML · document editing method as shown in item 7 of the scope of patent application, wherein the set C of the third element z is generated according to the following formula, and is expressed by a menu: When (z ,, zi + 丨) g Η, Η is the set of all neighboring edges in G, and G is the Glushkov automaton of the regular expression E corresponding to one element of the working file; Let Σ table G be the set of states corresponding to all elements; Α (Ει) table The subexpression ρ] is a set of states. The f-reachable (Zi) table in G can be reached by state 4 in the direction of the neighboring neighbors, and then, as in zi + 1 € f-reachable (Zi ), Then let C {z G Σ | ze i-reachable (Zj) and Zj + i C f-reachable (z)}; 28 For example, ~ ❿ach 敌 ⑹ 'sets w as an iterator expression of expression E and contains … The smallest, let, 1 C = {ze A (E1) I ze f-reachable (z,) ^ z, + I e f-reachable (z)} 〇 The third element z 10. If applying for a patent The XML file editing method shown in the seventh item of the scope, in which the set C is generated according to the following formula, and is represented by a menu: beware + l) eη 'η is the combination of all adjacent edges in G, and g is the reading of the file —Regular table corresponding to components Glushkov automaton of Darwin E; Let Σ table G correspond to all the element-shaped bear-shaped heart woods, and the set of states contained in the expression E1 of the A (E1) table, such as _call, is shown in G The set of states that are broken forward, then:, P ^ C = izGl | zCf, eacl ^ f-reachable (z)}, and U1) As for the reciprocal expression of some E, ζ (: peak Γ ), Set the most of them to 々Cl —tzeACElVhCf-reachablea)}, and order. two〔. C1; For some E's iterative expressions E2 *, ~ e resistant, let e2 be the largest one of them, then let C2 {ze A (E2) | ze f_reachable (Z |)}, and let pc uC2; (...) is the edge towards the object, then let F3 be the maximal iterative expression of E towel, and satisfy e laSt (E3) and Ζί + 1 e flrst (E3), let C = A (E3). The method for editing an XML file as described in item 7 of the article specifically includes-steps, that is, after adding-a <Z-square, 7L piece pair between Zi and Zi + 1, and then in the component pair. And Z and component pairs z 29 11. 1220035 people] automatically generate the necessary components so that the working document conforms to the applicable grammar; among them, the necessary components between d, 2 (2 and 4+!) Include Giushk In the v automaton G, the "point of connection with the heart 1)" is the state in which all paths from the sample Z to zl + 1) pass. 12. The method for editing a fox file as shown in item i of the patent claim includes an additional step, that is, after adding a second ordinary piece Z between the component pair 4 and zl + 丨, if the component pair Zι and z Between (z and Z | + ι), ,, and essential elements' and (zi, z) 0 Η ((乙 ζιΗ) ί Η), Η is the set of all adjacent edges in G, then in the element pair Zl A component slot is automatically generated between Z and Z (Z and 7) for users to add components. The necessary components between them (z 舁 zi + 丨) include Giushkov automaton G, &amp; and z &amp; And Xin Z, + 丨), that is, a state where all paths from z′z (from z to know |) pass. 13. —A kind of XML text file &amp; 叩 ^, 扁, 扁, includes a user interface to provide users to add or delete document elements in a work document, and save the work document as an XML Document mark; It is characterized in that the XML file editor can generate a first element solution for the two adjacent elements that conform to the definition of the file format ^ and "I as a user's prompt; the element included in the element menu If three components z are added between ㈣Z and +1, the relationship between the component pair 々 and z and the component pair z and Zlfl are in accordance with the definition of the file format. An XML file editor, where the XML file editor judges whether the relationship between two adjacent components is consistent with the defined file format definition: Let G be the one that produces one after another-the component corresponding The Glushk0v automaton of the regular expression '&amp; &quot; t, z, s, s' pl i is the end state in Table G; M 0z ... is the two adjacent states, ⑸, p CN; : 30 1220035 h eteachableh) 'reachable' table in G can be state &amp; According to the collection of the state of reach in g, it is considered that the relationship between the element pair Z and Z μ | is in accordance with the defined file format definition. 15 · If you apply for a patent, the file editor of the ship shown in Figure 13, where, the Viewing document editor Jie can generate a set c containing the third element z, and express it as a menu. When (Z ,, Zl + |) g η, η is the set of all adjacent edges in G, G is the The Glushkov automaton of the regular expression E corresponding to one element of the working file; Let the set of states corresponding to all elements in the Σ table G; The eighth table subexpression f be the Lu set with state 'f-reachable (Zi The set of states in G that can be reached by the state Zi according to the forward neighbor, then: If zi + 1 e f-reachable (Zi), then let C- {ze Σ I zei: reachable (z〇 and zw ei : reachable (z)}; If zi + 1 d, -reachabie (Z | ·), let Ei * be the iterative subexpression of the expression £ and include the smallest of &amp; and &amp;, let C == {Z e A (E1) | Z e f-reachable (Zi) or zi + | e f-reachable (z)}. 16. An XML file editor as shown in item η of the patent application scope, wherein the file is edited _ Can generate a set C containing the third element z, and use the menu to represent: When (zi, Z1 + 1) e Η, Η is the set of all adjacent edges in G, and () is the working file Glushkov automaton of the regular expression E corresponding to one element; Let Σ table G be the set of states corresponding to all elements; a (E1) the set of states contained in the subexpression E1; f-reachable (z〇 The list of states in G that can be reached by the state Zi according to the forward neighbor, then: If (4, Zn μ) is the forward neighbor, then let C: {z C Σ | z C f-reachable (Zj) And ζ · — c 31
TW92117067A 2003-06-24 2003-06-24 XML document editor TWI220035B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW92117067A TWI220035B (en) 2003-06-24 2003-06-24 XML document editor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW92117067A TWI220035B (en) 2003-06-24 2003-06-24 XML document editor

Publications (2)

Publication Number Publication Date
TWI220035B true TWI220035B (en) 2004-08-01
TW200500889A TW200500889A (en) 2005-01-01

Family

ID=34076280

Family Applications (1)

Application Number Title Priority Date Filing Date
TW92117067A TWI220035B (en) 2003-06-24 2003-06-24 XML document editor

Country Status (1)

Country Link
TW (1) TWI220035B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI394055B (en) * 2004-09-15 2013-04-21 Microsoft Corp Common charting using shapes

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI394055B (en) * 2004-09-15 2013-04-21 Microsoft Corp Common charting using shapes

Also Published As

Publication number Publication date
TW200500889A (en) 2005-01-01

Similar Documents

Publication Publication Date Title
CN108491205B (en) Front-end webpage development method and system based on component tree
US10796282B2 (en) Assembling a presentation by processing selected sub-component parts linked to one other sub-component part
US9953007B2 (en) Template-based content creation
US9195965B2 (en) Systems and methods providing collaborating among a plurality of users each at a respective computing appliance, and providing storage in respective data layers of respective user data, provided responsive to a respective user input, and utilizing event processing of event content stored in the data layers
US9348483B2 (en) Modeling system for graphic user interface
JP6518768B2 (en) Build a report
US7672995B2 (en) System and method for publishing collaboration items to a web site
US20080215621A1 (en) Metamodel-based automatic report generation
CN108984172B (en) Interface file generation method and device
CN109189383A (en) The generation method of code file, calculates equipment and storage medium at device
Chang et al. Creating interactive web data applications with spreadsheets
US20100299364A1 (en) Web application for debate maps
CN106970898A (en) Method and apparatus for generating article
BRPI0501951B1 (en) colorized template previews
McNutt et al. Integrated visualization editing via parameterized declarative templates
WO2014146482A1 (en) Method for inserting object in pdf document
Vujović et al. Comparative analysis of DSM graphical editor frameworks: Graphiti vs. Sirius
WO2020264053A1 (en) System and method for employing constraint based authoring
CN101354707A (en) Method and apparatus for customizing model entity expression based on expression regulation
Khalili et al. WYSIWYM–Integrated visualization, exploration and authoring of semantically enriched un-structured content
WO2012106901A1 (en) Web-based script language editing method, system and web client
TWI220035B (en) XML document editor
TW201445465A (en) Electronic document production system and electronic document producing system thereof
Chang et al. A plug-in architecture for connecting to new data sources on mobile devices
US10896161B2 (en) Integrated computing environment for managing and presenting design iterations

Legal Events

Date Code Title Description
MM4A Annulment or lapse of patent due to non-payment of fees