Device management method and apparatus, electronic device, and storage medium
By using a method that generates XML file packages on the server and parses them on the client, the problem of long development cycles and high costs for intelligent composite device management templates is solved, and the automatic generation and flexible switching of management templates are realized.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHINA MOBILEHANGZHOUINFORMATION TECH CO LTD
- Filing Date
- 2022-11-17
- Publication Date
- 2026-06-05
AI Technical Summary
In existing technologies, the development cycle of control templates for intelligent composite equipment is long and costly, and the control templates are highly customized, resulting in complex interoperability between equipment and templates and an inability to flexibly switch attributes.
The system obtains information about the target vendor from the server, generates an Extensible Markup Language (XML) file package, and then parses and generates a management template on the client side, thus achieving automatic generation of the management template and avoiding redundant development.
It shortened the development cycle of the management template, reduced the development cost, solved the problem of highly customized management templates, and enabled flexible switching of device attributes.
Smart Images

Figure CN116915529B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a device management method, apparatus, electronic device, and computer storage medium. Background Technology
[0002] With the rapid development of IoT and smart home technologies, the functions of smart composite devices are becoming increasingly diverse. For example, smart composite video door locks, in addition to basic functions such as remote unlocking, log management, user management, and temporary passwords, also integrate the functions of a security camera and a smart doorbell. For these new smart composite devices, new control templates need to be developed. However, the development cycle for new control templates is long and the cost is high. Summary of the Invention
[0003] To address the aforementioned technical problems, embodiments of the present invention provide a device management method, apparatus, electronic device, and computer-readable storage medium, which solve the problems of long development cycles and high costs in the management and control templates of intelligent composite devices.
[0004] This application provides a device management method applied to a server, including:
[0005] Obtain first information about the target manufacturer, wherein the first information is used to characterize the name identifier of the target manufacturer and the attributes of each of the multiple devices produced by the target manufacturer;
[0006] Based on the first information of the target manufacturer, an Extensible Markup Language (XML) file package corresponding to the target device is obtained; the target device refers to a device manufactured by the target manufacturer that has at least two attributes.
[0007] The system receives and responds to client requests, and sends the XML file package to the client; the XML file package is used by the client to generate a control template corresponding to the target device.
[0008] This application also provides a device management method applied to a client, including:
[0009] Receive second information about the target device, the second information being used to characterize the target manufacturer that produces the target device, and the attributes of the target device, the target device referring to a device produced by the target manufacturer that has at least two attributes;
[0010] Based on the second information of the target device, a request message is sent to the server, the request message being used to request the server to obtain the Extensible Markup Language (XML) file package corresponding to the target device;
[0011] Receive the XML file package corresponding to the target device sent by the server;
[0012] The XML file package is parsed to obtain the parsing results;
[0013] Based on the analysis results, a control template corresponding to the target device is generated.
[0014] This application also provides a device management apparatus for use on a server, comprising:
[0015] The acquisition module is used to acquire first information about the target manufacturer, wherein the first information is used to characterize the name identifier of the target manufacturer and the attributes of each of the multiple devices produced by the target manufacturer;
[0016] The first generation module is used to obtain an Extensible Markup Language (XML) file package corresponding to the target device based on the first information corresponding to the target manufacturer; the target device refers to a device manufactured by the target manufacturer that has at least two attributes;
[0017] The first sending module is used to receive and respond to the client's request information and send the XML file package to the client; the XML file package is used by the client to generate a control template corresponding to the target device.
[0018] This application also provides a device management apparatus for use on a client side, comprising:
[0019] The first receiving module is used to receive second information about the target device, the second information being used to characterize the target manufacturer that produces the target device and the attributes of the target device, wherein the target device refers to a device produced by the target manufacturer that has at least two attributes;
[0020] The second sending module is used to send request information to the server based on the second information of the target device. The request information is used to request the server to obtain the Extensible Markup Language (XML) file package corresponding to the target device.
[0021] The second receiving module is used to receive the XML file package corresponding to the target device sent by the server;
[0022] The parsing module is used to parse the XML file package and obtain the parsing results;
[0023] The second generation module is used to generate a control template corresponding to the target device based on the parsing results.
[0024] This application also provides an electronic device, including a processor and a memory, the memory for storing a computer program, and the processor for calling and running the computer program stored in the memory to perform the steps of the device management method as described in this application.
[0025] This application also provides a computer-readable storage medium storing executable instructions, which, when executed by a processor, implement the steps of the device management method as described in this application.
[0026] This application provides a device management method, apparatus, electronic device, and computer storage medium. The device management method includes: a server acquiring first information about a target manufacturer, the first information representing the name and identifier of the target manufacturer and the attributes of each of a plurality of devices produced by the target manufacturer; the server obtaining an Extensible Markup Language (XML) file package corresponding to the target device based on the first information about the target manufacturer; the target device refers to a device produced by the target manufacturer that has at least two attributes; a client receiving second information about the target device, the second information representing the target manufacturer that produces the target device and the attributes of the target device; the client sending a request to the server based on the second information about the target device, the request request requesting the XML file package corresponding to the target device; the server receiving and responding to the client's request, sending the XML file package to the client; the client receiving the XML file package corresponding to the target device sent by the server; the client parsing the XML file package to obtain a parsing result; and the client generating a management template corresponding to the target device based on the parsing result. The device management method provided in this application embodiment enables the automatic generation of target device control templates by configuring an XML file package on the server, thereby shortening the development cycle and reducing the development cost of the target device control templates. Attached Figure Description
[0027] Figure 1 A flowchart illustrating a device management method provided in an embodiment of this application;
[0028] Figure 2 A flowchart illustrating the second device management method provided in this application embodiment;
[0029] Figure 3 A flowchart illustrating the device management method provided as the first application example of this application;
[0030] Figure 4 A schematic diagram of the architecture of the control system for the intelligent composite device provided as the first application example of this application;
[0031] Figure 5 A flowchart illustrating the device management method provided as a second application example of this application;
[0032] Figure 6 This is a schematic diagram of the structure of a device management apparatus provided in an embodiment of this application;
[0033] Figure 7 This is a schematic diagram of the structure of the second type of device management device provided in the embodiments of this application;
[0034] Figure 8 This is a schematic diagram illustrating the composition of an electronic device provided in an embodiment of this application. Detailed Implementation
[0035] To provide a more detailed understanding of the features and technical content of this invention, the implementation of this invention will be described in detail below with reference to the accompanying drawings. The accompanying drawings are for reference only and are not intended to limit this invention.
[0036] The technical solutions of the embodiments of this application will now be described with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of this application without creative effort are within the scope of protection of this application.
[0037] It should be noted that in the embodiments of this application, the term "and / or" is merely a description of the relationship between related objects, indicating that there can be three relationships. For example, A and / or B can represent three situations: A exists alone, A and B exist simultaneously, and B exists alone.
[0038] In the description of the embodiments of this application, the term "correspondence" may indicate that there is a direct or indirect correspondence between two things, or that there is an association between two things, or that there is a relationship of instruction and being instructed, configuration and being configured, etc.
[0039] To facilitate understanding of the technical solutions of the embodiments of this application, the relevant technologies of the embodiments of this application are described below. The following relevant technologies are optional solutions and can be combined with the technical solutions of the embodiments of this application in any way, and they all fall within the protection scope of the embodiments of this application.
[0040] With the rapid development of the Internet of Things (IoT) and smart home technologies, the functions of smart composite devices are becoming increasingly diverse. For example, smart composite door locks, in addition to basic attributes such as remote unlocking, log management, user management, and temporary passwords, also integrate the features of security cameras and smart doorbells. For these types of smart composite devices, the main approach is to develop new control templates for their management.
[0041] However, the method of developing new control templates has the following drawbacks:
[0042] First, the integration of intelligent composite devices with management templates is complex, requiring the redevelopment of binding and management templates for the intelligent composite devices. Furthermore, the development cycle for management templates is long; during this period, for example, for intelligent multi-door locks, a management template for the door lock attribute, which is a basic attribute, also needs to be developed, resulting in redundant development.
[0043] Secondly, the control templates for intelligent composite devices in related technologies are highly customizable. Newly developed control templates are only suitable for a specific type of intelligent composite device. For example, if the corresponding control template for a smart composite door lock is connected to a smart composite table lamp, the related technology cannot meet the aforementioned requirements. Furthermore, for instance, if one wants to switch the control template corresponding to the security camera attribute of a smart composite door lock to the control template corresponding to the smart doorbell attribute, the related technology also cannot meet this requirement.
[0044] To address the aforementioned shortcomings, this application provides a device management method that shortens the development cycle and reduces the development cost of control templates for intelligent composite devices. The application scenarios of this application are described below.
[0045] One application scenario of this application includes a server and a client. The server and client can communicate and collaborate to manage intelligent composite devices. In practical applications, the number of clients is not limited. The server can be a cloud server or a physical server. The client can be a physical device, such as a terminal device like a mobile phone, personal computer, or tablet. Alternatively, the client can be a software module, such as an application installed on the physical device.
[0046] The application scenarios of this application embodiment have been described above. The process of the server and client executing the device management method is described below in conjunction with the above application scenarios.
[0047] like Figure 1 As shown, Figure 1 This is a flowchart illustrating a device management method provided in an embodiment of this application. Figure 1 The device management method described herein, applied to a server, includes:
[0048] Step 101: Obtain the first information of the target manufacturer, wherein the first information is used to characterize the name identifier of the target manufacturer and the attributes of each of the multiple devices produced by the target manufacturer;
[0049] Step 102: Based on the first information of the target manufacturer, obtain an Extensible Markup Language (XML) file package corresponding to the target device; the target device refers to a device manufactured by the target manufacturer that has at least two attributes;
[0050] Step 103: Receive and respond to the client's request information, and send the XML file package to the client; the XML file package is used by the client to generate a control template corresponding to the target device.
[0051] Specifically, for the server to manage the target devices, it needs to generate control files corresponding to the target manufacturer. The server then manages the target devices from the target manufacturer based on the control files. The server can be associated with one or more target manufacturers. Control files for devices manufactured by different target manufacturers are typically not interchangeable. In step 101, the multiple devices manufactured by the target manufacturer can be smart locks, smart doorbells, and smart lamps, etc. Device attributes refer to the name or purpose of device attributes, such as smart locks, smart doorbells, and smart lamps.
[0052] In practical applications, step 101 can be executed by the server retrieving the target manufacturer's initial information from a database. Specifically, the server can pre-store the required initial information, or it can retrieve the corresponding initial information about the device manufacturer from an online database or the database of another device. Alternatively, step 101 can be executed based on user input to retrieve the target manufacturer's initial information.
[0053] In practical applications, step 102 can be executed by the server automatically generating an XML file package corresponding to the target device based on the target device's attributes and a pre-stored XML file template. Alternatively, step 102 can be executed by the server obtaining the target device's XML file package based on input from the target manufacturer's developers.
[0054] Based on this, in one embodiment, obtaining the XML file package corresponding to the target device based on the first information of the target manufacturer includes:
[0055] Based on the first information of the target manufacturer, obtain each of at least two attributes of the target device;
[0056] Based on each of at least two attributes of the target device, an instantiated data template corresponding to each of the at least two attributes of the target device is obtained;
[0057] Based on the instantiated data template corresponding to each of at least two attributes of the target device, the function jump entry of other attributes is configured in the dynamically configured function jump entry of the instantiated data template corresponding to the first attribute of the target device, and an XML file package corresponding to the target device is generated; the other attributes refer to the attributes of the target device other than the first attribute.
[0058] In practical applications, the first information of the target manufacturer includes the attributes of each device produced by the target manufacturer, that is, the attributes of the target device. Therefore, based on the first information of the target manufacturer, the attributes of the target device can be obtained. In this embodiment of the application, the target device refers to a smart composite device that has at least two different attributes, such as a smart composite door lock with smart door lock attributes and smart doorbell attributes. The smart door lock attribute, as a basic attribute of the smart composite door lock, can be defined as the first attribute of the smart composite door lock, and the smart doorbell attribute, as an additional attribute of the smart composite door lock, can be defined as the second attribute of the smart composite door lock.
[0059] In this embodiment, the XML file serves as a configuration file, used by the client to generate a control template corresponding to the target device. Therefore, it is necessary to instantiate the data template corresponding to each of at least two attributes of the target device. Typically, the data template is instantiated by setting attribute values for the nodes of the XML template as needed. The XML template can be an existing template or a template written by the developer as required.
[0060] Based on this, in one embodiment, obtaining the instantiated data template corresponding to each of the at least two attributes of the target device based on each of the at least two attributes of the target device includes:
[0061] Based on each of the at least two attributes of the target device, an abstract definition is made for each of the at least two attributes of the target device and the hierarchical structure of each of the at least two attributes, to obtain an abstract data template corresponding to each of the at least two attributes of the target device.
[0062] Based on the abstract data template corresponding to each of the at least two attributes of the target device, attribute values are set for the nodes of the abstract data template corresponding to each of the at least two attributes of the target device to obtain the instantiated data template corresponding to each of the at least two attributes of the target device.
[0063] In practical applications, taking a composite smart door lock as an example, the smart composite door lock possesses both smart door lock and smart doorbell attributes. The hierarchical structure of the smart door lock and smart doorbell corresponds to its hierarchical structure on the Internet of Things (IoT) platform. For example, a smart door lock typically has a three-layer structure on the IoT platform: a sensing layer, a transmission layer, and an application layer. The sensing layer corresponds to the composite smart door lock and the smartphone app (device and client), the transmission layer corresponds to the home gateway and base station, and the application layer corresponds to the IoT platform (server). Developers can abstractly define the hierarchical structure of each attribute of the target device to obtain an abstract data template matching the target device. Taking the abstract data template of the door lock attribute of a composite smart door lock as an example, its nodes not only need to be configured with the functions of the smart door lock in the IoT platform, such as fingerprint unlocking and password unlocking, but also need to be configured with the relevant platforms and protocols it interfaces with.
[0064] Furthermore, in practical applications, taking the setting of attribute values for the smart lock attribute node of a composite smart lock as an example: its propertyList node configures the security platform related functions, its deviceTemplate node configures the functional templates of the security platform in the composite smart device, such as doorbell template, camera template and speaker template, its settingTemplate node configures the relevant docking platform and protocol, and the lockControlParam node configures the physical network platform related functions.
[0065] After obtaining the instantiated data template corresponding to each of at least two attributes of the target device, the function jump entry of other attributes is configured in the dynamically configured function jump entry of the instantiated data template corresponding to the first attribute of the target device, thereby generating an XML file package corresponding to the target device.
[0066] The following section describes the process of the client executing device management methods in the above application scenarios.
[0067] like Figure 2 As shown, Figure 2 This is a flowchart illustrating a second device management method provided in an embodiment of this application. Figure 2 The device management method described herein, applied to a client, includes:
[0068] Step 201: Receive second information about the target device, the second information being used to characterize the target manufacturer that produces the target device and the attributes of the target device, the target device referring to a device produced by the target manufacturer that has at least two attributes;
[0069] Step 202: Based on the second information of the target device, send a request message to the server, the request message being used to request the server to obtain the XML file package corresponding to the target device;
[0070] Step 203: Receive the XML file package corresponding to the target device sent by the server;
[0071] Step 204: Parse the XML file package to obtain the parsing result;
[0072] Step 205: Based on the analysis results, generate a control template corresponding to the target device.
[0073] In practical applications, the client can execute step 201 by receiving the second information of the target device through an operation request from the target device. Specifically, the operation request from the target device can be a binding operation or a management operation performed by the user on the client.
[0074] After receiving the target manufacturer and attribute information of the target device, the client can request the corresponding XML file package from the server.
[0075] In order to generate a management template corresponding to the target device based on the XML file package corresponding to the target device, the client must parse the XML file package corresponding to the target device and generate the management template corresponding to the target device based on the parsing result. The client can use the Document Object Model (DOM) parsing method. Specifically, parsing the XML file package to obtain the parsing result includes:
[0076] Parse the XML file package to obtain the first attribute and other attributes of the target device, wherein the other attributes refer to the attributes of the target device other than the first attribute;
[0077] Based on the first attribute of the target device, obtain the dynamically configured function jump entry corresponding to the first attribute;
[0078] Based on the other attributes of the target device and the dynamically configured function jump entry corresponding to the first attribute, the function template entry of the other attributes of the target device is obtained.
[0079] In practical applications, generating a control template corresponding to the target device based on the parsing results includes:
[0080] Based on the parsing results, attribute templates in the client are dynamically combined to generate a control template corresponding to the target device; the attribute template refers to the developed control templates corresponding to multiple devices produced by the target manufacturer.
[0081] This application provides a device management method, comprising: a server acquiring first information about a target manufacturer, the first information representing the name identifier of the target manufacturer and the attributes of each of a plurality of devices produced by the target manufacturer; the server obtaining an Extensible Markup Language (XML) file package corresponding to the target device based on the first information about the target manufacturer; the target device referring to a device produced by the target manufacturer that has at least two attributes; a client receiving second information about the target device, the second information representing the target manufacturer that produces the target device and the attributes of the target device; the client sending a request to the server based on the second information about the target device, the request request requesting the server to obtain the XML file package corresponding to the target device; the server receiving and responding to the client's request, sending the XML file package to the client; the client receiving the XML file package corresponding to the target device sent by the server; the client parsing the XML file package to obtain a parsing result; and the client generating a control template corresponding to the target device based on the parsing result. The device management method provided in this application enables the client to automatically generate a control template for the target device through an XML file package configured on the server, shortening the development cycle and reducing the development cost of the control template for the target device.
[0082] The following description, using specific application examples, further illustrates this application:
[0083] like Figure 3 As shown, Figure 3 A flowchart illustrating a device management method provided as a first application example of this application. The device management method includes:
[0084] Step 301: The server obtains the target vendor's initial information; specifically:
[0085] The first information includes the name and identifier of the target manufacturer, and the attributes of each of the multiple devices produced by the target manufacturer. In this application example, the devices produced by the target manufacturer include smart locks, smart doorbells, security cameras, and smart desk lamps, each with corresponding attributes for the lock, doorbell, camera, and desk lamp. Corresponding attribute templates have been developed for each of these devices. For example, door lock management templates, doorbell management templates, camera management templates, and desk lamp management templates.
[0086] Step 302: Based on the first information of the target manufacturer, the server obtains the XML file package corresponding to the target device, specifically:
[0087] The target device possesses at least two attributes and is a smart composite device. For example... Figure 4 As shown, Figure 4A schematic diagram of the architecture of the control system for the intelligent composite device provided as the first application example of this application. Figure 4 The intelligent composite device includes a power module (not shown), a wireless communication module, an intelligent communication module, and an intelligent security module. The wireless communication module can employ one or more combinations of ZigBee, Bluetooth, LoRa, and WiFi modules. This wireless communication module interacts with the physical network platform. The intelligent communication module interacts with the intelligent calling platform to enable voice and / or video calls. The intelligent security module interacts with the security platform to enable image transmission, anomaly alarms, and camera parameter settings. The physical network platform, intelligent calling platform, and security platform interact with the server through a client (an example of a smart terminal APP is used in the figure). In practical applications, the intelligent calling platform and security platform are often referred to together with the IoT platform as the IoT platform.
[0088] Taking the target device as an example of a smart composite door lock, the smart composite door lock has door lock attributes and doorbell attributes. The door lock attribute is defined as the first attribute as a basic attribute of the composite smart door lock, and the doorbell attribute is defined as the second attribute (or other attributes) as an additional attribute of the composite smart door lock.
[0089] The configuration of XML files in some key XML file packages is as follows:
[0090] <controltype> 14< / controltype>
[0091] <propertylist>
[0092] <property>
[0093] <name> deviceTemplate< / name>
[0094] <value> doorbellTemplate< / value>
[0095] < / property>
[0096] <property>
[0097] <name> settingTemplate< / name>
[0098] <value> sdSetting< / value>
[0099] < / property>
[0100] < / propertylist>
[0101] <lockcontrolparam>< / lockcontrolparam>
[0102] <lightinglampcontrolparameter>< / lightinglampcontrolparameter>
[0103] Among them, the controlType node is configured with the first attribute data template of the composite smart door lock;
[0104] The `propertyList` node configures the relevant functions of the security platform for the smart lock; the `deviceTemplate` node in its attribute list configures the relevant functions of the security platform for the smart lock, and its value represents the second attribute of the smart lock. The `settingTemplate` configures the relevant platforms and protocols for the smart lock to interface with.
[0105] The lockControlParam and LightingLampControlParameter nodes configure the relevant functions of the IoT platform, such as attributes of door locks, table lamps, etc., and their corresponding hierarchical structure.
[0106] Step 303: The client receives the second information from the target device;
[0107] Specifically: The second information is used to characterize the target manufacturer that produces the target device and the attributes of the target device; taking the target device as a smart composite door lock as an example, the door lock attribute is defined as the first attribute as the basic attribute of the composite smart door lock, and the doorbell attribute is defined as the second attribute as the additional attribute of the composite smart door lock.
[0108] Step 304: Based on the second information of the target device, the client sends a request to the server, the request being used to request the server to obtain the Extensible Markup Language (XML) file package corresponding to the target device;
[0109] Step 305: The server receives and responds to the client's request information, and sends the XML file package to the client;
[0110] Step 306: The client receives the XML file package corresponding to the target device sent by the server;
[0111] Step 307: The client parses the XML file package to obtain the parsing result; specifically:
[0112] Parse the XML file package to obtain the first attribute and other attributes of the target device. The other attributes refer to the attributes of the target device other than the first attribute. For example, by parsing the attribute value of the controlType node in the XML file package, the first attribute of the smart composite door lock is obtained as the door lock attribute. Parse the attribute value of the deviceTemplate node in the propertyList node to obtain the second attribute of the smart composite device as the doorbell attribute.
[0113] Based on the first attribute of the target device, obtain the dynamically configured function jump entry corresponding to the first attribute;
[0114] Based on the other attributes of the target device and the dynamically configured function jump entry corresponding to the first attribute, the function template entry of the other attributes of the target device is obtained.
[0115] Step 308: Based on the parsing result, the client generates a management template corresponding to the target device; specifically:
[0116] Based on the parsing results, the client dynamically navigates to the function template entry based on the other attributes of the target device, and the other attributes.
[0117] Compared with related technologies, the device management method provided in this application example has the following advantages:
[0118] First, the device management method provided in this application example allows the client to dynamically parse and combine the control template of the target device by obtaining the XML file package configured on the server. This eliminates the need to redevelop the corresponding control template based on the target device, shortening the development cycle and reducing development costs.
[0119] Second, the device management method provided in this application example enables the server to determine the attributes of the target device based on the target manufacturer's first information, and then dynamically configure the XML file package for the target device, thereby realizing the function of dynamically changing the intelligent composite device control template and solving the problem of highly customized control templates.
[0120] The following is a further description of this application with specific application examples:
[0121] like Figure 5 As shown, Figure 5 A flowchart illustrating a device management method provided as a second application example of this application. The device management method includes:
[0122] Step 501: Based on the target manufacturer's initial information, the developers configure the XML file package for the target device;
[0123] The first information includes the name identifier of the target manufacturer, and the attributes of each of the multiple devices manufactured by the target manufacturer; wherein, for example... Figure 5 As shown in the second application example of this application, the devices manufactured by the target manufacturer include smart door locks, smart doorbells, security cameras, and smart desk lamps, etc., each with corresponding attributes for door locks, doorbells, cameras, and desk lamps, and corresponding attribute templates have been developed for each of these devices. For example, door lock control templates, doorbell control templates, camera control templates, and desk lamp control templates.
[0124] Step 502: The server obtains the XML file package corresponding to the target device based on the developer's upload operation;
[0125] Among them, such as Figure 5 As shown, in the second application example of this application, the server is a cloud server.
[0126] Step 503: The client obtains the XML file package corresponding to the target device from the server through request information;
[0127] Among them, such as Figure 5As shown, in the second application example of this application, the client uses a smart terminal, on which a mobile APP is installed, and the smart terminal stores door lock control templates, doorbell control templates, camera control templates, and desk lamp control templates. The target device can be multiple, such as a first smart composite device with door lock and doorbell attributes, or a second smart composite device with camera and desk lamp attributes.
[0128] Step 504: The client parses the XML file package and, based on the parsing results, combines existing management templates to dynamically form a management template for the target device.
[0129] Among them, such as Figure 5 As shown, for a first intelligent composite device with door lock and doorbell attributes, the client dynamically combines existing door lock control templates and doorbell control templates based on the parsing results to dynamically form the control template for the first intelligent composite device. For a second intelligent composite device with camera and desk lamp attributes, the client dynamically combines existing camera control templates and desk lamp control templates based on the parsing results to dynamically form the control template for the second intelligent composite device.
[0130] To implement the device management method for servers provided in the embodiments of this application, the embodiments of this application also provide a device management apparatus for servers. For example... Figure 6 As shown, Figure 6 This is a schematic diagram of a device management apparatus provided in an embodiment of this application. The device management apparatus 600 includes:
[0131] The acquisition module 601 is used to acquire first information of the target manufacturer, wherein the first information is used to characterize the name identifier of the target manufacturer and the attributes of each of the multiple devices produced by the target manufacturer;
[0132] The first generation module 602 is used to obtain an Extensible Markup Language (XML) file package corresponding to the target device based on the first information corresponding to the target manufacturer; the target device refers to a device manufactured by the target manufacturer that has at least two attributes;
[0133] The first sending module 603 is used to receive and respond to the client's request information and send the XML file package to the client; the XML file package is used by the client to generate a control template corresponding to the target device.
[0134] In practical applications, the first generation module 602 is specifically used to obtain each of at least two attributes of the target device based on the first information of the target manufacturer.
[0135] Based on each of at least two attributes of the target device, an instantiated data template corresponding to each of the at least two attributes of the target device is obtained;
[0136] Based on the instantiated data template corresponding to each of at least two attributes of the target device, the function jump entry of other attributes is configured in the dynamically configured function jump entry of the instantiated data template corresponding to the first attribute of the target device, and an XML file package corresponding to the target device is generated; the other attributes refer to the attributes of the target device other than the first attribute.
[0137] In practical applications, the first generation module 602 is also specifically used to abstractly define each of the at least two attributes of the target device and the hierarchical structure of each of the at least two attributes based on each of the at least two attributes of the target device, so as to obtain an abstract data template corresponding to each of the at least two attributes of the target device.
[0138] Based on the abstract data template corresponding to each of the at least two attributes of the target device, attribute values are set for the nodes of the abstract data template corresponding to each of the at least two attributes of the target device to obtain the instantiated data template corresponding to each of the at least two attributes of the target device.
[0139] To implement the device management method for a client provided in the embodiments of this application, the embodiments of this application also provide a device management apparatus for a client. For example... Figure 7 As shown, Figure 7 This is a schematic diagram of the structure of a second type of device management device provided in an embodiment of this application. The device management device 700 includes:
[0140] The first receiving module 701 is used to receive second information of the target device, the second information being used to characterize the target manufacturer that produces the target device and the attributes of the target device, the target device referring to a device produced by the target manufacturer that has at least two attributes;
[0141] The second sending module 702 is used to send request information to the server based on the second information of the target device. The request information is used to request the server to obtain the Extensible Markup Language (XML) file package corresponding to the target device.
[0142] The second receiving module 703 is used to receive the XML file package corresponding to the target device sent by the server;
[0143] Parsing module 704 is used to parse the XML file package and obtain the parsing result;
[0144] The second generation module 705 is used to generate a control template corresponding to the target device based on the parsing results.
[0145] In practical applications, the parsing module 704 is specifically used to parse the XML file package to obtain the first attribute and other attributes of the target device, wherein the other attributes refer to the attributes of the target device other than the first attribute;
[0146] Based on the first attribute of the target device, obtain the dynamically configured function jump entry corresponding to the first attribute;
[0147] Based on the other attributes of the target device and the dynamically configured function jump entry corresponding to the first attribute, the function template entry of the other attributes of the target device is obtained.
[0148] In practical applications, the second generation module 705 is specifically used to dynamically combine the attribute templates in the client based on the parsing results to generate a control template corresponding to the target device; the attribute template refers to the developed control templates corresponding to multiple devices produced by the target manufacturer.
[0149] Those skilled in the art should understand that Figure 6 The aforementioned equipment management device 600 and Figure 7 The functions of each unit in the second type of equipment management device 700 shown can be understood by referring to the relevant description of the aforementioned equipment management method. Figure 6 The aforementioned equipment management device 600 and Figure 7 The functions of each unit in the second type of device management device 700 shown can be implemented by a program running on a processor or by specific logic circuits.
[0150] It should be noted that the device management device 600 and the second device management device 700 provided in the above embodiments are only illustrated by the division of the above-described program units when performing device management. In actual applications, the above processing can be assigned to different program units as needed, that is, the internal structure of the system can be divided into different program units to complete all or part of the processing described above. In addition, the device management device 600 and the second device management device 700 provided in the above embodiments belong to the same concept as the device management method embodiments, and their specific implementation process can be found in the method embodiments, which will not be repeated here.
[0151] Based on the hardware implementation of the above-described program units, and in order to implement the device management method provided in the embodiments of this application, the embodiments of this application also provide an electronic device, such as... Figure 8 As shown, Figure 8A schematic diagram illustrating the composition of an electronic device provided in an embodiment of this application; the electronic device 800 includes:
[0152] The processor 801 and the memory 802 are provided. The memory 802 stores a computer program. The processor 801 is used to call and run the computer program stored in the memory 802 to perform the steps of the device management method as described in the embodiments of this application.
[0153] In practical applications, such as Figure 7 As shown, the various components in the electronic device 800 are coupled together via a bus module 803. It is understood that the bus module 803 is used to implement communication between these components. In addition to a data bus, the bus module 803 also includes a power bus, a control bus, and a status signal bus. However, for clarity, in... Figure 7 The general labels all buses as bus module 703.
[0154] This application also provides a computer-readable storage medium storing executable instructions, which, when executed by a processor, implement the steps of the device management method provided in this application.
[0155] In some embodiments, the storage medium may be a magnetic random access memory (FRAM), a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), a flash memory, a magnetic surface memory, an optical disc, or a compact disc read-only memory (CD-ROM), etc.; or it may be a device that includes one or any combination of the above-mentioned memories.
[0156] In some embodiments, executable instructions may take the form of a program, software, software module, script, or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a standalone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.
[0157] As an example, executable instructions may, but do not necessarily, correspond to files in the file system. They may be stored as part of a file that holds other programs or data, for example, in one or more scripts in a Hyper Text Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple collaborative files (e.g., files that store one or more modules, subroutines, or code sections).
[0158] As an example, executable instructions can be deployed to execute on a single computing device, or on multiple computing devices located in one location, or on multiple computing devices distributed across multiple locations and interconnected via a communication network.
[0159] It should be noted that terms such as "first" and "second" are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.
[0160] The technical solutions described in the embodiments of this application can be combined arbitrarily without conflict.
[0161] In the several embodiments provided in this application, it should be understood that the disclosed methods and electronic devices can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods, such as: multiple units or components may be combined, or integrated into another system, or some features may be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the various components shown or discussed may be through some interfaces, and the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.
[0162] The units described above as separate components may or may not be physically separate. The components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of the units may be selected to achieve the purpose of this embodiment according to actual needs.
[0163] In addition, each functional unit in the various embodiments of this application can be integrated into a second processing unit, or each unit can be a separate unit, or two or more units can be integrated into a unit; the integrated unit can be implemented in hardware or in the form of hardware plus software functional units.
[0164] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.
Claims
1. A device management method applied to a server, characterized in that, include: Obtain first information about the target manufacturer, wherein the first information is used to characterize the name identifier of the target manufacturer and the attributes of each of the multiple devices produced by the target manufacturer; Based on the first information of the target manufacturer, an Extensible Markup Language (XML) file package corresponding to the target device is obtained; the target device refers to an intelligent composite device with at least two attributes manufactured by the target manufacturer. The at least two attributes include at least two of the following: door lock attributes, doorbell attributes, camera attributes, and table lamp attributes; The system receives and responds to client requests, and sends the XML file package to the client. The XML file package is used by the client to dynamically combine attribute templates in the client to generate a control template corresponding to the target device. The attribute templates refer to the developed control templates corresponding to multiple devices produced by the target manufacturer. The multiple devices include multiple smart door locks, smart doorbells, security cameras, and smart desk lamps. The step of obtaining an XML file package corresponding to the target device based on the first information of the target manufacturer includes: Based on the first information of the target manufacturer, obtain each of at least two attributes of the target device; Based on each of at least two attributes of the target device, an instantiated data template corresponding to each of the at least two attributes of the target device is obtained; Based on the instantiated data template corresponding to each of at least two attributes of the target device, the function jump entry of other attributes is configured in the dynamically configured function jump entry of the instantiated data template corresponding to the first attribute of the target device, and an XML file package corresponding to the target device is generated; the other attributes refer to the attributes of the target device other than the first attribute.
2. The method according to claim 1, characterized in that, The step of obtaining an instantiated data template corresponding to each of the at least two attributes of the target device, based on each of the at least two attributes of the target device, includes: Based on each of the at least two attributes of the target device, an abstract definition is made for each of the at least two attributes of the target device and the hierarchical structure of each of the at least two attributes, to obtain an abstract data template corresponding to each of the at least two attributes of the target device. Based on the abstract data template corresponding to each of the at least two attributes of the target device, attribute values are set for the nodes of the abstract data template corresponding to each of the at least two attributes of the target device to obtain the instantiated data template corresponding to each of the at least two attributes of the target device.
3. A device management method applied to a client, characterized in that, include: Receive second information about the target device, the second information being used to characterize the target manufacturer that produces the target device and the attributes of the target device, the target device referring to an intelligent composite device with at least two attributes produced by the target manufacturer; The at least two attributes include at least two of the following: door lock attributes, doorbell attributes, camera attributes, and table lamp attributes; Based on the second information of the target device, a request message is sent to the server, the request message being used to request the server to obtain the Extensible Markup Language (XML) file package corresponding to the target device; Receive the XML file package corresponding to the target device sent by the server; The XML file package is parsed to obtain the parsing results; Based on the analysis results, a control template corresponding to the target device is generated; wherein, generating the control template corresponding to the target device based on the analysis results includes: dynamically combining attribute templates in the client based on the analysis results to generate a control template corresponding to the target device; the attribute templates refer to the developed control templates corresponding to multiple devices produced by the target manufacturer; the multiple devices include multiple smart door locks, smart doorbells, security cameras, and smart desk lamps; The parsing of the XML file package to obtain the parsing result includes: Parse the XML file package to obtain the first attribute and other attributes of the target device, wherein the other attributes refer to the attributes of the target device other than the first attribute; Based on the first attribute of the target device, obtain the dynamically configured function jump entry corresponding to the first attribute; Based on the other attributes of the target device and the dynamically configured function jump entry corresponding to the first attribute, the function template entry of the other attributes of the target device is obtained.
4. A device management apparatus, applied to a server, characterized in that, include: The acquisition module is used to acquire first information about the target manufacturer, wherein the first information is used to characterize the name identifier of the target manufacturer and the attributes of each of the multiple devices produced by the target manufacturer; The first generation module is used to obtain an Extensible Markup Language (XML) file package corresponding to the target device based on the first information corresponding to the target manufacturer; the target device refers to an intelligent composite device with at least two attributes produced by the target manufacturer. The at least two attributes include at least two of the following: door lock attribute, doorbell attribute, camera attribute, and desk lamp attribute; wherein, obtaining the XML file package corresponding to the target device based on the first information of the target manufacturer includes: obtaining each of the at least two attributes of the target device based on the first information of the target manufacturer; obtaining an instantiated data template corresponding to each of the at least two attributes of the target device based on each of the at least two attributes of the target device; configuring function jump entries for other attributes in the dynamically configured function jump entry of the instantiated data template corresponding to the first attribute of the target device based on the instantiated data template corresponding to each of the at least two attributes of the target device, and generating an XML file package corresponding to the target device; the other attributes refer to the attributes of the target device other than the first attribute; The first sending module is used to receive and respond to the client's request information and send the XML file package to the client; the XML file package is used by the client to dynamically combine the attribute templates in the client to generate a control template corresponding to the target device, the attribute templates refer to the developed control templates corresponding to multiple devices produced by the target manufacturer; the multiple devices include multiple smart door locks, smart doorbells, security cameras and smart desk lamps.
5. A device management apparatus, applied to a client, characterized in that, include: The first receiving module is used to receive second information of the target device, the second information being used to characterize the target manufacturer that produces the target device and the attributes of the target device, the target device referring to an intelligent composite device with at least two attributes produced by the target manufacturer; The at least two attributes include at least two of the following: door lock attributes, doorbell attributes, camera attributes, and table lamp attributes; The second sending module is used to send request information to the server based on the second information of the target device. The request information is used to request the server to obtain the Extensible Markup Language (XML) file package corresponding to the target device. The second receiving module is used to receive the XML file package corresponding to the target device sent by the server; A parsing module is used to parse the XML file package to obtain a parsing result; wherein, parsing the XML file package to obtain a parsing result includes: parsing the XML file package to obtain a first attribute and other attributes of the target device, wherein the other attributes refer to attributes of the target device other than the first attribute; based on the first attribute of the target device, obtaining a dynamically configured function jump entry corresponding to the first attribute; and based on the other attributes of the target device and the dynamically configured function jump entry corresponding to the first attribute, obtaining a function template entry for the other attributes of the target device. The second generation module is used to generate a control template corresponding to the target device based on the parsing result; wherein, generating the control template corresponding to the target device based on the parsing result includes: dynamically combining attribute templates in the client based on the parsing result to generate a control template corresponding to the target device; the attribute templates refer to the developed control templates corresponding to multiple devices produced by the target manufacturer; the multiple devices include multiple smart door locks, smart doorbells, security cameras, and smart desk lamps.
6. An electronic device, characterized in that, It includes a processor and a memory for storing computer programs, the processor for calling and running the computer programs stored in the memory to perform the steps of the device management method as described in claim 1 or 2, or the steps of the device management method as described in claim 3.
7. A computer-readable storage medium storing executable instructions, characterized in that, When the executable instructions are executed by the processor, they implement the steps of the device management method as described in claim 1 or 2, or the steps of the device management method as described in claim 3.