CN112506584A - Resource file loading method, device, equipment, storage medium and product - Google Patents

Resource file loading method, device, equipment, storage medium and product Download PDF

Info

Publication number
CN112506584A
CN112506584A CN202011522105.5A CN202011522105A CN112506584A CN 112506584 A CN112506584 A CN 112506584A CN 202011522105 A CN202011522105 A CN 202011522105A CN 112506584 A CN112506584 A CN 112506584A
Authority
CN
China
Prior art keywords
resource
loaded
resource file
target application
file
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.)
Granted
Application number
CN202011522105.5A
Other languages
Chinese (zh)
Other versions
CN112506584B (en
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 Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and 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 Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202011522105.5A priority Critical patent/CN112506584B/en
Publication of CN112506584A publication Critical patent/CN112506584A/en
Application granted granted Critical
Publication of CN112506584B publication Critical patent/CN112506584B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44568Immediately runnable code

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The disclosure provides a resource file loading method, a device, equipment, a storage medium and a product, and relates to the field of resource file loading. The specific implementation scheme is as follows: determining a resource file to be loaded for a target application; determining whether a local resource sharing directory contains resource files to be loaded or not, wherein the resource sharing directory contains resource files shared by different applications; and loading the resource files to be loaded from the resource sharing directory under the condition that the resource sharing directory contains the resource files to be loaded. The method and the device solve the problem that the application is installed for the first time and wastes a large amount of time to download the resource file, and can improve the loading speed of the resource file.

Description

Resource file loading method, device, equipment, storage medium and product
Technical Field
The disclosure relates to the technical field of data processing, in particular to the field of resource file loading.
Background
With the continuous improvement of the performance of intelligent terminals such as mobile phones and the like, in order to provide better game experience, the sizes of resources such as the polygonal faces of games and the size of a mapping file in an application are continuously increased, so that a large amount of time is wasted for downloading the resource files (such as the mapping and model files) when the application is installed for the first time.
Disclosure of Invention
The present disclosure provides a method, apparatus, device, storage medium and product for resource file loading.
According to an aspect of the present disclosure, a resource file loading method is provided, which is applied to a client, and includes:
determining a resource file to be loaded for a target application;
determining whether a local resource sharing directory contains resource files to be loaded or not, wherein the resource sharing directory contains resource files shared by different applications;
and loading the resource files to be loaded from the resource sharing directory under the condition that the resource sharing directory contains the resource files to be loaded.
According to another aspect of the present disclosure, there is provided a resource file loading apparatus, applied to a client, including:
the first determining module is used for determining a resource file to be loaded for the target application;
the second determining module is used for determining whether a local resource sharing directory contains resource files to be loaded, and the resource sharing directory contains resource files shared by different applications;
and the resource loading module is used for loading the resource file to be loaded from the resource sharing directory under the condition that the resource file to be loaded is contained in the resource sharing directory.
According to another aspect of the present disclosure, there is provided an electronic device including:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform a method according to any one of the embodiments of the present disclosure.
According to another aspect of the present disclosure, there is provided a non-transitory computer readable storage medium having stored thereon computer instructions for causing a computer to perform a method in any of the embodiments of the present disclosure.
According to another aspect of the present disclosure, a computer program product is provided, comprising a computer program which, when executed by a processor, implements the method in any of the embodiments of the present disclosure.
According to the technology disclosed by the invention, the problem that the application is installed for the first time and wastes a large amount of time to download the resource file is solved, and the loading speed of the resource file can be improved.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present disclosure, nor do they limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not to be construed as limiting the present disclosure. Wherein:
FIG. 1 is a schematic diagram of a resource file loading method according to an embodiment of the present disclosure;
FIG. 2 is a schematic diagram of a resource file loading method according to an embodiment of the present disclosure;
FIG. 3 is a schematic diagram comparing loading patterns of new and old resource files from a developer perspective according to an embodiment of the disclosure;
FIG. 4 is a schematic diagram comparing loading patterns of new and old resource files from an application user perspective according to an embodiment of the present disclosure;
FIG. 5 is a schematic diagram of a resource file loading apparatus according to an embodiment of the present disclosure;
FIG. 6 is a schematic diagram of a resource file loading apparatus according to an embodiment of the present disclosure;
FIG. 7 is a schematic diagram of a resource file loading apparatus according to an embodiment of the present disclosure;
fig. 8 is a block diagram of an electronic device for implementing a resource file loading method according to an embodiment of the present disclosure.
Detailed Description
Exemplary embodiments of the present disclosure are described below with reference to the accompanying drawings, in which various details of the embodiments of the disclosure 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 present disclosure. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
In order to solve the problem that the application needs to waste a large amount of time to download the resource file when being installed for the first time, the two existing implementation schemes are as follows:
firstly, a manufacturer packs a large amount of resource files into an installation package of an application, which causes the volume of the installation package to be too large, and further causes the problems of slow downloading speed, application updating coverage, slow installation speed and the like.
And secondly, downloading the resource files from the server corresponding to the application after the application is started for the first time, so that the problem of overlarge volume of an installation package can be solved, but the problem of overlong application starting time exists due to the fact that the performance of the server corresponding to the application is uneven, and the downloading speed cannot be guaranteed particularly in a peak period.
The embodiment of the present disclosure provides a resource file loading method, which is applied to a client, and as shown in fig. 1, the method includes:
step S101: and determining a resource file to be loaded for the target application.
Step S102: and determining whether the local resource sharing directory contains resource files to be loaded or not, wherein the resource sharing directory contains resource files shared by different applications.
Step S103: and loading the resource files to be loaded from the resource sharing directory under the condition that the resource sharing directory contains the resource files to be loaded.
In practical application, various applications, such as applications of various games, can be installed on intelligent terminals such as mobile phones. During the execution of the application, various resource files, such as a map file and a model file, need to be loaded. Here, the map corresponding to the map file may be overlaid on the model corresponding to the model file. The model file may include a logic script file and an animation script file for the model. The logic script file is a script file in a component form, and certain logic functions can be executed after the logic script file is loaded. Animation effects may then be generated after the animation script file is loaded.
For various game applications, the types of resource files that need to be loaded for different applications are many the same, for example, for application a, the resource files that need to be loaded include at least resource files for trees, grassland, houses and vehicles, for application B, the resource files that need to be loaded include at least resource files for trees, grassland, houses and weapons, for application C, and the resource files that need to be loaded include at least resource files for trees, grassland, weapons and horses, and these applications are the same in that both resource files are used for trees and grassland. Based on this, in the scheme, a resource sharing directory commonly used by different applications is created locally at the client, and the resource sharing directory includes resource files shared by different applications, that is, each resource file can be loaded into different applications.
Still for example, the resource sharing directory includes resource files such as trees, grasslands, houses, vehicles, weapons, and horses, which may all be shared by different applications, for application a, the resource files such as trees, grasslands, houses, and vehicles may be loaded from the resource sharing directory, for application B, the resource files such as trees, grasslands, houses, and weapons may be loaded from the resource sharing directory, and for application C, the resource files such as trees, grasslands, weapons, and horses may be loaded from the resource sharing directory.
The above target application is the currently running application.
In the scheme, after the resource file to be loaded by the target application is determined, whether the resource file to be loaded is contained in the resource sharing directory can be determined firstly, and the resource file to be loaded can be loaded directly from the local resource sharing directory under the condition that the resource file to be loaded is contained in the resource sharing directory, so that the problem that the resource file is downloaded due to the fact that a large amount of time is wasted when the resource file is installed for the first time is solved by the method of loading the resource file from the local resource sharing directory, and the loading speed of the resource file can be improved. Compared with the prior art, on one hand, the resource files of the target application do not need to be packaged into the installation package of the target application, so that the volume of the installation package is reduced, the speed of downloading the installation package by a user is improved, the problems of slow downloading speed, game updating coverage, slow installation speed and the like caused by overlarge volume of the installation package are avoided, on the other hand, the resource files do not need to be downloaded from the server corresponding to the target application when the application is started for the first time, the problem of overlong application starting time caused by poor performance of the server corresponding to the target application is avoided, particularly in a peak period, the downloading speed cannot be guaranteed, and the resource file loading speed is improved.
In addition, because the resource files in the local resource sharing directory of the client can be shared by different applications, the loading requirements of different applications can be met by locally storing only one set of resource files without repeatedly storing the resource files, and the occupied space is greatly saved.
In one embodiment, the resource file loading method may further include: and downloading the resource file to be loaded from a sharing server except the server corresponding to the target application under the condition that the resource file to be loaded is not contained in the resource sharing directory, wherein the sharing server stores the resource file shared by different applications.
The server corresponding to the target application is an original server of the target application, and may provide a computing service for the target application. The original servers of different applications are different. And the shared server is a server other than the original server of the target application. The sharing server can provide a uniform resource file sharing loading service for different applications. The shared server can select a server with good and stable performance. In addition, the shared server may be, but is not limited to, a cloud server, i.e., a cloud platform.
In practical application, resource files required to be loaded by different applications can be predetermined, a set of resource files meeting different applications can be determined, and the set of resource files can be stored in a sharing server for sharing by different applications. And the resource files in the shared server can be updated according to actual needs. The updated resource files may be uploaded by developers of different applications or by maintenance personnel sharing the server.
Therefore, under the condition that the resource files to be loaded do not exist in the local resource sharing directory, the resource files to be loaded can be downloaded from the sharing server, the resource files are downloaded through the uniform sharing server, the performance of the sharing server is good and stable, the sharing server is not influenced by the performance of the server corresponding to the target application any more, peak clipping and valley filling effects are achieved due to different peak periods of various applications and the fact that the peak clipping and valley filling effects are staggered mutually is achieved, the downloading speed is improved, and the problem that the application first starting time is too long due to the fact that the resource files are downloaded from the server corresponding to the target application in the related art can be solved.
In one embodiment, the resource file loading method further includes: and updating the local resource sharing directory based on the downloaded resource file to be loaded. In practical application, after the resource sharing directory is updated, the target application can load and download the well-downloaded resource file to be loaded from the resource sharing directory.
Therefore, by dynamically updating the resource sharing directory, besides the target application, when other applications are in demand, the downloaded loading resource file can be directly loaded from the resource sharing directory, and the loading speed is increased.
In an embodiment, downloading a resource file to be loaded from a shared server other than a server corresponding to a target application, as shown in fig. 2, a specific implementation may include:
step S201: and obtaining the identification information of the resource file to be loaded based on the installation information obtained when the target application is installed.
In practical applications, identification information may be set in advance for each resource file, for example, identification information such as a number may be set. When the target application is developed, the resource file which needs to be loaded by the target application can be downloaded from the shared server, and development is carried out based on the downloaded resource file which needs to be loaded. After the development is completed, when the installation package of the target application is packaged, the identification information of the resource file to be loaded is packaged into the installation package. After the installation package of the target application is downloaded, the identification information of the resource file is included in the installation information obtained when the target application is installed based on the installation package, so that the identification information of the resource file to be loaded can be obtained based on the installation information obtained when the target application is installed.
Step S202: and generating a downloading request and sending the downloading request to the sharing server, wherein the downloading request carries the identification information of the resource file to be loaded, so that the sharing server responds to the downloading request, acquires the resource file to be loaded according to the identification information of the resource file to be loaded, and sends the resource file to be loaded to the client.
After receiving a download request of a client, the sharing server responds to the download request, can analyze the identification information of the resource file to be loaded carried in the download request, and obtains the resource file to be loaded identified by the identification information of the resource file to be loaded according to the identification information of the resource file to be loaded, and sends the resource file to be loaded to the client.
Step S203: and receiving the resource file to be loaded sent by the sharing server to realize downloading.
Therefore, the identification information of the resource file to be loaded can be obtained based on the installation information obtained when the target application is installed, and accurate downloading can be realized based on the identification information of the resource file to be loaded. In addition, when the installation package of the target application is packaged, the resource file to be loaded is packaged into the installation package, but the identification information of the resource file to be loaded is packaged into the installation package, so that the volume occupied by the identification information of the resource file is very small, and the volume of the installation package is greatly reduced.
It should be noted that, if the target application is an application which is installed locally for the first time and can share the resource file with other applications, when the target application is installed based on the installation package, it is determined that the resource sharing directory is not created locally, the resource sharing directory is created. At this time, the resource sharing directory is empty, and it is only required to determine the resource file to be loaded, download the resource file and update the resource file into the resource sharing directory. When other applications capable of sharing resource files are installed again, the resource sharing directory is determined to be established locally, and the resource sharing directory does not need to be established again.
In an embodiment, determining a resource file to be loaded for a target application may include: under the condition that the target application is started, determining a resource file to be loaded, which is required by the starting of the target application; or, in the process after the target application is started, determining the resource file to be loaded required by the current process of the target application. Here, the case where the target application is started may include a case where the target application is started for the first time, and may also include a case where the target application is started each time after the first time. Therefore, when the system is started, the resource files required by starting are loaded well, and the system can be started quickly. In the running process of the target application, when the resource file needs to be loaded in the current process, the resource file is loaded again, and the resource file does not need to be completely loaded, so that the processing speed is increased.
A resource file loading method provided by the embodiment of the present disclosure is described in more detail below by taking a specific application scenario as an example.
In the application scenario, the targeted applications are various game applications, and the applications can be installed in intelligent terminals such as mobile phones and used by application users.
The embodiment provides a resource file sharing service cloud platform (i.e. a sharing server), and as a server, all commonly used resource files, such as a map file, a model file (including a logic script file and an animation script file), and the like, can be integrated and stored at the server.
Specifically, the resource file sharing cloud platform of the embodiment is divided into two parts:
a first part: the resource file sharing cloud platform Software Development Kit (SDK).
SDKs are a collection of development tools used by software engineers to build application software for a particular software package, software framework, hardware platform, operating system, etc. Application developers of application vendors can develop applications based on SDK. In the application development process, an application developer can select a required mapping file and a required model file on a resource file sharing cloud platform and integrate the mapping file and the model file into own application.
A second part: the resource files share cloud platform cloud storage services.
After an application user downloads the installation package, the application can download the application developer from the resource file sharing cloud platform after being started to select the integrated resource file; if multiple applications use the same resource file, the applications will share the resource file and will not occupy the resource repeatedly.
The following contrasts the old resource file loading mode and the new resource file loading mode (i.e. the publicly provided resource file loading method) from the developer perspective and the application user perspective.
As shown in fig. 3, from the developer perspective, the old resource file loading schema:
an application developer performs application development based on an application development tool and resource files, the resource files are packaged into an application installation package after the development is completed, when an application user downloads the application installation package, a large number of resource files cause that the installation package is too large, the application user needs a large amount of time for waiting for downloading, and the resource files can be obtained after the application is installed.
As shown in FIG. 3, from the developer perspective, the new resource file loading schema:
an application developer downloads a resource file to be loaded by an application from a resource file sharing platform, application development is carried out based on the application SDK and the downloaded resource file, and after the development is finished, an application installation package is packaged, wherein the installation package does not need to contain the resource file, can contain identification information of the resource file, and reduces the volume of the installation package. And after the application is installed, automatically acquiring resources from the network, namely downloading the resource files to be loaded from the uniform resource file sharing cloud platform, so that the downloading speed is increased.
As shown in fig. 4, in the application user perspective, the old resource file loading mode:
for application A, resource files such as trees, grasslands, houses and vehicles for application A to load are separately stored.
For application B, resource files such as trees, grasslands, houses and weapons are separately stored for application B to load.
For application C, resource files such as trees, grassland, weaponry, and horses are separately stored for application C to load.
It can be seen that in the old resource file loading mode, resource files of trees, grasslands, houses and weapons are stored repeatedly.
As shown in fig. 4, in the application user perspective, the new resource file loading mode:
a set of resource files downloaded from the resource file sharing cloud platform, such as trees, grasslands, houses, weapons, vehicles, horses, and the like, are stored in the resource sharing directory.
Application a may load resource files such as trees, grasslands, houses, and vehicles from the resource sharing directory.
Application B may load resource files for trees, grasslands, houses, weapons, etc. from the resource-sharing directory.
Application C may load resource files such as trees, grasslands, weapons, and horses from the resource sharing directory.
Therefore, in the new resource file loading mode, only one set of resource files needs to be stored locally, the resource files can be used by a plurality of applications, and the occupied space is saved.
Therefore, a set of platform for sharing resource files is provided for application developers, uniform resource loading service is provided for different applications, application manufacturers do not need to pack the model files and the map files of common applications in the installation package, the volume of the installation package is reduced, after the application users download the installation package for installing the applications, the applications can download the resource files from the resource file sharing cloud platform when the resource files are loaded, and the downloading speed of the users is improved. If the same resource file is shared by a plurality of applications in the intelligent terminal such as the user mobile phone and the like, repeated downloading is not needed, and the purpose of saving the storage space of the user mobile phone in the intelligent terminal is achieved.
An embodiment of the present disclosure further provides a resource file loading apparatus, applied to a client, as shown in fig. 5, including:
a first determining module 501, configured to determine a resource file to be loaded for a target application;
a second determining module 502, configured to determine whether a local resource sharing directory includes a resource file to be loaded, where the resource sharing directory includes resource files shared by different applications;
the resource loading module 503 is configured to load the resource file to be loaded from the resource sharing directory when the resource sharing directory includes the resource file to be loaded.
In one embodiment, as shown in fig. 6, the system further includes a resource downloading module 504 configured to:
and downloading the resource file to be loaded from a sharing server except the server corresponding to the target application under the condition that the resource file to be loaded is not contained in the resource sharing directory, wherein the sharing server stores the resource file shared by different applications.
In one embodiment, as shown in fig. 7, a catalog update module 505 is further included for:
and updating the local resource sharing directory based on the downloaded resource file to be loaded.
In an embodiment, the resource downloading module 504 is specifically configured to:
obtaining identification information of a resource file to be loaded based on installation information obtained when a target application is installed;
generating a downloading request and sending the downloading request to a sharing server, wherein the downloading request carries identification information of a resource file to be loaded, so that the sharing server responds to the downloading request, acquires the resource file to be loaded according to the identification information of the resource file to be loaded and sends the resource file to a client;
and receiving the resource file to be loaded sent by the sharing server to realize downloading.
In an embodiment, the first determining module 501 is specifically configured to:
under the condition that the target application is started, determining a resource file to be loaded, which is required by the starting of the target application;
or, in the process after the target application is started, determining the resource file to be loaded required by the current process of the target application.
The functions of each module in each device in the embodiments of the present disclosure may refer to the corresponding description in the resource file loading method, and are not described herein again.
The present disclosure also provides an electronic device, a readable storage medium, and a computer program product according to embodiments of the present disclosure.
FIG. 8 illustrates a schematic block diagram of an example electronic device 800 that can be used to implement embodiments of the present disclosure. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the disclosure described and/or claimed herein.
As shown in fig. 8, the apparatus 800 includes a computing unit 801 that can perform various appropriate actions and processes according to a computer program stored in a Read Only Memory (ROM)802 or a computer program loaded from a storage unit 808 into a Random Access Memory (RAM) 803. In the RAM803, various programs and data required for the operation of the device 800 can also be stored. The calculation unit 801, the ROM 802, and the RAM803 are connected to each other by a bus 804. An input/output (I/O) interface 805 is also connected to bus 804.
A number of components in the device 800 are connected to the I/O interface 805, including: an input unit 806, such as a keyboard, a mouse, or the like; an output unit 807 such as various types of displays, speakers, and the like; a storage unit 808, such as a magnetic disk, optical disk, or the like; and a communication unit 809 such as a network card, modem, wireless communication transceiver, etc. The communication unit 809 allows the device 800 to exchange information/data with other devices via a computer network such as the internet and/or various telecommunication networks.
Computing unit 801 may be a variety of general and/or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 801 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various dedicated Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and the like. The computing unit 801 executes the various methods and processes described above, such as the resource file loading method. For example, in some embodiments, the resource file loading method may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as storage unit 808. In some embodiments, part or all of the computer program can be loaded and/or installed onto device 800 via ROM 802 and/or communications unit 809. When the computer program is loaded into RAM803 and executed by computing unit 801, one or more steps of the resource file loading method described above may be performed. Alternatively, in other embodiments, the computing unit 801 may be configured to perform the resource file loading method by any other suitable means (e.g., by means of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), system on a chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
Program code for implementing the methods of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on 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.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic input, speech input, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), and the Internet.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present disclosure may be executed in parallel or sequentially or in different orders, and are not limited herein as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved.
The above detailed description should not be construed as limiting the scope of the disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present disclosure should be included in the scope of protection of the present disclosure.

Claims (13)

1. A resource file loading method is applied to a client and comprises the following steps:
determining a resource file to be loaded for a target application;
determining whether a local resource sharing directory contains the resource file to be loaded, wherein the resource sharing directory contains resource files shared by different applications;
and loading the resource file to be loaded from the resource sharing directory under the condition that the resource file to be loaded is contained in the resource sharing directory.
2. The method of claim 1, further comprising:
and downloading the resource file to be loaded from a sharing server except the server corresponding to the target application under the condition that the resource file to be loaded is not contained in the resource sharing directory, wherein the sharing server stores the resource file shared by different applications.
3. The method of claim 2, further comprising:
and updating the local resource sharing directory based on the downloaded resource file to be loaded.
4. The method of claim 2, wherein the downloading the resource file to be loaded from a shared server other than the server corresponding to the target application comprises:
obtaining identification information of the resource file to be loaded based on installation information obtained when the target application is installed;
generating a downloading request and sending the downloading request to the sharing server, wherein the downloading request carries the identification information of the resource file to be loaded, so that the sharing server responds to the downloading request, acquires the resource file to be loaded according to the identification information of the resource file to be loaded, and sends the resource file to be loaded to the client;
and receiving the resource file to be loaded sent by the shared server to realize downloading.
5. The method of claim 1, wherein the determining the resource file to be loaded for the target application comprises:
under the condition that the target application is started, determining the resource file to be loaded required by the starting of the target application;
or, in the process after the target application is started, determining the resource file to be loaded required by the current process of the target application.
6. A resource file loading device is applied to a client and comprises:
the first determining module is used for determining a resource file to be loaded for the target application;
a second determining module, configured to determine whether a local resource sharing directory includes the resource file to be loaded, where the resource sharing directory includes resource files shared by different applications;
and the resource loading module is used for loading the resource file to be loaded from the resource sharing directory under the condition that the resource file to be loaded is contained in the resource sharing directory.
7. The apparatus of claim 6, further comprising a resource download module to:
and downloading the resource file to be loaded from a sharing server except the server corresponding to the target application under the condition that the resource file to be loaded is not contained in the resource sharing directory, wherein the sharing server stores the resource file shared by different applications.
8. The apparatus of claim 7, further comprising a directory update module to:
and updating the local resource sharing directory based on the downloaded resource file to be loaded.
9. The apparatus of claim 7, wherein the resource downloading module is specifically configured to:
obtaining identification information of the resource file to be loaded based on installation information obtained when the target application is installed; generating a downloading request and sending the downloading request to the sharing server, wherein the downloading request carries the identification information of the resource file to be loaded, so that the sharing server responds to the downloading request, acquires the resource file to be loaded according to the identification information of the resource file to be loaded, and sends the resource file to be loaded to the client; and receiving the resource file to be loaded sent by the shared server to realize downloading.
10. The apparatus of claim 6, wherein the first determining module is specifically configured to:
under the condition that the target application is started, determining the resource file to be loaded required by the starting of the target application; or, in the process after the target application is started, determining the resource file to be loaded required by the current process of the target application.
11. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-5.
12. A non-transitory computer readable storage medium having stored thereon computer instructions for causing a computer to perform the method of any one of claims 1-5.
13. A computer program product comprising a computer program which, when executed by a processor, implements the method according to any one of claims 1-5.
CN202011522105.5A 2020-12-21 2020-12-21 Resource file loading method, device, equipment, storage medium and product Active CN112506584B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011522105.5A CN112506584B (en) 2020-12-21 2020-12-21 Resource file loading method, device, equipment, storage medium and product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011522105.5A CN112506584B (en) 2020-12-21 2020-12-21 Resource file loading method, device, equipment, storage medium and product

Publications (2)

Publication Number Publication Date
CN112506584A true CN112506584A (en) 2021-03-16
CN112506584B CN112506584B (en) 2023-10-03

Family

ID=74921843

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011522105.5A Active CN112506584B (en) 2020-12-21 2020-12-21 Resource file loading method, device, equipment, storage medium and product

Country Status (1)

Country Link
CN (1) CN112506584B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113407347A (en) * 2021-06-30 2021-09-17 北京百度网讯科技有限公司 Resource scheduling method, device, equipment and computer storage medium
CN113505109A (en) * 2021-07-27 2021-10-15 北京字节跳动网络技术有限公司 File sharing method and device, computer equipment and storage medium
WO2023125083A1 (en) * 2021-12-29 2023-07-06 北京字跳网络技术有限公司 Resource file loading method and apparatus, electronic device and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103780700A (en) * 2014-01-26 2014-05-07 长沙裕邦软件开发有限公司 Application system and method for achieving compatibility and sharing among multi-source heterogeneous systems
WO2018045977A1 (en) * 2016-09-09 2018-03-15 腾讯科技(深圳)有限公司 Shared resource display method, device and storage medium
CN110377850A (en) * 2019-06-12 2019-10-25 五八有限公司 Resource file loading method, device, electronic equipment and storage medium
CN110445526A (en) * 2019-07-10 2019-11-12 视联动力信息技术股份有限公司 Data transmission method, device, system, electronic equipment and storage medium
CN110719319A (en) * 2019-09-18 2020-01-21 维沃移动通信有限公司 Resource sharing method, device, terminal equipment and storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103780700A (en) * 2014-01-26 2014-05-07 长沙裕邦软件开发有限公司 Application system and method for achieving compatibility and sharing among multi-source heterogeneous systems
WO2018045977A1 (en) * 2016-09-09 2018-03-15 腾讯科技(深圳)有限公司 Shared resource display method, device and storage medium
CN110377850A (en) * 2019-06-12 2019-10-25 五八有限公司 Resource file loading method, device, electronic equipment and storage medium
CN110445526A (en) * 2019-07-10 2019-11-12 视联动力信息技术股份有限公司 Data transmission method, device, system, electronic equipment and storage medium
CN110719319A (en) * 2019-09-18 2020-01-21 维沃移动通信有限公司 Resource sharing method, device, terminal equipment and storage medium

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
GENG QINGZHAI; ZHU XINGMING: "Development of scientific data sharing of water resources and sharing service system construction in China", IEEE *
宋梦蝶;王枫;武延军;: "基于服务化技术的个人数据资源共享方法", 计算机***应用, no. 09 *
张凌睿;杜仕勇;: "APP模式移动图书馆共享文化社区的构建研究", 图书馆, no. 09 *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113407347A (en) * 2021-06-30 2021-09-17 北京百度网讯科技有限公司 Resource scheduling method, device, equipment and computer storage medium
CN113407347B (en) * 2021-06-30 2023-02-24 北京百度网讯科技有限公司 Resource scheduling method, device, equipment and computer storage medium
CN113505109A (en) * 2021-07-27 2021-10-15 北京字节跳动网络技术有限公司 File sharing method and device, computer equipment and storage medium
WO2023125083A1 (en) * 2021-12-29 2023-07-06 北京字跳网络技术有限公司 Resource file loading method and apparatus, electronic device and storage medium

Also Published As

Publication number Publication date
CN112506584B (en) 2023-10-03

Similar Documents

Publication Publication Date Title
CN112506584B (en) Resource file loading method, device, equipment, storage medium and product
CN110888658B (en) Method and device for dynamically changing function modules in application program and storage medium
CN111026439B (en) Application program compatibility method, device, equipment and computer storage medium
CN113849312A (en) Data processing task allocation method and device, electronic equipment and storage medium
EP4060496A2 (en) Method, apparatus, device and storage medium for running inference service platform
CN110069265B (en) Service cluster upgrading method and device and storage medium
CN112671892B (en) Data transmission method, device, electronic equipment and medium
CN113126994A (en) Hotspot code processing method and device, electronic equipment and storage medium
CN114138358A (en) Application program starting optimization method, device, equipment and storage medium
CN113778546A (en) Method and device for gray scale optimization
CN113596920A (en) Flow control method and device, electronic equipment and storage medium
CN111796878A (en) Resource splitting and loading method and device applied to single-page application
CN112130986A (en) Method for cleaning application memory, server and terminal
CN113900734B (en) Application program file configuration method, device, equipment and storage medium
CN117539521B (en) Application program upgrading method and device, nonvolatile storage medium and electronic equipment
CN112600932B (en) Quantitative issuing method, console, issuing node, device and medium
CN113220282B (en) Development processing method, device and storage medium for applet
CN113741796B (en) Data persistence method and device for terminal application
CN114489715A (en) Method, device, equipment and medium for upgrading operating system of cloud mobile phone
CN116233051A (en) Page sharing method, device and equipment for applet and storage medium
CN116149753A (en) Application program installation method and device, electronic equipment and storage medium
CN113946518A (en) Debugging system and method for front-end development page, electronic device and storage medium
CN116737198A (en) Firmware pushing method, device, equipment and storage medium
CN113220576A (en) Management method, device, equipment and storage medium of test environment
CN115794165A (en) Application upgrading method and device, EPS and medium

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
GR01 Patent grant
GR01 Patent grant