Disclosure of Invention
The invention provides a device and a method for updating a list view and a computer readable storage medium, and mainly aims to update the interface effect of the list view under the condition that a new version of a client is not released.
To achieve the above object, the present invention provides an apparatus for updating a list view in an IOS system, the apparatus including a memory and a processor, the memory storing a list view updating program operable on the processor, the list view updating program when executed by the processor implementing the steps of:
when a view updating instruction is received, acquiring a data model corresponding to the view updating instruction, and acquiring class name fields of a cell class and a section class from the data model;
searching a cell class and a section class corresponding to the class name field from a pre-established set of the cell class and a pre-established set of the section class, wherein the cell class realizes a pre-defined cell protocol, the section realizes the pre-defined section protocol, the cell protocol comprises a cell interface in a data source protocol of UITableView and a cell interface in a proxy protocol of the UITableView, and the section protocol comprises the section interface in the data source protocol and the section interface in the proxy protocol;
and updating the list view according to the data model and the cell class and the section class corresponding to the class name field.
Optionally, a cell class and a section class created based on the UITableView are received, where the cell class implements a predefined cell protocol and the section class implements a predefined section protocol;
acquiring a preset general class of a data source and a preset general class of an agent, wherein the general class of the data source comprises an initial two-dimensional array of a cell data model and an initial one-dimensional array of a section data model;
initializing the cell class and the section class, and assigning the universal class of the data source and the universal class object of the agent to the data source and the agent of the UITableView;
and adding the created cell classes and the created section classes to the collection of the cell classes and the collection of the section classes respectively.
Optionally, the step of updating the list view according to the data model and the cell class and the section class corresponding to the class name field includes:
assembling the data model to obtain a two-dimensional array of the cell data model and a one-dimensional array of the section data model;
and assigning the obtained two-dimensional array of the cell data model and the one-dimensional array of the section data model to the general class of the data source so as to update the list view according to the cell class and the section class corresponding to the class name field.
Optionally, the cell interface includes a cell data source, a location corresponding to the cell, and a list view object; the section interface comprises a section data source, a position corresponding to the section and a list view object.
Optionally, the number of the one-dimensional arrays of the section data model represents the number of sections, the number of the two-dimensional arrays of the cell data model represents the number of sections, and the number of the one-dimensional arrays in each two-dimensional array is equal to the number of cells under the section corresponding to the two-dimensional array.
In addition, to achieve the above object, the present invention further provides a method for dynamically updating a list view in an IOS system, where the method includes:
when a view updating instruction is received, acquiring a data model corresponding to the view updating instruction, and acquiring class name fields of a cell class and a section class from the data model;
searching a cell class and a section class corresponding to the class name field from a pre-established set of the cell class and a pre-established set of the section class, wherein the cell class realizes a pre-defined cell protocol, the section realizes the pre-defined section protocol, the cell protocol comprises a cell interface in a data source protocol of UITableView and a cell interface in a proxy protocol of the UITableView, and the section protocol comprises the section interface in the data source protocol and the section interface in the proxy protocol;
and updating the list view according to the data model and the cell class and the section class corresponding to the class name field.
Optionally, the method further comprises:
receiving a cell class and a section class created based on the UITableView, wherein the cell class realizes a predefined cell protocol, and the section class realizes the predefined section protocol;
acquiring a preset general class of a data source and a preset general class of an agent, wherein the general class of the data source comprises an initial two-dimensional array of a cell data model and an initial one-dimensional array of a section data model;
initializing the cell class and the section class, and assigning the universal class of the data source and the universal class object of the agent to the data source and the agent of the UITableView;
and adding the created cell classes and the created section classes to the collection of the cell classes and the collection of the section classes respectively.
Optionally, the step of updating the list view according to the data model and the cell class and the section class corresponding to the class name field includes:
assembling the data model to obtain a two-dimensional array of the cell data model and a one-dimensional array of the section data model;
and assigning the obtained two-dimensional array of the cell data model and the one-dimensional array of the section data model to the general class of the data source so as to update the list view according to the cell class and the section class corresponding to the class name field.
Optionally, the cell interface includes a cell data source, a location corresponding to the cell, and a list view object; the section interface comprises a section data source, a position corresponding to the section and a list view object.
In addition, to achieve the above object, the present invention also provides a computer-readable storage medium having a list view update program stored thereon, where the list view update program is executable by at least one processor to implement the steps of the method for dynamically updating a list view in an IOS system as described above.
The device, the method and the computer readable storage medium for updating the list view provided by the invention are characterized in that a set of cell classes and a set of section classes are created in advance, a predefined cell protocol can be realized for the cell classes in the sets, the cell protocol comprises a cell interface in a data source protocol of UITableView and a cell interface in a proxy protocol of UITableView, the section protocol comprises a section interface in the data source protocol and a section interface in the proxy protocol, the interfaces of a data source and a proxy of UITableView are realized in each cell class and section class in the sets, when a view updating instruction is received, a data model corresponding to the view updating instruction is obtained, class name fields of the cell classes and the section classes are obtained from the data model, the cell classes and the section classes corresponding to the class name fields are searched from the sets, and the list view is updated according to the data model and the cell classes and the section classes corresponding to the searched class, the dynamic updating of the interface effect of the list view can be realized without reissuing a new version of the client.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The invention provides a device for updating a list view in an IOS system. Referring to fig. 1, a schematic diagram of an apparatus for updating a list view in an IOS system according to a preferred embodiment of the present invention is shown.
In this embodiment, the device for updating the list view in the IOS system may be a PC (Personal Computer), or may be a terminal device having a display function, such as a smart phone, a tablet Computer, or a portable Computer.
The updating device of the list view in the IOS system comprises a memory 11, a processor 12, a communication bus 13 and a network interface 14.
The memory 11 includes at least one type of readable storage medium, which includes a flash memory, a hard disk, a multimedia card, a card type memory (e.g., SD or DX memory, etc.), a magnetic memory, a magnetic disk, an optical disk, and the like. The memory 11 may in some embodiments be an internal storage unit of the updating means of the list view in the IOS system, for example a hard disk of the updating means of the list view in the IOS system. The memory 11 may also be an external storage device of the update apparatus of the list view in the IOS system in other embodiments, such as a plug-in hard disk provided on the update apparatus of the list view in the IOS system, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like. Further, the memory 11 may also include both an internal storage unit of the update apparatus of the list view in the IOS system and an external storage device. The memory 11 may be used not only to store application software of a device for updating a list view installed in the IOS system and various kinds of data, such as a code of a list view update program, etc., but also to temporarily store data that has been output or will be output.
The processor 12 may be, in some embodiments, a Central Processing Unit (CPU), controller, microcontroller, microprocessor or other data Processing chip for executing program codes stored in the memory 11 or Processing data, such as executing a list view update program.
The communication bus 13 is used to realize connection communication between these components.
The network interface 14 may optionally include a standard wired interface, a wireless interface (e.g., WI-FI interface), typically used to establish a communication link between the apparatus and other electronic devices.
FIG. 1 shows only the means for updating the list view in an IOS system having components 11-14 and a list view update program, but it is to be understood that not all of the shown components are required and that more or fewer components may alternatively be implemented.
Optionally, the device may further comprise a user interface, which may comprise a Display (Display), an input unit such as a Keyboard (Keyboard), and optionally a standard wired interface, a wireless interface. Alternatively, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, or the like. The display, which may also be referred to as a display screen or display unit, is used to display information processed in the updating means of the list view in the IOS system and to display a visualized user interface, among other things.
In the embodiment of the apparatus shown in fig. 1, the memory 11 stores therein a list view update program; the processor 12, when executing the list view update program stored in the memory 11, implements the following steps:
when a view updating instruction is received, acquiring a data model corresponding to the view updating instruction, and acquiring class name fields of a cell class and a section class from the data model;
searching a cell class and a section class corresponding to the class name field from a pre-established set of the cell class and a pre-established set of the section class, wherein the cell class realizes a pre-defined cell protocol, the section realizes the pre-defined section protocol, the cell protocol comprises a cell interface in a data source protocol of UITableView and a cell interface in a proxy protocol of the UITableView, and the section protocol comprises the section interface in the data source protocol and the section interface in the proxy protocol;
and updating the list view according to the data model and the cell class and the section class corresponding to the class name field.
The embodiment provides a scheme for realizing the update of the list view in the client without releasing a new client version in the IOS system. In this embodiment, in order to simplify the logical judgment in the list view and implement dynamic update of the list view, a developer defines a cell protocol and a section protocol in advance when developing software, and the cell protocol and the section protocol are used as a predefined cell protocol and a predefined section protocol to be implemented by a subsequently created cell class and a section class.
In this embodiment, a cell protocol is predefined, and includes defining all new interfaces related to a cell in a data source (data) and a proxy (delete) of a list view, where the new interfaces include a cell data source, a location corresponding to the cell, and a list view object; all cell classes implement the protocol. Predefining a section protocol, including defining a data source of a list view and all new interfaces related to the section in an agent, wherein the new interfaces comprise a section data source, a position corresponding to the section and a tableview object; all sections implement the protocol.
A common class (CommonDataSource) of data sources of the UITableView is pre-established. The CommonDataSource contains an initial two-dimensional array of a cell data model and an initial one-dimensional array of a section data model, and can realize all interfaces of a data source protocol of UITableView. The number of the one-dimensional arrays of the section data model represents the number of sections, the number of the two-dimensional arrays of the cell data model represents the number of sections, and the number of the one-dimensional arrays in each two-dimensional array is equal to the number of cells under the section corresponding to the two-dimensional array.
A common class (CommonDelegate) of the UITableView's proxy is pre-established, which is capable of implementing all interfaces of the UITableView's proxy protocol.
And the user creates a new cell class and a section class according to the required cell style and section style, and the created cell class and section class realize the predefined cell protocol and section protocol.
According to the method, a user can create cell classes and section classes capable of realizing different cell styles and section styles according to needs and add the cell classes and the section classes to a preset set of cell classes and a preset set of section classes.
Optionally, in an embodiment, the method further includes the following steps:
receiving a cell class and a section class created based on the UITableView, wherein the cell class realizes a predefined cell protocol, and the section class realizes the predefined section protocol;
acquiring a preset general class of a data source and a preset general class of an agent, wherein the general class of the data source comprises an initial two-dimensional array of a cell data model and an initial one-dimensional array of a section data model;
initializing the cell class and the section class, and assigning the universal class of the data source and the universal class object of the agent to the data source and the agent of the UITableView;
and adding the created cell classes and the created section classes to the collection of the cell classes and the collection of the section classes respectively.
The user creates a new cell class and a section class, inherits UITableView, correspondingly assigns common DataSource and common Delegate objects to a data source and a proxy of the UITableView in the initialization of the cell class and the section class, and names each created cell class and section class.
If a user needs to create a new list view, a data model of the list view to be created is obtained, the data model is assembled, a two-dimensional array of the data model of the cell and a one-dimensional array of the section data model are obtained, a proper cell class and a section class are selected from the set according to the cell style and the section style to be displayed, the data model and a class name field of the selected class are bound, the two-dimensional array of the data model of the cell and the one-dimensional array of the section data model are respectively and correspondingly assigned to an initial two-dimensional array and an initial one-dimensional array in the established general class of the data source, the creation of the list view is achieved, and the created list view is the achieved style of the cell class and the section class corresponding to the class name field in the data model.
The method for realizing the cell-related interface in the data source protocol of the UITableView comprises the following steps: the data model of the corresponding cell can be obtained through the two-dimensional array of the cell data model, the corresponding cell class is found through the class name field contained in the data model or the cell object is found through the tablevew object and the indexpath (index path), and then the predefined cell protocol is called. The manner of implementing the section-related interface in the data source protocol of UITableView is as follows: and acquiring a corresponding section data model through the one-dimensional array of the section data model, finding a corresponding section class through a class name field in the data model, and calling a predefined section protocol. In this way, the data source and agent interface of the UITableView is implemented in each cell class and section class in the set. The container containing the list does not need to realize a specific implementation method, so that the problem that a plurality of logic judgments are written in one interface implementation method to process different sections and cells does not occur, and the list view can be updated without releasing a version.
Regarding the manner of implementing the interface related to the cell and the interface related to the section in the proxy protocol of the UITableView, the manner is the same as the manner of implementing the interface related to the cell and the interface related to the section in the data source protocol of the UITableView, and details are not repeated herein.
In this embodiment, if a user wants to modify the style of the list view, if there is no required cell class and section class in the set, it is only necessary to create a new cell class and section class according to the required view style and store the new cell class and section class in the set of cell classes and section class, and remove the originally bound class name field in the data model, bind the newly created class name field of cell class and section class to the data model, and trigger a view update instruction. Or, if the set has the required cell class and section class, only the required cell class and section class are selected, and the class name field is updated and bound to the data model, so as to trigger the view updating instruction.
The device obtains a data model corresponding to a view updating instruction when receiving the view updating instruction, obtains a bound class name field from the data model, searches a cell class and a section corresponding to the class name field from a pre-created set of cell classes and a pre-created set of section classes, and updates a list view according to the data model and the cell class and the section class corresponding to the class name field.
As an embodiment, the step of updating the list view according to the data model and the cell class and the section class corresponding to the class name field includes:
assembling the data model to obtain a two-dimensional array of the cell data model and a one-dimensional array of the section data model;
and assigning the obtained two-dimensional array of the cell data model and the one-dimensional array of the section data model to the general class of the data source so as to update the list view according to the cell class and the section class corresponding to the class name field.
Since the common DataSource and common Delegate objects are correspondingly assigned to the data source and the agent of UITableView in the initialization of the cell class and the section class in the set, the two-dimensional array of the acquired cell data model and the one-dimensional array of the section data model are assigned to the general class of the data source during updating.
The updating device of the list view, which is provided by the invention, is pre-established with a set of cell classes and a set of section classes, the cell classes in the sets can realize a predefined cell protocol, the cell protocol comprises a cell interface in a data source protocol of UITableView, and a cell interface in a proxy protocol of the UITableView, wherein the section protocol comprises a section interface in the data source protocol and a section interface in the proxy protocol, the interfaces of the data source and the proxy of the UITableView are realized in each cell class and section class in the set, when a view updating instruction is received, acquiring a data model corresponding to the view updating instruction, acquiring class name fields of a cell class and a section class from the data model, searching the cell class and the section class corresponding to the class name fields from the set, and updating the list view according to the data model and the found cell class and section class, and dynamically updating the interface effect of the list view without re-releasing the client of the new version.
Alternatively, in other embodiments, the list view update program may be divided into one or more modules, and one or more modules are stored in the memory 11 and executed by one or more processors (in this embodiment, the processor 12) to implement the present invention.
Referring to fig. 2, which is a schematic diagram illustrating functional modules of a list view update program in an embodiment of the device for updating a list view according to the present invention, the list view update program may be divided into an obtaining module 10, a searching module 20, and an updating module 30, where:
the acquisition module 10 is configured to: when a view updating instruction is received, acquiring a data model corresponding to the view updating instruction, and acquiring class name fields of a cell class and a section class from the data model;
the lookup module 20 is configured to: searching a cell class and a section class corresponding to the class name field from a pre-established set of the cell class and a pre-established set of the section class, wherein the cell class realizes a pre-defined cell protocol, the section realizes the pre-defined section protocol, the cell protocol comprises a cell interface in a data source protocol of UITableView and a cell interface in a proxy protocol of the UITableView, and the section protocol comprises the section interface in the data source protocol and the section interface in the proxy protocol;
the update module 30 is configured to: and updating the list view according to the data model and the cell class and the section class corresponding to the class name field.
In addition, the invention also provides a method for dynamically updating the list view in the IOS system. Referring to fig. 3, a flowchart of a first embodiment of a method for dynamically updating a list view in an IOS system according to the present invention is shown. The method may be performed by an apparatus, which may be implemented by software and/or hardware.
In this embodiment, the method for dynamically updating a list view in an IOS system includes:
step S10, when a view updating instruction is received, acquiring a data model corresponding to the view updating instruction, and acquiring the class name fields of the cell class and the section class from the data model;
step S20, searching a cell class and a section class corresponding to the class name field from a pre-created set of cell classes and a pre-created set of section classes, wherein the cell class realizes a pre-defined cell protocol, the section realizes a pre-defined section protocol, the cell protocol comprises a cell interface in a data source protocol of UITableView and a cell interface in a proxy protocol of UITableView, and the section protocol comprises a section interface in the data source protocol and a section interface in the proxy protocol;
and step S30, updating the list view according to the data model and the cell class and the section class corresponding to the class name field.
The embodiment provides a scheme for realizing the update of the list view in the client without releasing a new client version in the IOS system. In this embodiment, in order to simplify the logical judgment in the list view and implement dynamic update of the list view, a developer defines a cell protocol and a section protocol in advance when developing software, and the cell protocol and the section protocol are used as a predefined cell protocol and a predefined section protocol to be implemented by a subsequently created cell class and a section class.
In this embodiment, a cell protocol is predefined, and includes defining all new interfaces related to a cell in a data source (data) and a proxy (delete) of a list view, where the new interfaces include a cell data source, a location corresponding to the cell, and a list view object; all cell classes implement the protocol. Predefining a section protocol, including defining a data source of a list view and all new interfaces related to the section in an agent, wherein the new interfaces comprise a section data source, a position corresponding to the section and a tableview object; all sections implement the protocol.
A common class (CommonDataSource) of data sources of the UITableView is pre-established. The CommonDataSource contains an initial two-dimensional array of a cell data model and an initial one-dimensional array of a section data model, and can realize all interfaces of a data source protocol of UITableView. The number of the one-dimensional arrays of the section data model represents the number of sections, the number of the two-dimensional arrays of the cell data model represents the number of sections, and the number of the one-dimensional arrays in each two-dimensional array is equal to the number of cells under the section corresponding to the two-dimensional array.
A common class (CommonDelegate) of the UITableView's proxy is pre-established, which is capable of implementing all interfaces of the UITableView's proxy protocol.
And the user creates a new cell class and a section class according to the required cell style and section style, and the created cell class and section class realize the predefined cell protocol and section protocol.
According to the method, a user can create cell classes and section classes capable of realizing different cell styles and section styles according to needs and add the cell classes and the section classes to a preset set of cell classes and a preset set of section classes.
Optionally, in an embodiment, the processor 12 is further configured to execute the list view updating program to implement the following steps:
receiving a cell class and a section class created based on the UITableView, wherein the cell class realizes a predefined cell protocol, and the section class realizes the predefined section protocol;
acquiring a preset general class of a data source and a preset general class of an agent, wherein the general class of the data source comprises an initial two-dimensional array of a cell data model and an initial one-dimensional array of a section data model;
initializing the cell class and the section class, and assigning the universal class of the data source and the universal class object of the agent to the data source and the agent of the UITableView;
and adding the created cell classes and the created section classes to the collection of the cell classes and the collection of the section classes respectively.
The user creates a new cell class and a section class, inherits UITableView, correspondingly assigns common DataSource and common Delegate objects to a data source and a proxy of the UITableView in the initialization of the cell class and the section class, and names each created cell class and section class.
If a user needs to create a new list view, a data model of the list view to be created is obtained, the data model is assembled, a two-dimensional array of the data model of the cell and a one-dimensional array of the section data model are obtained, a proper cell class and a section class are selected from the set according to the cell style and the section style to be displayed, the data model and a class name field of the selected class are bound, the two-dimensional array of the data model of the cell and the one-dimensional array of the section data model are respectively and correspondingly assigned to an initial two-dimensional array and an initial one-dimensional array in the established general class of the data source, the creation of the list view is achieved, and the created list view is the achieved style of the cell class and the section class corresponding to the class name field in the data model.
The method for realizing the cell-related interface in the data source protocol of the UITableView comprises the following steps: the data model of the corresponding cell can be obtained through the two-dimensional array of the cell data model, the corresponding cell class is found through the class name field contained in the data model or the cell object is found through the tablevew object and the indexpath (index path), and then the predefined cell protocol is called. The manner of implementing the section-related interface in the data source protocol of UITableView is as follows: and acquiring a corresponding section data model through the one-dimensional array of the section data model, finding a corresponding section class through a class name field in the data model, and calling a predefined section protocol. In this way, the data source and agent interface of the UITableView is implemented in each cell class and section class in the set. The container containing the list does not need to realize a specific implementation method, so that the problem that a plurality of logic judgments are written in one interface implementation method to process different sections and cells does not occur, and the list view can be updated without releasing a version.
Regarding the manner of implementing the interface related to the cell and the interface related to the section in the proxy protocol of the UITableView, the manner is the same as the manner of implementing the interface related to the cell and the interface related to the section in the data source protocol of the UITableView, and details are not repeated herein.
In this embodiment, if a user wants to modify the style of the list view, if there is no required cell class and section class in the set, it is only necessary to create a new cell class and section class according to the required view style and store the new cell class and section class in the set of cell classes and section class, and remove the originally bound class name field in the data model, bind the newly created class name field of cell class and section class to the data model, and trigger a view update instruction. Or, if the set has the required cell class and section class, only the required cell class and section class are selected, and the class name field is updated and bound to the data model, so as to trigger the view updating instruction.
The method comprises the steps that when a view updating instruction is received by a server, a data model corresponding to the view updating instruction is obtained, a bound class name field is obtained from the data model, a cell class and a section corresponding to the class name field are searched from a pre-established set of cell classes and a set of the section class, and a list view is updated according to the data model and the cell class and the section class corresponding to the class name field.
As an embodiment, the step of updating the list view according to the data model and the cell class and the section class corresponding to the class name field includes:
assembling the data model to obtain a two-dimensional array of the cell data model and a one-dimensional array of the section data model;
and assigning the obtained two-dimensional array of the cell data model and the one-dimensional array of the section data model to the general class of the data source so as to update the list view according to the cell class and the section class corresponding to the class name field.
Since the common DataSource and common Delegate objects are correspondingly assigned to the data source and the agent of UITableView in the initialization of the cell class and the section class in the set, the two-dimensional array of the acquired cell data model and the one-dimensional array of the section data model are assigned to the general class of the data source during updating.
The updating method of the list view, which is provided by the invention, is characterized in that a set of cell classes and a set of section classes are created in advance, the cell classes in the sets can realize a predefined cell protocol, the cell protocol comprises a cell interface in a data source protocol of UITableView, and a cell interface in a proxy protocol of the UITableView, wherein the section protocol comprises a section interface in the data source protocol and a section interface in the proxy protocol, the interfaces of the data source and the proxy of the UITableView are realized in each cell class and section class in the set, when a view updating instruction is received, acquiring a data model corresponding to the view updating instruction, acquiring class name fields of a cell class and a section class from the data model, searching the cell class and the section class corresponding to the class name fields from the set, and updating the list view according to the data model and the found cell class and section class, and dynamically updating the interface effect of the list view without re-releasing the client of the new version.
Furthermore, an embodiment of the present invention further provides a computer-readable storage medium, where a list view update program is stored on the computer-readable storage medium, where the list view update program is executable by at least one processor to implement the following operations:
when a view updating instruction is received, acquiring a data model corresponding to the view updating instruction, and acquiring class name fields of a cell class and a section class from the data model;
searching a cell class and a section class corresponding to the class name field from a pre-established set of the cell class and a pre-established set of the section class, wherein the cell class realizes a pre-defined cell protocol, the section realizes the pre-defined section protocol, the cell protocol comprises a cell interface in a data source protocol of UITableView and a cell interface in a proxy protocol of the UITableView, and the section protocol comprises the section interface in the data source protocol and the section interface in the proxy protocol;
and updating the list view according to the data model and the cell class and the section class corresponding to the class name field.
Further, the list view update program when executed by the processor further performs the following operations:
receiving a cell class and a section class created based on the UITableView, wherein the cell class realizes a predefined cell protocol, and the section class realizes the predefined section protocol;
acquiring a preset general class of a data source and a preset general class of an agent, wherein the general class of the data source comprises an initial two-dimensional array of a cell data model and an initial one-dimensional array of a section data model;
initializing the cell class and the section class, and assigning the universal class of the data source and the universal class object of the agent to the data source and the agent of the UITableView;
and adding the created cell classes and the created section classes to the collection of the cell classes and the collection of the section classes respectively.
Further, the list view update program when executed by the processor further performs the following operations:
assembling the data model to obtain a two-dimensional array of the cell data model and a one-dimensional array of the section data model;
and assigning the obtained two-dimensional array of the cell data model and the one-dimensional array of the section data model to the general class of the data source so as to update the list view according to the cell class and the section class corresponding to the class name field.
It should be noted that the above-mentioned numbers of the embodiments of the present invention are merely for description, and do not represent the merits of the embodiments. And the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, apparatus, article, or method that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, apparatus, article, or method. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, apparatus, article, or method that includes the element.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) as described above and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.