Component publishing method, device, electronic device and storage medium

By obtaining and compressing the dependent components of the target component and generating resource acquisition addresses, the problem of large storage space occupied by the target program caused by the UI component library is solved, and more efficient component resource management is achieved.

CN114138289BActive Publication Date: 2024-10-25BEIJING DAJIA INTERNET INFORMATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111452453.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-11-30
Publication Date
2024-10-25
Estimated Expiration
2041-11-30

AI Technical Summary

Technical Problem

When traditional technology uses UI component libraries for program development, the target program tends to occupy a large storage space because all components need to be introduced, resulting in redundant data packages.

Method used

By obtaining the dependent component mapping relationship of the target component, determining and compressing the dependent component collection, generating the resource acquisition address, and publishing the component release document, developers are allowed to obtain dependent component resources through the document without introducing all UI component library components.

Benefits of technology

Redundant data of the target program is reduced, unnecessary storage space is avoided, and development efficiency is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114138289B_ABST
    Figure CN114138289B_ABST
Patent Text Reader

Abstract

The present disclosure relates to a component publishing method, device, electronic device and storage medium, the method comprising: obtaining the dependent component mapping relationship corresponding to each target component in the target component set; determining the dependent components of each target component in the target component library based on the dependent component mapping relationship, and obtaining the dependent component set corresponding to each target component; generating the resource acquisition address corresponding to each dependent component set; and publishing the component publishing document including the resource acquisition address. The present disclosure can avoid the target program from occupying a large storage space and improve the development efficiency of the target program.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, and in particular to a component publishing method, device, electronic device, and storage medium. Background Art

[0002] A component may refer to encapsulating one or several code segments that perform their respective functions into one or several independent parts.

[0003] When using a UI (user interface) component library for program development in the traditional technology, developers often need to introduce all components in the UI component library into the target program, which easily causes the target program to occupy a large storage space. Summary of the invention

[0004] The present disclosure provides a component publishing method, device, electronic device and storage medium to at least solve the problem in the related art that the target program occupies a large storage space. The technical solution of the present disclosure is as follows:

[0005] According to a first aspect of an embodiment of the present disclosure, a component publishing method is provided, including:

[0006] For each target component in the target component set, obtaining a dependent component mapping relationship corresponding to each target component;

[0007] Based on the mapping relationship between the dependent components, the dependent components of each target component are determined in the target component library to obtain a set of dependent components corresponding to each target component;

[0008] Generate resource acquisition addresses corresponding to each of the dependent component sets;

[0009] A component release document including the resource acquisition addresses is published.

[0010] In a possible implementation, for each target component in the target component set, obtaining the component dependency relationship corresponding to each target component includes:

[0011] Read the component configuration file corresponding to the target component;

[0012] Determine the dependent component mapping relationship corresponding to the target component according to the dependent component description information in the component configuration file.

[0013] In a possible implementation, based on the mapping relationship between the dependent components, determining the dependent components of each target component in the target component library to obtain a set of dependent components corresponding to each target component includes:

[0014] Based on the mapping relationship between the dependent components, determining the dependent components of each target component in the target component library;

[0015] Adding the dependent components of the target component to the file directory corresponding to the target component;

[0016] The files in the file directory are compressed and packaged to obtain a compressed package of dependent components of the target component.

[0017] In a possible implementation, generating a resource acquisition address corresponding to each dependent component set includes:

[0018] Sending a compressed package of the dependent components of the target component to a target server; the target server is used to store data resources corresponding to the compressed package of the dependent components and generate a resource acquisition address of the compressed package of the dependent components;

[0019] Receive the resource acquisition address returned by the target server.

[0020] In a possible implementation, the publishing includes a component publishing document including each resource acquisition address, including:

[0021] Receiving a request for obtaining the component publishing document sent by the user terminal;

[0022] In response to the acquisition request, the component publishing document is sent to the user terminal.

[0023] In a possible implementation, based on the mapping relationship between the dependent components, determining the dependent components of each target component in the target component library to obtain a set of dependent components corresponding to each target component includes:

[0024] Determine the component name corresponding to the dependent component of the target component according to the dependent component mapping relationship corresponding to the target component;

[0025] According to the component name, dependent components of the target component are queried in the target component library.

[0026] According to a second aspect of an embodiment of the present disclosure, there is provided a component publishing device, comprising:

[0027] An acquisition unit is configured to execute, for each target component in the target component set, acquiring a dependent component mapping relationship corresponding to each target component;

[0028] A determination unit is configured to determine the dependent components of each target component in the target component library based on the mapping relationship between the dependent components, and obtain a dependent component set corresponding to each target component;

[0029] A generating unit, configured to generate resource acquisition addresses corresponding to each of the dependent component sets;

[0030] The publishing unit is configured to execute publishing of a component publishing document including each resource acquisition address.

[0031] In a possible implementation, the acquisition unit is specifically configured to read a component configuration file corresponding to the target component; and determine a dependent component mapping relationship corresponding to the target component according to dependent component description information in the component configuration file.

[0032] In one possible implementation, the determination unit is specifically configured to determine the dependent components of each target component in the target component library based on the mapping relationship between the dependent components; add the dependent components of the target component to a file directory corresponding to the target component; and compress and package the files in the file directory to obtain a compressed package of the dependent components of the target component.

[0033] In one possible implementation, the generation unit is specifically configured to execute sending a compressed package of a dependent component of the target component to a target server; the target server is used to store data resources corresponding to the compressed package of the dependent component and generate a resource acquisition address of the compressed package of the dependent component; and receive the resource acquisition address returned by the target server.

[0034] In a possible implementation, the publishing unit is specifically configured to execute receiving a request for obtaining the component publishing document sent by a user terminal; and sending the component publishing document to the user terminal in response to the request for obtaining the component publishing document.

[0035] In one possible implementation, the determination unit is specifically configured to determine the component name corresponding to the dependent component of the target component according to a dependent component mapping relationship corresponding to the target component; and query the dependent component of the target component in the target component library according to the component name.

[0036] According to a third aspect of an embodiment of the present disclosure, there is provided an electronic device, comprising a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the component publishing method as described in the first aspect or any possible implementation manner of the first aspect is implemented.

[0037] According to a fourth aspect of an embodiment of the present disclosure, a storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the component publishing method as described in the first aspect or any possible implementation manner of the first aspect is implemented.

[0038] According to a fifth aspect of an embodiment of the present disclosure, a computer program product is provided, the program product comprising a computer program, the computer program being stored in a readable storage medium, at least one processor of a device reading and executing the computer program from the readable storage medium, so that the device executes the component publishing method described in any possible implementation of the first aspect.

[0039] The technical solution provided by the embodiments of the present disclosure brings at least the following beneficial effects: for each target component in the target component set, by obtaining the dependent component mapping relationship corresponding to each target component, and based on the dependent component mapping relationship, the dependent components of each target component are determined in the target component library, the dependent component set corresponding to each target component is obtained, and then the resource acquisition address corresponding to each dependent component set is generated, and finally, by publishing a component release document including each resource acquisition address; in this way, when developers are developing a target program, they do not need to read the source code of each component, but can obtain the file resources of the dependent components of each component through the resource acquisition address in the component release document. At the same time, developers do not need to introduce all components in the UI component library for the target program, thereby reducing the redundant data of the target program data packet, and thus avoiding the target program from occupying excess storage space.

[0040] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] The drawings herein are incorporated into and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the description are used to explain the principles of the present disclosure, and do not constitute improper limitations on the present disclosure.

[0042] Figure 1 The invention is an application environment diagram showing a component publishing method according to an exemplary embodiment.

[0043] Figure 2 The figure is a flowchart of a component publishing method according to an exemplary embodiment.

[0044] Figure 3 The figure is a flowchart of another component publishing method according to an exemplary embodiment.

[0045] Figure 4 The invention is a block diagram of a component publishing device according to an exemplary embodiment.

[0046] Figure 5 It is a block diagram of an electronic device according to an exemplary embodiment. DETAILED DESCRIPTION

[0047] In order to enable ordinary persons in the art to better understand the technical solutions of the present disclosure, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the accompanying drawings.

[0048] It should be noted that the terms "first", "second", etc. in the specification and claims of the present disclosure and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present disclosure described herein can be implemented in an order other than those illustrated or described herein. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.

