CN113760248A - Method and device for generating application program - Google Patents

Method and device for generating application program Download PDF

Info

Publication number
CN113760248A
CN113760248A CN202010653297.7A CN202010653297A CN113760248A CN 113760248 A CN113760248 A CN 113760248A CN 202010653297 A CN202010653297 A CN 202010653297A CN 113760248 A CN113760248 A CN 113760248A
Authority
CN
China
Prior art keywords
template
data
code
identification
preset format
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.)
Pending
Application number
CN202010653297.7A
Other languages
Chinese (zh)
Inventor
崔宏宝
刘登勇
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.)
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information Technology Co Ltd
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 Beijing Jingdong Century Trading Co Ltd, Beijing Wodong Tianjun Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN202010653297.7A priority Critical patent/CN113760248A/en
Publication of CN113760248A publication Critical patent/CN113760248A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/33Intelligent editors
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/34Graphical or visual programming
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/61Installation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Stored Programmes (AREA)

Abstract

The invention discloses a method and a device for generating an application program, and relates to the technical field of computers. One embodiment of the method comprises: in response to the selection operation of a first template, determining template components corresponding to the first template, and retrieving codes corresponding to the template components from a code library; converting the identification, the name and the mapping object of the first template into data in a preset format; and packaging the data with the preset format and the codes to obtain a code packet corresponding to the first template and outputting the code packet so as to generate an application program through the code packet. According to the embodiment, a set of platform for rapidly generating App is built for personnel with low research and development capacity, the overall operation is simple and easy to implement, templates of different operating systems are different, the research and development efficiency is greatly improved, and the research and development threshold and the cost input are reduced.

Description

