DE10314834A1 - Computer software modification method with initial conversion of selected software components at modification points and delivery in mixed form for final conversion of software components on user side - Google Patents

Computer software modification method with initial conversion of selected software components at modification points and delivery in mixed form for final conversion of software components on user side Download PDF

Info

Publication number
DE10314834A1
DE10314834A1 DE10314834A DE10314834A DE10314834A1 DE 10314834 A1 DE10314834 A1 DE 10314834A1 DE 10314834 A DE10314834 A DE 10314834A DE 10314834 A DE10314834 A DE 10314834A DE 10314834 A1 DE10314834 A1 DE 10314834A1
Authority
DE
Germany
Prior art keywords
code
source code
transformation
formulated
program
Prior art date
Legal status (The legal status 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 status listed.)
Ceased
Application number
DE10314834A
Other languages
German (de)
Inventor
Roy Oberhauser
Christian Reichel
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Siemens Corp
Original Assignee
Siemens Corp
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 Siemens Corp filed Critical Siemens Corp
Priority to DE10314834A priority Critical patent/DE10314834A1/en
Priority to US10/551,454 priority patent/US8473937B2/en
Priority to PCT/EP2004/003301 priority patent/WO2004088549A2/en
Priority to EP04739074A priority patent/EP1609061A2/en
Publication of DE10314834A1 publication Critical patent/DE10314834A1/en
Ceased legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/51Source to source
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/76Adapting program code to run in a different environment; Porting

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Computer Hardware Design (AREA)
  • Evolutionary Computation (AREA)
  • Geometry (AREA)
  • Devices For Executing Special Programs (AREA)

Abstract

The method has selected components of the software (SW) expressed in source text (SC1,SC2,..SC) converted into a first XML code (CodeML) at each modification point, with delivery of the software (SW*) in mixed form and conversion of the XML code on the user side into a second XML code (CodeML*) via one or more transformations (T) for direct or indirect provision of modified software at the modification points which varies from the original software in its program sequence or program content. Also included are Independent claims for the following (a) a source code modification method; (b) a software modification arrangement; (c) a source code modification arrangement.

Description

Die Erfindung betrifft ein Verfahren und eine Anordnung zur Modifikation von Quellcode, bei dem/der ein Quellcode, beispielsweise ein Java-Quellcode, in eine Darstellung in einer Meta-Auszeichnungssprache, beispielsweise XML, übergeführt, dort, beispielsweise mit XSLT, transformiert und dann diese in der Meta-Auszeichnungssprache formulierte transformierte Darstellung in einen modifizierten Quellcode, beispielsweise derselben Ausgangssprache, zurückverwandelt wird.The The invention relates to a method and an arrangement for modification of source code in which a source code, for example a Java source code, into a representation in a meta markup language, for example XML, transferred, there, transformed with XSLT, for example, and then in the meta markup language formulated transformed representation in a modified source code, for example the same source language, is converted back.

Aus dem Internet ist unter http://beautyj.berlios.de/ ein Java Source Code Transformation Tool BeautyJ bekannt, bei dem ein Java Quellcode in eine XML-Darstellung umgewandelt wird, mittels Sourclet API, beispielsweise durch Einfügen von Leerzeichen oder geänderten Kommentaren an bestimmten Stellen, „verschönert" und anschließend der modifizierte Quellcode in Java Quellcode zurück konvertiert werden kann. Eine Transformation mittels XSLT wird hier, für diesen Zweck, nur vorgeschlagen, aber nicht umgesetzt.Out the Internet at http://beautyj.berlios.de/ is a Java Source Code Transformation Tool BeautyJ known, using a Java source code is converted into an XML representation using the Sourclet API, for example by inserting of spaces or changed Comments in certain places, "embellished" and then the modified source code back in Java source code can be converted. A transformation using XSLT is here For this Purpose, only suggested, but not implemented.

Die der Erfindung zugrunde liegende Aufgabe liegt nun darin, ein Verfahren und eine Anordnung zur Modifikation von Quellcode anzugeben, bei dem/der eine weitergehende noch flexiblere und effizientere Modifikation der Quellcodes erreicht wird.The The object underlying the invention is now a method and to provide an arrangement for modifying source code at a further, more flexible and efficient modification the source code is reached.

Diese Aufgabe wird hinsichtlich des Verfahrens durch die Merkmale des Patentanspruchs 1 und hinsichtlich der Anordnung durch die Merkmale des Anspruchs 11 erfindungsgemäß gelöst. Die weiteren Ansprüche betreffen bevorzugte Ausgestaltungen der Erfindung.This Task is with regard to the process by the features of Claim 1 and with regard to the arrangement by the features of claim 11 according to the invention. The further claims relate to preferred embodiments of the invention.