[0049] It should also be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for display, data for analysis, etc.) involved in this disclosure are all information and data authorized by the user or fully authorized by all parties.

[0050] The component publishing method provided in the present disclosure can be applied to Figure 1 In the application environment shown in the figure, the electronic device 104 obtains the dependent component mapping relationship corresponding to each target component in the target component set; the electronic device 104 determines the dependent components of each target component in the target component library based on the dependent component mapping relationship, and obtains the dependent component set corresponding to each target component; the electronic device 104 generates the resource acquisition address corresponding to each dependent component set; the electronic device 104 publishes the component publishing document including each resource acquisition address to the terminal 102.

[0051] Figure 2 is a flowchart of a component publishing method according to an exemplary embodiment. Figure 2 As shown, the component publishing method is used in an electronic device and includes the following steps.

[0052] In step S210, for each target component in the target component set, a dependent component mapping relationship corresponding to each target component is obtained.

[0053] The dependent component mapping relationship may refer to a mapping relationship between a target component and a dependent component of the target component.

[0054] Among them, the component can be a UI (user interface) component.

[0055] The target component set may refer to a set of UI components.

[0056] In a specific implementation, for each target component in the target component set, the electronic device can obtain the dependent component mapping relationship corresponding to each target component. The electronic device can read the component configuration file corresponding to the target component; then, the electronic device can determine the dependent component mapping relationship corresponding to the target component according to the dependent component description information in the component configuration file.

[0057] In step S220, based on the mapping relationship between the dependent components, the dependent components of each target component are determined in the target component library to obtain a dependent component set corresponding to each target component.

[0058] In a specific implementation, the electronic device can determine the component identifier corresponding to the dependent component of the target component according to the dependent component mapping relationship corresponding to the target component; and query the dependent component of the target component in the target component library according to the component identifier.

[0059] In step S230, a resource acquisition address corresponding to each dependent component set is generated.

[0060] In a specific implementation, the electronic device may upload the dependent component set corresponding to each target component to a content distribution network (CDN) in the form of a compressed package.

[0061] In step S240, a component publishing document including each resource acquisition address is published.

[0062] In a specific implementation, the electronic device may publish a component publishing document including various resource acquisition addresses.

[0063] The above-mentioned component publishing method, for each target component in the target component set, obtains the dependent component mapping relationship corresponding to each target component, and based on each dependent component mapping relationship, determines the dependent components of each target component in the target component library, obtains the dependent component set corresponding to each target component, and then generates the resource acquisition address corresponding to each dependent component set, and finally, publishes the component publishing document including the resource acquisition address; in this way, when the developer is developing the target program, the developer does not need to read the source code of each component, but can obtain the file resources of the dependent components of each component through the resource acquisition address in the component publishing document. At the same time, the developer does not need to introduce all the components in the UI component library for the target program, thereby reducing the redundant data of the target program data packet, and thus avoiding the target program from occupying excess storage space.

[0064] In an exemplary embodiment, for each target component in a target component set, the component dependency relationship corresponding to each target component is obtained, including: reading a component configuration file corresponding to the target component; and determining a dependent component mapping relationship corresponding to the target component according to dependent component description information in the component configuration file.

[0065] The component configuration file includes information for describing component dependency relationships corresponding to the target component.

[0066] In a specific implementation, when the electronic device obtains the component dependency relationship corresponding to each target component in the target component set, the electronic device can read the component configuration file corresponding to the target component; then, the electronic device can determine the dependency component mapping relationship corresponding to the target component based on the dependency component description information in the component configuration file.

[0067] The technical solution of this embodiment reads the component configuration file corresponding to the target component and can accurately determine the dependent component mapping relationship corresponding to the target component according to the dependent component description information in the component configuration file.

[0068] In an exemplary embodiment, based on the mapping relationships among the dependent components, the dependent components of each target component are determined in the target component library to obtain a set of dependent components corresponding to each target component, including: based on the mapping relationships among the dependent components, the dependent components of each target component are determined in the target component library; the dependent components of the target component are added to the file directory corresponding to the target component; and the files in the file directory are compressed and packaged to obtain a compressed package of the dependent components of the target component.

[0069] In a specific implementation, the electronic device determines the dependent components of each target component in the target component library based on the mapping relationship of each dependent component, and obtains the dependent component set corresponding to each target component. The electronic device adds the dependent components of the target component to the file directory corresponding to the target component; and compresses and packages the files in the file directory to obtain a compressed package of the dependent components of the target component.

[0070] Specifically, the electronic device can read the dependency information in the configuration file for each UI component, and recursively put all dependent components of the component into the same directory by executing the node script. Then, the electronic device automatically zips the directory through the node script to form a zip compressed package of the dependent components of the target component.

[0071] The technical solution of this embodiment is to determine the dependent components of each target component in the target component library based on the mapping relationship of each dependent component; add the dependent components of the target component to the file directory corresponding to the target component; compress and package the files in the file directory to obtain a compressed package of the dependent components of the target component, thereby compressing and packaging the dependent components corresponding to each target component, which is convenient for the subsequent distribution of the dependent components of each component.

[0072] In an exemplary embodiment, generating a resource acquisition address corresponding to each dependent component set includes: sending a dependent component compression package of the target component to a target server; and receiving the resource acquisition address returned by the target server.

[0073] The target server is used to store data resources corresponding to the dependent component compressed package and generate a resource acquisition address of the dependent component compressed package. In practical applications, the target server may be a server in a content delivery network (CDN).

[0074] In a specific implementation, in the process of generating resource acquisition addresses corresponding to each dependent component set, the electronic device may upload the dependent component compressed package of the target component to a server in a content delivery network (CDN). The server in the content delivery network (CDN) may store the data resources corresponding to the received dependent component compressed package in a preset database, generate a resource acquisition address of the dependent component compressed package, and send the resource acquisition address to the electronic device, so that the electronic device receives the resource acquisition address returned by the target server.

[0075] The technical solution of this embodiment is to send the dependent component compressed package of the target component to the target server, so that the target server stores the data resources corresponding to the dependent component compressed package and generates a resource acquisition address of the dependent component compressed package, thereby realizing the generation of the resource acquisition address corresponding to each dependent component set.

[0076] In an exemplary embodiment, publishing a component publishing document including various resource acquisition addresses includes: receiving an acquisition request sent by a user terminal for the component publishing document; and sending the component publishing document to the user terminal in response to the acquisition request.

[0077] In a specific implementation, when an electronic device publishes a component release document including various resource acquisition addresses, when a user needs to obtain the component release document, the user can send an acquisition request for the component release document through a user terminal. After the electronic device receives the acquisition request sent by the user terminal for the component release document, the electronic device responds to the acquisition request and sends the component release document to the user terminal, which is then received by the user terminal. After the user terminal receives the component release document, the user can obtain the dependent component compressed package of the required UI component through the resource acquisition address in the component release document.

[0078] The technical solution of this embodiment receives an acquisition request sent by a user terminal for a component release document; in response to the acquisition request, the component release document is sent to the user terminal, thereby being able to promptly respond to the needs of developers and promptly send the component release document to the developer's user terminal.

[0079] In an exemplary embodiment, the method also includes: in response to an access operation to at least one resource acquisition address in a component release document, determining a target component corresponding to the accessed resource acquisition address; sending a compressed package acquisition request for the target component to a target server; the target server is used to return a dependent component compressed package corresponding to the target component in response to the compressed package acquisition request; and receiving the dependent component compressed package returned by the target server.

[0080] In a specific implementation, the electronic device can determine the target component corresponding to the accessed resource acquisition address in response to an access operation on at least one resource acquisition address in a component release document; then, the electronic device sends a compressed package acquisition request for the target component to the target server, for the target server to receive the compressed package acquisition request.

[0081] After receiving the compressed package acquisition request, the target server responds to the compressed package acquisition request and returns the dependent component compressed package corresponding to the target component to the user terminal, so that the user terminal receives the dependent component compressed package returned by the target server.

[0082] In an exemplary embodiment, based on the mapping relationship between each dependent component, the dependent components of each target component are determined in the target component library to obtain a set of dependent components corresponding to each target component, including: determining the component name corresponding to the dependent component of the target component according to the mapping relationship between the dependent components corresponding to the target component; and querying the dependent components of the target component in the target component library according to the component name.

[0083] In a specific implementation, when the electronic device determines the dependent components of each target component in the target component library based on the mapping relationship of each dependent component and obtains the dependent component set corresponding to each target component, the electronic device can determine the component name corresponding to the dependent component of the target component according to the dependent component mapping relationship corresponding to the target component; then, the electronic device retrieves the component corresponding to the component name in the target component library based on the component name as the dependent component of the target component.

[0084] The technical solution of this embodiment determines the component name corresponding to the dependent component of the target component according to the dependent component mapping relationship corresponding to the target component, and accurately queries the dependent component of the target component in the target component library according to the component name.

[0085] Figure 3 is a flowchart of another component publishing method according to an exemplary embodiment. Figure 3 As shown, this method is used to Figure 1 In the electronic device, the following steps are included.

[0086] In step S310, for each target component in the target component set, a component configuration file corresponding to the target component is read.

[0087] In step S320, a dependent component mapping relationship corresponding to the target component is determined according to the dependent component description information in the component configuration file.

[0088] In step S330, based on the mapping relationship between the dependent components, the dependent components of each target component are determined in the target component library, and the dependent components of the target component are added to the file directory corresponding to the target component.

[0089] In step S340, the files in the file directory are compressed and packaged to obtain a compressed package of dependent components of the target component.

[0090] In step S350, the dependent component compressed package of the target component is sent to the target server; the target server is used to store the data resources corresponding to the dependent component compressed package and generate a resource acquisition address of the dependent component compressed package.

[0091] In step S360, the resource acquisition address returned by the target server is received.

[0092] In step S370, a component publishing document including the resource acquisition addresses is published.

[0093] It should be noted that the specific limitations of the above steps can be found in the specific limitations of a component publishing method mentioned above, which will not be repeated here.

[0094] It should be understood that although Figure 2 and Figure 3 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 2 and Figure 3 At least part of the steps may include multiple steps or multiple stages. These steps or stages are not necessarily performed at the same time, but can be performed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed in turn or alternately with other steps or at least part of the steps or stages in other steps.

[0095] It can be understood that the same / similar parts between the various embodiments of the above method in this specification can refer to each other, and each embodiment focuses on the differences from other embodiments. For related points, please refer to the description of other method embodiments.

[0096] Figure 4 is a block diagram of a component publishing device according to an exemplary embodiment. Figure 4 , the device comprises:

[0097] The acquisition unit 410 is configured to execute, for each target component in the target component set, acquiring a dependent component mapping relationship corresponding to each target component;

[0098] The determining unit 420 is configured to determine the dependent components of each target component in the target component library based on the mapping relationship between the dependent components, and obtain a dependent component set corresponding to each target component;

[0099] A generating unit 430 is configured to generate a resource acquisition address corresponding to each of the dependent component sets;

[0100] The publishing unit 440 is configured to execute publishing of a component publishing document including the resource acquisition addresses.

[0101] In a possible implementation, the acquisition unit 410 is specifically configured to read a component configuration file corresponding to the target component; and determine a dependent component mapping relationship corresponding to the target component according to dependent component description information in the component configuration file.

[0102] In one possible implementation, the determination unit 420 is specifically configured to determine the dependent components of each target component in the target component library based on the mapping relationship between the dependent components; add the dependent components of the target component to the file directory corresponding to the target component; and compress and package the files in the file directory to obtain a compressed package of the dependent components of the target component.

[0103] In one possible implementation, the generation unit 430 is specifically configured to execute sending a compressed package of a dependent component of the target component to a target server; the target server is used to store data resources corresponding to the compressed package of the dependent component and generate a resource acquisition address of the compressed package of the dependent component; and receive the resource acquisition address returned by the target server.

[0104] In a possible implementation, the publishing unit 440 is specifically configured to execute receiving a request for obtaining the component publishing document sent by a user terminal; and sending the component publishing document to the user terminal in response to the request for obtaining the component publishing document.

[0105] In one possible implementation, the determination unit 420 is specifically configured to determine the component name corresponding to the dependent component of the target component according to the dependent component mapping relationship corresponding to the target component; and query the dependent component of the target component in the target component library according to the component name.

[0106] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0107] Figure 5 1 is a block diagram of an electronic device 500 for executing a component publishing method according to an exemplary embodiment. For example, the electronic device 500 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.

[0108] Reference Figure 5 , the electronic device 500 may include one or more of the following components: a processing component 502 , a memory 504 , a power component 506 , a multimedia component 508 , an audio component 510 , an input / output (I / O) interface 512 , a sensor component 514 , and a communication component 516 .

[0109] The processing component 502 generally controls the overall operation of the electronic device 500, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 502 may include one or more processors 520 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 502 may include one or more modules to facilitate the interaction between the processing component 502 and other components. For example, the processing component 502 may include a multimedia module to facilitate the interaction between the multimedia component 508 and the processing component 502.

[0110] The memory 504 is configured to store various types of data to support operations on the electronic device 500. Examples of such data include instructions for any application or method operating on the electronic device 500, contact data, phone book data, messages, pictures, videos, etc. The memory 504 may be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk, optical disk, or graphene memory.

[0111] The power supply component 506 provides power to the various components of the electronic device 500. The power supply component 506 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the electronic device 500.

[0112] The multimedia component 508 includes a screen that provides an output interface between the electronic device 500 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 508 includes a front camera and / or a rear camera. When the electronic device 500 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.

[0113] The audio component 510 is configured to output and / or input audio signals. For example, the audio component 510 includes a microphone (MIC), and when the electronic device 500 is in an operating mode, such as a call mode, a recording mode, and a speech recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 504 or sent via the communication component 516. In some embodiments, the audio component 510 also includes a speaker for outputting an audio signal.

[0114] I / O interface 512 provides an interface between processing component 502 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: a home button, a volume button, a start button, and a lock button.

[0115] The sensor assembly 514 includes one or more sensors for providing various aspects of status assessment for the electronic device 500. For example, the sensor assembly 514 can detect the open / closed state of the electronic device 500, the relative positioning of the components, such as the display and keypad of the electronic device 500, and the sensor assembly 514 can also detect the position change of the electronic device 500 or the components of the electronic device 500, the presence or absence of contact between the user and the electronic device 500, the orientation or acceleration / deceleration of the device 500, and the temperature change of the electronic device 500. The sensor assembly 514 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 514 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 514 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.

[0116] The communication component 516 is configured to facilitate wired or wireless communication between the electronic device 500 and other devices. The electronic device 500 can access a wireless network based on a communication standard, such as WiFi, a carrier network (such as 2G, 3G, 4G or 5G), or a combination thereof. In an exemplary embodiment, the communication component 516 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 516 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

[0117] In an exemplary embodiment, the electronic device 500 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the above methods.

[0118] In an exemplary embodiment, a computer-readable storage medium including instructions is also provided, such as a memory 504 including instructions, and the above instructions can be executed by the processor 520 of the electronic device 500 to perform the above method. For example, the computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0119] In an exemplary embodiment, a computer program product is further provided. The computer program product includes instructions. The instructions can be executed by the processor 520 of the electronic device 500 to complete the above method.

[0120] It should be noted that the above-mentioned devices, electronic devices, computer-readable storage media, computer program products, etc. may also include other implementation methods according to the description of the method embodiments. The specific implementation methods can refer to the description of the relevant method embodiments, which will not be described one by one here.

[0121] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. The present disclosure is intended to cover any variations, uses or adaptations of the present disclosure that follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The description and examples are to be considered exemplary only, and the true scope and spirit of the present disclosure are indicated by the claims.

[0122] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims

1. A component publishing method, characterized in that: include: For each target component in the target component set, obtaining a dependent component mapping relationship corresponding to each target component; Based on the mapping relationships of the dependent components, the dependent components of each target component are determined in the target component library to obtain a set of dependent components corresponding to each target component; including: based on the mapping relationships of the dependent components, the dependent components of each target component are determined in the target component library; the dependent components of the target component are added to the file directory corresponding to the target component; the file directory is compressed and packaged to obtain a compressed package of the dependent components of the target component; Generate a resource acquisition address corresponding to each dependent component set; including: sending a dependent component compressed package of the target component to a target server; the target server is used to store data resources corresponding to the dependent component compressed package and generate a resource acquisition address for the dependent component compressed package; receive the resource acquisition address returned by the target server; A component release document including the resource acquisition addresses is published.

2. The component publishing method according to claim 1, characterized in that: The step of obtaining component dependencies corresponding to each target component in the target component set includes: Read the component configuration file corresponding to the target component; Determine the dependent component mapping relationship corresponding to the target component according to the dependent component description information in the component configuration file.

3. The component publishing method according to claim 1, characterized in that: The method further comprises: In response to an access operation to at least one of the resource acquisition addresses in the component publishing document, determining a target component corresponding to the accessed resource acquisition address; Sending a compressed package acquisition request for the target component to the target server; the target server is used to respond to the compressed package acquisition request and return a dependent component compressed package corresponding to the target component; Receive the dependent component compressed package returned by the target server.

4. The component publishing method according to claim 1, characterized in that: The release includes a component release document containing each resource acquisition address, including: Receiving a document acquisition request sent by a user terminal for publishing a document of the component; In response to the document acquisition request, the component publishing document is sent to the user terminal.

5. The component publishing method according to claim 1, characterized in that: The step of determining the dependent components of each target component in the target component library based on the mapping relationship between the dependent components to obtain a set of dependent components corresponding to each target component includes: Determine the component name corresponding to the dependent component of the target component according to the dependent component mapping relationship corresponding to the target component; According to the component name, dependent components of the target component are queried in the target component library.

6. A component publishing device, characterized in that: include: An acquisition unit is configured to execute, for each target component in the target component set, acquiring a dependent component mapping relationship corresponding to each target component; A determination unit is configured to determine the dependent components of each target component in the target component library based on the mapping relationship between the dependent components, and obtain a dependent component set corresponding to each target component; A generating unit, configured to generate resource acquisition addresses corresponding to each of the dependent component sets; A publishing unit, configured to execute publishing of a component publishing document including each resource acquisition address; The determining unit is specifically configured to determine the dependent components of each target component in the target component library based on the mapping relationship between the dependent components; and add the dependent components of the target component to a file directory corresponding to the target component; Compress and package the files in the file directory to obtain a compressed package of dependent components of the target component; The generation unit is specifically configured to execute sending the dependent component compressed package of the target component to the target server; the target server is used to store the data resources corresponding to the dependent component compressed package and generate a resource acquisition address of the dependent component compressed package; and receive the resource acquisition address returned by the target server.

7. The component publishing device according to claim 6, characterized in that: The acquisition unit is specifically configured to read a component configuration file corresponding to the target component; and determine a dependent component mapping relationship corresponding to the target component according to dependent component description information in the component configuration file.

8. The component publishing device according to claim 6, characterized in that: The device also includes: an access unit, configured to execute an access operation in response to at least one of the resource acquisition addresses in the component release document, and determine the target component corresponding to the accessed resource acquisition address; a sending unit, configured to execute sending a compressed package acquisition request for the target component to the target server; the target server is used to return a dependent component compressed package corresponding to the target component in response to the compressed package acquisition request; and a receiving unit, configured to execute receiving the dependent component compressed package returned by the target server.

9. The component publishing device according to claim 6, characterized in that: The publishing unit is specifically configured to receive a document acquisition request sent by a user terminal for the component publishing document; and send the component publishing document to the user terminal in response to the document acquisition request.

10. The component publishing device according to claim 6, characterized in that: The determination unit is specifically configured to determine the component name corresponding to the dependent component of the target component according to the dependent component mapping relationship corresponding to the target component; and query the dependent component of the target component in the target component library according to the component name.

11. An electronic device, characterized in that: include: processor; a memory for storing instructions executable by the processor; The processor is configured to execute the instructions to implement the component publishing method according to any one of claims 1 to 5.

12. A computer-readable storage medium, characterized in that: When the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the component publishing method as claimed in any one of claims 1 to 5.

13. A computer program product, comprising instructions, characterized in that: When the instruction is executed by a processor of an electronic device, the electronic device is enabled to execute the component publishing method as described in any one of claims 1 to 5.