Method and device for generating application program
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method and an apparatus for generating an application program.
Background
With the rapid development of the internet, the mobile terminal APP has gradually merged into the life of people. At present, mobile terminal APP is developed based on local respective languages, for example, an iOS system uses OC (object-c) and Swift languages, an Android system uses java and Kotlin languages, and the like, and currently, a React Native and a Flutter framework developed across platforms are also derived.
However, the existing real Native and Flutter frameworks and the optimization of language levels such as Swift and Kotlin all have technical thresholds, that is, research and development personnel are required to have certain research and development capabilities, and a research and development team also needs to consume large labor and time costs in the research and development process.
Disclosure of Invention
In view of this, embodiments of the present invention provide a method and an apparatus for generating an application, which can at least solve a phenomenon that development of APP requires research and development capabilities of developers in the prior art.
To achieve the above object, according to an aspect of an embodiment of the present invention, there is provided a method of generating an application, including:
in response to the selection operation of a first template, determining template components corresponding to the first template, and retrieving codes corresponding to the template components from a code library;
converting the identification, the name and the mapping object of the first template into data in a preset format; wherein, the mapping object records the template information of the first template;
and packaging the data with the preset format and the codes to obtain a code packet corresponding to the first template and outputting the code packet so as to generate an application program through the code packet.
Optionally, the determining the template component corresponding to the first template, and retrieving the code corresponding to each template component from a code library, further includes: displaying attribute information corresponding to the template component, responding to deletion operation of the template component and/or modification operation of attribute values in the attribute information, generating a second template, and adjusting the code;
the converting the identification, the name and the mapping object of the first template into data in a predetermined format includes: receiving input of the identification and the name of the second template, creating a mapping object, and converting the input identification, the name and the created mapping object into data in a predetermined format;
the packing the data with the preset format and the codes to obtain and output the code package corresponding to the first template comprises the following steps: and packaging the data with the preset format and the adjusted codes to obtain and output a code packet corresponding to the second template.
Optionally, the converting the identifier, the name, and the mapping object of the first template into data in a predetermined format further includes:
responding to click operation on the dependency relationship, acquiring and displaying a template list associated with the first template according to the identification, receiving selection operation on a third template in the template list, and taking the third template as a next template of the first template; and
converting the identification, the name and the mapping object of the third template into data in a preset format;
the packing the data with the preset format and the codes to obtain and output the code package corresponding to the first template comprises the following steps: packing the preset format data of a first template, the preset format data of a third template, codes corresponding to all template components in the first template and codes corresponding to all template components in the third template to generate and output a code package; wherein the predetermined format data of the first template comprises an identification of the third template.
Optionally, before the determining, in response to the selection operation on the first template, a template component corresponding to the first template, the method further includes: responding to the selection operation of an operating system, extracting and displaying a template list corresponding to the operating system; the operating system is an android system, an iOS system or a third-party system;
the retrieving of the code corresponding to each template component from the code library includes: retrieving codes corresponding to the operating system and the template components from a code library;
the packing the predetermined format data and the code includes: and packaging the data with the preset format and the code based on a packaging mode corresponding to the operating system.
To achieve the above object, according to another aspect of the embodiments of the present invention, there is provided an apparatus for generating an application, including:
the selection module is used for responding to selection operation of a first template, determining template components corresponding to the first template, and retrieving codes corresponding to the template components from a code library;
the conversion module is used for converting the identification, the name and the mapping object of the first template into data in a preset format; wherein, the mapping object records the template information of the first template;
and the packaging module is used for packaging the data with the preset format and the codes to obtain and output a code package corresponding to the first template so as to generate an application program through the code package.
Optionally, the selecting module is further configured to: displaying attribute information corresponding to the template component, responding to deletion operation of the template component and/or modification operation of attribute values in the attribute information, generating a second template, and adjusting the code;
the conversion module is configured to: receiving input of the identification and the name of the second template, creating a mapping object, and converting the input identification, the name and the created mapping object into data in a predetermined format;
the packaging module is used for: and packaging the data with the preset format and the adjusted codes to obtain and output a code packet corresponding to the second template.
Optionally, the conversion module is further configured to:
responding to click operation on the dependency relationship, acquiring and displaying a template list associated with the first template according to the identification, receiving selection operation on a third template in the template list, and taking the third template as a next template of the first template; and
converting the identification, the name and the mapping object of the third template into data in a preset format;
the packaging module is further configured to: packing the preset format data of a first template, the preset format data of a third template, codes corresponding to all template components in the first template and codes corresponding to all template components in the third template to generate and output a code package; wherein the predetermined format data of the first template comprises an identification of the third template.
Optionally, the system further includes an extraction module, configured to: responding to the selection operation of an operating system, extracting and displaying a template list corresponding to the operating system; the operating system is an android system, an iOS system or a third-party system;
the selection module is configured to: retrieving codes corresponding to the operating system and the template components from a code library;
the packaging module is used for: and packaging the data with the preset format and the code based on a packaging mode corresponding to the operating system.
To achieve the above object, according to still another aspect of embodiments of the present invention, there is provided an electronic device for generating an application program.
The electronic device of the embodiment of the invention comprises: one or more processors; a storage device, configured to store one or more programs, which when executed by the one or more processors, cause the one or more processors to implement any of the above methods for generating an application.
To achieve the above object, according to a further aspect of the embodiments of the present invention, there is provided a computer readable medium having a computer program stored thereon, the computer program, when executed by a processor, implementing any of the above methods for generating an application program.
According to the scheme provided by the invention, one embodiment of the invention has the following advantages or beneficial effects: a multi-terminal SDK library is established by developing a fixed template and a template component in the initial stage by a research and development team. And on the basis, a visual online editor is established for the user so that the user can configure the template assembly independently and change the attribute of the template, and the code configured in the SDK library is combined for assembly and packaging to generate the App suitable for different operating systems.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
FIG. 1 is a schematic main flow diagram of a method for generating an application according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of a multiple operating system generating a code package;
FIG. 3 is a schematic diagram of an online editor interface in accordance with an embodiment of the invention;
FIG. 4 is a flow diagram illustrating an alternative method of generating an application in accordance with an embodiment of the present invention;
FIG. 5 is a schematic diagram of the main modules of an apparatus for generating an application according to an embodiment of the present invention;
FIG. 6 is an exemplary system architecture diagram in which embodiments of the present invention may be employed;
FIG. 7 is a schematic block diagram of a computer system suitable for use with a mobile device or server implementing an embodiment of the invention.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Referring to fig. 1, a main flowchart of a method for generating an application according to an embodiment of the present invention is shown, which includes the following steps:
s101: in response to the selection operation of a first template, determining template components corresponding to the first template, and retrieving codes corresponding to the template components from a code library;
s102: converting the identification, the name and the mapping object of the first template into data in a preset format; wherein, the mapping object records the template information of the first template;
s103: and packaging the data with the preset format and the codes to obtain a code packet corresponding to the first template and outputting the code packet so as to generate an application program through the code packet.
In the above embodiment, for step S101, the Development team is used to develop the common templates and the template components (i.e., UI piece meta components) for different operating systems in advance in the initial stage, and a multi-port SDK (Software Development Kit) library is built, as shown in fig. 2. For example, the page templates, namely an Android system page template 1, an iOS system page template 2, and a third-party system (e.g., windows, phone) page template 3, may display the page template 1 after the user selects the Android system.
The scheme also builds an online editor, which is shown in fig. 3 and comprises a template online preview area, a UI fragment component selection area and a template attribute editing area, and is used for a user to select a template (namely, a first template), configure the template component and attribute information of the template component. For example, after the user selects the template "text _ info" in the template online preview area, the middle part of the interface displays the template preview, the upper left corner displays the template components required by the template "text _ info", and the upper right corner displays the attribute information corresponding to the template components, including the attribute names and the attribute values.
The SDK library also stores the codes of the template components in advance, and when the attribute information of the template components and the template components is not changed, the codes corresponding to the selected operating system and the template components can be directly retrieved from the SDK library. However, if the template component and the attribute information thereof are changed, the code thereof needs to be adapted, which is described in detail with reference to fig. 4.
For step S102, after the first template and the template component are selected, json data in a fixed format is output: [ { "id": id "," name ": name", "event _ next _ id": id "," data ":" { } "].
Wherein, the meaning of each field is as follows:
id template ID
Name Name of template
event_next_id Switched next template ID
Data Data required by template
If the user selects only one template, the event _ next _ id is a default value, such as 0. However, if the user needs to select a template after configuring the current first template, for example, multiple templates are needed for interface switching, and the dependency option may be clicked. The device determines a list of templates having associations/dependencies with the first template for selection by the user based on the identification of the first template in response to the operation by the user. For example, a third template in the template list is selected as a next template of the first template, and the ID of the third template is used as the value of event _ next _ ID.
It should be noted that some templates do not have a direct relationship, for example, the template 4 corresponds to a shopping interface, and the template 5 corresponds to a pet interface, so the associated template list of the template 4 does not include the template 5.
Each template can analyze the data content contained in the data according to different services, which also requires that each template contains a mapping object T with a data relationship for recording template information. And reflecting the data out of the mapping object T by using JSON (Java Server object notation) analysis tools related to each platform so as to complete business logic. The pseudo code is as follows:
public T parseData(String data){
return jsonUtil.parse(data);
}
for step S103, after the json data format conversion and the code of the template component are completed, the codes of the Android system and the iOS system are assembled and packaged through the gradle and the macro definition.
1. The Android system sets java and res resource directories in sourceSets through gradle:
sourceSets{
java.dirs=[Template1/java,Template2/java]
res.dirs=[Template1/res,Template2/res]
}
after the code engineering is assembled, constructing and outputting the engineering through a CI (Continuous content Integration) platform and a gradle script; wherein, CI belongs to the existing construction tool without innovation.
2. The iOS system sets source _ file and resources resource directory by configuring the podspec
se.run(){|root|
# Source File
s.source_files="#{root}/Template1/*.{h,m,mm,cpp,hpp}","#{root}/T emplate1/**/*.{h,m,mm,cpp,hpp}"
// resource setting
s.resources="#{root}/Template/Assets/*.*"
}
In addition, when the number of templates selected by the user is plural, json format data of each template and a code of a template component are packed at this time. For example, json data of the first template, json data of the third template, codes of template components in the first template, and codes of template components in the third template.
The method provided by the embodiment builds a set of platform for rapidly generating App for personnel with low research and development capability, is simple and feasible in overall operation, greatly improves research and development efficiency according to different templates of different operating systems, and reduces research and development cost of a team while reducing research and development thresholds.
Referring to fig. 4, a flow chart of an alternative method for generating an application according to an embodiment of the present invention is shown, including the following steps:
s401: responding to the selection operation of a first template, determining a template component corresponding to the first template, and displaying attribute information corresponding to the template component;
s402: responding to the deletion operation of the template component and/or the change operation of the attribute value in the attribute information, generating a second template, and adjusting the codes corresponding to the template components retrieved from the code library;
s403: receiving input of the identification and the name of the second template, creating a mapping object, and converting the input identification, the name and the created mapping object into data in a predetermined format;
s404: and packaging the data with the preset format and the adjusted codes to obtain and output a code packet corresponding to the second template so as to generate the application program through the code packet.
In the above embodiment, with respect to steps S401 and S402, also referring to fig. 3, the online editor includes a template online preview area, a UI fragment component selection area, and a template property editing area. After a user selects a template 'text _ info' in a template online preview area, a template component corresponding to the template 'text _ info' is displayed at the upper left corner of the interface, and attribute information corresponding to the template component, including an attribute name and an attribute value, is displayed at the upper right corner of the interface.
The user can edit and configure the template component in the UI fragment component selection area, because the first template is determined, the edit and configuration of the template component can only be deleting operation, and the change of the attribute information is only attribute value changing operation, but if a template component is deleted, the corresponding attribute information is adaptively deleted. In addition, the initial time of the attribute value is a default value, and the user can not change the attribute value beyond a certain range.
After the template component and/or attribute information of the first template is changed, the state of the first template may be different from that of the original first template, and the changed first template is set as the second template in order to be distinguished from the original first template. After the second template is generated, due to the change of the template components and the attribute information, the codes need to be adaptively adjusted, for example, if the template component 1 in the original first template is deleted, the codes of the template component 1 do not need to be acquired subsequently; the attribute value of the template component 2 is changed from "Null" to "3", and the corresponding code is also changed adaptively.
For steps S403 and S404, subsequent json format data conversion and code packaging are performed based on the second template.
The identification and name of the second template may be user-defined or may be generated based on the first template. For example, the name of the first template is text _ info, and the name of the corresponding second template is text _ info _1, which identifies the same. For the mapping object created for the second template, the mapping object of the first template may be copied and adapted.
According to the method provided by the embodiment, for the selected template, the user can change the template component and the attribute information according to the requirement of the user, so that the personalized template is obtained.
The splash screen interface and the home page of the e-commerce platform are taken as an example for explanation in connection with the embodiment. Firstly, a research and development team establishes two configurable templates respectively for an Android system and an iOS system, wherein the template 1 comprises a splash screen interface base map, a logo, file information, splash screen interface dwell time and attribute configuration after the end of the splash screen, and the first page of the template 2 comprises a banner button icon and a file and corresponding click attributes, and a bottom navigation button icon and a file and corresponding click attributes. Random template IDs (which may also be user-defined) are generated for template 1 and template 2.
And constructing a visual online editor, wherein a user can select a template and configure the template in the editor, such as a base map link, a logo, a file text, a flashing screen retention time, an event configuration after the flashing screen is finished and the like in the flashing screen template. And after the user operation is finished, outputting the ID, the name, the mapping object and the next template ID of the template in a json format, and searching a code corresponding to the template component from the SDK library.
The specific derivation format is (including partial information of template 1 and template 2, and template 2 is the next template of template 1):
[ { "id": 1"," name ": Splash", "event _ next _ id": 2"," data ":" { \ duration \ ": 1000\", \\ background \ ": backsound \ back _ background.jpg \", \\\ logo \ ": logo \ logo" }, { "id": 2"," name ": Index", "event _ next _ id": 2"," data "{ \\\ banner \" } [ { "icon \": i-con 1.jpg \ and \ "desc \ electrospark \ electronic commerce platform supermarket" } data "{" banner \ "}
\\ "event _ next \ \ 3\ \, { \ icon \ \ icon \ 2.jpg \ and \" desc \ digital electrical appliance
\\\ "event _ next \": 4\ 4 \\\\ \ me \ "menu \ me \ [ { \" icon \ \ ie \ "icon1.jpg \ me \\\" desc \ me \ e \ "E-commerce platform supermarket
\\ \ event _ next \ \ X \ \, \ icon \ desc \ icon2. digital appliance \ and \ event _ next \ X \ j \ } \
According to the configuration information, codes corresponding to the template components of the template 1 and the template components of the template 2 are selected from the Android system and the iOS system respectively and combined, and then packaging and outputting are carried out by using packaging tools of the operating systems.
According to the scheme, a research and development team develops the fixed template and the template component at the initial stage to establish a multi-terminal SDK library. And on the basis, a visual online editor is established for the user so that the user can configure the template assembly independently and change the attribute of the template, and the code configured in the SDK library is combined for assembly and packaging to generate the App suitable for different operating systems.
Referring to fig. 5, a schematic diagram of main modules of an apparatus 500 for generating an application according to an embodiment of the present invention is shown, including:
a selecting module 501, configured to determine, in response to a selection operation on a first template, template components corresponding to the first template, and retrieve codes corresponding to the template components from a code library;
a conversion module 502, configured to convert the identifier, the name, and the mapping object of the first template into data in a predetermined format; wherein, the mapping object records the template information of the first template;
and a packing module 503, configured to pack the data in the predetermined format and the code, obtain a code packet corresponding to the first template, and output the code packet, so as to generate an application program through the code packet.
In the device for implementing the present invention, the selecting module 501 is further configured to: displaying attribute information corresponding to the template component, responding to deletion operation of the template component and/or modification operation of attribute values in the attribute information, generating a second template, and adjusting the code;
the conversion module 502 is configured to: receiving input of the identification and the name of the second template, creating a mapping object, and converting the input identification, the name and the created mapping object into data in a predetermined format;
the packing module 503 is configured to: and packaging the data with the preset format and the adjusted codes to obtain and output a code packet corresponding to the second template.
In the device implemented by the present invention, the converting module 502 is further configured to:
responding to click operation on the dependency relationship, acquiring and displaying a template list associated with the first template according to the identification, receiving selection operation on a third template in the template list, and taking the third template as a next template of the first template; and
converting the identification, the name and the mapping object of the third template into data in a preset format;
the packing module 503 is further configured to: packing the preset format data of a first template, the preset format data of a third template, codes corresponding to all template components in the first template and codes corresponding to all template components in the third template to generate and output a code package; wherein the predetermined format data of the first template comprises an identification of the third template.
The apparatus further includes an extraction module 504 (not shown) for: responding to the selection operation of an operating system, extracting and displaying a template list corresponding to the operating system; the operating system is an android system, an iOS system or a third-party system;
the selecting module 501 is configured to: retrieving codes corresponding to the operating system and the template components from a code library;
the packing module 503 is configured to: and packaging the data with the preset format and the code based on a packaging mode corresponding to the operating system.
In addition, the detailed implementation of the device in the embodiment of the present invention has been described in detail in the above method, so that the repeated description is not repeated here.
FIG. 6 illustrates an exemplary system architecture 600 to which embodiments of the invention may be applied.
As shown in fig. 6, the system architecture 600 may include terminal devices 601, 602, 603, a network 604, and a server 605 (by way of example only). The network 604 serves to provide a medium for communication links between the terminal devices 601, 602, 603 and the server 605. Network 604 may include various types of connections, such as wire, wireless communication links, or fiber optic cables, to name a few.
A user may use the terminal devices 601, 602, 603 to interact with the server 605 via the network 604 to receive or send messages or the like. Various communication client applications can be installed on the terminal devices 601, 602, 603.
The terminal devices 601, 602, 603 may be various electronic devices having display screens and supporting web browsing, and the server 605 may be a server providing various services.
It should be noted that the method provided by the embodiment of the present invention is generally executed by the server 605, and accordingly, the apparatus is generally disposed in the server 605.
It should be understood that the number of terminal devices, networks, and servers in fig. 6 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
Referring now to FIG. 7, shown is a block diagram of a computer system 700 suitable for use with a terminal device implementing an embodiment of the present invention. The terminal device shown in fig. 7 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 7, the computer system 700 includes a Central Processing Unit (CPU)701, which can perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)702 or a program loaded from a storage section 708 into a Random Access Memory (RAM) 703. In the RAM 703, various programs and data necessary for the operation of the system 700 are also stored. The CPU 701, the ROM 702, and the RAM 703 are connected to each other via a bus 704. An input/output (I/O) interface 705 is also connected to bus 704.
The following components are connected to the I/O interface 705: an input portion 706 including a keyboard, a mouse, and the like; an output section 707 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage section 708 including a hard disk and the like; and a communication section 709 including a network interface card such as a LAN card, a modem, or the like. The communication section 709 performs communication processing via a network such as the internet. A drive 710 is also connected to the I/O interface 705 as needed. A removable medium 711 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 710 as necessary, so that a computer program read out therefrom is mounted into the storage section 708 as necessary.
In particular, according to the embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program can be downloaded and installed from a network through the communication section 709, and/or installed from the removable medium 711. The computer program performs the above-described functions defined in the system of the present invention when executed by the Central Processing Unit (CPU) 701.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules described in the embodiments of the present invention may be implemented by software or hardware. The described modules may also be provided in a processor, which may be described as: a processor includes a selection module, a conversion module, and a packing module. Where the names of these modules do not in some cases constitute a limitation on the module itself, for example, a packing module may also be described as a "packing code package module".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to comprise:
in response to the selection operation of a first template, determining template components corresponding to the first template, and retrieving codes corresponding to the template components from a code library;
converting the identification, the name and the mapping object of the first template into data in a preset format; wherein, the mapping object records the template information of the first template;
and packaging the data with the preset format and the codes to obtain a code packet corresponding to the first template and outputting the code packet so as to generate an application program through the code packet.
According to the technical scheme of the embodiment of the invention, a multi-terminal SDK library is established by developing the fixed template and the template component in the initial stage by a research and development team. And on the basis, a visual online editor is established for the user so that the user can configure the template assembly independently and change the attribute of the template, and the code configured in the SDK library is combined for assembly and packaging to generate the App suitable for different operating systems.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (10)

1. A method of generating an application, comprising:
in response to the selection operation of a first template, determining template components corresponding to the first template, and retrieving codes corresponding to the template components from a code library;
converting the identification, the name and the mapping object of the first template into data in a preset format; wherein, the mapping object records the template information of the first template;
and packaging the data with the preset format and the codes to obtain a code packet corresponding to the first template and outputting the code packet so as to generate an application program through the code packet.
2. The method of claim 1, wherein determining the template components corresponding to the first template, retrieving the code corresponding to each template component from a code library, further comprises: displaying attribute information corresponding to the template component, responding to deletion operation of the template component and/or modification operation of attribute values in the attribute information, generating a second template, and adjusting the code;
the converting the identification, the name and the mapping object of the first template into data in a predetermined format includes: receiving input of the identification and the name of the second template, creating a mapping object, and converting the input identification, the name and the created mapping object into data in a predetermined format;
the packing the data with the preset format and the codes to obtain and output the code package corresponding to the first template comprises the following steps: and packaging the data with the preset format and the adjusted codes to obtain and output a code packet corresponding to the second template.
3. The method of claim 1, wherein converting the identification, name, and mapping object of the first template into predetermined format data further comprises:
responding to click operation on the dependency relationship, acquiring and displaying a template list associated with the first template according to the identification, receiving selection operation on a third template in the template list, and taking the third template as a next template of the first template; and
converting the identification, the name and the mapping object of the third template into data in a preset format;
the packing the data with the preset format and the codes to obtain and output the code package corresponding to the first template comprises the following steps: packing the preset format data of a first template, the preset format data of a third template, codes corresponding to all template components in the first template and codes corresponding to all template components in the third template to generate and output a code package; wherein the predetermined format data of the first template comprises an identification of the third template.
4. The method according to any one of claims 1-3, further comprising, prior to said determining a template component corresponding to a first template in response to a selection operation on the first template: responding to the selection operation of an operating system, extracting and displaying a template list corresponding to the operating system; the operating system is an android system, an iOS system or a third-party system;
the retrieving of the code corresponding to each template component from the code library includes: retrieving codes corresponding to the operating system and the template components from a code library;
the packing the predetermined format data and the code includes: and packaging the data with the preset format and the code based on a packaging mode corresponding to the operating system.
5. An apparatus for generating an application, comprising:
the selection module is used for responding to selection operation of a first template, determining template components corresponding to the first template, and retrieving codes corresponding to the template components from a code library;
the conversion module is used for converting the identification, the name and the mapping object of the first template into data in a preset format; wherein, the mapping object records the template information of the first template;
and the packaging module is used for packaging the data with the preset format and the codes to obtain and output a code package corresponding to the first template so as to generate an application program through the code package.
6. The apparatus of claim 5, wherein the selection module is further configured to: displaying attribute information corresponding to the template component, responding to deletion operation of the template component and/or modification operation of attribute values in the attribute information, generating a second template, and adjusting the code;
the conversion module is configured to: receiving input of the identification and the name of the second template, creating a mapping object, and converting the input identification, the name and the created mapping object into data in a predetermined format;
the packaging module is used for: and packaging the data with the preset format and the adjusted codes to obtain and output a code packet corresponding to the second template.
7. The apparatus of claim 5, wherein the conversion module is further configured to:
responding to click operation on the dependency relationship, acquiring and displaying a template list associated with the first template according to the identification, receiving selection operation on a third template in the template list, and taking the third template as a next template of the first template; and
converting the identification, the name and the mapping object of the third template into data in a preset format;
the packaging module is further configured to: packing the preset format data of a first template, the preset format data of a third template, codes corresponding to all template components in the first template and codes corresponding to all template components in the third template to generate and output a code package; wherein the predetermined format data of the first template comprises an identification of the third template.
8. The apparatus of any one of claims 5-7, further comprising an extraction module to: responding to the selection operation of an operating system, extracting and displaying a template list corresponding to the operating system; the operating system is an android system, an iOS system or a third-party system;
the selection module is configured to: retrieving codes corresponding to the operating system and the template components from a code library;
the packaging module is used for: and packaging the data with the preset format and the code based on a packaging mode corresponding to the operating system.
9. An electronic device, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-4.
10. A computer-readable medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-4.
CN202010653297.7A 2020-07-08 2020-07-08 Method and device for generating application program Pending CN113760248A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010653297.7A CN113760248A (en) 2020-07-08 2020-07-08 Method and device for generating application program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010653297.7A CN113760248A (en) 2020-07-08 2020-07-08 Method and device for generating application program

Publications (1)

Publication Number Publication Date
CN113760248A true CN113760248A (en) 2021-12-07

Family

ID=78785517

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010653297.7A Pending CN113760248A (en) 2020-07-08 2020-07-08 Method and device for generating application program

Country Status (1)

Country Link
CN (1) CN113760248A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114461358A (en) * 2021-12-22 2022-05-10 阿里巴巴(中国)有限公司 Service processing method and system

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103176785A (en) * 2011-12-26 2013-06-26 中国电信股份有限公司 Widget application online implement system and method
WO2017072872A1 (en) * 2015-10-28 2017-05-04 株式会社日立製作所 Business program generation assistance system and business program generation assistance method
CN107579851A (en) * 2017-09-14 2018-01-12 郑州云海信息技术有限公司 The method and apparatus for determining the execution sequence of resource layout template
CN108170656A (en) * 2017-12-28 2018-06-15 阿里巴巴集团控股有限公司 Template establishment method, document creating method, rendering intent and device
US10108399B1 (en) * 2016-08-25 2018-10-23 Worldplay, LLC Systems and methods for translating data read from proxy APIs into computing code
CN108780465A (en) * 2016-03-25 2018-11-09 微软技术许可有限责任公司 The dependence identification based on attribute for operation sequencing
CN110727431A (en) * 2019-09-17 2020-01-24 阿里巴巴集团控股有限公司 Applet generation method and apparatus
CN110955418A (en) * 2019-12-13 2020-04-03 中国南方电网有限责任公司 Code generation method and device, computer equipment and storage medium

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103176785A (en) * 2011-12-26 2013-06-26 中国电信股份有限公司 Widget application online implement system and method
WO2017072872A1 (en) * 2015-10-28 2017-05-04 株式会社日立製作所 Business program generation assistance system and business program generation assistance method
CN108780465A (en) * 2016-03-25 2018-11-09 微软技术许可有限责任公司 The dependence identification based on attribute for operation sequencing
US10108399B1 (en) * 2016-08-25 2018-10-23 Worldplay, LLC Systems and methods for translating data read from proxy APIs into computing code
CN107579851A (en) * 2017-09-14 2018-01-12 郑州云海信息技术有限公司 The method and apparatus for determining the execution sequence of resource layout template
CN108170656A (en) * 2017-12-28 2018-06-15 阿里巴巴集团控股有限公司 Template establishment method, document creating method, rendering intent and device
CN110727431A (en) * 2019-09-17 2020-01-24 阿里巴巴集团控股有限公司 Applet generation method and apparatus
CN110955418A (en) * 2019-12-13 2020-04-03 中国南方电网有限责任公司 Code generation method and device, computer equipment and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
阳林;及俊川;李新;: "一种可视化代码生成器的研究及应用", 科研信息化技术与应用, no. 02, 20 March 2016 (2016-03-20) *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114461358A (en) * 2021-12-22 2022-05-10 阿里巴巴(中国)有限公司 Service processing method and system

Similar Documents

Publication Publication Date Title
CN109634598B (en) Page display method, device, equipment and storage medium
US20210034336A1 (en) Executing a process-based software application in a first computing environment and a second computing environment
CN109918607B (en) Page construction method and device, medium and computing equipment
CN113504908A (en) Business code generation method and device, electronic equipment and computer readable medium
CN109725901A (en) Development approach, device, equipment and the computer storage medium of front-end code
CN112540763A (en) Front-end page generation method and device, platform equipment and storage medium
CN112100550A (en) Page construction method and device
CN110780874B (en) Method and device for generating information
CN106027785A (en) Voice processing method and terminal
CN110795181A (en) Application program interface display method and device based on skip protocol and electronic equipment
CN109814957B (en) Label adding method and device for IOS (input/output system)
CN113760276A (en) Method and device for generating page code
CN112214250B (en) Application program component loading method and device
WO2023092580A1 (en) Page display method and apparatus, storage medium, and electronic device
CN109766095A (en) A kind of thematic page creation method of activity, relevant apparatus and equipment
CN113760248A (en) Method and device for generating application program
CN112926008A (en) Method and device for generating form page, electronic equipment and storage medium
CN112965713A (en) Development method, device and equipment of visual editor and storage medium
CN116048517B (en) API (application program interface) generating method, system and device based on B/S (browser/Server) architecture application system
CN115469849A (en) Service processing system, method, electronic device and storage medium
CN113535037A (en) Interactive display method and device for command line terminal, computer readable medium and equipment
CN111880698A (en) Information processing method and device of intelligent terminal, electronic equipment and storage medium
CN110704537A (en) Intelligent contract generation method, device, equipment and storage medium
CN113806596B (en) Operation data management method and related device
CN115951869A (en) Page development method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination