CN114217873A - Plug-in determining method and device, electronic equipment and storage medium - Google Patents

Plug-in determining method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN114217873A
CN114217873A CN202111542574.8A CN202111542574A CN114217873A CN 114217873 A CN114217873 A CN 114217873A CN 202111542574 A CN202111542574 A CN 202111542574A CN 114217873 A CN114217873 A CN 114217873A
Authority
CN
China
Prior art keywords
plug
detected
target
determining
ins
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111542574.8A
Other languages
Chinese (zh)
Inventor
桓乐乐
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing ByteDance Network Technology Co Ltd
Original Assignee
Beijing Jingling Information System 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 Jingling Information System Technology Co Ltd filed Critical Beijing Jingling Information System Technology Co Ltd
Priority to CN202111542574.8A priority Critical patent/CN114217873A/en
Publication of CN114217873A publication Critical patent/CN114217873A/en
Pending legal-status Critical Current

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
    • G06F9/44526Plug-ins; Add-ons

Landscapes

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

Abstract

The disclosure provides a plug-in determination method, a plug-in determination device, an electronic device, a readable storage medium and a computer program product, and relates to the field of operating systems. The scheme comprises the following steps: traversing a pre-configured plug-in storage directory to obtain at least one plug-in to be detected, wherein the plug-in to be detected is a pre-configured plug-in with a specific function; reading plug-in description information carried in the plug-in to be detected, and determining a target plug-in with a target function in at least one plug-in to be detected based on the plug-in description information, wherein the plug-in description information is information which is configured in the plug-in to be detected in advance and is at least used for describing a specific function. According to the scheme, when the specific function of the plug-in to be detected is determined, the specific function of the plug-in to be detected can be determined by reading the description information of the plug-in without loading and analyzing the plug-in to be detected, and then whether the plug-in to be detected is the target plug-in or not is judged. Therefore, the efficiency of determining the specific function of the plug-in to be detected is improved, and the calling efficiency of the plug-in can be further improved.

Description

Plug-in determining method and device, electronic equipment and storage medium
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a method and an apparatus for determining a plug-in, an electronic device, a readable storage medium, and a computer program product.
Background
A plug-in is a program written by an application program interface following a certain specification, which runs under an operating system specified by the program for implementing various specific functions. Thus, the plug-in has a crucial role in the operating system.
Disclosure of Invention
The present disclosure provides a plug-in determination method, device, electronic device, readable storage medium, and computer program product to improve the calling efficiency of a plug-in and ensure the extensibility of the plug-in.
According to an aspect of the present disclosure, there is provided a plug-in determination method, including:
traversing a pre-configured plug-in storage directory to obtain at least one plug-in to be detected, wherein the plug-in to be detected is a pre-configured plug-in with a specific function;
reading plug-in description information carried in the plug-in to be detected, and determining a target plug-in with a target function in at least one plug-in to be detected based on the plug-in description information, wherein the plug-in description information is information which is configured in the plug-in to be detected in advance and is at least used for describing a specific function.
According to a second aspect of the present disclosure, there is provided an apparatus for determining a plug-in, the apparatus comprising:
the to-be-detected plug-in unit determining unit is used for traversing the pre-configured plug-in storage directory to obtain at least one to-be-detected plug-in, wherein the to-be-detected plug-in is a pre-configured plug-in with a specific function;
and the target plug-in determining unit is used for reading the plug-in description information carried in the plug-in to be detected and determining a target plug-in with a target function in at least one plug-in to be detected based on the plug-in description information, wherein the plug-in description information is information which is configured in the plug-in to be detected in advance and is at least used for describing a specific function.
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, there is provided a computer program product comprising computer programs/instructions, characterized in that the computer programs/instructions, when executed by a processor, implement the method in any of the embodiments of the present disclosure.
The technology of the disclosure can determine a target plug-in with a specific function including a target function in at least one plug-in to be detected by reading plug-in description information which is carried in the plug-in to be detected and is used for describing the specific function. Therefore, when the specific function of the plug-in to be detected is determined, the plug-in to be detected does not need to be loaded and analyzed, but the specific function of the plug-in to be detected can be determined only by reading the plug-in description information carried in the plug-in to be detected, and then whether the plug-in to be detected is the target plug-in or not is determined. Therefore, the efficiency of determining the specific function of the plug-in to be detected is improved, and the calling efficiency of the plug-in can be further improved.
In addition, in the technology of the disclosure, the plug-in to be detected is a pre-configured plug-in with a specific function, so that the plug-in is ensured to have better expansibility.
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 flow chart of a method for determining a plug-in provided in an embodiment of the present disclosure;
fig. 2 is a flowchart of a first plug-in determination method provided in an embodiment of the present disclosure;
FIG. 3 is a flow chart of another method of plug-in determination provided in an embodiment of the present disclosure;
FIG. 4 is a schematic diagram of an apparatus for determining an insert provided in an embodiment of the present disclosure;
fig. 5 is a schematic diagram of an electronic device provided in 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 the embodiment of the present disclosure, the operating system supporting the plug-in operation may be various GNU/Linux distribution versions, such as Ubuntu (wubang), Debian, Red Hat, and the like; the System can also be an Android Operating System, which covers an Android OS (Operating System) and an AOSP (Android Open Source Project) issued by Google and various derived systems based on the AOSP, such as MIUI, EMUI, OneUI and the like; other common operating systems are also possible.
The plug-in implementation forms are often as follows: the first method is as follows: integrating a plurality of functions into one plug-in; the second method is as follows: different plug-ins are configured for different functions, respectively.
For the first implementation form of the plug-in, if the plug-in needs to be called to implement a certain target function, it must first be determined whether the plug-in has the target function. At this time, the plug-in needs to be loaded into the program and analyzed, and the function of the plug-in can be obtained, so as to further determine whether the plug-in has the target function. Therefore, the confirmation of the target plug-in is time-consuming, and the calling efficiency of the plug-in is low. And grouping functions in a plug-in also results in poor expandability of the plug-in.
For the second implementation form of the plug-in, if a certain target function needs to be implemented by calling the plug-in, a target plug-in with the target function needs to be detected in different plug-ins. That is, it is determined whether a target plug-in having a target function exists among the plurality of plug-ins. At this time, in the related art, when determining whether a target plug-in with a target function exists in a plurality of plug-ins, it is often necessary to load all the current plug-ins to be detected and call a related interface to obtain a specific function of the current plug-in to be detected, so that it is determined whether the current plug-in to be detected has the target function. And if the current plug-in is not the target plug-in, then the plug-in needs to be uninstalled.
Although the second implementation form of the plug-in can ensure that the plug-in has high expandability, in the process of determining the target plug-in, a plurality of plug-ins to be detected need to be loaded and unloaded. Therefore, the confirmation of the target plug-in is time-consuming, and the calling efficiency of the plug-in is low. And the plug-in is repeatedly loaded and unloaded, which also results in poor security of plug-in calling.
In order to solve the problem that the calling efficiency of the plug-in is low and ensure that the plug-in has high expandability, the embodiment of the disclosure provides a plug-in determination method. Referring to fig. 1 in detail, fig. 1 is a flowchart illustrating a method for determining a plug-in an embodiment of the disclosure. The plug-in determining method comprises the following steps:
step S101: and traversing the pre-configured plug-in storage directory to obtain at least one plug-in to be detected, wherein the plug-in to be detected is a pre-configured plug-in with a specific function.
Step S102: reading plug-in description information carried in the plug-in to be detected, and determining a target plug-in with a target function in at least one plug-in to be detected based on the plug-in description information, wherein the plug-in description information is information which is configured in the plug-in to be detected in advance and is at least used for describing a specific function.
According to the plug-in determining method in the embodiment of the disclosure, the target plug-in with the specific function including the target function can be determined in at least one plug-in to be detected by reading the plug-in description information which is carried in the plug-in to be detected and is used for describing the specific function. Therefore, when the specific function of the plug-in to be detected is determined, the plug-in to be detected does not need to be loaded and analyzed, but the specific function of the plug-in to be detected can be determined only by reading the plug-in description information carried in the plug-in to be detected, and then whether the plug-in to be detected is the target plug-in or not is determined. Therefore, the efficiency of determining the specific function of the plug-in to be detected is improved, and the calling efficiency of the plug-in can be further improved.
The specific implementation manner of obtaining the specific function of the plug-in to be detected by using the plug-in description information may be as follows: reading and analyzing the plug-in description information in the plug-in to be detected, and obtaining the specific function described in the plug-in description information so as to determine the specific function of the plug-in to be detected. In order to reduce the data copy amount required by reading information, the method can further adopt a memory mapping mode to read the plug-in description information in the plug-in to be detected.
In addition, in the embodiment of the disclosure, the plug-in to be detected is a pre-configured plug-in with a specific function, so that the plug-in is ensured to have better expansibility. And because the plug-in is not required to be repeatedly loaded and unloaded, the safety of plug-in calling is also ensured.
In the embodiment of the present disclosure, the function, type, and file type of the plug-in are not specifically limited, and a common plug-in includes: browser development plug-ins, search plug-ins, test plug-ins, advertising plug-ins, banking plug-ins, desktop plug-ins, and other plug-ins for performing some intended operation.
The plug-in description information is information carried in the plug-in to be detected and at least used for describing a specific function.
The specific function means a specific function that can be realized by the plug-in; the target function is a function meeting a preset function requirement. The target plug-in having the target function means that the specific function of the target plug-in includes the target function.
For the same type of plug-in, it can be subdivided into a plurality of plug-ins according to the specific functions. Specifically, taking a browser plug-in as an example, a common browser plug-in includes: the system comprises a translation plug-in for language translation, an advertisement blocking plug-in for advertisement blocking and a downloading plug-in for file downloading.
Of course, different inserts may have the same specific function. That is, the same function may be achieved by different plug-ins. That is, parsing of jpeg (Joint Photographic Experts Group) format pictures can be realized by a plurality of different picture plug-ins. For example: in practical application, the initial plug-in is subjected to continuous optimization upgrading and the like, so that different plug-ins with multiple versions with specific functions are generated. Specifically, an initial version of plug-in (denoted as plug-in version 1.0), a second version of plug-in (denoted as plug-in version 2.0) generated after the initial version of plug-in is optimally upgraded, and a third version of plug-in (denoted as plug-in version 3.0) generated after the second version of plug-in is optimally upgraded again.
In the embodiment of the present disclosure, the so-called plug-in description information can be used to describe, in addition to the plug-in function, version information of the plug-in, a plug-in name, a plug-in ID (Identity Document) pre-configured for the plug-in, and the like.
The plug-in description information is generally information imported when the plug-in to be detected is configured in advance. And the JSON (JavaScript Object Notation) format is easy to read and write by people and is easy to analyze and generate by a machine. Therefore, the plug-in description information is generally description information in JSON format. Of course, description information of other data formats than the JSON format may be used.
The plug-in storage directory is a storage directory configured for storing plug-ins in a preset storage space.
In order to implement accurate and comprehensive detection of a to-be-detected plug-in unit and improve the possibility of detecting a target plug-in unit, in an embodiment of the present disclosure, determining an implementation manner of at least one to-be-detected plug-in unit includes: firstly, determining a pre-configured plug-in storage directory; and then traversing the plug-in storage directory, and taking the plug-ins stored in the plug-in storage directory as the plug-ins to be detected.
In order to improve the detection efficiency of the target plug-in, and thus further improve the calling efficiency of the plug-in, in an embodiment of the present disclosure, the following steps may be taken to determine the target plug-in, specifically referring to fig. 2, where fig. 2 is a flowchart of a method for determining a first plug-in provided in the embodiment of the present disclosure. The method comprises the following specific steps:
step S201: and sequentially detecting whether the plug-in to be detected has the target function or not based on the plug-in description information.
Step S202: and determining the plug-in to be detected with the target function as the target plug-in under the condition that the plug-in to be detected is detected to have the target function.
Step S203: and under the condition that the at least one plug-in to be detected is traversed and the plug-in to be detected with the target function is not detected, determining that the target plug-in does not exist in the at least one plug-in to be detected.
That is, all the to-be-detected plug-ins are sequentially detected, and when the to-be-detected plug-ins with the target function are detected, further detection of the remaining to-be-detected plug-ins is stopped, and the to-be-detected plug-ins with the target function are determined as the target plug-ins.
And when the to-be-detected plug-ins with the target function are not detected, sequentially detecting the remaining to-be-detected plug-ins, and determining that the target plug-ins do not exist in at least one to-be-detected plug-ins after all the to-be-detected plug-ins are detected and the to-be-detected plug-ins with the target function are not detected.
As there may be a plurality of to-be-detected plug-ins having the target function among the at least one to-be-detected plug-in. For example: optimizing and upgrading the initial plug-in with the target function to generate different versions of plug-ins; or different plug-ins of different types but each having the target function. At this time, in order to ensure that the optimal degree of different plug-ins for implementing the same specific function is differentiated, different loading priorities may be set in advance for different plug-ins according to the performance of different plug-ins for implementing the same specific function, and the loading priorities of the corresponding plug-ins are described by the plug-in description information.
The loading priority is used to indicate the degree to which a plug-in having a certain specified function is preferentially loaded when the specified function is implemented. Taking the description information of which the plug-in description information is in the JSON format as an example, when the plug-in description information is also used for describing the loading priority of the plug-in to be detected, the so-called plug-in description information is as follows:
"type": "image Decode", "change plug-in type picture decoding;
"decode Type": "JPEG",// decoding type, pictures in JPEG format;
"priority": 1,// priority;
"id": "1234567890"// the unique serial number of the plug-in;
"description":“decode jpeg image”。
in order to ensure that the selected target plug-in is the preferred plug-in for implementing the target function, when the plug-in description information is also used to describe the loading priority of the plug-in to be detected, the specific implementation process is as shown in fig. 3, and fig. 3 is a flowchart of another plug-in determination method provided in the embodiment of the present disclosure. The method comprises the following specific steps:
step S301: and sequentially detecting whether the plug-in to be detected has the target function or not based on the plug-in description information.
Step S302: and under the condition that the plug-in to be detected has the target function, determining the plug-in to be detected with the target function as a candidate plug-in.
Step S303: determining whether the candidate plug-ins need to be subjected to loading priority verification or not based on the plug-in description information;
step S304: and under the condition that the candidate plug-in does not need to carry out loading priority check, determining the candidate plug-in as the target plug-in.
Step S305: traversing the remaining plug-ins to be detected in at least one plug-in to be detected under the condition that the candidate plug-ins need to be subjected to loading priority verification to obtain other plug-ins to be detected which accord with the target function;
step S306: and determining a target plug-in from the candidate plug-ins and other plug-ins to be detected.
Step S307: and under the condition that the at least one plug-in to be detected is traversed and the plug-in to be detected with the target function is not detected, determining that the target plug-in does not exist in the at least one plug-in to be detected.
In the embodiment of the disclosure, for different versions of plug-ins generated by continuous optimization and upgrade of an initial plug-in, priorities of the different versions of plug-ins can be determined according to the version update sequence of the plug-ins. Specifically, the newer the version of the plug-in, the higher the loading priority of the version of the plug-in. For example: for three different versions of the same plug-in that implement parsing of jpeg format pictures: the loading priority of the "jpeg format picture analysis plug-in version 1.0", "jpeg format picture analysis plug-in version 2.0" and "jpeg format picture analysis plug-in version 3.0" is sequentially increased when the target function is to realize the analysis of jpeg format pictures, and the loading priority of the "jpeg format picture analysis plug-in version 1.0", "jpeg format picture analysis plug-in version 2.0" and "jpeg format picture analysis plug-in version 3.0" is sequentially increased.
For different plug-ins belonging to different types and having a specified function, the loading priority of the specified function realized by a plurality of different plug-ins can be preset according to the performance of the different plug-ins realizing the specified function. For example: for a plurality of different plug-ins that implement parsing of jpeg format pictures: the "jpeg format picture analysis plug-in 1", "jpeg format picture analysis plug-in 2" and "jpeg format picture analysis plug-in 3" may be preset with the loading priorities of the "jpeg format picture analysis plug-in 1", "jpeg format picture analysis plug-in 2" and "jpeg format picture analysis plug-in 3" as follows: low, medium, and high.
In the embodiment of the disclosure, when determining the target plug-in, whether the plug-in to be detected has the target function is sequentially determined based on the function description information in the plug-in description information. And under the condition that the plug-in to be detected has the target function, stopping detecting the rest plug-ins to be detected, determining the plug-ins to be detected with the target function as candidate plug-ins, and further determining whether the plug-ins to be detected include information for describing the loading priority or not in the plug-in description information.
Specifically, the specific implementation manner for determining whether the candidate plug-in needs to perform the loading priority check based on the plug-in description information is as follows: determining whether the plug-in description information of the candidate plug-in comprises information for describing loading priority; if yes, determining that the candidate plug-in needs to be subjected to loading priority verification; otherwise, determining that the candidate plug-in does not need to perform loading priority check.
When the plug-in description information of the candidate plug-ins includes information for describing the loading priority, traversing at least one plug-in to be detected to obtain at least one plug-in to be detected which all has a target function and is used as the candidate plug-in, and determining the target plug-in all the candidate plug-ins.
In the embodiment of the disclosure, in order to ensure that the target plugin is the most selected plugin for realizing the plugin function corresponding to the target function, a plugin with the highest loading priority may be selected from at least one candidate plugin as the target plugin. The specific implementation process is as follows: firstly, acquiring loading priorities corresponding to candidate plug-ins and other plug-ins to be detected; then, determining the plug-in to be detected with the highest loading priority in the candidate plug-ins and other plug-ins to be detected; and finally, determining the plug-in to be detected with the highest loading priority as the target plug-in.
In the embodiment of the present disclosure, a priority threshold may also be set for the priority, and a to-be-detected plug-in with a loading priority reaching the priority threshold is determined as a target plug-in among the candidate plug-ins and the other to-be-detected plug-ins.
In addition, in order to improve the efficiency and accuracy of determining the target plug-in, in the embodiment of the present disclosure, after at least one plug-in to be detected is determined, a plug-in list for recording the ID of the plug-in to be detected, the name of the plug-in to be detected, and the detection order of the plug-in to be detected may be generated for the at least one plug-in to be detected. And sequentially detecting whether the plug-ins to be detected have the target function or not according to the plug-in detection sequence.
In the embodiment of the disclosure, after the target plug-in is determined in the at least one plug-in to be detected, the target plug-in can be further loaded, and the target function is executed based on the target plug-in. Thereby achieving the target function.
As shown in fig. 4, an embodiment of the present disclosure provides a plug-in determination apparatus, including:
the to-be-detected plug-in determining unit 401 is configured to traverse a pre-configured plug-in storage directory to obtain at least one to-be-detected plug-in, where the to-be-detected plug-in is a pre-configured plug-in with a specific function;
the target plug-in determining unit 402 is configured to read plug-in description information carried in the to-be-detected plug-in, and determine a target plug-in having a target function in at least one to-be-detected plug-in based on the plug-in description information, where the plug-in description information is information that is configured in advance in the to-be-detected plug-in and is used for describing at least a specific function.
In another embodiment of the present disclosure, the to-be-detected plug-in determination unit 401 may further include:
the storage directory determining subunit is used for determining the plug-in storage directory;
and the storage directory traversal subunit is used for traversing the plug-in storage directory and determining the plug-ins stored under the plug-in storage directory as the plug-ins to be detected.
In another embodiment of the present disclosure, the target plug-in determination unit 402 may further include:
the first function requirement detection subunit is used for sequentially detecting whether the plug-in to be detected has the target function or not based on the plug-in description information;
the first target determining subunit is used for determining the plug-in to be detected with the target function as the target plug-in under the condition that the plug-in to be detected is detected to have the target function.
In another embodiment of the present disclosure, the target plug-in determination unit 402 may further include:
the second function requirement detection subunit is used for sequentially detecting whether the plug-in to be detected has a target function or not based on the plug-in description information under the condition that the plug-in description information is also used for describing the loading priority of the plug-in to be detected;
the candidate plug-in determining subunit is used for determining the plug-in to be detected with the target function as the candidate plug-in under the condition that the plug-in to be detected is detected to have the target function;
the priority check determining subunit is used for determining whether the candidate plug-in needs to be subjected to the loading priority check or not based on the plug-in description information;
and the second target plug-in determining subunit is used for determining the candidate plug-in as the target plug-in under the condition that the candidate plug-in does not need to carry out loading priority check.
In another embodiment of the present disclosure, the target plug-in determination unit 402 may further include:
the to-be-detected plug-in traversal subunit is used for traversing undetected to-be-detected plug-ins under the condition that the candidate plug-ins need to be subjected to loading priority verification to obtain other to-be-detected plug-ins with the target function;
and the third target plug-in determining subunit is used for determining the target plug-in from the candidate plug-ins and other plug-ins to be detected.
In another embodiment of the present disclosure, the third target plug-in determination subunit may further include:
acquiring loading priorities corresponding to candidate plug-ins and other plug-ins to be detected;
and the fourth target plug-in determining subunit is used for determining the plug-in to be detected with the highest loading priority as the target plug-in from the candidate plug-ins and other plug-ins to be detected.
In another embodiment of the present disclosure, the target plug-in determination unit 402 may further include:
and the fifth target plug-in determining subunit is configured to determine that the target plug-in does not exist in the at least one plug-in to be detected when the at least one plug-in to be detected is traversed and the plug-in to be detected with the target function is not detected.
In another embodiment of the present disclosure, the apparatus may further include:
the target plug-in loading unit is used for loading a target plug-in;
and the function execution unit is used for executing the target function based on the target plug-in.
According to an embodiment of the present disclosure, the present disclosure also provides an electronic device and a readable storage medium.
FIG. 5 illustrates a schematic block diagram of an example electronic device 500 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. 5, the apparatus 500 comprises a computing unit 501 which may perform various appropriate actions and processes in accordance with a computer program stored in a Read Only Memory (ROM)502 or a computer program loaded from a storage unit 508 into a Random Access Memory (RAM) 503. In the RAM503, various programs and data required for the operation of the device 500 can also be stored. The calculation unit 501, the ROM502, and the RAM503 are connected to each other by a bus 504. An input/output (I/O) interface 505 is also connected to bus 504.
A number of components in the device 500 are connected to the I/O interface 505, including: an input unit 506 such as a keyboard, a mouse, or the like; an output unit 507 such as various types of displays, speakers, and the like; a storage unit 508, such as a magnetic disk, optical disk, or the like; and a communication unit 509 such as a network card, modem, wireless communication transceiver, etc. The communication unit 509 allows the device 500 to exchange information/data with other devices through a computer network such as the internet and/or various telecommunication networks.
The computing unit 501 may be a variety of general-purpose and/or special-purpose processing components having processing and computing capabilities. Some examples of the computing unit 501 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 so forth. The calculation unit 501 executes the respective methods and processes described above, such as the determination method of the plug-in. For example, in some embodiments, the plug-in determination method may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as storage unit 508. In some embodiments, part or all of the computer program may be loaded and/or installed onto the device 500 via the ROM502 and/or the communication unit 509. When the computer program is loaded into the RAM503 and executed by the computing unit 501, one or more steps of the plug-in determination method described above may be performed. Alternatively, in other embodiments, the computing unit 501 may be configured to perform the plug-in determination 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, speech, 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. The server may be a cloud server, a server of a distributed system, or a server with a combined blockchain.
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, sequentially, or in different orders, as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved, and the present disclosure is not limited herein.
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 (12)

1. A method for determining a plug-in, comprising:
traversing a pre-configured plug-in storage directory to obtain at least one plug-in to be detected, wherein the plug-in to be detected is a pre-configured plug-in with a specific function;
reading plug-in description information carried in the plug-in to be detected, and determining a target plug-in with a target function in at least one plug-in to be detected based on the plug-in description information, wherein the plug-in description information is information which is configured in the plug-in to be detected in advance and is at least used for describing the specific function.
2. The method according to claim 1, wherein the step of determining the insert to be detected comprises:
determining the plug-in storage directory;
and traversing the plug-in storage directory, and determining the plug-ins stored in the plug-in storage directory as the plug-ins to be detected.
3. The method according to claim 1, wherein the determining of the target plug-in with the target function among the at least one plug-in to be detected comprises:
sequentially detecting whether the to-be-detected plug-ins have the target function or not based on the plug-in description information;
and under the condition that the to-be-detected plug-in is detected to have the target function, determining the to-be-detected plug-in with the target function as the target plug-in.
4. The method according to claim 1, wherein in a case that the plug-in description information is also used for describing a loading priority of the plug-ins to be detected, the determining, in at least one of the plug-ins to be detected, a target plug-in having a target function includes:
sequentially detecting whether the to-be-detected plug-ins have the target function or not based on the plug-in description information;
under the condition that the to-be-detected plug-in is detected to have the target function, determining the to-be-detected plug-in with the target function as a candidate plug-in;
determining whether the candidate plug-in needs to be subjected to loading priority verification or not based on the plug-in description information;
and under the condition that the candidate plug-in does not need to carry out loading priority check, determining the candidate plug-in as the target plug-in.
5. The method according to claim 4, wherein the determining of the target plug-in with the target function in the at least one plug-in to be detected further comprises:
traversing the undetected plug-in to be detected under the condition that the candidate plug-in needs to be subjected to loading priority verification to obtain other plug-ins to be detected with the target function;
and determining the target plug-in the candidate plug-ins and other plug-ins to be detected.
6. The method according to claim 5, wherein the determining the target plug-in among the candidate plug-ins and the other plug-ins to be detected comprises:
obtaining loading priorities corresponding to the candidate plug-ins and the other plug-ins to be detected;
and determining the plug-in to be detected with the highest loading priority as the target plug-in from the candidate plug-ins and other plug-ins to be detected.
7. The method according to claim 3 or 4, wherein the determining of the target plug-in with the target function among the at least one plug-in to be detected further comprises:
and under the condition that the at least one plug-in to be detected is traversed and the plug-in to be detected with the target function is not detected, determining that the target plug-in does not exist in the at least one plug-in to be detected.
8. The method according to any one of claims 3-6, further comprising:
loading the target plug-in;
and executing the target function based on the target plug-in.
9. An apparatus for determining a plug-in, comprising:
the to-be-detected plug-in unit determining unit is used for traversing a pre-configured plug-in storage directory to obtain at least one to-be-detected plug-in, wherein the to-be-detected plug-in is a pre-configured plug-in with a specific function;
and the target plug-in determining unit is used for reading plug-in description information carried in the plug-ins to be detected, and determining a target plug-in with a target function in at least one plug-in to be detected based on the plug-in description information, wherein the plug-in description information is information which is configured in the plug-ins to be detected in advance and is at least used for describing the specific function.
10. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein 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 to 8.
11. 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 to 8.
12. A computer program product comprising computer program/instructions, characterized in that the computer program/instructions, when executed by a processor, implement the steps of the method of any one of claims 1 to 8.
CN202111542574.8A 2021-12-14 2021-12-14 Plug-in determining method and device, electronic equipment and storage medium Pending CN114217873A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111542574.8A CN114217873A (en) 2021-12-14 2021-12-14 Plug-in determining method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111542574.8A CN114217873A (en) 2021-12-14 2021-12-14 Plug-in determining method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN114217873A true CN114217873A (en) 2022-03-22

Family

ID=80702931

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111542574.8A Pending CN114217873A (en) 2021-12-14 2021-12-14 Plug-in determining method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114217873A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105426200A (en) * 2015-10-30 2016-03-23 小米科技有限责任公司 Communication module firmware and plug-in generation method and apparatus
CN109977670A (en) * 2019-03-12 2019-07-05 福建天晴数码有限公司 Android application safety monitoring method, storage medium based on plug-in unit load
CN111190657A (en) * 2020-01-07 2020-05-22 北京字节跳动网络技术有限公司 Activity configuration method and device, readable medium and electronic equipment

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105426200A (en) * 2015-10-30 2016-03-23 小米科技有限责任公司 Communication module firmware and plug-in generation method and apparatus
CN109977670A (en) * 2019-03-12 2019-07-05 福建天晴数码有限公司 Android application safety monitoring method, storage medium based on plug-in unit load
CN111190657A (en) * 2020-01-07 2020-05-22 北京字节跳动网络技术有限公司 Activity configuration method and device, readable medium and electronic equipment

Similar Documents

Publication Publication Date Title
US11151024B2 (en) Dynamic automation of DevOps pipeline vulnerability detecting and testing
CN113342345A (en) Operator fusion method and device of deep learning framework
US20150220332A1 (en) Resolving merge conflicts that prevent blocks of program code from properly being merged
CN113127050B (en) Application resource packaging process monitoring method, device, equipment and medium
CN110659210A (en) Information acquisition method and device, electronic equipment and storage medium
CN113760769A (en) Test case processing method and device, electronic equipment and storage medium
CN112528641A (en) Method and device for establishing information extraction model, electronic equipment and readable storage medium
CN114372256A (en) Application program running method, device, equipment and storage medium
US9575750B2 (en) Generic annotation seeker
CN112363814A (en) Task scheduling method and device, computer equipment and storage medium
CN109145591B (en) Plug-in loading method of application program
CN115543967A (en) Data migration method and device, electronic equipment and computer readable medium
US9075679B1 (en) Creating a prerequisite checklist corresponding to a software application
US11068246B2 (en) Control flow graph analysis
US9110893B2 (en) Combining problem and solution artifacts
CN114217873A (en) Plug-in determining method and device, electronic equipment and storage medium
CN115643094A (en) Threat information fusion method and device, electronic equipment and storage medium
CN115328736A (en) Probe deployment method, device, equipment and storage medium
CN115421831A (en) Method, device, equipment and storage medium for generating calling relation of activity component
CN114201729A (en) Method, device and equipment for selecting matrix operation mode and storage medium
CN113760765B (en) Code testing method and device, electronic equipment and storage medium
CN110647519B (en) Method and device for predicting missing attribute value in test sample
CN115509543A (en) Method and device for determining document validity, electronic equipment and storage medium
CN114115854A (en) SDK file generation method, device, equipment and storage medium
CN117852043A (en) Determination method and device for abnormal device, electronic device and storage 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
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20220408

Address after: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Applicant after: BEIJING BYTEDANCE NETWORK TECHNOLOGY Co.,Ltd.

Address before: 2005, floor 2, No. 39, West Street, Haidian District, Beijing 100080

Applicant before: Beijing jingling Information System Technology Co.,Ltd.