CN113407276A - Information processing method, device, equipment and storage medium - Google Patents

Information processing method, device, equipment and storage medium Download PDF

Info

Publication number
CN113407276A
CN113407276A CN202110673735.0A CN202110673735A CN113407276A CN 113407276 A CN113407276 A CN 113407276A CN 202110673735 A CN202110673735 A CN 202110673735A CN 113407276 A CN113407276 A CN 113407276A
Authority
CN
China
Prior art keywords
control
modified
relation table
data
nesting
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202110673735.0A
Other languages
Chinese (zh)
Inventor
杨飞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information 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 Jingdong Century Trading Co Ltd, Beijing Wodong Tianjun Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN202110673735.0A priority Critical patent/CN113407276A/en
Publication of CN113407276A publication Critical patent/CN113407276A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The application discloses an information processing method, which comprises the following steps: receiving modification operation of a user on a target interface, and determining a control ID of a to-be-modified control aimed at by the modification operation; the control to be modified is a control in the target interface; modifying the data under the control ID in the nesting relation table corresponding to the target interface to obtain a modified nesting relation table; and sending the modified nesting relation table to a client. In addition, the application also discloses an information processing device, an electronic device and a storage medium.

Description

Information processing method, device, equipment and storage medium
Technical Field
The present application relates to the field of information processing, and relates to, but is not limited to, an information processing method, apparatus, device, and storage medium.
Background
Terminal devices (e.g., mobile phones, tablet computers, etc.) usually have various Applications (APPs) installed therein, where each APP includes an interface for a user to view.
At present, when an interface in an APP is modified, a server generally needs to modify a whole template file including the interface, send the modified template file to a client, load the template file again by the client, and then perform an interface initialization process again to complete interface refreshing.
Thus, if the content of the interface is only modified, the entire template file needs to be modified, and then the entire template file is binary-coded, loaded, decoded, parsed and rendered, so that the modified interface can be displayed on the client. Thus, there is a problem that the modification period for modifying the interface is long.
Disclosure of Invention
Embodiments of the present application provide an information processing method, apparatus, device, and storage medium for solving at least one problem in the related art, which can shorten a modification period for modifying an interface.
The technical scheme of the application is realized as follows:
in a first aspect, an embodiment of the present application provides an information processing method, where the method includes:
receiving modification operation of a user on a target interface;
determining a control ID of a control to be modified for the modification operation; the control to be modified is a control in the target interface;
modifying the data under the control ID in the nesting relation table corresponding to the target interface to obtain a modified nesting relation table;
and sending the modified nesting relation table to a client.
In a second aspect, an embodiment of the present application provides an information processing method, where the method includes:
receiving the modified nesting relation table; the modified nesting relation table is obtained by modifying data under the control ID of the control to be modified in the nesting relation table corresponding to the target interface;
presenting a modified target interface based on the modified nesting relation table; and the control to be modified in the modified target interface is changed relative to the control to be modified in the target interface.
In a third aspect, an embodiment of the present application provides an information processing apparatus, including:
the first receiving unit is used for receiving modification operation of a user on a target interface;
the determining unit is used for determining the control ID of the control to be modified for the modifying operation; the control to be modified is a control in the target interface;
the modification unit is used for modifying the data under the control ID in the nesting relation table corresponding to the target interface to obtain a modified nesting relation table;
and the sending unit is used for sending the modified nesting relation table to a client.
In a fourth aspect, an embodiment of the present application provides an information processing apparatus, including:
the second receiving unit is used for receiving the modified nesting relation table; the modified nesting relation table is obtained by modifying data under the control ID of the control to be modified in the nesting relation table corresponding to the target interface;
the display unit is used for presenting a modified target interface based on the modified nesting relation table; and the control to be modified in the modified target interface is changed relative to the control to be modified in the target interface.
In a fifth aspect, an embodiment of the present application provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the information processing method when executing the computer program.
In a sixth aspect, an embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored, and the computer program, when executed by a processor, implements the information processing method described above.
The embodiment of the application provides an information processing method, an information processing device, information processing equipment and a storage medium, wherein a server receives modification operation of a user on a target interface and determines a control ID of a control to be modified, which is aimed at by the modification operation; the control to be modified is a control in the target interface; modifying the data under the control ID in the nesting relation table corresponding to the target interface to obtain a modified nesting relation table; and sending the modified nesting relation table to a client. In the process of modifying the interface, only the control ID of the control to be modified in the target interface needs to be determined, and the data under the control ID of the control to be modified in the nesting relation table corresponding to the target interface needs to be modified, so that the whole template file is prevented from being modified, and the modification period for modifying the interface can be shortened.
Drawings
Fig. 1 is an information processing system according to an embodiment of the present application;
fig. 2 is an alternative schematic flow chart of an information processing method provided in an embodiment of the present application;
FIG. 3 is an alternative diagram of a control provided in an embodiment of the present application;
FIG. 4 is an alternative schematic diagram of a target interface provided by embodiments of the present application;
fig. 5 is an alternative schematic flow chart of an information processing method provided in an embodiment of the present application;
fig. 6 is an alternative schematic flow chart of an information processing method provided in an embodiment of the present application;
fig. 7 is an alternative schematic flow chart of an information processing method provided in an embodiment of the present application;
fig. 8 is an alternative schematic structural diagram of an information processing apparatus according to an embodiment of the present application;
fig. 9 is an alternative schematic structural diagram of an information processing apparatus according to an embodiment of the present application;
fig. 10 is an alternative structural schematic diagram of an electronic device provided in an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, specific technical solutions of the present application will be described in further detail below with reference to the accompanying drawings in the embodiments of the present application. The following examples are intended to illustrate the present application but are not intended to limit the scope of the present application.
The embodiment of the application can provide an information processing method and device, equipment (such as electronic equipment) and a storage medium (such as a computer readable storage medium). In practical applications, the information processing method can be implemented by using an information processing device.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein in the description of the present application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used herein, the term "and/or" includes any and all combinations of one or more of the associated listed items.
The information processing method of the embodiment of the present application is applicable to the information processing system 100 shown in fig. 1, and as shown in fig. 1, the information processing system 100 includes a server 10 and a client 20. Wherein the server 10 and the client 20 communicate with each other via a network 30.
The server 10 modifies the data under the control ID of the control to be modified in the nesting relationship table corresponding to the target interface to obtain a modified nesting relationship table, and then sends the modified nesting relationship table to the client 20 through the network 30, and after receiving the modified nesting relationship table, the client 20 can present the modified target interface based on the modified nesting relationship table.
Embodiments of an information processing method, an information processing apparatus, an information processing device, and a storage medium according to the embodiments of the present application are described below with reference to a schematic diagram of an information processing system shown in fig. 1.
Fig. 2 is a schematic flow chart of an implementation of an information processing method provided in an embodiment of the present application, where the method is applied to an information processing apparatus serving as a server, and as shown in fig. 2, the method may include the following steps:
s201, the server receives the modification operation of the user on the target interface.
Here, the target interface may include: one or more containers, a container may comprise: one or more controls.
The container may include: the control system comprises a horizontal container and a vertical container, wherein the horizontal container is a container comprising at least two horizontally arranged controls, and the vertical container is a container comprising at least two vertically arranged controls. The controls may include: the picture control is used for displaying a picture, and the text control is used for displaying a text.
In one example, as shown in fig. 3, the container includes: horizontal container 301 and vertical container 302, the control includes: a picture control 303 and a text control 304, wherein in the horizontal container 301, two picture controls 303 are horizontally arranged, and in the vertical container 302, two text controls 304 are vertically arranged.
In this embodiment, the server may include: an interface configuration system, wherein the interface configuration system is used for configuring a target interface, wherein the configuration of the target interface may include: and configuring the control in the target interface.
In some embodiments, the configuration of the target interface may further include: and configuring the container in the target interface, and after configuring the container, configuring the control included in the container.
In an example, as shown in fig. 4, the target interface 400 includes a vertical container 401, a horizontal container 402 and a horizontal container 403 are nested in the vertical container 401, a picture control 402a and a text control 402b are nested in the horizontal container 402, a vertical container 404 and a vertical container 405 are nested in the horizontal container 403, a picture control 404a and a text control 404b are nested in the vertical container 404, and a picture control 405a and a text control 405b are nested in the vertical container 405.
S202, the server determines the control ID of the control to be modified for the modification operation.
Here, the control to be modified is a control in the target interface.
In practical application, if a user needs to modify a control a in a target interface, the user may modify the control a, at this time, the server may receive the modification operation of the user, and determine that a control to be modified, to which the modification operation of the user is directed, is the control a according to the modification operation, so that the control ID of the control a may be determined.
Here, the control ID is used to indicate which control in the target interface is, and the server may determine, according to the control ID, the control in the target interface corresponding to the control ID.
After determining the to-be-modified control targeted by the modification operation of the user, the server may determine the control ID of the to-be-modified control.
After determining the control ID of the control to be modified, the server may determine in which container the control to be modified is included according to the container ID of the container in the target interface. Where the container ID is used to indicate which container in the target interface is. The server may determine, based on the container ID, a container in the target interface that corresponds to the container ID.
In an example, as shown in fig. 4, the control ID of the picture control 402a is 20001, the control ID of the text control 402b is 20002, the control ID of the picture control 404a is 20003, the control ID of the text control 404b is 20004, the control ID of the picture control 405a is 20005, and the control ID of the text control 405b is 20006; the container ID of the vertical container 401 is 101, the container ID of the horizontal container 402 is 1001, the container ID of the horizontal container 403 is 1002, the container ID of the vertical container 404 is 10001, and the container ID of the vertical container 405 is 10002.
S203, the server modifies the data under the control ID in the nesting relation table corresponding to the target interface to obtain a modified nesting relation table.
Here, the nesting relation table corresponding to the target interface includes: and data under all control IDs in the target interface, wherein the data under the control IDs comprise: rendering order of controls, layout data, and control content.
Layout data for a control, comprising: information characterizing the layout of the control, such as the position of the control and the size of the control, wherein the size of the control may include: width of the control and height of the control.
In an example, taking the picture control 402a in fig. 4 as an example, the width of the picture control is 20, the height of the picture control is 20, and the rendering order is 3.
The control content of the control comprises information for representing the content to be presented in the control, such as: address of picture, text content.
In an example, in the case that the control is a picture control, taking the picture control 402a in fig. 4 as an example, the control content of the picture control 402a is the address of the picture control, e.g., hep:// _ jpg; in the case where the control is a text control, taking the text control 402b in fig. 4 as an example, the control content of the text control is "this is text".
In the embodiment of the application, the modification operation is used for modifying one or both of layout data and control content of the control to be modified.
In this embodiment of the present application, the nesting relationship table corresponding to the target interface may further include: data under all container IDs in the target interface, wherein the data under the container ID comprises: container ID, container type, rendering order of containers, width of container, height of container, and rounded corners of container.
In an example, taking the container 401 in fig. 4 as an example, the container ID of the container is 101, the type of the container is vertical, the rendering order of the containers is 1, the width of the container is 200, the height of the container is 180, and the round corner of the container is 10.
And S204, the server sends the modified nesting relation table to the client.
Here, the server sends the modified nesting relation table to the client, so that the modified interface can be displayed in the client.
According to the information processing method provided by the embodiment of the application, a server receives modification operation of a user on a target interface, and determines a control ID of a control to be modified, which is aimed at by the modification operation; the control to be modified is a control in the target interface; modifying the data under the control ID in the nesting relation table corresponding to the target interface to obtain a modified nesting relation table; and sending the modified nesting relation table to a client. In the process of modifying the interface, only the control ID of the control to be modified in the target interface needs to be determined, and the data under the control ID of the control to be modified in the nesting relation table corresponding to the target interface needs to be modified, so that the whole template file is prevented from being modified, and the modification period for modifying the interface can be shortened.
In some embodiments, the information processing method further includes:
and the server determines the modification data of the modification operation aiming at the control to be modified.
Here, modifying the data includes: one or both of layout data and control content.
The server judges the type of the modified data;
here, the types of the modification data include: the system comprises a first type and a second type, wherein the modification data of the first type is layout data, and the modification data of the second type is control content.
If the user modifies the size of the control to be modified, the server can determine that the modification data of the control to be modified, which is aimed at by the modification operation of the user, is the layout data of the control to be modified; if the user modifies the content of the control to be modified, the server may determine that the modification data of the control to be modified, which is targeted by the modification operation of the user, is the control content of the control to be modified.
And the server determines a nesting relation table comprising the control ID according to the type of the modified data.
Here, the type of the modification data is different, and the nesting relation table including the control ID determined by the server is different.
If the layout data of the control is modified, the server only needs to modify the nesting relation table corresponding to the layout data, and does not need to modify all the nesting relation tables associated with the target page; similarly, if the control content of the control is modified, the server only needs to modify the nesting relation table corresponding to the control content, and does not need to modify all the nesting relation tables associated with the target page. In this way, decoupling of layout data modification and control content modification of the controls may be achieved.
In some embodiments, the determining, according to the type of the modification data, a nesting relationship table including the control ID includes:
if the type of the modification data comprises a first type, determining a first nesting relationship table comprising the control ID; the first type of modification data is layout data.
Here, if the type of the modification data includes layout data, the server may determine a first nesting relationship table from a nesting relationship table of the layout data including the control ID and the control content, the data included in the first nesting relationship table being layout data under the control ID.
In one example, the control ID of the picture control is 20001, and the data under the control ID includes: layout data and control content, if the server modifies the layout data of the control, for example, the size of the control, the type of the modified data can be determined to be a first type, so that a first nesting relation table can be determined from the nesting relation table of the layout data and the control content including the control ID, wherein the first nesting relation table only includes the layout data of the control ID and does not include the control content of the control ID.
Correspondingly, the step S203 includes:
and modifying the data under the control ID in the first nesting relation table corresponding to the target interface according to the layout data to obtain a modified first nesting relation table.
Here, if the layout data is modified, after determining the first nesting relationship table, the server may modify data under the control ID in the first nesting relationship table to obtain a modified first nesting relationship table.
In some embodiments, after obtaining the modified first nesting relationship table, the server may send the modified first nesting relationship table to the client through the layout interface.
In some embodiments, the determining, according to the type of the modification data, a nesting relationship table including the control ID includes:
if the type of the modification data comprises a second type, determining a second nesting relationship table comprising the control ID; the second type of modified data is control content;
here, if the type of the modification data includes the control content, the server may determine a second nesting relationship table from the nesting relationship table of the layout data including the control ID and the control content, the data included in the second nesting relationship table being the control content under the control ID.
In one example, the control ID of the text control is 20002, and the data under the control ID includes: the layout data of the control and the control content of the control, if the server modifies the control content of the control, for example, the control content, the type of the modification data may be determined as a control second type, so that a second nesting relation table may be determined from a nesting relation table of the layout data including the control ID and the control content, wherein the second nesting relation table includes only the control content of the control ID and does not include the layout data of the control ID.
Correspondingly, the step S203 includes:
and modifying the data under the control ID in a second nesting relation table corresponding to the target interface according to the control content to obtain a modified second nesting relation table.
Here, if the control content is modified, after determining the second nesting relationship table, the server may modify data under the control ID in the second nesting relationship table to obtain a modified second nesting relationship table.
In some embodiments, after obtaining the modified second nesting relationship table, the server may send the modified second nesting relationship table to the client through the content interface.
In some embodiments, the information processing method further includes:
the server receives the configuration of each control in the target interface; the configuration comprises: a layout configuration and a content configuration;
in this embodiment, the server may further include: and the dynamic server is used for carrying out layout configuration and content configuration on each control in the target interface.
The layout configuration is to set the background color, the fillet, the size, the coordinates and the like of each picture control in the target interface, and to set the text color, the text size and the like of each text control in the target interface.
The content is configured to the picture addresses of the picture controls and the text content of the text controls in the target interface.
And the server obtains a first nesting relation table based on the layout configuration.
Here, the server obtains the first nesting relation table based on data included in the layout configuration.
And the server obtains a second nesting relation table based on the content configuration.
Here, the server obtains the second nesting relation table based on data included in the content configuration.
The server sends the first nesting relation table and the second nesting relation table to the client; the first nesting relation table and the second nesting relation table are used for the client to display the target interface.
Here, after determining the first nesting relationship table including the layout configuration and the second nesting relationship table including the content configuration, the server sends the first nesting relationship table and the second nesting relationship table to the client, and the client may display the target interface after receiving the first nesting relationship table and the second nesting relationship table.
Fig. 5 is a schematic flow chart of an implementation of an information processing method according to an embodiment of the present application, where the method is applied to an information processing apparatus serving as a client, and as shown in fig. 5, the method may include the following steps:
s501, the client receives the modified nesting relation table.
And the modified nesting relation table is obtained by modifying the data under the control ID of the control to be modified in the nesting relation table corresponding to the target interface.
S502, the client presents the modified target interface based on the modified nesting relation table.
And the control to be modified in the modified target interface is changed relative to the control to be modified in the target interface.
Here, after receiving the modified nesting relation table, the client may analyze the layout data in the modified nesting relation table through a Software Development Kit (SDK) in the client to complete initialization of the interface, and analyze the content data in the modified nesting relation table to complete content update of the interface.
In the process of initializing the interface, the client can render the container and the control, wherein in the process of rendering, the root container can be rendered first, and then the child containers and the control nested in the root container are rendered in sequence.
In the process of updating the content of the interface, the client can replace the original control content of the control by using the received new control content of the control.
In some embodiments, the information processing method further includes:
the client judges the type of the modified nesting relation table;
when the type of the modified nesting relation table comprises a first type, the client receives the modified first nesting relation table; the first type of modified data is layout data;
when the type of the modified nesting relation table comprises a second type, the client receives the modified second nesting relation table; the second type of modified data is control content.
Here, after the client receives the modified first nesting relation table, the client may analyze the layout data in the first nesting relation table to obtain the layout configuration of the target interface; after the client receives the modified second nesting relation table, the client can update the control content in the second nesting relation table to obtain the control content of the target interface.
In some embodiments, the information processing method further includes:
the client receives a first nesting relation table obtained based on layout configuration and a second nesting relation table obtained based on content configuration;
here, after receiving the first nesting relation table obtained based on the layout configuration sent by the server and the second nesting relation table obtained based on the content configuration sent by the server, the client may analyze the first nesting relation table to obtain information such as background color, size, and position of each control in the target interface, and update the picture content and text content of each control in the target interface according to the second nesting relation table.
And the client displays the target interface according to the receiving sequence of the first nesting relation table and the second nesting relation table.
In some embodiments, the client displays the target interface according to the receiving order of the first nested relation table and the second nested relation table, including:
under the condition that the first nesting relation table is received firstly and then the second nesting relation table is received, firstly displaying the layout configuration of each control in the target interface, and then loading the content configuration of each control in the target interface;
and simultaneously displaying the layout configuration and the content configuration of each control in the target interface under the condition of receiving the second nesting relation table firstly and then receiving the first nesting relation table.
In the embodiment of the application, if the client receives the first nesting relation table first and then receives the second nesting relation table, the client may initialize the target interface through the layout initialization module after receiving the first nesting relation table, and assign values to the controls in the target interface after receiving the second nesting relation table. The method comprises the steps of initializing a target interface to carry out layout configuration on all controls in the target interface, wherein at the moment, all the controls in the target interface have no control content, assigning values to all the controls in the target interface by a client after the layout configuration of all the controls in the target interface is carried out, and enabling all the controls in the target interface to have the control content after the values are assigned.
During the process of initializing the interface, the container and the control can be rendered, so that the initialization of the interface is completed. In the process of rendering the containers, the initialization module can find the root container first, render the root container, find the child containers nested in the root container, render the child containers, and recursively render the child containers layer by layer from outside to inside. In the process of rendering the control, the control nested under the root container can be found first, the control nested under the root container is rendered, then the control nested under the child container is found to be rendered, the control nested under the child container is rendered, for the child control nested under one control, the outer control can be rendered first, and then the child control nested under the control is rendered.
After receiving the second nesting relation table, the client may assign a value to the interface content according to the received second nesting relation table, for example, if the client is a picture control, a picture is set at the position of the picture control, and if the client is a text control, a text is set at the position of the text control.
In the process of initializing the interface, only a blank area or a default occupation bitmap is reserved for the picture control, and only a text display area is reserved for the text control without displaying any text, so that after the interface is initialized, the content of the interface is required to be updated, and the final interface display is completed.
In the embodiment of the application, if the client receives the second nesting relation table first and then receives the first nesting relation table, the client integrates the layout data and the control content through the data analysis module after receiving the first nesting relation table, and integrates the first nesting relation table and the second nesting relation table into one table, so that the initialization of the interface and the assignment of the interface content are completed.
In some embodiments, if the client receives the first nesting relationship table and does not receive the second nesting relationship table, or the client receives the second nesting relationship table and does not receive the first nesting relationship table, the client may start a retry mechanism to re-receive the nesting relationship table sent by the server. The number of retries is generally 2, and if data is correctly acquired in the retries process, the information processing method is executed according to the sequence of data acquisition. If the retry times are used up and the data loading is still failed, the page is converted from the loading prompt state to the page loading exception prompt state.
In some embodiments, as shown in fig. 6, after the client receives the modified nesting relation table sent by the server, the client performs the following steps:
and S601, starting target interface rendering and updating.
And S602, starting an interface request.
Wherein, the S602 includes:
s602a, start the layout interface request.
S602b, start content interface request.
S602a1, judging whether the layout data is loaded normally.
If the loading is normal, executing S602a 2; if the loading is not normal, a retry mechanism is started and S603 is executed, wherein S603 is to determine whether the retry number is greater than 2.
S602a2, the layout data is analyzed.
S602a3, it is determined whether or not there is content data.
If the content data exists, executing S602b 2; if there is no content data, S602a4 is executed. Here, in S602b2, the content data is analyzed.
S602a4, initializing the root container.
And S602a5, initializing the sub-containers.
S602a6, initializing the child control.
After the above S602a5 is executed, S602a7 is executed, in which S602a7 is to determine whether there is a child container in the child container, and if there is a child container, the S602a5 and S602a6 are executed again; if there is no child container, S602a8 is executed.
S602a8, interface initialization is completed.
S602a9, judging whether the control displays the content.
If the content is displayed, executing S605; if no content is shown, S602b9 is performed. Here, S605 is to end the interface rendering and updating, and S602b9 is to determine whether there is content data.
After the above S602b is performed, the following S602b1 is performed.
S602b1, judging whether the control content is loaded normally.
If the loading is normal, executing S602b 2; if the loading is not normal, a retry mechanism is initiated and S603 is performed.
S602b2, the content data is analyzed.
S602b3, it is determined whether layout data is present.
If there is layout data, go to S602b 4; if there is no layout data, S602c is executed.
S602b4, integrating layout data and control content.
S602, 602c, judging whether the target interface is initialized. If so, then S602b5 is performed.
And S602b5, determining a root container.
And S602b6, determining the child container.
And S602b7, updating the child control.
After the above S602b6 is executed, S602b8 is executed, where S602b8 is to determine whether there is a sub-container in the sub-containers. If the child container exists, re-executing the above S602b6 and S602b 7; if there is no child container, the following S604 is performed.
And S604, finishing the updating of the target interface.
As shown in fig. 7, the information processing method provided in the embodiment of the present application includes:
s701, the server receives the modification operation of the user on the target interface.
S702, the server determines the control ID of the control to be modified for the modification operation.
S703, the server modifies the data under the control ID in the nesting relation table corresponding to the target interface to obtain a modified nesting relation table.
S704, the server sends the modified nesting relation table to the client.
S705, the client receives the modified nesting relation table.
S706, the client presents the modified target interface based on the modified nesting relation table.
For the description of S701, please refer to the description of S201 in the above embodiment; for the description of S702, please refer to the description of S201 in the above embodiment; for the description of S703, please refer to the description of S203 in the above embodiment; for the description of S704, please refer to the description of S204 in the above embodiment; for the description of S705, please refer to the description of S501 in the above embodiment; for the description of S706, please refer to the description of S502 in the above embodiment.
The information processing system provided by the application comprises three modules, namely an interface configuration platform, a dynamic service and a mobile client. The interface configuration platform is a visual editing place of a dynamic layout interface, mainly completes layout configuration and content configuration, and then performs associated binding on layout and content data through a control id. The dynamic service provides two data services, namely a layout data service and a content data service, and formats layout information and content information issued by a configuration platform respectively, and finally issues the layout information and the content information to a mobile terminal through a layout interface and a content interface in a JSON format. The mobile terminal is a final place for displaying the dynamic layout, after the layout data is obtained from the layout interface of the server terminal, the dynamic SDK embedded in the mobile terminal carries out data analysis, then the initialization rendering work of the container control and the sub-controls thereof is gradually completed from outside to inside, and finally the content data obtained by the content interface is updated to the control which is just initialized, so that the display of the whole dynamic interface is completed.
After the nesting relation, position and size attribute configuration of the dynamic layout container is completed, layout attributes such as control fillets, colors, sizes, inner and outer edge distances and the like can be set according to requirements, and the attributes are uploaded to dynamic services together for layout data processing when issued.
And then configuring content data, wherein the step is relatively simple, and the steps are mainly to assign values to the picture control and the text control in the dynamic interface, set a picture address for the picture control and set text content for the text control.
The technical scheme has the main idea that dynamic layout data and content data are decoupled, a corresponding relation is established between the dynamic layout data and the content data through a control id, the dynamic layout data and the content data are clicked and released after a configuration platform completes interface configuration, and the layout data and the content data are uploaded to a dynamic server side respectively. And the server side carries out formatting processing on the uploaded layout data and content data respectively, keeps the same nesting relation between the layout data and the content data, and finally generates standard JSON data to be issued to the mobile client side as shown in the following figure four.
The mobile client starts a data request module to start requesting data, the interface displays and loads a loading state, then the interface layout initialization is completed through the layout data issued by the layout interface, and the content display (interface update) is completed through the content data issued by the content interface. Since data is decoupled into two interfaces, there are problems of data coming before going and loading failure, which are mainly divided into the following four cases:
1. the layout data comes first, and the content data comes later;
2. the layout data comes first, and the loading of the content data fails;
3. the content data comes first, and the layout data comes later;
4. the content data comes first, and the layout data fails to be loaded;
1 and 3 are two normal data receiving cases, but the processing modes of the two cases are greatly different, and the case that the layout data first arrives at the content data and then arrives at the content data is described first. In this case, after the client acquires the layout data, the layout initialization module is started immediately to fully utilize the waiting time of content data loading, because the layout data is designed into a nested structure simulating real layout, when the interface layout is initialized, the initialization module only needs to find a root container first, and then recursively renders layer by layer from outside to inside, each layer of child controls can be rendered in order according to a rendering sequence set by a configuration platform, and when child containers exist in the child containers, all the layout data behind the child container nodes are transmitted to the rendering module as parameters, and the rendering of the child controls in the child containers is completed. The process recurses layer by layer until the controls of all the leaf nodes finish rendering, so that the initialization of the interface layout is finished.
However, this step is not completed yet, and in order to display rich content on the interface, the interface needs to be updated with the content data acquired later. When the control is initialized, only default data is used for displaying, the image control only reserves a blank area or displays a default occupied bitmap, and the text control only reserves a text display area and does not display any text. As described above, the content data and the layout data are decoupled, and are only linked through the control id, and the content data is also designed into a nested structure simulating a real layout for the purpose of updating the interface content in a layer-by-layer recursive manner from outside to inside in a similar manner to the initialized layout. When the content is displayed by the updating control, the updating module firstly finds the root container, then retrieves the content data of the child control through the id, and assigns the initialized child control, and under the condition that the child container exists, all the content data behind the child container node are taken as parameters and then transmitted to the updating module to assign the child control in the child container. Therefore, after the client executes the layout and content double-recursion flow, the client removes the loading state to complete the display work of the whole interface.
Next, the following description will be given of the case that the content data first arrives at the layout data and then arrives, in this case, since the layout data is not yet acquired, the interface continues to show the loading state, and the initialization module waits for the arrival of the layout data. Although the content data is acquired, the interface is not initialized, and the update module does not start the update process. After the layout data comes, the data analysis module integrates the layout data and the content data and integrates the layout data and the content data into a structure with layout and content data according to the original nesting relation. In short, the two parts of data in the fourth diagram are combined into one, namely, the content data is added into the layout data, as shown in the fifth diagram, so that the original two nested recursive flows can be combined into one.
The following processing flow is consistent with the interface initialization in the case 1, the layout data does not have content data during the initialization in the case 1, and the assignment work of the controls can be completed while initializing each control after the content data exists. And finally removing the loading state and displaying the dynamically rendered interface.
2 and 4 are two cases of data acquisition abnormality, in the scheme, a retry mechanism is provided when data acquisition is abnormal, and the retry mechanism is started no matter the layout interface or the content interface fails to acquire data, the retry frequency is generally set to 2, and if data is correctly acquired in the retry process, the rendering process 1 or 3 is executed according to the sequence of data acquisition. If the retry times are used up and the data loading is still failed, the page is converted from the loading prompting state to the page loading abnormity prompting state.
The complete dynamic interface rendering flow of the client is shown in fig. 6:
and if the interface layout is not changed, but the content is changed, the server side determines whether to only send the content data or not through the interface access parameter transmitted by the client side when the client side refreshes the interface pull data, the access parameter indicates the server side, and the client side only refreshes the content or initializes the interface to render the data request. If the latter, the client will execute the whole dynamic interface rendering process; if the data is the former, only the content interface in the two interfaces of the client acquires the data, and the layout interface does not carry any layout data except for returning a status field informing that the layout data of the client is unchanged. After the refreshed content data is taken and analyzed, the client end completes the recursion flow of one-time content updating.
Fig. 8 is an information processing apparatus provided in an embodiment of the present application, and is applied to a server, and as shown in fig. 8, the information processing apparatus 800 includes:
a first receiving unit 801, configured to receive a modification operation of a target interface by a user;
a determining unit 802, configured to determine a control ID of a control to be modified for the modifying operation; the control to be modified is a control in the target interface;
a modifying unit 803, configured to modify data under the control ID in the nesting relationship table corresponding to the target interface, so as to obtain a modified nesting relationship table;
a sending unit 804, configured to send the modified nesting relationship table to a client.
In some embodiments, the apparatus 800 further comprises: a judgment unit;
the determining unit 802 is further configured to determine modification data of the control to be modified for the modifying operation; a judging unit, configured to judge a type of the modified data; the determining unit 802 is further configured to determine, according to the type of the modification data, a nesting relationship table including the control ID.
In some embodiments, the determining unit 802 is further configured to determine a first nesting relationship table including the control ID if the type of the modification data includes a first type; the first type of modified data is layout data; correspondingly, the modifying unit 803 is further configured to modify, according to the layout data, data under the control ID in the first nesting relationship table corresponding to the target interface, so as to obtain a modified first nesting relationship table.
In some embodiments, the determining unit 802 is further configured to determine a second nesting relationship table including the control ID if the type of the modification data includes a second type; the second type of modified data is control content; correspondingly, the modifying unit 803 is further configured to modify, according to the control content, the data under the control ID in the second nesting relationship table corresponding to the target interface, so as to obtain a modified second nesting relationship table.
In some embodiments, the apparatus 800 further comprises: an acquisition unit;
a first receiving unit 801, further configured to receive configurations for each control in the target interface; the configuration comprises: a layout configuration and a content configuration;
the acquisition unit is used for acquiring a first nesting relation table based on the layout configuration; the content configuration module is further used for obtaining a second nesting relation table based on the content configuration;
a sending unit 804, further configured to send the first nesting relationship table and the second nesting relationship table to the client; the first nesting relation table and the second nesting relation table are used for the client to display the target interface.
Fig. 9 is an information processing apparatus provided in an embodiment of the present application, and as shown in fig. 9, the information processing apparatus 900 includes:
a second receiving unit 901, configured to receive the modified nesting relationship table; the modified nesting relation table is obtained by modifying data under the control ID of the control to be modified in the nesting relation table corresponding to the target interface;
a display unit 902, configured to present a modified target interface based on the modified nesting relation table; and the control to be modified in the modified target interface is changed relative to the control to be modified in the target interface.
In some embodiments, the apparatus 900 further comprises: the judging unit is used for judging the type of the modified nesting relation table;
the second receiving unit 901 is further configured to receive the modified first nesting relation table when the type of the modified nesting relation table includes modification data of the first type; the first type of modified data is layout data;
the second receiving unit 901 is further configured to receive the modified second nesting relation table when the type of the modified nesting relation table includes modified data of a second type; the second type of modified data is control content.
In some embodiments, the second receiving unit 901 is further configured to receive a first nesting relationship table obtained based on the layout configuration and a second nesting relationship table obtained based on the content configuration;
the display unit 902 is further configured to display the target interface according to the receiving order of the first nesting relationship table and the second nesting relationship table.
In some embodiments, the display unit 902 is further configured to, when the first nesting relationship table is received first and then the second nesting relationship table is received, display the layout configuration of each control in the target interface first and then display the content configuration of each control in the target interface;
the display unit 902 is further configured to simultaneously display the layout configuration and the content configuration of each control in the target interface when the second nesting relationship table is received first and then the first nesting relationship table is received.
The embodiment of the present application further provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor, and when the processor executes the computer program, the steps in the information processing method according to any of the above embodiments are implemented.
An embodiment of the present application further provides a computer-readable storage medium, in which a computer program is stored, and when the computer program is executed by a processor, the information processing method according to any of the above embodiments is implemented.
Here, it should be noted that: the above description of the electronic and computer-readable storage medium is similar to the description of the method embodiments above, with similar beneficial effects as the method embodiments. For technical details not disclosed in the embodiments of the storage medium and apparatus of the present application, reference is made to the description of the embodiments of the method of the present application for understanding.
The units included in the information processing apparatus provided in the embodiment of the present application may be implemented by a processor in an electronic device; of course, the implementation can also be realized through a specific logic circuit; in the implementation process, the Processor may be a Central Processing Unit (CPU), a microprocessor Unit (MPU), a Digital Signal Processor (DSP), a Field Programmable Gate Array (FPGA), or the like.
The above description of the apparatus embodiments, similar to the above description of the method embodiments, has similar beneficial effects as the method embodiments. For technical details not disclosed in the embodiments of the apparatus of the present application, reference is made to the description of the embodiments of the method of the present application for understanding.
In the embodiment of the present application, if the information processing method is implemented in the form of a software functional module and sold or used as a standalone product, the information processing method may also be stored in a computer readable storage medium. Based on such understanding, the technical solutions of the embodiments of the present application may be essentially implemented or portions thereof contributing to the related art may be embodied in the form of a software product stored in a storage medium, and including several instructions for enabling a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the methods described in the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read Only Memory (ROM), a magnetic disk, or an optical disk. Thus, embodiments of the present application are not limited to any specific combination of hardware and software.
It should be noted that fig. 10 is a schematic hardware entity diagram of an electronic device according to an embodiment of the present application, and as shown in fig. 10, the electronic device 1000 includes: a processor 1001, at least one communication bus 1002, at least one external communication interface 1004, and memory 1005. Wherein the communication bus 1002 is configured to enable connective communication between these components. In an example, the electronic device 1000 further comprises: a user interface 1003, wherein the user interface 1003 may comprise a display screen, and the external communication interface 1004 may comprise a standard wired interface and a wireless interface.
The Memory 1005 is configured to store instructions and applications executable by the processor 1001, and may also buffer data (e.g., image data, audio data, voice communication data, and video communication data) to be processed or already processed by the processor 1001 and modules in the electronic device, and may be implemented by a FLASH Memory (FLASH) or a Random Access Memory (RAM).
It should be appreciated that reference throughout this specification to "one embodiment" or "an embodiment" means that a particular feature, structure or characteristic described in connection with the embodiment is included in at least one embodiment of the present application. Thus, the appearances of the phrases "in one embodiment" or "in some embodiments" in various places throughout this specification are not necessarily all referring to the same embodiment. Furthermore, the particular features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. It should be understood that, in the various embodiments of the present application, the sequence numbers of the above-mentioned processes do not mean the execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present application. The above-mentioned serial numbers of the embodiments of the present application are merely for description and do not represent the merits of the embodiments.
It should be noted that, in this document, 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 an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
In the several embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. The above-described device embodiments are merely illustrative, for example, the division of the unit is only a logical functional division, and there may be other division ways in actual implementation, such as: multiple units or components may be combined, or may be integrated into another system, or some features may be omitted, or not implemented. In addition, the coupling, direct coupling or communication connection between the components shown or discussed may be through some interfaces, and the indirect coupling or communication connection between the devices or units may be electrical, mechanical or other forms.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units; can be located in one place or distributed on a plurality of network units; some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, all functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may be separately regarded as one unit, or two or more units may be integrated into one unit; the integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional unit.
Those of ordinary skill in the art will understand that: all or part of the steps for realizing the method embodiments can be completed by hardware related to program instructions, the program can be stored in a computer readable storage medium, and the program executes the steps comprising the method embodiments when executed; and the aforementioned storage medium includes: various media that can store program codes, such as a removable Memory device, a Read Only Memory (ROM), a magnetic disk, or an optical disk.
Alternatively, the integrated units described above in the present application may be stored in a computer-readable storage medium if they are implemented in the form of software functional modules and sold or used as independent products. Based on such understanding, the technical solutions of the embodiments of the present application may be essentially implemented or portions thereof contributing to the related art may be embodied in the form of a software product stored in a storage medium, and including several instructions for enabling a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the methods described in the embodiments of the present application. And the aforementioned storage medium includes: a removable storage device, a ROM, a magnetic or optical disk, or other various media that can store program code.
The above description is only for the embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of changes or substitutions within the technical scope of the present application, and shall be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (13)