Die Erfindung besteht im Wesentlichen darin, dass der in eine Meta-Auszeichnungssprache, beispielsweise XML, transformierte Quellcode mit weiteren Informationen, wie beispielsweise Ausgangszuständen, auszutauschenden Code-Fragmenten und auf die jeweilige natürliche Sprache des Anwenders zugeschnittenen Fremdsprachenmodulen, mit einer in seinen Elementen standardisierten und übersichtlich beschreibbaren Transformation, beispielsweise XSLT, vermischt wird, wodurch, nach einer Rückkonvertierung aus XML in die ursprüngliche Programmiersprache, ein neuer Quellcode entsteht, bei dem nicht nur die Darstellung, sondern auch der eigentliche Programminhalt bzw. der Programmablauf entsprechend den weiteren Informationen und den Transformationsvorschriften verändert wurde.The Invention essentially consists in that in a meta markup language, for example XML, transformed source code with further information, such as initial states to be exchanged Code fragments and the respective natural language of the user tailored foreign language modules, with one in its elements standardized and clear writable transformation, for example XSLT, is mixed, whereby, after a reverse conversion from XML to the original Programming language, a new source code is created, which does not only the presentation, but also the actual program content or the program flow according to the further information and the transformation regulations were changed.

Die Erfindung wird im Folgenden anhand von in den Zeichnungen dargestellten Beispielen näher erläutert. Dabei zeigtThe The invention is illustrated below with reference to the drawings Examples closer explained. It shows

Zeichnung 1 ein Gesamtblockdiagramm zur Erläuterung der Erfindung,drawing 1 is an overall block diagram for explaining the invention;

Zeichnung 2 ein Blockschaltbild zur Erläuterung des erfindungsgemäßen Austauschens von Code-Fragmenten,drawing 2 is a block diagram for explanation of the exchange according to the invention of code fragments,

Zeichnung 3 ein Blockschaltbild zur Erläuterung des erfindungsgemäßen Einfügens von Zustandsdaten,drawing 3 is a block diagram for explanation the inventive insertion of State data,

Zeichnung 4 ein Blockschaltbild zur Erläuterung der Variationsmöglichkeiten des erfindungsgemäßen Einbaus von Informationen unddrawing 4 is a block diagram for explanation the possible variations of the installation according to the invention of information and

Zeichnung 5 ein Blockschaltbild zur Erläuterung des erfindungsgemäßen Einbaus von Fremdsprachmodulen zur Internationalisierung des Quellcodes.drawing 5 is a block diagram for explanation of the installation according to the invention of foreign language modules to internationalize the source code.

In Zeichnung 1 ist ein Gesamtblockdiagramm zur Erläuterung der Erfindung dargestellt, bei dem zunächst ein Quellcode SC durch einen Konverter CONV in einen in einer Meta-Auszeichnungssprache formulierten ersten Code CodeML umwandelt wird, wobei der Quellcode SC bei sofortiger Kompilierung einen Byte Code bzw. Binärcode B ergeben kann. Zu dem in der Meta-Auszeichnungssprache dargestellten Code CodeML wird nun eine zusätzliche Information INFO auf dem Wege einer durch Transformationsregeln TR beschriebenen Transformation T dem Code CodeML bzw. dem letztlich dem Quellcode SC hinzugefügt, wodurch sich ein zweiter ebenfalls in der Meta-Auszeichnungssprache formulierten Code CodeML* ergibt. Ein weiterer Konverter RCONV wandelt nach der Transformation den Code CodeML* in einen Quellcode SC* zurück, der typischerweise in derselben Sprache wie der Quellcode SC formuliert ist. Durch einen Compiler COMP wird schließlich der modifizierte Code SC* in einen modifizierten Byte Code B* oder aber gleich in einen ausführbaren Binärcode umgewandelt. Wesentlich ist hierbei, dass sich der Byte-Code B* vom Byte-Code B unterscheidet bzw. dass der Quellcode nicht nur in seiner Darstellung, sondern auch in seinem Programmablauf geändert wurde.1 shows an overall block diagram for explaining the invention, in which a source code SC is first converted by a converter CONV into a first code CodeML formulated in a meta-markup language, the source code SC being immediately compiled a byte code or binary code B can result. Additional information INFO is now added to the code CodeML or ultimately the source code SC to the code CodeML shown in the meta-markup language by means of a transformation T described by transformation rules TR, which results in a second code also formulated in the meta-markup language CodeML * results. Another converter RCONV converts the code CodeML * back into a source code SC * after the transformation typically in the same language as the source code SC. The modified code SC * is finally converted into a modified byte code B * or else into an executable binary code by a compiler COMP. It is important here that the byte code B * differs from the byte code B or that the source code has been changed not only in its representation but also in its program flow.

Der Quellcode SC und der modifizierte Quellcode SC* sind beispielsweise in der Programmiersprache Java und die Codes CodeML und CodeML* sind beispielsweise in der Meta-Auszeichnungssprache XML formuliert, wobei „XML" für Extended Markup Language steht.The Source code SC and the modified source code SC * are for example in the Java programming language and the codes CodeML and CodeML * are, for example, in the meta markup language XML formulated, with "XML" for Extended Markup Language is there.

In Zeichnung 3 ist ein erstes Ausführungsbeispiel dargestellt, bei dem die zusätzliche Information INFO in Form von Daten D, bspw. Initialisierungszuständen SSDb, Zustandsdaten SDa, Datenbankdaten Dc, beliebige Daten x, dem CodeML hinzugemischt werden, wobei diese Daten beispielsweise feste Zustände bzw. Werte für Konstanten und Variablen darstellen. Auf diese Weise kann der Quellcode SC mit festen Zuständen versorgt und transformiert werden, so dass ein benötigter Zustand zur Laufzeit des Programms, z.B. als Initialisierungszustand SSDb, sofort zur Verfügung steht und nicht mehr gesondert ermittelt werden muss. Auf diese Weise können auch Objekt-Zustände in den Code eingebracht werden, die ein Wiederaufsetzen (Recovery) eines unterbrochenen Programms am selben Ort mit denselben Zuständen ermöglichen, ohne dass zusätzliche aufwändige programmtechnische Vorkehrungen hierfür getroffen werden müssen.In Drawing 3 is a first embodiment shown, where the additional Information INFO in the form of data D, for example initialization states SSDb, Status data SDa, database data Dc, any data x, the CodeML are mixed in, these data being, for example, fixed states or Values for Represent constants and variables. This way the source code SC with fixed states be supplied and transformed so that a required state at program runtime, e.g. as initialization state SSDb, immediately available stands and no longer has to be determined separately. To this Way can also object states are brought into the code, which a recovery enable an interrupted program in the same location with the same conditions, without additional complex program-technical precautions must be taken for this.

Die Transformation T, z. B. eine Extended Stylesheet Language Transformation oder XSLT, wird durch Transformationsregeln TR, z. B. innerhalb von XSL (Extended Stylesheet Language) Dateien beschrieben, wobei bspw. die in XSL formulierten Regeln u.a. beschreiben wie der in XML-codierte Quellcode CodeML mit den Zustandsdaten aus D kombiniert wird, um einen neuen modifizierten Quellcode CodeML* mit SSDb, SDa und Dc zu bilden.The Transformation T, e.g. B. an Extended Stylesheet Language Transformation or XSLT, is determined by transformation rules TR, e.g. B. within described by XSL (Extended Stylesheet Language) files, where e.g. the rules formulated in XSL etc. describe like the one in XML-coded source code CodeML combined with the status data from D. is to a new modified source code CodeML * with SSDb, SDa and to form Dc.

Die Regeln einer Transformation T können dabei so geartet sein, dass die Informationen in ihrer ursprünglichen Form aber auch in einer durch Regeln geänderten Form hinzugemischt werden.The Rules of a transformation T can be such that the information is in its original Form but also mixed in a form changed by rules become.

Die Regeln einer Transformation T können dabei auch so geartet sein, dass die Transformation T, z.B. mit Hilfe von if-conditions, durch die Informationen bzw. Daten beeinflusst werden.The Rules of a transformation T can also be such that the transformation T, e.g. With Help from if-conditions that influence information or data become.

Die im Anhang 1 befindlichen Programmauflistungen Listing 1 bis Listing 6 zeigen dies an einem konkreten Beispiel, bei dem in einer Testklasse des Quellcodes die nicht initialisierte Variable String m_sWelcome in eine initialisierte Form String m_sWelcome = "hello"; transformiert wird. Hierbei zeigt das Listing 1 das entsprechende Java-Programm TestOutput.java, dass in eine XML-Darstellung TestOutput.xjava konvertiert wird. In Listing 3 ist die XML-Datei State.XML mit dem Zustandswert "hello" dargestellt. In Listing 4 folgt dann die Transformationsanweisung zum Vermischen Mixing.xsl, die mit Anweisungen wie template match = und apply-templates dafür sorgen, dass der Code an der richtigen Stelle modifiziert wird.The Program listings in Appendix 1, Listing 1 to Listing 6 show this using a concrete example in which in a test class of the source code the uninitialized variable String m_sWelcome in an initialized form String m_sWelcome = "hello"; is transformed. Here shows Listing 1 the corresponding Java program TestOutput.java that is converted into an XML representation TestOutput.xjava. In listing 3 shows the XML file State.XML with the state value "hello". In Listing 4 then follows the transformation instruction for mixing Mixing.xsl with instructions like template match = and apply-templates ensure, that the code is modified in the right place.

In Zeichnung 2 ist ein zweites Ausführungsbeispiel dargestellt, bei dem ein in XML codiertes Code-Fragment CFb mit einem ursprünglichen in XML codierten Quellcode CodeML, der ein Code-Fragment CFa enthält, durch die Transformation T derart transformiert wird, dass im modifizierten XML-codierten Quellcode CodeML* anstelle des bisher vorhandenen Fragments CFa ein Code-Fragment CFb enthalten ist. Die Transformation T wird hierbei auch von Transformationsregeln TR gesteuert. Ein derartiger Austausch von Code-Fragmenten kann unter bestimmten Umständen z.B. als „Patching" bezeichnet werden. Durch das erfindungsgemäße Verfahren kann ein Patching in konsistenter Weise mit einem maximalen Grad an Freiheit für den Softwareentwickler erreicht werden, wobei dies beispielsweise automatisch und unter Berücksichtigung gegenseitiger Abhängigkeiten erfolgen kann.In Drawing 2 is a second embodiment shown, in which a code fragment encoded in XML CFb an original in XML coded source code CodeML, which contains a code fragment CFa the transformation T is transformed such that in the modified XML-encoded source code CodeML * instead of the previously existing CFa fragment, a code fragment CFb is included. The transformation T is also governed by transformation rules TR controlled. Such an exchange of code fragments can under certain circumstances e.g. be referred to as "patching". By the method according to the invention can be patching consistently with a maximum degree freedom for him Software developers can be reached, for example automatically and considering each other dependencies can be done.

Für dieses Ausführungsbeispiel ist ein konkreter Fall durch die Listings 1A bis 6A der im Anhang 2 befindlichen Programmauflistungen gezeigt. Aus dem Java-Source-Code TestOutput.java wird wiederum ein TextOutput.xjava erzeugt. In Listing 3A kann man die Datei CodeFragment.xml erkennen, die ein Code-Fragment bereitstellt. Das Listing 4A enthält nun in der Datei Patching.xsl die Regeln für die Transformation T, wobei wiederum die Befehle template match = und apply-templates zum Einsatz kommen. Im Listing 5A ist dann der Inhalt der Datei TestOutput.xjava(*) mit dem modifizierten XML Quellcode und in Listing 6A in der Datei TestOutput.java(*) der modifizierte Java Quellcode dargestellt. Bei diesem Beispiel wird in der öffentlichen Testklasse die Stringzuweisung String m_sWelcome = "hello"; durch eine Stringzuweisung String m_sWelcome = System.getProperty("WELCOME"); ersetzt, wobei hier also der feste Wert "hello" durch die vom System angeforderte Eigenschaft "WELCOME" ersetzt wird, und die beispielsweise irrtümlich „hardcodierte" Wertzuweisung nun „gepatched" werden kann.For this exemplary embodiment, a specific case is shown by the listings 1A to 6A of the program listings located in Appendix 2. A TextOutput.xjava is generated from the Java source code TestOutput.java. Listing 3A shows the CodeFragment.xml file, which provides a code fragment. Listing 4A now contains the rules for the transformation T in the Patching.xsl file, whereby again the commands template match = and apply-templates are used. Listing 5A shows the contents of the TestOutput.xjava (*) file with the modified XML source code, and Listing 6A shows the modified Java source code in the TestOutput.java (*) file. In this example, the string assignment String m_sWelcome = "hello"; through a string assignment String m_sWelcome = Sys tem.getProperty ( "WELCOME"); replaced, with the fixed value "hello" being replaced by the property "WELCOME" requested by the system, and the incorrectly "hard-coded" value assignment, for example, can now be "patched".

Zeichnung 4 betrifft ein drittes Anwendungsbeispiel der Erfindung, bei dem die Informationen INFO von Zeichnung 1 nicht nur in der oben angegebenen Weise in Form von Informationen INFO1, sondern auch zusätzlich Form von in den Transformationsregeln eingebetteten Informationen INFO2 bzw. Fragmenten hinzugemischt werden.drawing 4 relates to a third application example of the invention, in which the information INFO of drawing 1 is not only given in the above Way in the form of information INFO1, but also additional form of information embedded in the transformation rules INFO2 or fragments are added.

Zeichnung 5 betrifft ein viertes Anwendungsbeispiel der Erfindung, bei dem XML-Quellcode CodeML mit dem Codefragment CF, das die Fremdsprachenfragmente LF1 und LF2 enthält, durch die Transformation T kombiniert wird, um einen modifizierten Code CodeML*, beispielsweise angepasst an die natürliche Sprache des Benutzers (L1 = german), zu erhalten. Die Transformation XSLT wird hierbei von Transformationsregeln TR bestimmt, die die zu ändernden Stellen des Quellcodes sowie die jeweilige ausgewählte natürliche Sprache, also beispielsweise german oder english, spezifiziert. Durch das erfindungsgemäße Verfahren wird so eine Lokalisierung und Internationalisierung des Quellcodes auf effiziente und ökonomische Weise, bei einer Minimierung der hierfür erforderlichen zusätzlichen Laufzeit, erreicht.drawing 5 relates to a fourth application example of the invention, in which XML source code CodeML with the code fragment CF, which is the foreign language fragments LF1 and LF2 contains is combined by the transformation T to a modified Code CodeML *, for example adapted to the natural language of the User (L1 = german). The XSLT transformation will here determined by transformation rules TR, which are to be changed The source code and the selected natural language, for example, German or English. By the inventive method localization and internationalization of the source code on efficient and economical Way, while minimizing the additional required Runtime reached.

Die oben genannten Ausprägungen des erfindungsgemäßen Verfahrens können einzeln und in beliebiger Reihenfolge nacheinander erfolgen.The above mentioned forms of the method according to the invention can individually and in any order one after the other.

Durch das erfindungsgemäße Verfahren ergeben sich eine Reihe von Vorteilen, wie beispielsweise:

  • 1. Es können schnelle und flexible Änderungen im Quellcode vorgenommen werden.
  • 2. Es ist nur ein System für Problemstellungen wie Patching, Customizing, Updating, etc. erforderlich und nicht eine Reihe verschiedener teilweise proprietärer Werkzeuge.
  • 3. Das Verfahren basiert auf Standards wie XML und XSLT und ist hinsichtlich der Konvertierbarkeit in andere Programmiersprachen geringeren Beschränkungen unterworfen als andere Verfahren zur Modifikation von Quellcode.
  • 4. Selbst für spezielle und komplizierte Quellcode-Modifikationen sind keine proprietären Speziallösungen erforderlich, sondern es können hierfür existierende Standards wie XSLT, XPath und XQuery genutzt werden.
  • 5. Diese Art der Modifikation erlaubt die Erstellung von Hierarchien u.a. durch die Möglichkeit zur geordneten, automatisierten Hintereinanderausführung (Pipelines) mehrerer Transformationen, bspw. von Patches.
  • 7. Die Transformationen können für eine allgemeine Wiederverwendung in XSLT-Dateien gespeichert werden, so daß Bibliotheken z.B. für bestimmte Abläufe entstehen können.
  • B. Es kann eine XML-Repräsentation des Quellcodes in einer XML-Datenbasis gespeichert und bei Bedarf mit Hilfe einer XSTL in einfacher Weise an die jeweiligen Kundenbedürfnisse angepasst werden (Customization).
  • 9. Durch die Verwendung der Standards XMLSchema oder DTD oder entsprechende XSLTs kann der Code vorab (ohne Kompilierung), auf bestimmte Korrektheitsaspekte hin, überprüft (validiert) werden.
  • 10. Übliche XML-Tools können zur einfachen Bearbeitung bzw. Visualisierung und Bestimmung von Beziehungen im Code verwendet werden.
  • 11. Dauerhafte XML-basierte Programmbibliotheken, die XPath-Anfragen unterstützen, können die Wiederverwendung von Code durch besseres Auffinden eines Codes bzw. von Code-Fragmenten oder Templates verbessert werden.
The method according to the invention results in a number of advantages, such as:
  • 1. Quick and flexible changes can be made in the source code.
  • 2. Only one system for problems such as patching, customizing, updating, etc. is required and not a number of different, partly proprietary tools.
  • 3. The method is based on standards such as XML and XSLT and is subject to fewer restrictions with regard to convertibility into other programming languages than other methods for modifying source code.
  • 4. Even for special and complicated source code modifications, no proprietary special solutions are required, but existing standards such as XSLT, XPath and XQuery can be used for this.
  • 5. This type of modification allows hierarchies to be created, inter alia, by the possibility of orderly, automated execution (pipelines) of several transformations, for example patches.
  • 7. The transformations can be saved for general reuse in XSLT files, so that libraries can be created for certain processes, for example.
  • B. An XML representation of the source code can be stored in an XML database and, if necessary, easily adapted to the respective customer needs using an XSTL (customization).
  • 9. By using the XMLSchema or DTD standards or corresponding XSLTs, the code can be checked (validated) in advance (without compilation) for certain correctness aspects.
  • 10. Common XML tools can be used for easy editing or visualization and determination of relationships in the code.
  • 11. Permanent XML-based program libraries that support XPath requests can improve code reuse by better finding code, code fragments, or templates.

Anhang 1 Listing 1: TestOutput.java

Figure 00090001
Appendix 1 Listing 1: TestOutput.java
Figure 00090001

Listing 2: TestOutput.xjava

Figure 00090002
Listing 2: TestOutput.xjava
Figure 00090002

Listing 3: State.xml

Figure 00090003
Listing 3: State.xml
Figure 00090003

Listing 4: Mixing.xsl

Figure 00090004
Listing 4: Mixing.xsl
Figure 00090004

Figure 00100001
Figure 00100001

Listing 5: TestOutput.xjava (*)

Figure 00100002
Listing 5: TestOutput.xjava (*)
Figure 00100002

Listing 6: TestOutput.java (*)

Figure 00100003
Listing 6: TestOutput.java (*)
Figure 00100003

Anhang 2 Listing 1A: TestOutput.java

Figure 00110001
Appendix 2 Listing 1A: TestOutput.java
Figure 00110001

Listing 2A: TestOutput.xjava

Figure 00110002
Listing 2A: TestOutput.xjava
Figure 00110002

Listing 3A: CodeFragment.xml

Figure 00110003
Listing 3A: CodeFragment.xml
Figure 00110003

Listing 4A: Patching.xsl

Figure 00110004
Listing 4A: Patching.xsl
Figure 00110004

Figure 00120001
Figure 00120001

Listing 5A: TestOutput.xjava (*)

Figure 00120002
Listing 5A: TestOutput.xjava (*)
Figure 00120002

Listing 6A: TestOutput.java (*)

Figure 00120003
Listing 6A: TestOutput.java (*)
Figure 00120003

Claims (11)

Verfahren zur Modifikation von Quellcode, – bei dem ein in einer ersten Programmiersprache formulierter Quellcode (SC) in einen in einer Meta-Auszeichnungssprache formulierten ersten Code (CodeML) umgewandelt wird, – bei dem eine in der Meta-Auszeichnungssprache formulierte, den späteren Programmablauf (B*) beeinflussende Information (INFO) durch eine Transformation (T) zu diesem ersten Code ersetzend oder nichtersetzend hinzugefügt und so der ebenfalls in der Meta-Auszeichnungssprache formulierte zweiten Code (CodeML*) gebildet wird, wobei die Transformation in Abhängigkeit von in einer Transformationsbeschreibungssprache formulierten Transformationsregeln (TR) erfolgt, und – bei dem dieser zweite Code in einen in der ersten Programmiersprache oder einer anderen Programmiersprache formulierten zweiten Quellcode (SC*) verwandelt wird, wobei sich der Programminhalt bzw. Programmablauf (B) des ersten Quellcodes (SC) vom Programminhalt bzw. Programmablauf (B*) des zweiten Quellcodes (SC*) unterscheidet.Process for modifying source code, - in which a source code (SC) formulated in a first programming language in a first formulated in a meta markup language Code (CodeML) is converted - one in the meta markup language formulated the later Program sequence (B *) influencing information (INFO) by a Transformation (T) replacing or replacing this first code and so on the second, also formulated in the meta markup language Code (CodeML *) is formed, the transformation depending of transformation rules formulated in a transformation description language (TR), and - at which this second code into one in the first programming language or another programming language formulated second source code (SC *) is transformed, whereby the program content or program sequence (B) the first source code (SC) of the program content or program sequence (B *) of the second source code (SC *) differs. Verfahren nach Anspruch 1, bei dem diese Information (INFO) mindestens ein Code-Fragment (CFb) enthält und bei dem der zweite Quellcode dadurch gebildet wird, dass mindestens ein im ersten Quellcode enthaltenes Code-Fragment (CFa) mit Hilfe der Transformation durch das mindestens eine im Fragment enthaltene Code-Fragment (CFb) ersetzt wird.Method according to claim 1, where this information (INFO) contains at least one code fragment (CFb) and where the second Source code is formed in that at least one in the first source code contained code fragment (CFa) with the help of the transformation replaces the at least one code fragment (CFb) contained in the fragment becomes. Verfahren nach Anspruch 1, bei dem die Information (INFO) speziell Daten (D) in Form von Initialisierungszuständen (SSDb) oder Zustandsdaten (SDa) oder Datenbankdaten (Dc) enthalten.The method of claim 1, wherein the information (INFO) specifically data (D) in the form of initialization states (SSDb) or contain status data (SDa) or database data (Dc). Verfahren nach Anspruch 3, bei die Transformationsregeln (TR) von diesen Daten (D) beeinflusst werden.Method according to claim 3, in which the transformation rules (TR) are influenced by this data (D). Verfahren nach einem der Ansprüche 1 bis 4, bei dem Daten (D) und/oder Code-Fragmente (CF) zusätzlich in den Transformationsregeln eingebettet sind.Method according to one of claims 1 to 4, in which data (D) and / or code fragments (CF) additionally in the transformation rules are embedded. Verfahren nach einem der Ansprüche 1 bis 5, bei dem von checkpoints generierte Daten mittels einer Transformation so hinzugefügt werden, das der interne Zustand des ursprünglichen Programms beim Neustart des Programms zur Verfügung steht bzw. von diesem genutzt werden kann.Method according to one of Claims 1 to 5, in which data generated by checkpoints are added by means of a transformation such that the internal state of the original program when it is restarted the program is available or can be used by it. Verfahren nach einem der Ansprüche 1 bis 5, bei dem Informationen (INFO) Updates oder Patches enthalten.Method according to one of claims 1 to 5, in which information (INFO) updates or patches included. Verfahren nach Anspruch 1 bis 5, bei dem Fragmente (LF1, LF2) Informationen zur Internationalisierung enthalten, die der Anpassung an unterschiedliche natürliche Sprachen dienen.The method of claims 1 to 5, wherein the fragments (LF1, LF2) contain information on internationalization that serve the adaptation to different natural languages. Verfahren nach einem der Ansprüche 1 bis 5, bei dem Daten und/oder Code-Fragmente aus einer Bibliothek entstammen und auf Kunden oder Kundengruppen abgestimmte Informationen tragen.Method according to one of claims 1 to 5, in which data and / or code fragments come from and on a library Carry coordinated information to customers or customer groups. Verfahren nach einem der vorhergehenden Ansprüche, bei dem die Programmiersprache des ersten und zweiten Quellcodes Java und die Meta-Auszeichnungssprache XML ist und bei dem die Transformation und der Regelbeschreibung mittels XSLT und XSL erfolgt.Method according to one of the preceding claims, which is the programming language of the first and second Java source code and the meta markup language is XML and in which the transformation and the rule description is done using XSLT and XSL. Anordnung zur Modifikation von Quellcode, – bei der ein erster Konverter (CONV) derart vorhanden ist, dass ein in einer ersten Programmiersprache formulierter Quellcode (SC) in einen in einer Meta-Auszeichnungssprache formulierten ersten Code (CodeML) umgewandelt wird, – bei der ein Prozessor derart vorhanden ist, dass eine in der Meta-Auszeichnungssprache formulierte, den späteren Programmablauf (B*) beeinflussende Information (INFO) durch eine Transformation (T) zu diesem ersten Code ersetzend oder nichtersetzend hinzugefügt und so der ebenfalls in der Meta-Auszeichnungssprache formulierte zweiten Code (CodeML*) gebildet wird, wobei die Transformation in Abhängigkeit von in einer Transformationsbeschreibungssprache formulierten Transformationsregeln (TR) erfolgt, und – bei der ein zweiter Konverter (RCONV) derart vorhanden ist, dass dieser zweite Code in einen in der ersten Programmiersprache oder einer anderen Programmiersprache formulierten zweiten Quellcode (SC*) verwandelt wird, wobei sich der Programminhalt bzw. Programmablauf (B) des ersten Quellcodes (SC) vom Programminhalt bzw. Programmablauf (B*) des zweiten Quellcodes (SC*) unterscheidet.Arrangement for modification of source code, - in the a first converter (CONV) is present such that one in one first programming language formulated source code (SC) into a a first code (CodeML) formulated in a meta markup language becomes, - at which has a processor such that one in the meta markup language formulated the later Program sequence (B *) influencing information (INFO) by a Transformation (T) to replace or not to replace this first code added and so that also in the meta markup language Formulated second code (CodeML *) is formed, the transformation dependent on of transformation rules formulated in a transformation description language (TR), and - at which a second converter (RCONV) is available such that this second code in one in the first programming language or one another programming language formulated second source code (SC *) is transformed, whereby the program content or program flow (B) the first source code (SC) of the program content or program sequence (B *) of the second source code (SC *) differs.
DE10314834A 2003-04-01 2003-04-01 Computer software modification method with initial conversion of selected software components at modification points and delivery in mixed form for final conversion of software components on user side Ceased DE10314834A1 (en)

Priority Applications (4)

Application Number Priority Date Filing Date Title
DE10314834A DE10314834A1 (en) 2003-04-01 2003-04-01 Computer software modification method with initial conversion of selected software components at modification points and delivery in mixed form for final conversion of software components on user side
US10/551,454 US8473937B2 (en) 2003-04-01 2004-03-29 Method and array for changing software or source code
PCT/EP2004/003301 WO2004088549A2 (en) 2003-04-01 2004-03-29 Method and array for changing software or source code
EP04739074A EP1609061A2 (en) 2003-04-01 2004-03-29 Method and array for changing software or source code

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
DE10314834A DE10314834A1 (en) 2003-04-01 2003-04-01 Computer software modification method with initial conversion of selected software components at modification points and delivery in mixed form for final conversion of software components on user side

Publications (1)

Publication Number Publication Date
DE10314834A1 true DE10314834A1 (en) 2004-11-04

Family

ID=33103158

Family Applications (1)

Application Number Title Priority Date Filing Date
DE10314834A Ceased DE10314834A1 (en) 2003-04-01 2003-04-01 Computer software modification method with initial conversion of selected software components at modification points and delivery in mixed form for final conversion of software components on user side

Country Status (1)

Country Link
DE (1) DE10314834A1 (en)

Non-Patent Citations (5)

* Cited by examiner, † Cited by third party
Title
ATTALI, Isabelle: u.a.: Aspect and XML-oriented Sematic Framework Generator: SmartTools. In: Sec- ond Worshop on Language Descriptions, Tools and Applications, LDTAČ02, ETAPSČ2002, Electronic Not- es in Theoretical Computer Science(ENTCS), 2002
ATTALI, Isabelle: u.a.: Aspect and XML-oriented Sematic Framework Generator: SmartTools. In: Sec- ond Worshop on Language Descriptions, Tools and Applications, LDTAC02, ETAPSC2002, Electronic Not-es in Theoretical Computer Science(ENTCS), 2002 *
GERMON, Roy: Using XML as an Intermediate Form for Compiler Development. In: XML Conference & Exposi- tion 2001, Orlando, Florida, USA, Dezember 2001
GERMON, Roy: Using XML as an Intermediate Form forCompiler Development. In: XML Conference & Exposi-tion 2001, Orlando, Florida, USA, Dezember 2001 *
SCHONGER Stefan, PULVERMÜLLER Elke, SARSTEDT Ste- fan: Aspect-Oriented Programming and Compenent Weaving: Using XML Reprensentations of Abstract Syntax Trees. In: Workshop Aspecktorientierte Softwareentwicklung, Universität Bonn, Institut für Informatik III, 21-22. Februar 2002 *

Similar Documents

Publication Publication Date Title
EP1176482B1 (en) Method and computer program for generating a regulation or control system
EP2422288B1 (en) Medical treatment apparatus
WO1991008534A1 (en) Process for dynamically linking definable programme elements of an interactive data-processing system
DE10116809A1 (en) Programmable controller for the development of control programs uses sequential processing
EP1723513B1 (en) Method for configuring a computer program
DE10234971A1 (en) Program code generation method for generating program code from source text uses a processor core in a micro-controller to run the program code and a compiler to generate corresponding commands
DE19924702A1 (en) Determining global register conflicts in a computer program uses unitary data structure to evaluate the global registers
DE102004009676A1 (en) Methods and systems for generating command support files
EP1682951A1 (en) Method and device for adapting functions for controlling operating sequences
WO2004088549A2 (en) Method and array for changing software or source code
WO2005098617A1 (en) Method for preventing data inconsistency between accesses of different functions of an application to a global variable in a data processing installation
DE19924437A1 (en) Global register initialization method in network, by using global variable information contained in object file
DE10314834A1 (en) Computer software modification method with initial conversion of selected software components at modification points and delivery in mixed form for final conversion of software components on user side
DE102008044808B4 (en) Method for generating program code in an operating system memory and an application memory of a data carrier
DE10138533A1 (en) Protection of control programs transmitted over the Internet from a developer to a customer using asymmetric encryption of the program code, which is decrypted by the end user after parameter editing
DE10314832B3 (en) Computer software modification method with initial conversion of selected software components at modification points and delivery in mixed form for final conversion of software components on user side
EP0560342B1 (en) Method for debugging HDL-programs
DE10314835A1 (en) Computer software modification method with initial conversion of selected software components at modification points and delivery in mixed form for final conversion of software components on user side
DE19954793A1 (en) Compiling machine program involves re-compiling only these source text data files using changed Include data files and those source text data files that have been changed
DE102004022183B4 (en) Correction of program object code due to source text changes is made without generating all new modules
EP1920328B1 (en) Operation code switching
DE10300541A1 (en) Workable data file generation method, involves dividing target name into parts at given points
DE10314831A1 (en) Computer software modification method with initial conversion of selected software components at modification points and delivery in mixed form for final conversion of software components on user side
DE102004039200A1 (en) Version-marking of binary data function routines or DLLs to enable checking of consistency with a calling binary data or executable program, by incorporating a code within the DLL so that it can be checked by a calling EXE program
DE10254530A1 (en) Control system upgrading method in which an information set description relating to a first software configuration is first converted into a neutral meta-description, which is then converted into a second software information set

Legal Events

Date Code Title Description
OP8 Request for examination as to paragraph 44 patent law
8131 Rejection