CN107092475B - Calling method and device of interactive control - Google Patents

Calling method and device of interactive control Download PDF

Info

Publication number
CN107092475B
CN107092475B CN201611190723.8A CN201611190723A CN107092475B CN 107092475 B CN107092475 B CN 107092475B CN 201611190723 A CN201611190723 A CN 201611190723A CN 107092475 B CN107092475 B CN 107092475B
Authority
CN
China
Prior art keywords
jump link
trigger object
client
link
jump
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
CN201611190723.8A
Other languages
Chinese (zh)
Other versions
CN107092475A (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.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding 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 Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201611190723.8A priority Critical patent/CN107092475B/en
Publication of CN107092475A publication Critical patent/CN107092475A/en
Application granted granted Critical
Publication of CN107092475B publication Critical patent/CN107092475B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/37Compiler construction; Parser generation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04842Selection of displayed objects or displayed text elements
    • 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/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
    • 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)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The embodiment of the application discloses a method and a device for calling an interactive control. In the embodiment of the application, a lightweight parser specially used for parsing the jump link is embedded in the client of the application in advance, and interaction parameters for calling the interaction control are packaged into the jump link by using a jump link protocol naturally supported by various operating systems and are sent to the client of the application, so that the parser parses the interaction parameters to complete the update of the client code. In this way, by embedding the parser in the client in advance, the user does not have to install the latest client frequently. In addition, the function of the parser is single and light, and the parser is specially used for parsing jump links which are naturally supported by various operating systems, so that the embedding of the parser in the client is different from the embedding of the SDK in the client, the light-weight parser cannot cause the client to be bloated, and a large amount of running memory and storage space of a mobile terminal are saved.

Description

Calling method and device of interactive control
Technical Field
The application relates to the technical field of software, in particular to a method and a device for calling an interactive control.
Background
In the field of software technology, components that can be seen by and interact with a User in a Graphical User Interface (GUI) are referred to as interactive controls. The user can input or select data in the interactive control by taking the interactive control as an operation object so as to complete the operation.
Generally, operating systems provide native interactive controls, such as visual frames, visual lists, etc., for invocation by applications installed in the operating system. The application can customize the called interactive control, that is, configure the interactive logic (such as style, content, interactive form) of the called interactive control through the preset interactive parameters, so as to meet the functional requirements. Of course, the application may also customize an interactive control with a certain interactive logic, and when a certain function needs to be implemented, the interactive control with the interactive logic corresponding to the interactive parameter is called according to the preset interactive parameter. In an application, more than one function needing to call the interactive control is often required, and the interactive logic required by each function is different. This requires more than one set of interaction parameters to be preset in the application.
Fig. 1a is a schematic diagram of triggering an interaction control in a mobile terminal operating system according to the present application. As shown in fig. 1a, in case that a user wants to replace an avatar used in a social application, the user first enters an avatar setting interface of the social application, and triggers an interaction control after selecting "replace avatar" in the avatar setting interface, as shown in fig. 1 b. In fig. 1b, the style of the interactive control is three same-sized tabs in a rectangular frame, that is, "select from album", "take picture", and "close", and the user may select a certain option in the interactive control, such as "select from album", so that it is possible to implement an interactive mode of jumping to album and selecting a self-satisfied picture from album as a head portrait.
The interactive control for setting the avatar in fig. 1b is a pull-up type visual list, which pops up from the bottom of the screen, the style is unified with the interface design style of the social application, the content of the option is set by the social application, and the effect (entering an album to select pictures) generated by clicking a certain option by the user is also set by the social application. The interaction control shown in fig. 1b may be an interaction control defined by an application according to preset interaction parameters, or may be a native interaction control provided by an application calling system, and instantiates the native interaction control according to the preset interaction parameters.
In the existing method for calling the interactive control, on one hand, based on the flexibility of the service, the application developer often needs to change the preset interactive parameters; on the other hand, the preset interaction parameters are stored in the client codes of the application, after the application is installed in the operating system, if the developer of the application needs to change the preset interaction parameters, only two ways can be selected, one way is to require the user to install a new version of the application (update the interaction parameters in the client codes) in the operating system, and the other way is to embed a Software Development Kit (SDK) supporting the dynamic technology, such as a ReactNative SDK, into the client of the application in advance, receive a data packet which is sent by a server and is packaged with the interaction parameters, and obtain the interaction parameters by analyzing the data packet, thereby completing the update of the interaction parameters in the client codes.
However, frequently releasing new versions of applications and requiring user installation may reduce the convenience of the user in using the applications; however, if the SDK is embedded in the application in advance, the client of the application is too bulky, and occupies a large running memory and storage space of the mobile terminal.
Disclosure of Invention
The embodiment of the application provides a method and a device for calling an interactive control, so that convenience of using an application by a user is improved, and running memory and storage space occupied by a client of the application are saved.
In order to solve the above technical problem, the embodiment of the present application is implemented as follows:
according to the calling method of the interactive control, a resolver is embedded in a client in advance, and the resolver is used for resolving a jump link, and the method comprises the following steps:
the client receives the jump link issued by the server; the skip link carries a target client identifier and an interaction parameter, wherein the target client identifier is the identifier of the client;
sending the jump link to an operating system so that the operating system returns the jump link to the client according to a target client identifier carried in the jump link;
receiving the jump link returned by the operating system;
analyzing the interaction parameters from the jump link through the analyzer;
and calling an interactive control according to the interactive parameters.
The calling device for the interactive control, provided by the embodiment of the application, is embedded with an analyzer in advance, where the analyzer is used for analyzing a jump link, and the device includes:
the first receiving module is used for receiving the jump link issued by the server; the skip link carries a destination device identifier and an interaction parameter, wherein the destination device identifier is the identifier of the device;
the sending module is used for sending the jump link to an operating system so that the operating system returns the jump link to the device according to a target device identifier carried in the jump link;
the second receiving module is used for receiving the jump link returned by the operating system;
the analysis module analyzes the interaction parameters from the jump link through the analyzer;
and the calling module calls the interactive control according to the interactive parameters.
As can be seen from the above technical solutions provided in the embodiments of the present application, a lightweight parser dedicated for parsing a jump link is embedded in an application client in advance, and interaction parameters for invoking an interaction control are encapsulated in the jump link by using a jump link protocol that is naturally supported by various operating systems, and are sent to the application client, so that the parser parses the interaction parameters to complete updating of a client code. In this way, by embedding the parser in the client in advance, the user does not have to install the latest client frequently. In addition, the function of the parser is single and light, and the parser is specially used for parsing jump links which are naturally supported by various operating systems, so that the embedding of the parser in the client is different from the embedding of the SDK in the client, the light-weight parser cannot cause the client to be bloated, and a large amount of running memory and storage space of a mobile terminal are saved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, it is obvious that the drawings in the following description are only some embodiments described in the present application, and for those skilled in the art, other drawings can be obtained according to the drawings without any creative effort.
1 a-1 b are schematic diagrams of triggering an interactive control in a mobile terminal operating system according to the present application;
fig. 2 is a flowchart of a method for invoking an interactive control according to an embodiment of the present application;
FIG. 3 is a flowchart of parsing a URL through a parser according to an embodiment of the present application;
4 a-4 c are schematic diagrams of interaction controls provided by an embodiment of the present application in a scenario where a user shops on an e-commerce platform;
fig. 5 is a schematic diagram of an invoking device of an interaction control according to an embodiment of the present application.
Detailed Description
The embodiment of the application provides a calling method and device of an interactive control.
In order to make those skilled in the art better understand the technical solutions in the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
As described in the background art, in the existing method for calling an interactive control, an application developer can update the client code of an application installed on a mobile terminal of a user only through the following two ways: requiring the user to reinstall the latest version of the client, or using some dynamic technologies, such as ReactNative, JSPatch, etc., to dynamically update the client code.
This is because, in general, the client code of the application installed in the operating system is often Native-level code (Native code), once the client of the application is installed in the operating system, the Native code cannot be easily changed, and the Native code describes the interaction parameters required by the application to invoke the interaction control.
In fact, when an application developer needs to update the interaction parameters, the developer often chooses to issue a latest version of client for the user to install, and the interaction parameters recorded in the client code of the client are the interaction parameters updated by the developer. However, the convenience of the user for using the application is sacrificed just for the limited updating of the interaction parameters, and is nothing more done by the developer.
In addition, the developer also has a choice of updating the interaction parameters in the client code, namely embedding a ReactNative SDK, a JSPatch SDK and other SDKs which support dynamic update of the client code into the client in advance. However, the SDKs are often bulky in function, which results in a large size, and if the large size of SDKs are embedded in the client only for dynamic update of the interaction parameters, which results in a bulky client, the client occupies a large amount of operating memory and storage space of the mobile terminal of the user.
In summary, how to design an efficient method for invoking an interactive control makes it possible to support the server to dynamically update the interactive parameters, and on the other hand, it is not necessary to use too heavy technical means, which becomes a technical problem to be solved in the art.
In view of this, in the technical solution claimed in the present application, a lightweight parser, which has a single function and is dedicated to parsing the jump link under the jump link protocol supported by each operating system, may be embedded in the client in advance, which is also a reason for the lightweight of the parser. And the resolver supports dynamic updating of interaction parameters in the client code.
That is, the resolver can be regarded as a SDK having a simplified function and reduced weight. The developer encapsulates the updated interactive parameters into a skip link form at the server, and then sends the skip link to the corresponding client, the client follows the skip link protocol, and needs to send the skip link to the operating system for positioning, and then the operating system sends the skip link to the client corresponding to the target client identifier according to the target client identifier carried in the skip link, that is, the client which initially receives the skip link sent from the server. The parser may then parse the jump link to obtain updated interaction parameters. This is also the subtlety of the solution.
This is because the jump link protocol is commonly used in mobile operating systems such as android, the mobile operating system (iOS), etc. developed by ***, and the main function of the jump link is to implement a jump between applications or application modules, such as an application a jumping to an application B. According to the scheme, the jump link pointing to the application A is sent to the operating system by the application A by utilizing the characteristic of the jump link, the interaction parameters carried in the operation link are smoothly transported to the application A on the premise that a jump link protocol allows, and only then, the embedded analyzer in the application A starts to work, so that the interaction parameters are smoothly analyzed from the jump link and used as new interaction parameters for replacing old interaction parameters in a client code, and then, the interaction control is called according to the new interaction parameters.
That is, the operation that the application a sends the received jump link to the operating system and then receives the operation link returned by the operating system again is useless, and is actually a flow that is necessary under the jump link protocol, because for the lightweight of the application a, a parser dedicated to parse the jump link is specially embedded in the application a, and the parser starts to operate only after receiving the jump link sent from the operating system, which is also the regulation of the jump link protocol.
The jump link protocol is so defined because, as previously mentioned, the function of the jump link is to effect a jump between applications or application modules. For example, the shopping application a needs to call the payment function of the payment application B to support the user payment, the application a may send a jump link to the operating system, where the jump link carries a destination client identifier of the application B and some necessary service data (such as an amount to be paid, a payment port, and the like), and the operating system may determine, according to the destination client identifier, the client of the application to which the jump link points, that is, the application B. The operating system will then launch application B, where the user can complete the payment.
The core idea of the technical scheme claimed by the application is that a lightweight resolver is embedded in advance for an application client, the reason of lightweight of the resolver is that the resolver has a single function, namely only a jump link based on a jump link protocol can be resolved, the resolved interaction parameter replaces an old interaction parameter in a client code, and in order to enable the resolver to work, the jump link supported by the jump link protocol is matched to encapsulate an updated interaction parameter, and the jump link is regarded as a 'carrying tool' of the interaction parameter to dynamically issue the interaction parameter, so that the purpose of dynamically calling an interaction control is achieved.
It should be noted that, the present application does not limit how the jump link protocol is specifically, and all protocols used for jumping between applications or application modules may be the jump link protocol described in the present application. The jump link may be in a link form, or may be in other data forms, which is not limited in this application.
The uniform resource locator URL Scheme is a common jump link. For convenience of description, in the following explanation of the present solution, the URL Scheme will be described as an example.
The technical solutions provided by the embodiments of the present application are described in detail below with reference to the accompanying drawings.
Fig. 2 is a flowchart of a control method for an interactive control according to an embodiment of the present application, where the control method includes the following steps:
s201: and the client receives the jump link issued by the server.
In this embodiment, the client is a client of an application corresponding to the server. In the following description, an application is a concept on a software level, a client is a concept on a hardware level, and an application and a client are a unified pair of concepts.
In this embodiment of the present application, the jump link protocol may specifically be a URL Scheme protocol that is naturally supported by each operating system, and the jump link may be a URL. The URL for application or inter-application-module hopping may be in the format: "app:// platformmapi/interaction? … … ", where the app is a destination client identifier (which may be an application name), the destination client identifier is a Scheme, the value of the platform field is a host name, the value of the interaction field is an application module name, both the host name and the module name need to conform to the URL Scheme protocol, otherwise, the URL is illegal, and the parser cannot parse illegal URLs. The value of the params field may be some parameters of the application process that needs to receive the URL.
For example, application a needs to invoke the payment module of application B, and application a may send the URL to the operating system as follows: "appB:// Jim's phone/pay? And params is 100 ", which means that the application a installed in Jim's mobile phone needs to call the payment module of the application B to help the user to complete 100-yuan payment.
It should be emphasized that fields such as host name and application module name may not be included in a segment of URL, and for the technical problem to be solved by the present application, fields that must be included in a segment of URL are app field and params field. For example, the URL may be in the format: "a 3546:// params ═ … …", indicating that the interaction parameter in the client code of the client identified as a3546 as the destination client is to be updated to "… …".
In this embodiment of the present application, an application developer may encode the updated interaction parameter at the server, and encapsulate the interaction parameter into a URL, that is, encapsulate the interaction parameter into a params field of the URL. Meanwhile, the schema of the URL may be an application name of a client of an application corresponding to the server.
In the embodiment of the application, the method for encapsulating the interactive parameter by the developer may be to firstly JSON the interactive parameter to generate a JSON string after JSON, then urencode-coding the JSON string to generate a urencoded string after coding, and using the urencoded string as a value of a params field of the URL.
It is worth emphasizing that the solution claimed in the present application is applicable to operating systems that natively support the jump link protocol.
In the embodiment of the application, the skip link carries a destination client identifier and an interaction parameter, and the destination client identifier is an identifier of the client.
Specifically, the interaction parameter may be a set of parameters, such that the client may determine the interaction logic (e.g., style, content, interaction form) of the invoked interaction control according to the interaction parameter, where the style may be the shape, size, color, transparency, and the like of the interaction control; the content can be content displayed in the interactive control, such as content of options, content of prompt messages and the like; the interaction form can be a form when the user interacts with the interaction control, and comprises the interaction control of whether the user clicks a certain button in the interaction control to pop up a new interaction control or not, and what function the user clicks the interaction control popped up by the certain button in the almost space.
S202: and sending the jump link to an operating system.
S203: and receiving the jump link returned by the operating system.
In the embodiment of the application, after receiving the URL issued by the server, the client cannot directly analyze the URL through the parser, because the URL does not conform to the specification of the URL Scheme protocol, and the parser can only analyze the URL sent by the operating system.
Therefore, after receiving the URL issued by the server, the client may send the URL to the operating system according to the URL Scheme protocol, the operating system determines the destination client identifier, i.e., the Scheme, carried in the URL according to the URL Scheme protocol, and after the URL is legal, determines that the client to which the URL points is the client. The operating system then sends the URL to the client. The target client identification is legal, namely the format of the target client identification conforms to the specification of a URL Scheme protocol, and the client corresponding to the target client identification is the client installed in the operating system.
S204: and analyzing the interaction parameters from the jump link through the analyzer.
In the embodiment of the application, the client can respectively determine the values of the fields in the jump link through the resolver; and when the jump link is determined to be legal according to the values of each field determined respectively, determining the value of the parameter field in the jump link as the interactive parameter.
Fig. 3 is a flowchart for resolving a URL through a resolver according to an embodiment of the present disclosure. As shown in fig. 3, the parser determines whether the values of the fields of the URL are legal one by one, that is, whether the values meet the specification of the URL Scheme protocol, and if any field is illegal, the parser determines that the URL is illegal and stops parsing. When the URL is determined to be legal, the value of the params field in the URL can be analyzed to be used as an interactive parameter. It should be noted that, in the embodiment of the present application, a URL may only include a Scheme field and a params field, and the steps shown in fig. 3 are not necessarily required by the present embodiment.
Suppose a URL of "yu 4:/Jim's phone/pay? params … … ", the URL is illegal because the URL format does not conform to the specifications of the URL Scheme protocol. In case the URL is modified to "yu 4:// Jim's phone/pay? If params is … … ", the URL is legal.
After the client analyzes the interactive parameters carried by the URL through the analyzer, the analyzer can replace the analyzed updated interactive parameters with the corresponding old interactive parameters through a Native interface of the operating system. The updated interactive parameters can carry corresponding information, so that the resolver can accurately replace the new interactive parameters and the old interactive parameters according to the corresponding information.
For example, the function of the interaction control a corresponding to the interaction parameter a in the client code is to modify the avatar, the interaction control a may be as shown in fig. 1b, and if the developer needs to change the content of the option in the interaction control a shown in fig. 1b to "select from the avatar album", "shoot by itself", or "not change", the updated interaction parameter a' encapsulated in the URL by the developer may at least include the following information: "interactive control corresponding to head portrait replacement", "option contents are selected from the head portrait album, shot by oneself, and not replaced" in order. The "interactive control corresponding to the replaced avatar" is the corresponding information, and the parser can accurately replace the interactive parameter a with the interactive parameter a' according to the corresponding information.
In addition, when the native interaction control of the operating system needs to be called, the interaction parameter may further include a type of the interaction control that needs to be called, such as a view frame (uialert view) in the iOS, a visual list (UIActionSheet) in the iOS, an information view (ToastView) in the android system, and the like, which are native interaction control types provided by the operating system.
In addition, the triggering of an interactive control is often dependent on the trigger object to which it is bound. The trigger object may be a button in a user interface, a specific point in time, etc. As shown in fig. 1a, after the user clicks the button "replace avatar" in the replace avatar interface, the interactive control shown in fig. 1b pops up, and the behavior of the user clicking the button "replace avatar" is the trigger object bound by the interactive control shown in fig. 1 b.
Generally, the binding relationship between the trigger object and an interaction control is written in the client code by a developer, that is, the corresponding relationship between the trigger object and the corresponding interaction parameter is always clear. In the scheme, after the new interaction parameter carried in the URL issued by the server replaces the old interaction parameter in the client code, the trigger object corresponding to the new interaction parameter is also the trigger object corresponding to the old interaction parameter, and the binding relationship written by the developer in the client code remains unchanged.
In the embodiment of the application, a trigger object corresponding to the jump link can be determined according to the interaction parameter; and when the trigger object is monitored to be triggered, calling an interaction control according to the interaction parameters.
When the binding relationship between the URL and each trigger object has been explicitly recorded in the client code, the client may not process the URL after receiving the URL sent by the operating system, and when the trigger object corresponding to the interaction parameter carried in the URL of the client is triggered, the client starts to analyze the URL, and invokes the interaction control according to the analyzed interaction parameter.
Of course, if the binding relationship between each trigger object and the interaction control is not clear in the client code of the application, the server may also implement dynamic customization of the binding relationship between the interaction control and the trigger object by issuing the trigger object identifier associated with the URL, or adding the trigger object identifier to the encapsulated interaction parameter. The trigger object identifier may indicate a trigger object bound by the interaction control corresponding to the interaction parameter carried by the URL.
In this embodiment of the application, before the interactive parameters are analyzed from the jump link through the analyzer, the trigger object corresponding to the jump link is determined according to the jump link, and when it is monitored that the trigger object is triggered, the interactive parameters are analyzed from the jump link through the analyzer.
Specifically, before the interaction parameter is parsed from the jump link by the parser, the trigger object corresponding to the jump link may be determined in the following two ways. The first method is as follows: the trigger object identifier can be analyzed from the jump link through the analyzer, and the trigger object corresponding to the trigger object identifier is used as the trigger object corresponding to the jump link. The second method comprises the following steps: the server side can issue a trigger object identifier associated with the jump link, the client side determines a trigger object corresponding to the trigger object identifier according to the trigger object identifier associated with the jump link, and the trigger object is used as the trigger object corresponding to the jump link.
For the first mode, when the binding relationship between the URL and each trigger object is not explicitly recorded in the client code, the client may first determine the trigger object corresponding to the URL, that is, the trigger object bound to the interaction control corresponding to the interaction parameter carried by the URL, according to the trigger object identifier associated with the URL and issued by the received server, without performing processing after receiving the URL sent by the operating system.
For the second mode, when the binding relationship between the URL and each trigger object is not explicitly recorded in the client code, the interaction parameter carried by the URL issued by the server includes a trigger object identifier, and the client may analyze the trigger object identifier from the URL through an analyzer before analyzing the URL. Subsequently, when the trigger object is triggered, the client can analyze each field in the URL through the parser, and after determining that the URL is legal, the value of the params field is used as the interaction parameter. The trigger object identifier may be carried in any other field of the URL except the Scheme field.
In addition, as for the second mode, the mode of issuing the jump link and the trigger object identifier associated with the jump link by the server may be that the jump link and the trigger object identifier issued simultaneously are used as the associated jump link and trigger object identifier; or making a specific mark on the issued trigger object identifier to mark the URL associated with the trigger object identifier. In short, the manner of issuing the jump link and the trigger object identifier associated with the jump link by the server may be various, as long as the URL corresponding to the popped interactive control is the URL associated with the trigger object identifier when the trigger object determined by the client according to the trigger object identifier is triggered.
S205: and calling an interactive control according to the interactive parameters.
In the embodiment of the application, after the interactive parameters are analyzed by the analyzer, the analyzed interactive parameters are used as updated interactive parameters to replace old interactive parameters corresponding to the updated interactive parameters in the client codes, so that when the trigger object is triggered, the client calls the interactive control according to the new interactive parameters. Of course, the interaction control invoked by the client may be a native interaction control provided by the operating system, or may also be an application-defined interaction control.
In the embodiment of the application, after the application pops up the interactive control, the user clicks a certain option on the interactive control, which may cause the interactive control to exit, and the operation of the current round is finished, and may also cause a new interactive control to pop up for further interaction with the user. For example, in the scenario of changing avatars as shown in FIGS. 1a and 1b, a user clicking on any of the interactive controls shown in FIG. 1b will cause the interactive control to exit. For example, in the scenario that the user purchases on the e-commerce platform as shown in fig. 4a to 4c, the user clicks an option "delete order" corresponding to "order 1" in the interface as shown in fig. 4a in the order management interface, the application pops up an interactive control as shown in fig. 4b, the user clicks an option "determine" in the interactive control, the application may also pop up an interactive control as shown in fig. 4c to prompt the user whether to purchase the same type of goods, and when the user further clicks a "good" option in fig. 4c, the application jumps out of a purchase interface for the same type of goods.
In the above example shown in fig. 4a to 4c, after the user interacts with the interaction control in fig. 4b, the interaction control in fig. 4c pops up, and this interaction form is also the content of the interaction logic corresponding to the interaction parameter, and this content of the interaction logic can also be implemented by setting a specific interaction parameter. That is, the interaction parameters carried in one segment of URL may support the application to invoke more than one interaction control, and the interaction logic of the interaction control in fig. 4b and the interaction logic of the interaction control in fig. 4c may be covered by the interaction parameters in the same segment of URL. In addition, the interaction parameter may further include information "a certain option or button in the interaction control in fig. 4b is used as a trigger object corresponding to the interaction control in fig. 4 c".
Further, the URL carrying the interaction parameter corresponding to the interaction control in fig. 4b and the URL carrying the interaction parameter corresponding to the interaction control in fig. 4c may not be the same URL. That is to say, the application may receive two pieces of URLs sent by the server, that is, the URL1 and the URL2, the interaction parameter 1 carried in the URL1 is used to invoke the interaction control in fig. 4b, the interaction control parameter 2 carried in the URL2 is used to invoke the interaction control in fig. 4c, the application may determine the trigger object bound to the interaction control in fig. 4b according to the URL1, and determine the trigger object bound to the interaction control in fig. 4c according to the URL2, and it is worth emphasizing that the trigger object bound to the interaction control in fig. 4c may be an option or a button in the interaction control in fig. 4 b.
The scenarios shown in fig. 4a to 4c are just one of the main scenarios to which the claimed solution is applicable. In such a scenario, when a user performs complex interaction with the GUI (needs to invoke more than one, even more, interactive controls), the interactive controls to be invoked by the application are also flexible, and if the server can efficiently dynamically configure the interactive parameters corresponding to the interactive controls, powerful service support can be provided for such a scenario. The method for calling the interactive control can be used for dynamically configuring the client by the server, so that the dynamic calling of the interactive control by the client is realized.
In summary, with the method for calling an interactive control shown in fig. 2, a lightweight parser dedicated for parsing a jump link is embedded in an application client in advance, and by using a jump link protocol that is naturally supported by various operating systems, an interactive parameter for calling the interactive control is encapsulated in the jump link and sent to the application client, so that the parser parses the interactive parameter to complete the update of the client code. In this way, by embedding the parser in the client in advance, the user does not have to install the latest client frequently. In addition, the function of the parser is single and light, and the parser is specially used for parsing jump links which are naturally supported by various operating systems, so that the embedding of the parser in the client is different from the embedding of the SDK in the client, the light-weight parser cannot cause the client to be bloated, and a large amount of running memory and storage space of a mobile terminal are saved.
Based on the invoking method of the interactive control shown in fig. 2, an embodiment of the present application further provides a device for invoking the interactive control, as shown in fig. 5, a parser is embedded in the device in advance, where the parser is used to parse a jump link, and the device includes:
a first receiving module 501, configured to receive the jump link issued by the server; the skip link carries a destination device identifier and an interaction parameter, wherein the destination device identifier is the identifier of the device;
a sending module 502, configured to send the jump link to an operating system, so that the operating system returns the jump link to the device according to a destination device identifier carried in the jump link;
a second receiving module 503, receiving the jump link returned by the operating system;
the analysis module 504 is used for analyzing the interaction parameters from the jump link through the analyzer;
and the calling module 505 is used for calling the interactive control according to the interactive parameters.
The second receiving module 503 receives the jump link returned by the operating system after determining that the destination device identifier is legal.
The analysis module 504 determines values of fields in the jump link respectively through the analyzer; and when the jump link is determined to be legal according to the values of each field determined respectively, determining the value of the parameter field in the jump link as the interactive parameter.
The jump link specifically includes: jump link URL based on uniform resource location protocol URL Scheme; the parser is specifically configured to parse the URL.
The calling module 505 determines a trigger object corresponding to the jump link according to the interaction parameter; and when the trigger object is monitored to be triggered, calling an interaction control according to the interaction parameters.
The device further comprises: the determining module is used for determining a trigger object corresponding to the jump link according to the jump link before the interactive parameter is analyzed from the jump link through the analyzer;
the analysis module 504 is configured to analyze the interaction parameter from the jump link through the analyzer when it is monitored that the trigger object is triggered.
The determining module analyzes a trigger object identifier from the jump link through the analyzer; and taking the trigger object corresponding to the trigger object identifier as the trigger object corresponding to the jump link.
The first receiving module is used for receiving the jump link issued by the server and the trigger object identifier associated with the jump link;
the determining module is used for determining a trigger object corresponding to the trigger object identifier according to the trigger object identifier associated with the jump link; and taking the trigger object as a trigger object corresponding to the jump link.
In the 90 s of the 20 th century, improvements in a technology could clearly distinguish between improvements in hardware (e.g., improvements in circuit structures such as diodes, transistors, switches, etc.) and improvements in software (improvements in process flow). However, as technology advances, many of today's process flow improvements have been seen as direct improvements in hardware circuit architecture. Designers almost always obtain the corresponding hardware circuit structure by programming an improved method flow into the hardware circuit. Thus, it cannot be said that an improvement in the process flow cannot be realized by hardware physical modules. For example, a Programmable Logic Device (PLD), such as a Field Programmable Gate Array (FPGA), is an integrated circuit whose Logic functions are determined by programming the Device by a user. A digital system is "integrated" on a PLD by the designer's own programming without requiring the chip manufacturer to design and fabricate application-specific integrated circuit chips. Furthermore, nowadays, instead of manually making an Integrated Circuit chip, such Programming is often implemented by "logic compiler" software, which is similar to a software compiler used in program development and writing, but the original code before compiling is also written by a specific Programming Language, which is called Hardware Description Language (HDL), and HDL is not only one but many, such as abel (advanced Boolean Expression Language), ahdl (alternate Hardware Description Language), traffic, pl (core universal Programming Language), HDCal (jhdware Description Language), lang, Lola, HDL, laspam, hardward Description Language (vhr Description Language), vhal (Hardware Description Language), and vhigh-Language, which are currently used in most common. It will also be apparent to those skilled in the art that hardware circuitry that implements the logical method flows can be readily obtained by merely slightly programming the method flows into an integrated circuit using the hardware description languages described above.
The controller may be implemented in any suitable manner, for example, the controller may take the form of, for example, a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro) processor, logic gates, switches, an Application Specific Integrated Circuit (ASIC), a programmable logic controller, and an embedded microcontroller, examples of which include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320, the memory controller may also be implemented as part of the control logic for the memory. Those skilled in the art will also appreciate that, in addition to implementing the controller as pure computer readable program code, the same functionality can be implemented by logically programming method steps such that the controller is in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers and the like. Such a controller may thus be considered a hardware component, and the means included therein for performing the various functions may also be considered as a structure within the hardware component. Or even means for performing the functions may be regarded as being both a software module for performing the method and a structure within a hardware component.
The systems, devices, modules or units illustrated in the above embodiments may be implemented by a computer chip or an entity, or by a product with certain functions. One typical implementation device is a computer. In particular, the computer may be, for example, a personal computer, a laptop computer, a cellular telephone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
For convenience of description, the above devices are described as being divided into various units by function, and are described separately. Of course, the functionality of the units may be implemented in one or more software and/or hardware when implementing the present application.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention 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 invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams 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 a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). 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 computer storage media 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 that can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
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 an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
As will be appreciated by one skilled in the art, 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 application may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. The application may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
The above description is only an example of the present application and is not intended to limit the present application. Various modifications and changes may occur to those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.

Claims (16)

1. A calling method of an interactive control is characterized in that a parser is embedded in a client in advance and used for parsing a jump link, and the method comprises the following steps:
the client receives the jump link issued by the server; the skip link carries the identification of the client and the updated interaction parameter;
sending the jump link to an operating system so that the operating system returns the jump link to the client according to the identifier of the client carried in the jump link;
receiving the jump link returned by the operating system;
analyzing the updated interaction parameters from the jump link through the analyzer;
replacing the old interactive parameters in the client according to the updated interactive parameters so as to update the interactive control called by the client;
and calling the updated interactive control.
2. The method of claim 1, wherein receiving the jumped link returned by the operating system specifically comprises:
and receiving the jump link returned by the operating system after the identification of the client is determined to be legal.
3. The method according to claim 1, wherein the parsing the updated interaction parameters from the jump link through the parser specifically includes:
respectively determining the value of each field in the jump link through the analyzer;
and when the jump link is determined to be legal according to the values of each field determined respectively, determining the value of the parameter field in the jump link as the updated interactive parameter.
4. The method according to claim 1, wherein the jump link specifically comprises: jump link URL based on uniform resource location protocol URL Scheme;
the parser is specifically configured to parse the URL.
5. The method according to any one of claims 1 to 4, wherein invoking an interaction control according to the updated interaction parameter specifically includes:
determining a trigger object corresponding to the jump link according to the updated interaction parameter;
and when the trigger object is monitored to be triggered, calling an interactive control according to the updated interactive parameters.
6. The method according to any one of claims 1 to 4, wherein before the updated interaction parameters are parsed out from the jump link by the parser, the method further comprises:
determining a trigger object corresponding to the jump link according to the jump link;
analyzing the updated interaction parameters from the jump link through the analyzer, specifically including:
when it is monitored that the trigger object is triggered, the updated interaction parameters are analyzed from the jump link through the analyzer.
7. The method according to claim 6, wherein determining the trigger object corresponding to the jumped link according to the jumped link specifically includes:
analyzing a trigger object identifier from the jump link through the analyzer;
and taking the trigger object corresponding to the trigger object identifier as the trigger object corresponding to the jump link.
8. The method of claim 6, wherein the receiving, by the client, the jump link delivered by the server specifically includes:
the client receives the jump link and a trigger object identifier associated with the jump link issued by the server;
determining a trigger object corresponding to the jump link according to the jump link, specifically comprising:
determining a trigger object corresponding to the trigger object identifier according to the trigger object identifier associated with the jump link;
and taking the trigger object as a trigger object corresponding to the jump link.
9. An apparatus for invoking an interactive control, wherein a parser is embedded in the apparatus in advance, and the parser is configured to parse a jump link, the apparatus comprising:
the first receiving module is used for receiving the jump link issued by the server; the skip link carries the identifier of the device and the updated interaction parameter;
the sending module is used for sending the jump link to an operating system so that the operating system returns the jump link to the device according to the identifier of the device carried in the jump link;
the second receiving module is used for receiving the jump link returned by the operating system;
the analysis module is used for analyzing the updated interaction parameters from the jump link through the analyzer;
the calling module is used for replacing the old interactive parameters in the device according to the updated interactive parameters so as to update the interactive control called by the device; and calling the updated interactive control.
10. The apparatus of claim 9, wherein the second receiving module receives the jump link returned by the operating system after determining that the identification of the apparatus is legal.
11. The apparatus according to claim 9, wherein the parsing module determines values of fields in the jump link respectively through the parser; and when the jump link is determined to be legal according to the values of each field determined respectively, determining the value of the parameter field in the jump link as the updated interactive parameter.
12. The apparatus of claim 9, wherein the jump link specifically comprises: jump link URL based on uniform resource location protocol URL Scheme; the parser is specifically configured to parse the URL.
13. The device according to any one of claims 9 to 12, wherein the calling module determines a trigger object corresponding to the jump link according to the updated interaction parameter; and when the trigger object is monitored to be triggered, calling an interactive control according to the updated interactive parameters.
14. The apparatus of any one of claims 9 to 12, further comprising: the determining module is used for determining a trigger object corresponding to the skip link according to the skip link before the updated interaction parameters are analyzed from the skip link through the analyzer;
and when the analysis module monitors that the trigger object is triggered, the updated interaction parameters are analyzed from the jump link through the analyzer.
15. The apparatus of claim 14, wherein the determining module parses a trigger object identifier from the jump link through the parser; and taking the trigger object corresponding to the trigger object identifier as the trigger object corresponding to the jump link.
16. The apparatus of claim 14, wherein the first receiving module receives the jump link and a trigger object identifier associated with the jump link sent by a server;
the determining module determines a trigger object corresponding to the trigger object identifier according to the trigger object identifier associated with the jump link; and taking the trigger object as a trigger object corresponding to the jump link.
CN201611190723.8A 2016-12-21 2016-12-21 Calling method and device of interactive control Active CN107092475B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611190723.8A CN107092475B (en) 2016-12-21 2016-12-21 Calling method and device of interactive control

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611190723.8A CN107092475B (en) 2016-12-21 2016-12-21 Calling method and device of interactive control

Publications (2)

Publication Number Publication Date
CN107092475A CN107092475A (en) 2017-08-25
CN107092475B true CN107092475B (en) 2020-12-08

Family

ID=59648758

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611190723.8A Active CN107092475B (en) 2016-12-21 2016-12-21 Calling method and device of interactive control

Country Status (1)

Country Link
CN (1) CN107092475B (en)

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107679831B (en) * 2017-10-09 2021-01-08 金蝶软件(中国)有限公司 Method and related device for calling ERP function
CN107818046B (en) * 2017-10-11 2022-03-22 五八有限公司 A/B test method and device for application program page
CN109725959A (en) * 2018-05-08 2019-05-07 平安普惠企业管理有限公司 Response method, display equipment and the computer readable storage medium of page control
CN110858146B (en) * 2018-08-23 2024-04-12 阿里巴巴新加坡控股有限公司 Data processing method, apparatus and machine readable medium
CN109840146B (en) * 2019-01-16 2023-05-09 腾讯科技(深圳)有限公司 Service processing method, device, terminal and storage medium
CN110209393B (en) * 2019-04-24 2023-07-07 深圳点猫科技有限公司 Programming implementation method and device for head portrait replacement in game education
CN111274127B (en) * 2020-01-14 2023-04-07 北京百度网讯科技有限公司 Code jumping method, device, equipment and medium in code evaluation
CN113010610A (en) * 2021-04-15 2021-06-22 上海绚显科技有限公司 Data synchronization method and device
CN113660267B (en) * 2021-08-17 2022-07-26 电子科技大学 Botnet detection system, method and storage medium for IoT environment
CN114721618A (en) * 2022-03-30 2022-07-08 北京城市网邻信息技术有限公司 Display method and device of interactive control, electronic equipment and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103034546A (en) * 2012-12-17 2013-04-10 北京奇虎科技有限公司 Method and device for application programs to intercommunicate in internet work operating system (IOS)
WO2014149643A1 (en) * 2013-03-15 2014-09-25 Motorola Mobility Llc System and method for transferring software applications and data between two mobile devices with different operating systems
CN105808291A (en) * 2016-03-03 2016-07-27 腾讯科技(深圳)有限公司 Application connection method and device for terminal

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103034546A (en) * 2012-12-17 2013-04-10 北京奇虎科技有限公司 Method and device for application programs to intercommunicate in internet work operating system (IOS)
WO2014149643A1 (en) * 2013-03-15 2014-09-25 Motorola Mobility Llc System and method for transferring software applications and data between two mobile devices with different operating systems
CN105808291A (en) * 2016-03-03 2016-07-27 腾讯科技(深圳)有限公司 Application connection method and device for terminal

Also Published As

Publication number Publication date
CN107092475A (en) 2017-08-25

Similar Documents

Publication Publication Date Title
CN107092475B (en) Calling method and device of interactive control
KR102179149B1 (en) Page component dynamic layout
CN109002362B (en) Service method, device and system and electronic equipment
CN107038042B (en) Service execution method and device
CN107370778B (en) Method and system for starting application
CN107370775B (en) Method and system for starting application
CN107045438B (en) Application top view processing method, device and component
CN103970563B (en) The method of dynamic load Android class
CN111796823A (en) Method and device for updating page and displaying page and page maintenance system
CN110442327B (en) Application program construction method, device and server
CN107479868B (en) Interface loading method, device and equipment
CN108170430B (en) Interface display method and system
CN105740033A (en) Terminal equipment, plug-in loading and running device and plug-in loading and running method
CN110597564A (en) Installation package construction and service component loading method, device and terminal equipment
CN102693238B (en) Widget application process, system and multimedia terminal
CN112559934A (en) Page popup display method and device
CN109343970B (en) Application program-based operation method and device, electronic equipment and computer medium
CN110020370B (en) Method and device for realizing animation in client application and framework of animation script
CN110941443B (en) Method and device for modifying file name in SDK (software development kit) and electronic equipment
CN111090425B (en) Program packaging method and device and electronic equipment
CN110022351B (en) Service request processing method and device
CN113556260A (en) Flow monitoring method and device, storage medium and electronic equipment
CN110874322A (en) Test method and test server for application program
CN110502251B (en) Application installation method and device
CN111242731B (en) Service execution 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