1. An information processing method, characterized in that the method comprises:
receiving modification operation of a user on a target interface;
determining a control ID of a control to be modified for the modification operation; the control to be modified is a control in the target interface;
modifying the data under the control ID in the nesting relation table corresponding to the target interface to obtain a modified nesting relation table;
and sending the modified nesting relation table to a client.
2. The method of claim 1, further comprising:
determining modification data of the control to be modified for which the modification operation is directed;
judging the type of the modified data;
and determining a nesting relation table comprising the control ID according to the type of the modified data.
3. The method of claim 2, wherein determining a nesting relationship table comprising the control ID based on the type of the modification data comprises:
if the type of the modification data comprises a first type, determining a first nesting relationship table comprising the control ID; the first type of modified data is layout data;
correspondingly, modifying the data under the control ID in the nesting relationship table corresponding to the target interface to obtain a modified nesting relationship table, including:
and modifying the data under the control ID in the first nesting relation table corresponding to the target interface according to the layout data to obtain a modified first nesting relation table.
4. The method of claim 2, wherein determining a nesting relationship table comprising the control ID based on the type of the modification data comprises:
if the type of the modification data comprises a second type, determining a second nesting relationship table comprising the control ID; the second type of modified data is control content;
correspondingly, modifying the data under the control ID in the nesting relationship table corresponding to the target interface to obtain a modified nesting relationship table, including:
and modifying the data under the control ID in a second nesting relation table corresponding to the target interface according to the control content to obtain a modified second nesting relation table.
5. The method of claim 1, further comprising:
receiving the configuration of each control in the target interface; the configuration comprises: a layout configuration and a content configuration;
obtaining a first nesting relation table based on the layout configuration;
obtaining a second nesting relation table based on the content configuration;
sending the first nesting relation table and the second nesting relation table to the client; the first nesting relation table and the second nesting relation table are used for the client to display the target interface.
6. An information processing method, characterized in that the method comprises:
receiving the modified nesting relation table; the modified nesting relation table is obtained by modifying data under the control ID of the control to be modified in the nesting relation table corresponding to the target interface;
presenting a modified target interface based on the modified nesting relation table; and the control to be modified in the modified target interface is changed relative to the control to be modified in the target interface.
7. The method of claim 6, further comprising:
judging the type of the modified nesting relation table;
when the type of the modified nesting relation table comprises modification data of a first type, receiving the modified first nesting relation table; the first type of modified data is layout data;
when the type of the modified nested relation table comprises modified data of a second type, receiving the modified second nested relation table; the second type of modified data is control content.
8. The method of claim 6, further comprising:
receiving a first nesting relation table obtained based on layout configuration and a second nesting relation table obtained based on content configuration;
and displaying the target interface according to the receiving sequence of the first nesting relation table and the second nesting relation table.
9. The method of claim 8, wherein displaying the target interface according to the order of receipt of the first nested relationship table and the second nested relationship table comprises:
under the condition that the first nesting relation table is received firstly and then the second nesting relation table is received, firstly displaying the layout configuration of each control in the target interface, and then loading the content configuration of each control in the target interface;
and simultaneously displaying the layout configuration and the content configuration of each control in the target interface under the condition of receiving the second nesting relation table firstly and then receiving the first nesting relation table.
10. An information processing apparatus characterized in that the apparatus comprises:
the first receiving unit is used for receiving modification operation of a user on a target interface;
the determining unit is used for determining the control ID of the control to be modified for the modifying operation; the control to be modified is a control in the target interface;
the modification unit is used for modifying the data under the control ID in the nesting relation table corresponding to the target interface to obtain a modified nesting relation table;
and the sending unit is used for sending the modified nesting relation table to a client.
11. An information processing apparatus characterized in that the apparatus comprises:
the second receiving unit is used for receiving the modified nesting relation table; the modified nesting relation table is obtained by modifying data under the control ID of the control to be modified in the nesting relation table corresponding to the target interface;
the display unit is used for presenting a modified target interface based on the modified nesting relation table; and the control to be modified in the modified target interface is changed relative to the control to be modified in the target interface.
12. An electronic device comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein the processor implements the information processing method of any one of claims 1 to 5 or implements the information processing method of any one of claims 6 to 9 when executing the computer program.
13. A computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the information processing method of any one of claims 1 to 5, or implements the information processing method of any one of claims 6 to 9.
CN202110673735.0A 2021-06-17 2021-06-17 Information processing method, device, equipment and storage medium Pending CN113407276A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110673735.0A CN113407276A (en) 2021-06-17 2021-06-17 Information processing method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110673735.0A CN113407276A (en) 2021-06-17 2021-06-17 Information processing method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN113407276A true CN113407276A (en) 2021-09-17

Family

ID=77684903

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110673735.0A Pending CN113407276A (en) 2021-06-17 2021-06-17 Information processing method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113407276A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114130016A (en) * 2021-12-07 2022-03-04 腾讯科技(深圳)有限公司 Control resource management method and related device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114130016A (en) * 2021-12-07 2022-03-04 腾讯科技(深圳)有限公司 Control resource management method and related device
CN114130016B (en) * 2021-12-07 2023-07-14 腾讯科技(深圳)有限公司 Control resource management method and related device

Similar Documents

Publication Publication Date Title
CN109885324B (en) Processing method, device, terminal and storage medium of application program installation package
US10573082B2 (en) Target object display method, device and system
US9589063B2 (en) Two-dimensional code processing method and terminal
WO2016155379A1 (en) Method, device and system for dynamically acquiring app interface control data
US11720370B2 (en) Electronic apparatus and method of executing application program
CN109508189B (en) Layout template processing method and device and computer readable storage medium
CN109492607B (en) Information pushing method, information pushing device and terminal equipment
US10943281B2 (en) Information search method, information search device and information search non-transitory computer storage medium
CN113407276A (en) Information processing method, device, equipment and storage medium
CN111857712A (en) Form processing method, device, terminal and medium
CN111767492B (en) Picture loading method and device, computer equipment and storage medium
CN111931708A (en) Form generation method and device
CN114329091A (en) Data directory generation method, device and equipment
CN104361047B (en) Data display method and device in client
CN114115869A (en) User interface UI processing method and device
CN115080686A (en) Commodity reference resolution method and device for live broadcast platform and computing equipment
CN114692581A (en) Electronic form sub-table display method, device, equipment and storage medium
CN112445811A (en) Data service method, device, storage medium and component based on SQL configuration
CN112367535A (en) Generation method and device of active user interface
CN112083902A (en) Control method of storage cabinet, storage cabinet and readable storage medium
CN111339656A (en) Cabinet production method and system and electronic equipment
CN105589870A (en) Webpage advertisement filtering method and system
CN114189741B (en) Image processing method and related device
CN113835846B (en) Method and device for creating k8s cluster and computer-readable storage medium
CN109144446B (en) Image display method, image display device, electronic equipment and computer readable storage medium

Legal Events

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