CN110968315B - Element data structure changing method and device, storage medium and processor - Google Patents

Element data structure changing method and device, storage medium and processor Download PDF

Info

Publication number
CN110968315B
CN110968315B CN201811163432.9A CN201811163432A CN110968315B CN 110968315 B CN110968315 B CN 110968315B CN 201811163432 A CN201811163432 A CN 201811163432A CN 110968315 B CN110968315 B CN 110968315B
Authority
CN
China
Prior art keywords
combination
data structure
elements
combination type
type element
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201811163432.9A
Other languages
Chinese (zh)
Other versions
CN110968315A (en
Inventor
许桂鑫
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Gridsum Technology Co Ltd
Original Assignee
Beijing Gridsum Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Gridsum Technology Co Ltd filed Critical Beijing Gridsum Technology Co Ltd
Priority to CN201811163432.9A priority Critical patent/CN110968315B/en
Publication of CN110968315A publication Critical patent/CN110968315A/en
Application granted granted Critical
Publication of CN110968315B publication Critical patent/CN110968315B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/38Creation or generation of source code for implementing user interfaces

Abstract

The embodiment of the invention provides a method and a device for changing an element data structure, a storage medium and a processor, wherein the method comprises the following steps: integrating the elements participating in the combination to obtain a combination type element, wherein the combination type element comprises at least two common type elements; storing the combination type elements into a designated array according to a first data structure; when the state of the combination type element is monitored to be changed, the first data structure of the combination type element is changed in a designated array, wherein the states of all common type elements contained in the combination type element are changed at the same time. The problems of troublesome operation and high cost caused by the fact that the dom elements in the HTML interface are required to be adjusted one by one through the bottom code in the related art are solved.

Description

Element data structure changing method and device, storage medium and processor
Technical Field
The present invention relates to the field of computer programming, and in particular, to a method and apparatus for changing an element data structure, a storage medium, and a processor.
Background
The hypertext markup language (Hyper Text Markup Language, abbreviated as HTML) interface is the result of rendering a document object model (Document Object Model, abbreviated as DOM) node tree. FIG. 1 is a schematic diagram of a data structure of a DOM node tree in the related art, as shown in FIG. 1, by programming we can control the position and style of each DOM node (e.g. html, body, a).
The style implementation needs to be modified or the interface HTML structure needs to be changed one by one, each adjustment needs to be realized by means of modified codes, and the cost is high and the operation is inconvenient.
Aiming at the problems of troublesome operation and high cost caused by the fact that the modification of dom elements in an HTML interface needs to be adjusted one by one through underlying codes in the related art, no reasonable solution exists at present.
Disclosure of Invention
The embodiment of the invention provides a target control channel locking method and device, a base station, a storage medium and a processor, which at least solve the problems of troublesome operation and high cost caused by the fact that the DOM elements in an HTML interface are required to be adjusted one by one through a bottom code in the related art.
According to an embodiment of the present invention, there is provided a modification method of an element data structure, including: integrating the elements participating in the combination to obtain a combination type element, wherein the combination type element comprises at least two common type elements; storing the combination type elements into a designated array according to a first data structure; when the state of the combination type element is monitored to be changed, the first data structure of the combination type element is changed in the appointed array, wherein the states of all the common type elements contained in the combination type element are changed at the same time.
Preferably, the integrating the elements participating in the combination to obtain a combination type element includes one of the following: combining at least two common type elements participating in combination to obtain a first combination type element: combining at least two first combination type elements participating in combination to obtain a second combination type element; and combining at least one common type element and at least one first combination type element which participate in combination to obtain a third combination type element.
Preferably, altering the first data structure of the combination type element in the specified array comprises: and in the process of changing the state of the combination type element, changing the first data structure of the combination type element for a plurality of times according to a preset period.
Preferably, after integrating the elements participating in the combination to obtain the combination type element, the method further includes: and storing all common type elements contained in the combined type elements into the appointed array according to a second data structure.
Preferably, after altering the first data structure of the combination type element in the specified array, the method further comprises: and updating the second data structures of all common type elements contained in the combined type elements according to the changed first data structures of the combined type elements.
Preferably, before storing the combination type element in the specified array according to the first data structure, the method further comprises: defining the first data structure, wherein the first data structure comprises: the common style data comprises element types, element identities, element names, a set of common type elements contained in a combination, common style data of the common type elements contained in the combination, and common position data of the common type elements contained in the combination; before storing all the common type elements contained in the combined type element in the specified array according to the second data structure, the method further includes: defining the second data structure, wherein the second data structure comprises: element type, element identity, element name, style data for the element, location data for the element.
Preferably, the changing the state of the combination type element includes: the state of at least one of the combination type elements changes: coordinate position, color, size, font style.
According to another embodiment of the present invention, there is also provided an apparatus for modifying an element data structure, including: the integration module is used for integrating the elements participating in the combination to obtain a combination type element, wherein the combination type element comprises at least two common type elements; the first storage module is used for storing the combination type elements into a designated array according to a first data structure; and the changing module is used for changing the first data structure of the combination type element in the appointed array when the state of the combination type element is monitored to be changed, wherein the states of all the common type elements contained in the combination type element are changed at the same time.
According to another embodiment of the present invention, there is also provided a storage medium storing a program for implementing the modification method of the element data structure of any one of the above method embodiments when the program is executed.
According to another embodiment of the present invention, there is also provided a processor for executing a program, wherein the program is executed to execute: the method for modifying an element data structure according to any one of the above method embodiments.
According to the embodiment of the invention, the elements participating in the combination are integrated to obtain the combination type element, wherein the combination type element comprises at least two common type elements; storing the combination type elements into a designated array according to a first data structure; when the state of the combination type element is monitored to be changed, the first data structure of the combination type element is changed in the appointed array, wherein the states of all common type elements contained in the combination type element are changed simultaneously, the problem that in the related technology, the dom elements are required to be adjusted one by one through bottom codes when being modified in an HTML interface, the operation is troublesome and the cost is high is solved, different elements can be grouped together at the front end for unified operation, the operation is simple, the cost is saved, and the user experience is improved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiments of the invention and together with the description serve to explain the invention and do not constitute a limitation on the invention. In the drawings:
FIG. 1 is a schematic diagram of a data structure of a DOM node tree in the related art;
FIG. 2 is a block diagram of a hardware architecture of a mobile terminal according to a modification method of an element data structure according to an embodiment of the present invention;
FIG. 3 is a flow chart of a method of modifying an element data structure in an embodiment of the invention;
FIG. 4 is a schematic diagram of the status of a combination type element in a display interface according to an embodiment of the present invention;
fig. 5 is a block diagram of a modification apparatus of an element data structure according to an embodiment of the present invention.
Detailed Description
The invention will be described in detail hereinafter with reference to the drawings in conjunction with embodiments. It should be noted that, in the case of no conflict, the embodiments and features in the embodiments may be combined with each other.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present invention and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order.
Example 1
The method embodiment provided in the first embodiment of the present application may be executed in a mobile terminal, a computer terminal or a similar computing device. Taking the mobile terminal as an example, fig. 2 is a block diagram of a hardware structure of the mobile terminal according to an embodiment of the present invention. As shown in fig. 2, the mobile terminal 10 may include one or more (only one is shown in fig. 2) processors 102 (the processor 102 may include, but is not limited to, a microprocessor MCU or a processing device such as a programmable logic device FPGA) and a memory 104 for storing data, and optionally a transmission device 106 for communication functions and an input-output device 108. It will be appreciated by those skilled in the art that the structure shown in fig. 1 is merely illustrative and not limiting of the structure of the mobile terminal described above. For example, the mobile terminal 10 may also include more or fewer components than shown in FIG. 2 or have a different configuration than shown in FIG. 1.
The memory 104 may be used to store a computer program, for example, a software program of application software and a module, such as a computer program corresponding to a method for obtaining a scheduled throughput in an embodiment of the present invention, and the processor 102 executes the computer program stored in the memory 104, thereby performing various functional applications and data processing, that is, implementing the above-mentioned method. Memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include memory located remotely from the processor 102, which may be connected to the mobile terminal 10 via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission means 106 is arranged to receive or transmit data via a network. The specific examples of networks described above may include wireless networks provided by the communication provider of the mobile terminal 10. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, simply referred to as NIC) that can connect to other network devices through a base station to communicate with the internet. In one example, the transmission device 106 may be a Radio Frequency (RF) module, which is used to communicate with the internet wirelessly.
The embodiment of the invention provides a method for changing an element data structure. FIG. 3 is a flowchart of a method for modifying an element data structure according to an embodiment of the present invention, as shown in FIG. 3, the method includes:
step S301, integrating elements participating in combination to obtain a combination type element, wherein the combination type element comprises at least two common type elements;
step S303, storing the combination type element into a designated array according to a first data structure;
in step S305, when it is detected that the state of the combination type element is changed, the first data structure of the combination type element is changed in the specified array, wherein the states of all the normal type elements included in the combination type element are changed at the same time.
Through the method, the elements participating in the combination are integrated to obtain the combination type element, wherein the combination type element comprises at least two common type elements; storing the combination type elements into a designated array according to a first data structure; when the state of the combination type element is monitored to be changed, the first data structure of the combination type element is changed in the appointed array, wherein the states of all common type elements contained in the combination type element are changed simultaneously, the problem that in the related technology, the dom elements are required to be adjusted one by one through bottom codes when being modified in an HTML interface, the operation is troublesome and the cost is high is solved, different elements can be grouped together at the front end for unified operation, the operation is simple, the cost is saved, and the user experience is improved.
It should be noted that, an array herein may be understood as a predefined set of data structures, and common type elements and combined type elements are stored in a specified array according to the predefined data structures, respectively, where the elements stored in the array may implement simultaneous modification of states of multiple elements on the front-end interface.
The common type elements are understood to be single dom elements, and the elements participating in the combination at least comprise two common type elements, and after the common type elements are combined to obtain the combined type elements, the elements can further participate in the combination, that is, the combined type elements involved in the embodiment of the invention can be a combination of a single element and a single element, a combination of a single element and a combined element, or a combination of a combined element and a combined element.
According to a preferred implementation of the embodiment of the present invention, the above step S301 may be implemented by: combining at least two common type elements participating in the combination to obtain a first combination type element: combining at least two first combination type elements participating in combination to obtain a second combination type element; and combining at least one common type element and at least one first combination type element which participate in the combination to obtain a third combination type element.
According to a preferred implementation of the embodiment of the present invention, the above step S305 may be implemented by: in the process of changing the state of the combination type element, the first data structure of the combination type element is changed for a plurality of times according to a preset period.
It should be noted that, after step S305, that is, when the state of the combination type element is monitored to be changed, the first data structure of the combination type element is changed in the specified array, and the changed state may be rendered on the interface.
According to a preferred implementation of the embodiment of the present invention, after step S301, the method further includes: all common type elements contained in the combined type elements are stored in a specified array according to a second data structure.
According to a preferred implementation of the embodiment of the present invention, after step S305, the method further includes: and updating the second data structures of all the common type elements contained in the combined type elements according to the first data structures of the changed combined type elements.
According to a preferred implementation of the embodiment of the present invention, before storing all the common type elements included in the combined type element in the specified array according to the second data structure, the method further includes: defining a second data structure, wherein the second data structure comprises: element type, element identity, element name, style data for the element, location data for the element.
By way of example, the second data structure of the generic type element may be defined in terms of the structure shown below:
wherein, the type represents an element type, which may include text, picture, music, voice, button, etc., the ID is used to uniquely identify the element, the name is an element name, the style represents a style of the element, which includes various element styles related in HTML interfaces such as color, font, shadow setting, icon size, etc., and the tips represents a position of the element on the display interface, which is indicated by two values left and top in this embodiment, where left may represent a distance between a left edge of the element and a left boundary of the display interface, and top may represent a distance between an upper edge of the element and an upper boundary of the display interface.
The method further includes, prior to storing the combination type element in the specified array according to the first data structure: defining a first data structure, wherein the first data structure comprises: element type, element identity, element name, collection of common type elements contained within a combination, common style data of common type elements contained within a combination, common location data of common type elements contained within a combination.
By way of example, the first data structure of the combined type element may be defined in terms of the structure shown below:
note that, here, the type may indicate whether the element is a combination type element, and if the element is a combination type element, the type value may be set to group. The first data structure has one more group of group list settings than the second data structure, where the group list is used to store the names or IDs of all common type elements contained in the combined type element.
According to a preferred implementation of the embodiment of the present invention, the status of the combination type element includes at least one of: coordinate position, color, size, font style.
In order to better understand the modification method of the element data structure provided by the embodiment of the present invention, the following description will take the example of changing the position state of the element of the combination type.
Fig. 4 is a schematic diagram of a state of a combination type element in a display interface according to an embodiment of the present invention, as shown in fig. 4, by combining two common type elements, namely, a "title" input box element and an "OK" key element, to form a combination type element a, for example, by clicking on a combination between trigger elements, for example, by clicking on the "title" first with a mouse, then pressing a custom function key (for example, ctrl), and clicking on the "OK" again, where both elements have been selected, and they will constitute a new element, namely, a combination type element a. At this time, the "title" element, the "OK" key element and the combination type element a need to be stored in the designated array, respectively, where the "title" element, the "OK" key element are stored according to the second data structure, and the combination type element a is stored according to the first data structure. It should be noted that, the data structure of the combined type element may show the height and width of the combined element a, and the specific calculation mode is as follows:
after the title element and the OK key element are selected, a combination type element can be automatically generated by default, a confirmation box can be popped up to confirm whether the two elements are combined together, when the two elements are determined to be combined together, a new combination type element A is the whole, and in the combination state, any element (whether the title element or the OK key element) is selected by default, and the combination type element A is selected. When the combination state is released, the "title" element and the "OK" key element are restored to the independent normal type elements.
When the movement of the combination type element A from the upper area to the lower area of the display interface is monitored, position data in the first data structure of the combination type element A can be changed after the movement of the combination type element A is stopped, then the interface is rendered after the data is changed, and the combination type element A with the changed position is displayed. And the position data in the first data structure of the combination type element A can be changed every t time, for example, 0.1s according to a preset period t in the process of stopping movement of the combination type element A, and the display interface is rendered after each change, so that the movement track of the combination type element A can be displayed on the interface.
When the first data structure of the combination type element a is changed, the data structures of the two common type elements "title" and "OK" contained in the a can be updated according to the changed data structure of the a, so that the two common type elements "title" and "OK" can be maintained in the changed state when the combination operation is exited.
In the embodiment of the invention, the position of the DOM nodes which are combined and the color of the DOM nodes can be adjusted at will in the webpage experience, and the mode is not required to be modified one by one or the HTML structure of the webpage is not required to be changed. The front-end technology is used for grouping and uniformly controlling the positions and the common patterns of elements such as pictures, input boxes, buttons and the like in the webpage, so that the user experience is enhanced.
Example 2
In this embodiment, a device for modifying an element data structure is further provided, and the device is used to implement the foregoing embodiments and preferred embodiments, and is not described in detail. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. While the means described in the following embodiments are preferably implemented in software, implementation in hardware, or a combination of software and hardware, is also possible and contemplated.
FIG. 5 is a block diagram of an apparatus for modifying an element data structure according to an embodiment of the present invention, as shown in FIG. 4, the apparatus comprising:
the integration module 50 is configured to integrate elements participating in the combination to obtain a combination type element, where the combination type element includes at least two common type elements;
a first storage module 52, configured to store the combination type element into a specified array according to a first data structure;
and a changing module 54, configured to change the first data structure of the combination type element in the specified array when it is detected that the state of the combination type element changes, where the states of all the common type elements included in the combination type element change simultaneously.
By the above means, the integration module 50 integrates the elements participating in the combination to obtain a combination type element, where the combination type element includes at least two common type elements; the first storage module 52 stores the combination type elements in a specified array according to a first data structure; when the state of the combination type element is monitored to be changed, the changing module 54 designates a first data structure for changing the combination type element in the array, wherein the states of all common type elements contained in the combination type element are changed simultaneously, the problem that in the related art, the DOM elements need to be adjusted one by one through the bottom code in the HTML interface is solved, the operation is troublesome and the cost is high is caused, different elements can be grouped together at the front end for unified operation, the operation is simple, the cost is saved, and the user experience is improved.
According to a preferred implementation of the embodiment of the present invention, the integration module is further configured to: combining at least two common type elements participating in the combination to obtain a first combination type element: combining at least two first combination type elements participating in combination to obtain a second combination type element; and combining at least one common type element and at least one first combination type element which participate in the combination to obtain a third combination type element.
According to a preferred implementation of the embodiment of the present invention, the modification module is further configured to: in the process of changing the state of the combination type element, the first data structure of the combination type element is changed for a plurality of times according to a preset period.
According to a preferred implementation of the embodiment of the present invention, the above device further comprises: and the second storage module is used for storing all the common type elements contained in the combined type elements into the appointed array according to the second data structure.
According to a preferred implementation of the embodiment of the present invention, the above device further comprises: and the updating module is used for updating the second data structures of all the common type elements contained in the combined type elements according to the changed first data structures of the combined type elements.
According to a preferred implementation of the embodiment of the present invention, the above device further comprises: a first defining module for defining a first data structure, wherein the first data structure comprises: the common style data comprises element types, element identities, element names, a set of common type elements contained in a combination, common style data of the common type elements contained in the combination, and common position data of the common type elements contained in the combination; a second definition module for defining a second data structure, wherein the second data structure comprises: element type, element identity, element name, style data for the element, location data for the element.
According to a preferred implementation of the embodiment of the present invention, the changing of the state of the combination type element includes: the state of at least one of the combination type elements changes: coordinate position, color, size, font style.
The modifying means of the element data structure includes a processor and a memory, the integrating module 50, the first storing module 52, the modifying module 54, etc. are stored in the memory as program units, and the processor executes the program units stored in the memory to implement the corresponding functions.
The processor includes a kernel, and the kernel fetches the corresponding program unit from the memory. The kernel can be provided with one or more than one kernel, and the problems of troublesome operation and high cost caused by the fact that the modification of the dom elements in the HTML interface in the related art needs to be adjusted one by one through the bottom code are solved by adjusting the kernel parameters.
The memory may include volatile memory, random Access Memory (RAM) and/or nonvolatile memory, such as Read Only Memory (ROM) or flash memory (flashRAM), among other forms in computer readable media, the memory including at least one memory chip.
The embodiment of the invention provides a storage medium, on which a program is stored, which when executed by a processor implements a method of modifying the element data structure.
The embodiment of the invention provides a processor which is used for running a program, wherein the program runs to execute a method for changing an element data structure.
The embodiment of the invention provides equipment, which comprises a processor, a memory and a program stored in the memory and capable of running on the processor, wherein the processor realizes the following steps when executing the program: (method claim step, independent + dependent). The device herein may be a server, PC, PAD, cell phone, etc.
The present application also provides a computer program product adapted to perform, when executed on a data processing device, a program initialized with the method steps of:
integrating the elements participating in the combination to obtain a combination type element, wherein the combination type element comprises at least two common type elements; storing the combination type elements into a designated array according to a first data structure; when the state of the combination type element is monitored to be changed, the first data structure of the combination type element is changed in the appointed array, wherein the states of all the common type elements contained in the combination type element are changed at the same time.
Preferably, when executed on a data processing device, is adapted to carry out a program initialized with the following method steps:
combining at least two common type elements participating in combination to obtain a first combination type element: combining at least two first combination type elements participating in combination to obtain a second combination type element; and combining at least one common type element and at least one first combination type element which participate in combination to obtain a third combination type element.
Preferably, when executed on a data processing device, is adapted to carry out a program initialized with the following method steps:
and in the process of changing the state of the combination type element, changing the first data structure of the combination type element for a plurality of times according to a preset period.
Preferably, when executed on a data processing device, is adapted to carry out a program initialized with the following method steps:
and storing all common type elements contained in the combined type elements into the appointed array according to a second data structure.
Preferably, when executed on a data processing device, is adapted to carry out a program initialized with the following method steps:
and updating the second data structures of all common type elements contained in the combined type elements according to the changed first data structures of the combined type elements.
Preferably, when executed on a data processing device, is adapted to carry out a program initialized with the following method steps:
defining the first data structure, wherein the first data structure comprises: the common style data comprises element types, element identities, element names, a set of common type elements contained in a combination, common style data of the common type elements contained in the combination, and common position data of the common type elements contained in the combination; before storing all the common type elements contained in the combined type element in the specified array according to the second data structure, the method further includes: defining the second data structure, wherein the second data structure comprises: element type, element identity, element name, style data for the element, location data for the element.
Preferably, when executed on a data processing device, is adapted to carry out a program initialized with the following method steps:
the state of at least one of the combination type elements changes: coordinate position, color, size, font style.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In one typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include volatile memory in a computer-readable medium, random Access Memory (RAM) and/or nonvolatile memory, etc., such as Read Only Memory (ROM) or flash memory (flashRAM). Memory is an example of a computer-readable medium.
Computer readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of storage media for a computer include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium, which can be used to store information that can be accessed by a computing device. Computer-readable media, as defined herein, does not include transitory computer-readable media (transmission media), such as modulated data signals and carrier waves.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus 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, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article or apparatus that comprises an element.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The foregoing is merely exemplary of the present application and is not intended to limit the present application. Various modifications and changes may be made to the present application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc. which are within the spirit and principles of the present application are intended to be included within the scope of the claims of the present application.

Claims (7)

1. A method of modifying an element data structure, comprising:
integrating the elements participating in the combination to obtain a combination type element, wherein the combination type element comprises at least two common type elements, and the common type elements are dom elements;
after integrating the elements participating in the combination to obtain a combination type element, the method further comprises: storing all common type elements contained in the combined type elements into a designated array according to a second data structure;
storing the combination type element into the specified array according to a first data structure;
when the state of the combination type element is monitored to be changed, changing the first data structure of the combination type element in the appointed array, wherein the states of all the common type elements contained in the combination type element are changed at the same time;
wherein altering the first data structure of the combination type element in the specified array comprises: in the process of changing the state of the combination type element, changing the first data structure of the combination type element for a plurality of times according to a preset period;
after altering the first data structure of the combination type element in the specified array, the method further comprises: and updating the second data structures of all common type elements contained in the combined type elements according to the changed first data structures of the combined type elements.
2. The method of claim 1, wherein integrating the elements participating in the combination to obtain a combination type element comprises one of:
combining at least two common type elements participating in combination to obtain a first combination type element:
combining at least two first combination type elements participating in combination to obtain a second combination type element;
and combining at least one common type element and at least one first combination type element which participate in combination to obtain a third combination type element.
3. The method of claim 1, wherein the step of determining the position of the substrate comprises,
before storing the combination type element in the specified array according to the first data structure, the method further includes:
defining the first data structure, wherein the first data structure comprises: the common style data comprises element types, element identities, element names, a set of common type elements contained in a combination, common style data of the common type elements contained in the combination, and common position data of the common type elements contained in the combination;
before storing all the common type elements contained in the combined type element in the specified array according to the second data structure, the method further includes:
defining the second data structure, wherein the second data structure comprises: element type, element identity, element name, style data for the element, location data for the element.
4. A method according to any one of claims 1 to 3, wherein the changing of the state of the combination type element comprises:
the state of at least one of the combination type elements changes:
coordinate position, color, size, font style.
5. An apparatus for modifying an element data structure, comprising:
the integration module is used for integrating the elements participating in the combination to obtain a combination type element, wherein the combination type element comprises at least two common type elements, and the common type elements are dom elements;
after integrating the elements participating in the combination to obtain the combination type element, the method further comprises the following steps: storing all common type elements contained in the combined type elements into a designated array according to a second data structure;
the first storage module is used for storing the combination type elements into the appointed array according to a first data structure;
a changing module, configured to change, when it is detected that the state of the combination type element changes, the first data structure of the combination type element in the specified array, where the states of all the common type elements included in the combination type element change at the same time;
wherein altering the first data structure of the combination type element in the specified array comprises: in the process of changing the state of the combination type element, changing the first data structure of the combination type element for a plurality of times according to a preset period;
after altering the first data structure of the combination type element in the specified array, further comprising: and updating the second data structures of all common type elements contained in the combined type elements according to the changed first data structures of the combined type elements.
6. A storage medium storing a program which, when executed, is adapted to carry out the method of modifying an element data structure according to any one of claims 1 to 4.
7. A processor configured to execute a program, wherein the program is configured to, when executed, perform: a method of modifying an element data structure as claimed in any one of claims 1 to 4.
CN201811163432.9A 2018-09-30 2018-09-30 Element data structure changing method and device, storage medium and processor Active CN110968315B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811163432.9A CN110968315B (en) 2018-09-30 2018-09-30 Element data structure changing method and device, storage medium and processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811163432.9A CN110968315B (en) 2018-09-30 2018-09-30 Element data structure changing method and device, storage medium and processor

Publications (2)

Publication Number Publication Date
CN110968315A CN110968315A (en) 2020-04-07
CN110968315B true CN110968315B (en) 2023-12-26

Family

ID=70029386

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811163432.9A Active CN110968315B (en) 2018-09-30 2018-09-30 Element data structure changing method and device, storage medium and processor

Country Status (1)

Country Link
CN (1) CN110968315B (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101071375A (en) * 2007-05-22 2007-11-14 腾讯科技(深圳)有限公司 Interface development system and control combing method
CN101571800A (en) * 2008-04-29 2009-11-04 中兴通讯股份有限公司 Method and device for processing activex relation in control interface
CN102243573A (en) * 2011-07-27 2011-11-16 北京风灵创景科技有限公司 Method and device for managing element attribute in application program
CN102446100A (en) * 2010-12-14 2012-05-09 微软公司 Type and length abstraction for data types
CN104395881A (en) * 2012-06-01 2015-03-04 谷歌有限公司 Representation and conversion of dynamically-typed arrays
CN105549888A (en) * 2015-12-15 2016-05-04 芜湖美智空调设备有限公司 Combined control generation method and device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9696974B2 (en) * 2013-03-13 2017-07-04 Microsoft Technology Licensing, Llc. Graph-based model for type systems

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101071375A (en) * 2007-05-22 2007-11-14 腾讯科技(深圳)有限公司 Interface development system and control combing method
CN101571800A (en) * 2008-04-29 2009-11-04 中兴通讯股份有限公司 Method and device for processing activex relation in control interface
CN102446100A (en) * 2010-12-14 2012-05-09 微软公司 Type and length abstraction for data types
CN102243573A (en) * 2011-07-27 2011-11-16 北京风灵创景科技有限公司 Method and device for managing element attribute in application program
CN104395881A (en) * 2012-06-01 2015-03-04 谷歌有限公司 Representation and conversion of dynamically-typed arrays
CN105549888A (en) * 2015-12-15 2016-05-04 芜湖美智空调设备有限公司 Combined control generation method and device

Also Published As

Publication number Publication date
CN110968315A (en) 2020-04-07

Similar Documents

Publication Publication Date Title
US9158534B2 (en) Smart endpoint architecture
CN110110174B (en) Data visualization page generation, monitoring and display method, browser and server
CN111104635B (en) Method and device for generating form webpage
CN109725901A (en) Development approach, device, equipment and the computer storage medium of front-end code
CN106250104B (en) A kind of remote operating system for server, method and device
CN106487553A (en) The processing method of VNF example, device and VNFM
CN108810646A (en) Group information pushes control method, device and computer readable storage medium
CN112162915A (en) Test data generation method, device, equipment and storage medium
CN110941428B (en) Website creation method and device
US10712731B2 (en) Control device, control method, and non-transitory computer-readable recording medium
CN111026494A (en) Business process processing method, device and equipment
CN109426415B (en) Method and device for generating cascade selector
CN107241385B (en) Internet of things data acquisition system and method
CN111007733B (en) Method and device for integrating smart home terminal APP with smart device
US8959191B2 (en) Script modification suggestion
CN110968315B (en) Element data structure changing method and device, storage medium and processor
CN106648567B (en) Data acquisition method and device
CN112256377A (en) Popup window data processing method and device
CN108804088B (en) Protocol processing method and device
CN111090974A (en) Report generation method, device and equipment
CN107369192B (en) Connection relation processing method and device
CN109683887A (en) A kind of construction method and device for supporting the customized web project of multi-scheme
CN109614098A (en) The generation method and device of configuration interface
CN111221651B (en) Load balancing configuration method, device, server and readable storage medium
WO2016206437A1 (en) Rom package generation method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant