Equipment capability information management method and device, equipment and storage medium
By receiving and parsing the capability information of IoT devices, generating information subscription sets and storing them to a database, the problem of low efficiency in obtaining and displaying equipment capabilities information in the prior art is solved, and efficient storage and display effects are achieved.
Patent Information
- Application Number
- CN202411821721.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-11
- Publication Date
- 2025-04-04
AI Technical Summary
In the prior art, the capability information acquisition and display efficiency of IoT devices is low and cannot meet the needs of large-scale device management.
By receiving device capability information reported by the terminal device, extracting a string array, parsing and generating information subscription sets, and storing it in the database to update the device capability list. Respond to information query instructions and output structured display results based on the database.
It improves the storage and display efficiency of equipment capability information, reduces invalid information during information uploading, provides a unified and structured display structure, and improves query response speed.
Smart Images

Figure CN119760184A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of Internet of Things, and in particular to a method, apparatus, device and storage medium for managing device capability information. Background Art
[0002] With the development of IoT technology, more and more devices are connected to the Internet, forming a huge IoT ecosystem. As a lightweight M2M communication protocol, LwM2M (Lightweight Machine-to-Machine) has been widely used in the field of IoT due to its low power consumption, easy deployment and management. The LwM2M protocol defines a series of objects, each of which contains multiple resources, which are used to describe the various functions and states of the device, and are used for device capability reporting, configuration management and remote control.
[0003] However, in the existing technology, the reporting and parsing process of device capability information is cumbersome, the construction of subscription sets lacks flexibility, and the storage monitoring and query display efficiency is low, which cannot meet the needs of large-scale device management. With the surge in the number of IoT devices, the efficiency of acquiring and displaying capability information of IoT devices in a unified network has become even lower.
[0004] The above contents are only used to assist in understanding the technical solution of the present invention and do not constitute an admission that the above contents are prior art. Summary of the invention
[0005] The main purpose of the present invention is to provide a device capability information management method, apparatus, device and storage medium, aiming to solve the technical problem of low efficiency in acquiring and displaying capability information of IoT devices in the prior art.
[0006] To achieve the above object, the present invention provides a method for managing device capability information, the method comprising the following steps:
[0007] Receive device capability information reported by the terminal device, and extract the string array in the device capability information;
[0008] Parsing the string array to generate an information subscription set of the device capability information;
[0009] Storing the information subscription set in a database accordingly to update the device capability list pre-stored in the database;
[0010] In response to the information query instruction, a structured display result of the device capability information corresponding to the information query instruction is output based on the database, and the structured display result is obtained by performing structured processing on the device capability list.
[0011] Optionally, the parsing the string array to generate an information subscription set of the device capability information includes:
[0012] Determining the hierarchical depth of the string array;
[0013] Parsing the string array according to the target processing strategy corresponding to the hierarchical depth to obtain the target resource corresponding to each string array;
[0014] An information subscription set of the device capability information is generated according to the target resource and the string array.
[0015] Optionally, generating an information subscription set of the device capability information according to the target resource and the string array includes:
[0016] Update the string array according to the resource identification code of the target resource to obtain a target string array;
[0017] The target string array is filled into the initial subscription set to obtain an information subscription set.
[0018] Optionally, storing the information subscription set in a database to update a device capability list pre-stored in the database includes:
[0019] When the target terminal device corresponding to the information subscription set meets a preset condition, determining a target device identification code of the target terminal device;
[0020] Deleting the historical subscription set corresponding to the target device identification code in the database, and storing the device identification code and the corresponding information subscription set in the database to update the pre-stored device capability list;
[0021] The preset condition includes that the terminal device reports for the first time, or the device capability information in the information subscription set is different from the historical device capability information in the history subscription set corresponding to the device identification code in the database.
[0022] Optionally, outputting a structured display result of the device capability information corresponding to the information query instruction based on the database includes:
[0023] Retrieving a device capability list stored in the database;
[0024] Parsing the device capability list to obtain at least one device object identification code, at least one instance identification code, and at least one resource information identification code;
[0025] Structural processing is performed according to each device object identification code, each identification code and each resource information identification code to obtain a structured display result of the device capability information.
[0026] Optionally, parsing the device capability list includes:
[0027] Extracting a list character string corresponding to the device capability list, and determining a target character in the list character string;
[0028] Segmenting the list character string based on the target character to obtain at least one device object identification code and at least one instance identification code;
[0029] The resource information identification code corresponding to each device object identification code is queried from the database.
[0030] Optionally, the page structuring processing is performed according to each device object identification code, each identification code and each resource information identification code to obtain a structured display result of the device capability information, including:
[0031] Constructing a corresponding first instance according to each resource identification code, wherein the first instance is associated with the resource identification code, resource name, resource type, resource operation, and access path;
[0032] Generate an instance access path according to each device object identification code and each instance identification code, and detect whether a target instance exists in a preset container through the instance access path;
[0033] If not, construct a second instance corresponding to each instance identification code, wherein the second instance is associated with the instance identification code, the instance name, and the instance access path;
[0034] constructing a device object access path according to each device object identification code, and creating a third instance based on the device object access path, wherein the third instance is associated with the device object identification code, the device object name, and the instance list;
[0035] Testing the uniqueness of the first instance, the second instance, and the third instance by using a preset container;
[0036] When the detection passes, the preset container is converted into a structured display result of the device capability information.
[0037] In addition, to achieve the above-mentioned purpose, the present invention further proposes a device capability information management device, the device capability information management device comprising:
[0038] A receiving module, used to receive device capability information reported by a terminal device and extract a string array from the device capability information;
[0039] A parsing module, used for parsing the string array to generate an information subscription set of the device capability information;
[0040] A storage module, used to store the information subscription set in a database to update the device capability list pre-stored in the database;
[0041] The output module is used to respond to the information query instruction and output the structured display result of the device capability information corresponding to the information query instruction based on the database, wherein the structured display result is obtained by structured processing of the device capability list.
[0042] In addition, to achieve the above-mentioned purpose, the present invention also proposes a device capability information management device, which includes: a memory, a processor, and a device capability information management program stored in the memory and executable on the processor, and the device capability information management program is configured to implement the steps of the device capability information management method described above.
[0043] In addition, to achieve the above-mentioned purpose, the present invention also proposes a storage medium, on which a device capability information management program is stored, and when the device capability information management program is executed by a processor, the steps of the device capability information management method described above are implemented.
[0044] In addition, to achieve the above-mentioned purpose, the present application also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, the steps of the device capability information management method as described above are implemented.
[0045] One or more technical solutions proposed in the present invention have at least the following technical effects: The present invention discloses a device capability information management method, the device capability information management method comprising: receiving device capability information reported from a terminal device, and extracting a string array in the device capability information; parsing the string array to generate an information subscription set of the device capability information; storing the information subscription set in a database to update the device capability list pre-stored in the database; in response to an information query instruction, outputting a structured display result of the device capability information corresponding to the information query instruction based on the database, the structured display result being obtained by structured processing of the device capability list. Compared with the prior art, the present invention receives device capability information reported by each terminal device and extracts the string array contained in the device capability information, thereby reducing invalid information in the information upload process and improving the storage efficiency of the device capability information. By parsing the string array, an information subscription set of the device capability information is generated and stored in a database, providing a unified and structured display structure for subsequent information query. After the information query instruction is triggered, the structured display result of the device capability information of each terminal device can be queried in the database, thereby improving the display efficiency of the device capability information and avoiding the technical problem of low efficiency in acquiring and displaying capability information of IoT devices in the prior art. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0047] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0048] Figure 1 It is a flowchart of the first embodiment of the device capability information management method of the present invention;
[0049] Figure 2 It is a flowchart of a second embodiment of the device capability information management method of the present invention;
[0050] Figure 3 A schematic diagram of a flow chart of a third embodiment of a method for managing device capability information of the present invention;
[0051] Figure 4 This is a schematic diagram of a structured display result of an embodiment of a device capability information management method of the present invention;
[0052] Figure 5 A schematic diagram of a device capability information management interface of an Internet of Things terminal device according to an embodiment of a device capability information management method of the present invention;
[0053] Figure 6 It is a structural block diagram of a first embodiment of the device capability information management apparatus of the present invention;
[0054] Figure 7 It is a structural diagram of a device capability information management device for a hardware operating environment involved in an embodiment of the present invention.
[0055] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0056] It should be understood that the specific embodiments described herein are only used to explain the technical solutions of the present application and are not used to limit the present application.
[0057] In order to better understand the technical solution of the present application, a detailed description will be given below in conjunction with the accompanying drawings and specific implementation methods.
[0058] Based on this, the embodiment of the present invention provides a device capability information management method, referring to Figure 1 , Figure 1 It is a flowchart of a first embodiment of a method for managing device capability information of the present invention.
[0059] In this embodiment, the device capability information management method includes:
[0060] Step S10: receiving device capability information reported by the terminal device, and extracting a character string array in the device capability information.
[0061] It should be noted that the execution subject of this embodiment can be a computing service device with data processing, network communication and program running functions, such as a tablet computer, a personal computer, a mobile phone, etc., or an electronic device capable of realizing the above functions, a control computer or a cloud server, etc. The following takes the cloud server as an example to illustrate this embodiment and the following embodiments.
[0062] It should be noted that during the operation of the Internet of Things, in order to effectively monitor the operating status of each device in the Internet of Things, each terminal device in the Internet of Things needs to upload operation logs and device capability information regularly or in real time. A large amount of operation logs and device capability information will cause the control core of the Internet of Things, that is, the cloud server, to be overloaded, resulting in low equipment management efficiency of the Internet of Things and slow response speed when facing user query needs.
[0063] In this embodiment, by receiving the device capability information reported by each terminal device and extracting the string array contained in the device capability information, invalid information in the information upload process is reduced, the storage efficiency of the device capability information is improved, and the query efficiency when facing subsequent query tasks is improved.
[0064] Device capability information refers to the sum of information such as the functions, performance parameters, compatibility, interface types, etc. of the device, including but not limited to hardware specifications, software capabilities, network connection status, interface status, sensors, security functions, and other attribute information.
[0065] Each terminal device in the Internet of Things reports the objects and resource information it supports, including object ID, instance ID, and resource ID, through the LwM2M protocol. After receiving the information reported by each terminal device, the cloud server will check the validity of the device ID and whether the device exists, and then parse the information reported by the device and convert it into a data structure that is easy to process, that is, extract the string array, to improve the efficiency of data storage and data query.
[0066] Step S20: Parse the string array to generate an information subscription set of the device capability information.
[0067] It should be noted that parsing the string array refers to building an observation capability set, including capability information at the object, instance, and resource levels, for subsequent device status monitoring, by applying predefined rules, such as ignoring certain standard objects, or automatically subscribing to specific objects and resources, to filter out capability information that needs to be subscribed.
[0068] Step S30: storing the information subscription set in a database accordingly to update the device capability list pre-stored in the database.
[0069] The device capability list stores the device capability information of each terminal device in the Internet of Things, which is convenient for users to monitor and manage the operating status of the Internet of Things devices.
[0070] Furthermore, the storing the information subscription set in a database to update the device capability list pre-stored in the database includes:
[0071] When the target terminal device corresponding to the information subscription set meets a preset condition, determining a target device identification code of the target terminal device;
[0072] Deleting the historical subscription set corresponding to the target device identification code in the database, and storing the device identification code and the corresponding information subscription set in the database to update the pre-stored device capability list;
[0073] The preset condition includes that the terminal device reports for the first time, or the device capability information in the information subscription set is different from the historical device capability information in the history subscription set corresponding to the device identification code in the database.
[0074] In the specific implementation, if the device reports for the first time or the reported information is different from that stored in the database, the Object List information in the database is updated. In order to prevent read and write exceptions caused by duplicate database key values, in this embodiment, when storing data, a strategy of first deleting and then inserting is adopted, that is, the historical subscription set of the terminal device corresponding to the target device identification code is deleted first, and then the new information subscription set is written.
[0075] Step S40: in response to the information query instruction, outputting a structured display result of the device capability information corresponding to the information query instruction based on the database, wherein the structured display result is obtained by performing structured processing on the device capability list.
[0076] It should be understood that the information query instruction refers to the control instruction used by the user to monitor or view the operating status of each device in the Internet of Things, and the structured display result refers to the device capability list and device capability information displayed in a certain format.
[0077] This embodiment receives device capability information reported by each terminal device and extracts the string array contained in the device capability information, thereby reducing invalid information in the information upload process and improving the storage efficiency of the device capability information. The string array is parsed to generate an information subscription set of the device capability information and store it in a database, thereby providing a unified and structured display structure for subsequent information query. After the information query instruction is triggered, the structured display results of the device capability information of each terminal device can be queried in the database, thereby improving the display efficiency of the device capability information and avoiding the technical problem of low efficiency in acquiring and displaying capability information of IoT devices in the prior art.
[0078] Based on the first embodiment of the present application, in the second embodiment of the present application, the same or similar contents as those in the above-mentioned embodiment 1 can be referred to the above introduction, and will not be repeated in the following. Figure 2 , step S20, comprising:
[0079] Step S201: Determine the hierarchical depth of the string array.
[0080] Step S202: parsing the string array according to the target processing strategy corresponding to the hierarchical depth to obtain the target resource corresponding to each string array.
[0081] Step S203: Generate an information subscription set of the device capability information according to the target resource and the string array.
[0082] It should be noted that the hierarchical depth of the string array refers to the data format, complexity, nesting depth, etc. of the string array. In this embodiment, according to the different data formats, complexities or nesting depths of the string array, different processing strategies can be selected to parse the string array to extract the information represented by the string.
[0083] In a specific implementation, the target processing strategy includes but is not limited to a string of length 3 (in the form of / object ID / instance number), which indicates an object-level subscription; if the object ID is 19 and the instance number is 0, find a specific resource and add it to the subscription set; if the object ID is not in the IGNORED_OBJECTS set, add object-level and instance-level subscription information respectively; for a string of length 4 or 5 (in the form of / object ID / instance number / resource ID), it indicates a resource-level subscription; check the object ID and resource ID, and if they meet the conditions, find the resource and add it to the subscription set.
[0084] The subscription set refers to a pre-created empty subscription set subscriptionSet.
[0085] Further, generating the information subscription set of the device capability information according to the target resource and the string array includes:
[0086] Update the string array according to the resource identification code of the target resource to obtain a target string array;
[0087] The target string array is filled into the initial subscription set to obtain an information subscription set.
[0088] It should be understood that all capability information that meets the subscription conditions is added to subscriptionSet in the format of / object ID / instance number / resource ID to obtain an information subscription set. For ease of understanding, the analysis case of the capability information string array reported by an IoT device based on the LwM2M protocol is used to illustrate. It is assumed that the capability information string array reported by an IoT device based on the LwM2M protocol is: [ / 1 / 0; / 2 / 0; / 2 / 1; / 2 / 2; / 2 / 3; / 3 / 0; / 19 / 0; / 19 / 1], and the object ID set of IGNORED_OBJECTS defined in this system is [0, 1, 2, 4, 5, 6, 7, 9, 15, 27000], then the device capability subscription set finally generated by the algorithm is [ / 19 / 0 / 0; / 3 / 0 / 17; / 3 / 0 / 18; / 3 / 0 / 19; / 3 / 0 / 10; / 3 / 0 / 11; / 3 / 0; / 3 / 0 / 12; / 3 / 0 / 13; / 3 / 0 / 14; / 3 / 0 / 15; / 3 / 0 / 16; / 3; / 3 / 0 / 2; / 3 / 0 / 20; / 3 / 0 / 3; / 3 / 0 / 21; / 3 / 0 / 4; / 3 / 0 / 22; / 3 / 0 / 5; / 3 / 0 / 6; / 3 / 0 / 7; / 3 / 0 / 8; / 3 / 0 / 9; / 3 / 0 / 0; / 3 / 0 / 1].
[0089] This embodiment determines the hierarchical depth of the string array; parses the string array according to the target processing strategy corresponding to the hierarchical depth to obtain the corresponding target resources of each string array; generates an information subscription set of the device capability information according to the target resources and the string array, and improves the efficiency of data storage and subsequent reading and writing by converting the device capability information reported by each terminal device into an information subscription set in a unified data format.
[0090] Based on the second embodiment of the present application, in the third embodiment of the present application, the same or similar contents as those in the first embodiment can be referred to the above description, and will not be described in detail later. Figure 3 , step S40, comprising:
[0091] Step S401: extracting the device capability list stored in the database.
[0092] Step S402: Parse the device capability list to obtain at least one device object identification code, at least one instance identification code, and at least one resource information identification code.
[0093] Step S403: Perform structural processing according to each device object identification code, each identification code and each resource information identification code to obtain a structured display result of the device capability information.
[0094] It should be noted that the device capability information stored in the database is converted into a structured display result so that users can directly operate the device, and finally the optimized device capability information including remote control options is presented to the user in an intuitive way. The page displays the device capability list, providing the device management platform with real-time monitoring capabilities.
[0095] Further, parsing the device capability list includes:
[0096] Extracting a list character string corresponding to the device capability list, and determining a target character in the list character string;
[0097] Segmenting the list character string based on the target character to obtain at least one device object identification code and at least one instance identification code;
[0098] The resource information identification code corresponding to each device object identification code is queried from the database.
[0099] In a specific implementation, the process of splitting the string refers to splitting the objectList string into a series of capability description strings according to semicolons.
[0100] For each capability string fragment, it is split using specific characters such as semicolons or slashes during the compilation phase. After the device object ID and instance ID are extracted by splitting the string, all resource information corresponding to the device object ID is obtained by querying the database to obtain the resource information identification code. If the resource information identification code does not exist, the current terminal device object is skipped and the database is queried to obtain the basic information of the device object. If the resource information identification code does not exist, the current object is skipped.
[0101] Furthermore, the page structured processing is performed according to each device object identification code, each identification code and each resource information identification code to obtain a structured display result of the device capability information, including:
[0102] Constructing a corresponding first instance according to each resource identification code, wherein the first instance is associated with the resource identification code, resource name, resource type, resource operation, and access path;
[0103] Generate an instance access path according to each device object identification code and each instance identification code, and detect whether a target instance exists in a preset container through the instance access path;
[0104] If not, construct a second instance corresponding to each instance identification code, wherein the second instance is associated with the instance identification code, the instance name, and the instance access path;
[0105] constructing a device object access path according to each device object identification code, and creating a third instance based on the device object access path, wherein the third instance is associated with the device object identification code, the device object name, and the instance list;
[0106] Testing the uniqueness of the first instance, the second instance, and the third instance by using a preset container;
[0107] When the detection passes, the preset container is converted into a structured display result of the device capability information.
[0108] In a specific implementation, for the first instance, all resource information in the database can be traversed, and for each resource, an Lwm2mResourceList instance is created, and its resource information identification code, resource name, resource type, resource operation, path, and observed status are set, and it is checked whether the resource already exists in the preset container Map. If it exists, it is skipped, otherwise it is added to the resource list and stored in the preset container, where the preset container is used to ensure the uniqueness of device objects, instances, and resource information.
[0109] For the second instance, you can use the device object information identifier and instance information identifier to construct the instance path, check whether the instance already exists in the preset container, if it exists, skip it, otherwise create an Lwm2mInstanceList instance, set its instance information identifier, instance name, path and whether it is observed, and associate it with the resource list
[0110] For the third instance, you can construct the object path using the device object information identification code, create an Lwm2mObjectList instance, set its object information identification code, object name and path, and associate the instance list
[0111] Finally, all device object information in the preset container is added to the corresponding collection, and finally a structured device capability information collection is formed, which is returned as the query result, completing the efficient query and display optimization of the device capability information.
[0112] Specifically, refer to Figure 4 and Figure 5 , Figure 4 This is a schematic diagram of an example of a structured display result of this embodiment. Figure 5This is a schematic diagram of a page for managing device capability information of terminal devices in the Internet of Things in this embodiment. Assume that the capability information string array reported by an Internet of Things device of the LwM2M protocol is [ / 1 / 0; / 2 / 0; / 2 / 1; / 2 / 2; / 2 / 3; / 3 / 0; / 19 / 0; / 19 / 1], and the device capability subscription set finally generated by the algorithm is [ / 19 / 0 / 0; / 3 / 0 / 17; / 3 / 0 / 18; / 3 / 0 / 19; / 3 / 0 / 10; / 3 / 0 / 11; / 3 / 0; / 3 / 0 / 12; / 3 / 0 / 13; / 3 / 0 / 14; / 3 / 0 / 15; / 3 / 0 / 16; / 3; / 3 / 0 / 2; / 3 / 0 / 20; / 3 / 0 / 3; / 3 / 0 / 21; / 3 / 0 / 4; / 3 / 0 / 22; / 3 / 0 / 5; / 3 / 0 / 6; / 3 / 0 / 7; / 3 / 0 / 8; / 3 / 0 / 9; / 3 / 0 / 0; / 3 / 0 / 1], we can get Figure 4 The structured display results shown.
[0113] This embodiment extracts the device capability list stored in the database; parses the device capability list to obtain at least one device object identification code, at least one instance identification code, and at least one resource information identification code; performs structured processing according to each device object identification code, each identification code, and each resource information identification code to obtain a structured display result of the device capability information. By performing structured processing on the device identification code, resource identification code, and instance identification code respectively, the database storage and query logic are optimized, and the consumption of storage resources and computing resources is reduced. Therefore, the query time is reduced, the system response speed is improved, the query time of the device capability information is shortened, and the user experience is improved.
[0114] This application also provides a device capability information management device, please refer to Figure 6 , the device capability information management device comprises:
[0115] The receiving module 10 is used to receive device capability information reported by the terminal device and extract the character string array in the device capability information.
[0116] The parsing module 20 is used to parse the string array and generate an information subscription set of the device capability information.
[0117] The storage module 30 is used to store the information subscription set in a database to update the device capability list pre-stored in the database.
[0118] The output module 40 is used to respond to the information query instruction and output the structured display result of the device capability information corresponding to the information query instruction based on the database, wherein the structured display result is obtained by structuring the device capability list.
[0119] This embodiment receives device capability information reported by each terminal device and extracts the string array contained in the device capability information, thereby reducing invalid information in the information upload process and improving the storage efficiency of the device capability information. The string array is parsed to generate an information subscription set of the device capability information and store it in a database, thereby providing a unified and structured display structure for subsequent information query. After the information query instruction is triggered, the structured display results of the device capability information of each terminal device can be queried in the database, thereby improving the display efficiency of the device capability information and avoiding the technical problem of low efficiency in acquiring and displaying capability information of IoT devices in the prior art.
[0120] In one embodiment, the parsing module 20 is also used to determine the hierarchical depth of the string array; parse the string array according to the target processing strategy corresponding to the hierarchical depth to obtain the corresponding target resources of each string array; and generate an information subscription set of the device capability information based on the target resources and the string array.
[0121] In one embodiment, the parsing module 20 is further used to update the string array according to the resource identification code of the target resource to obtain a target string array; and fill the target string array into the initial subscription set to obtain an information subscription set.
[0122] In one embodiment, the storage module 30 is also used to determine the target device identification code of the target terminal device when the target terminal device corresponding to the information subscription set meets the preset conditions; delete the historical subscription set corresponding to the target device identification code in the database, and store it in the database according to the device identification code and the corresponding information subscription set to update the pre-stored device capability list; wherein the preset conditions include the first reporting of the terminal device, or the device capability information in the information subscription set is different from the historical device capability information in the historical subscription set corresponding to the device identification code in the database.
[0123] In one embodiment, the output module 40 is also used to extract the device capability list stored in the database; parse the device capability list to obtain at least one device object identification code, at least one instance identification code and at least one resource information identification code; perform structured processing according to each device object identification code, each identification code and each resource information identification code to obtain a structured display result of the device capability information.
[0124] In one embodiment, the output module 40 is further used to extract the list string corresponding to the device capability list and determine the target characters in the list string; segment the list string based on the target characters to obtain at least one device object identification code and at least one instance identification code; and query the resource information identification code corresponding to each device object identification code from the database.
[0125] In one embodiment, the output module 40 is also used to construct a corresponding first instance according to each resource identification code, and the first instance is associated with the resource identification code, resource name, resource type, resource operation and access path; generate an instance access path according to each device object identification code and each instance identification code, and detect whether there is a target instance in a preset container through the instance access path; if not, construct a second instance corresponding to each instance identification code, and the second instance is associated with the instance identification code, instance name and instance access path; construct a device object access path according to each device object identification code, and create a third instance based on the device object access path, and the third instance is associated with the device object identification code, device object name and the instance list; detect the uniqueness of the first instance, the second instance and the third instance through a preset container; when the detection passes, convert the preset container into a structured display result of the device capability information.
[0126] The present application provides a device capability information management device, which includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the device capability information management method in the above-mentioned embodiment 1.
[0127] Reference below Figure 7 , which shows a schematic diagram of the structure of a device capability information management device suitable for implementing the embodiment of the present application. The device capability information management device in the embodiment of the present application may include but is not limited to mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Descriptions), PMPs (Portable Media Players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 7 The device capability information management device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0128] like Figure 7 As shown, the device capability information management device may include a processing device 1001 (e.g., a central processing unit, a graphics processor, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM: Read Only Memory) 1002 or a program loaded from a storage device 1003 to a random access memory (RAM: Random Access Memory) 1004. In RAM1004, various programs and data required for the operation of the device capability information management device are also stored. The processing device 1001, ROM1002, and RAM1004 are connected to each other through a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Generally, the following systems can be connected to the I / O interface 1006: an input device 1007 including, for example, a touch screen, a touch pad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc.; an output device 1008 including, for example, a liquid crystal display (LCD: Liquid Crystal Display), a speaker, a vibrator, etc.; a storage device 1003 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1009. The communication device 1009 can allow the device capability information management device to communicate with other devices wirelessly or by wire to exchange data. Although the figure shows a device capability information management device with various systems, it should be understood that it is not required to implement or have all the systems shown. More or fewer systems can be implemented or have alternatively.
[0129] In particular, according to the embodiments disclosed in the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device, or installed from a storage device 1003, or installed from a ROM 1002. When the computer program is executed by the processing device 1001, the above-mentioned functions defined in the method of the embodiment disclosed in the present application are executed.
[0130] The device capability information management device provided by the present application adopts the device capability information management method in the above embodiment to solve the technical problem of device capability information management. Compared with the prior art, the beneficial effects of the device capability information management device provided by the present application are the same as the beneficial effects of the device capability information management method provided by the above embodiment, and other technical features in the device capability information management device are the same as the features disclosed in the method of the previous embodiment, which will not be repeated here.
[0131] It should be understood that the various parts disclosed in this application can be implemented by hardware, software, firmware or a combination thereof. In the description of the above embodiments, specific features, structures, materials or characteristics can be combined in any one or more embodiments or examples in a suitable manner.
[0132] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
[0133] The present application provides a computer-readable storage medium having computer-readable program instructions (ie, computer programs) stored thereon, and the computer-readable program instructions are used to execute the device capability information management method in the above-mentioned embodiment.
[0134] The computer-readable storage medium provided in the present application may be, for example, a USB flash drive, but is not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, systems or devices, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, 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 disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, system or device. The program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination of the above.
[0135] The computer-readable storage medium may be included in the device capability information management device; or may exist independently without being installed in the device capability information management device.
[0136] The computer-readable storage medium carries one or more programs. When the one or more programs are executed by the device capability information management device, the device capability information management device performs device capability information management.
[0137] Computer program code for performing the operations of the present application may be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, C++, and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0138] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0139] The modules involved in the embodiments described in this application may be implemented by software or hardware, wherein the name of the module does not constitute a limitation on the unit itself in some cases.
[0140] The readable storage medium provided by the present application is a computer-readable storage medium, which stores computer-readable program instructions (i.e., computer programs) for executing the above-mentioned device capability information management method, and can solve the technical problems of device capability information management. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided by the present application are the same as the beneficial effects of the device capability information management method provided by the above-mentioned embodiment, and will not be repeated here.
[0141] The present application also provides a computer program product, including a computer program, which implements the steps of the above-mentioned device capability information management method when executed by a processor.
[0142] The computer program product provided by this application can solve the technical problem of device capability information management. Compared with the prior art, the beneficial effects of the computer program product provided by this application are the same as the beneficial effects of the device capability information management method provided by the above embodiment, which will not be repeated here.
[0143] The above descriptions are only some embodiments of the present application, and are not intended to limit the patent scope of the present application. All equivalent structural changes made using the contents of the present application specification and drawings under the technical concept of the present application, or direct / indirect applications in other related technical fields are included in the patent protection scope of the present application.
Claims
1. A device capability information management method, characterized in that: The device capability information management method comprises: Receive device capability information reported by the terminal device, and extract the string array in the device capability information; Parsing the string array to generate an information subscription set of the device capability information; Storing the information subscription set in a database accordingly to update the device capability list pre-stored in the database; In response to the information query instruction, a structured display result of the device capability information corresponding to the information query instruction is output based on the database, and the structured display result is obtained by performing structured processing on the device capability list.
2. The method according to claim 1, characterized in that The parsing of the string array to generate an information subscription set of the device capability information includes: Determining the hierarchical depth of the string array; Parsing the string array according to the target processing strategy corresponding to the hierarchical depth to obtain the target resource corresponding to each string array; An information subscription set of the device capability information is generated according to the target resource and the string array.
3. The method according to claim 2, characterized in that The step of generating an information subscription set of the device capability information according to the target resource and the string array includes: Update the string array according to the resource identification code of the target resource to obtain a target string array; The target string array is filled into the initial subscription set to obtain an information subscription set.
4. The method according to claim 1, characterized in that The storing the information subscription set in a database accordingly to update the device capability list pre-stored in the database includes: When the target terminal device corresponding to the information subscription set meets a preset condition, determining a target device identification code of the target terminal device; Deleting the historical subscription set corresponding to the target device identification code in the database, and storing the device identification code and the corresponding information subscription set in the database to update the pre-stored device capability list; The preset condition includes that the terminal device reports for the first time, or the device capability information in the information subscription set is different from the historical device capability information in the history subscription set corresponding to the device identification code in the database.
5. The method according to claim 1, characterized in that The outputting, based on the database, a structured display result of the device capability information corresponding to the information query instruction includes: Retrieving a device capability list stored in the database; Parsing the device capability list to obtain at least one device object identification code, at least one instance identification code, and at least one resource information identification code; Structural processing is performed according to each device object identification code, each identification code and each resource information identification code to obtain a structured display result of the device capability information.
6. The method according to claim 5, characterized in that The parsing of the device capability list includes: Extracting a list character string corresponding to the device capability list, and determining a target character in the list character string; Segmenting the list character string based on the target character to obtain at least one device object identification code and at least one instance identification code; The resource information identification code corresponding to each device object identification code is queried from the database.
7. The method according to claim 5, characterized in that The page structured processing is performed according to each device object identification code, each identification code and each resource information identification code to obtain a structured display result of the device capability information, including: Constructing a corresponding first instance according to each resource identification code, wherein the first instance is associated with the resource identification code, resource name, resource type, resource operation, and access path; Generate an instance access path according to each device object identification code and each instance identification code, and detect whether a target instance exists in a preset container through the instance access path; If not, construct a second instance corresponding to each instance identification code, wherein the second instance is associated with the instance identification code, the instance name, and the instance access path; constructing a device object access path according to each device object identification code, and creating a third instance based on the device object access path, wherein the third instance is associated with the device object identification code, the device object name, and the instance list; Testing the uniqueness of the first instance, the second instance, and the third instance by using a preset container; When the detection passes, the preset container is converted into a structured display result of the device capability information.
8. A device capability information management device, characterized in that: The device capability information management device comprises: A receiving module, used to receive device capability information reported by a terminal device and extract a string array from the device capability information; A parsing module, used for parsing the string array to generate an information subscription set of the device capability information; A storage module, used to store the information subscription set in a database to update the device capability list pre-stored in the database; The output module is used to respond to the information query instruction and output the structured display result of the device capability information corresponding to the information query instruction based on the database, wherein the structured display result is obtained by structured processing of the device capability list.
9. A device capability information management device, characterized in that: The device capability information management device comprises: a memory, a processor, and a device capability information management program stored in the memory and executable on the processor, wherein the device capability information management program is configured to implement the steps of the device capability information management method according to any one of claims 1 to 7.
10. A storage medium, characterized in that: The storage medium stores a device capability information management program, and when the device capability information management program is executed by the processor, the steps of the device capability information management method according to any one of claims 1 to 7 are implemented.