CN108920333A - State-event monitoring method, state-event monitor - Google Patents

State-event monitoring method, state-event monitor Download PDF

Info

Publication number
CN108920333A
CN108920333A CN201810719745.1A CN201810719745A CN108920333A CN 108920333 A CN108920333 A CN 108920333A CN 201810719745 A CN201810719745 A CN 201810719745A CN 108920333 A CN108920333 A CN 108920333A
Authority
CN
China
Prior art keywords
self
state
event
defined control
call back
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.)
Granted
Application number
CN201810719745.1A
Other languages
Chinese (zh)
Other versions
CN108920333B (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.)
BOE Technology Group Co Ltd
Original Assignee
BOE Technology Group 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 BOE Technology Group Co Ltd filed Critical BOE Technology Group Co Ltd
Priority to CN201810719745.1A priority Critical patent/CN108920333B/en
Publication of CN108920333A publication Critical patent/CN108920333A/en
Application granted granted Critical
Publication of CN108920333B publication Critical patent/CN108920333B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/302Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a software system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3051Monitoring arrangements for monitoring the configuration of the computing system or of the computing system component, e.g. monitoring the presence of processing resources, peripherals, I/O links, software programs
    • 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)
  • Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Quality & Reliability (AREA)
  • Human Computer Interaction (AREA)
  • Mathematical Physics (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The present invention provides a kind of state-event monitoring method, state-event monitor, belongs to state-event monitoring technical field, can solve the problems, such as that user can not obtain certain state-events in the prior art.State-event monitoring method of the invention includes:Succession encapsulation carried out to each primary control in each display window being pre-designed, generates self-defined control corresponding with the primary control;Poll determines the self-defined control of current display window;Obtain the status change data of the self-defined control;State-event is determined according to the status change data.

Description

State-event monitoring method, state-event monitor
Technical field
The invention belongs to state-event monitoring technical fields, and in particular to a kind of state-event monitoring method, state-event Monitor.
Background technique
In the prior art, the case mechanism of Android (Android) system itself can usually provide big required for user Partial event state carries out software application development so that user is based on these state-events.But in some special circumstances, Android system is not provide state-event, such as when the grade of user is lower, android system will limit the user Permission, cause the user directly by android system obtain state-event it is limited, thus make the application and development of user by To very big obstruction.
Summary of the invention
The present invention is directed at least solve one of the technical problems existing in the prior art, user institute can be obtained by providing one kind Need the state-event monitoring method of state-event.
Solving technical solution used by present invention problem is a kind of state-event monitoring method, including:
Succession encapsulation is carried out to each primary control in each display window being pre-designed, is generated and the primary control The corresponding self-defined control of part;
Poll determines the self-defined control of current display window;
Obtain the status change data of the self-defined control;
State-event is determined according to the status change data.
Preferably, the status change data includes primary changes data and customized delta data;
Described the step of state-event is determined according to the status change data, including:
According to the primary changes data and customized delta data, corresponding event is determined, and determine the event State.
Preferably, the step of status change data for obtaining the self-defined control specifically includes:
The status change data of the self-defined control is obtained by call-back manner.
It is further preferred that the self-defined control is provided with call back function interface;
The status change data step for obtaining the self-defined control with the first predetermined manner specifically includes:
Corresponding readjustment is set to the binding of each self-defined control of current display window by the call back function interface Function, to obtain the status change data of each self-defined control by the call back function.
It is further preferred that the call back function includes:Primordial condition call back function and customized state callbacks function;
The status change data includes primary changes data and customized delta data;
It is described corresponding to the binding setting of each self-defined control of current display window by the call back function interface The step of call back function, status change data to obtain each self-defined control by the call back function, specifically includes:
It is corresponding primary to the binding setting of each self-defined control of current display window by the call back function interface State callbacks function, to obtain the primary changes data of each self-defined control by the primordial condition call back function;
It is made by oneself by the call back function interface to the binding setting of each self-defined control of current display window is corresponding Adopted state callbacks function, to obtain the customized delta data of each self-defined control by the customized state callbacks function.
It is further preferred that the state-event monitoring method further includes:
After the current display window is not as display window, the call back function of the self-defined control binding is released.
Solving technical solution used by present invention problem is a kind of state-event monitor, including:
Customized unit, for carrying out succession encapsulation to each primary control in each display window being pre-designed, Generate self-defined control corresponding with the primary control;
Control poll units determine the self-defined control of current display window for poll, and the self-defined control is by being Primary control in system is inherited encapsulation and is generated;
Condition Monitoring Unit, for obtaining the status change data of the self-defined control;
Event converting unit, for determining state-event according to the status change data.
Preferably, the Condition Monitoring Unit is specifically used for, and the state of the self-defined control is obtained by call-back manner Delta data.
It is further preferred that the self-defined control is provided with call back function interface;
The Condition Monitoring Unit is specifically used for, by call back function interface to the customized control of each of current display window Corresponding call back function is arranged in part binding, to obtain the status change data of each self-defined control by the call back function.
It is further preferred that the state-event monitor further includes:Call back function lifting unit, for when described current After display window is not as display window, the call back function of the self-defined control binding is released.
Detailed description of the invention
Fig. 1 is the flow chart of the state-event monitoring method of the embodiment of the present invention 1;
Fig. 2 is the flow chart of the state-event monitoring method of the embodiment of the present invention 2;
Fig. 3 is the schematic diagram of current display interface in the embodiment of the present invention 2;
Fig. 4 is the block diagram of the state-event monitor of the embodiment of the present invention 3.
Specific embodiment
Technical solution in order to enable those skilled in the art to better understand the present invention, with reference to the accompanying drawing and specific embodiment party Present invention is further described in detail for formula.
Embodiment 1:
As shown in Figure 1, can be used in Android system the present embodiment provides a kind of state-event monitoring method, according to The state change of terminal current display interface determines the current state-event of terminal, thus solve user in the process of development without The problem of state-event needed for method is obtained using the primary mechanism of system.
State-event monitoring method in the present embodiment includes the following steps:
S11, succession encapsulation is carried out to each primary control in each display window being pre-designed, generate and primary control The corresponding self-defined control of part.
The display window of terminal is made of multiple controls.In the present embodiment, by used in the real-time display window of terminal To the state change of control determine the ongoing event of terminal and state-event.But in systems due to user Permission is limited or system in script control (primary control) the reasons such as monitoring function is limited, cause user that can only obtain Partial event state.Therefore, by carrying out succession encapsulation to primary control in the present embodiment, more monitoring function are assigned for it Can, self-defined control is generated, to be monitored using self-defined control to more status change datas.Wherein, to user When carrying out inheriting encapsulation, user can select to be packaged different primary controls according to the difference of required monitoring event, Can finally obtain required state-event.
Simultaneously as the primary control that terminal when carrying out different event, is used is different, display interface is also different. For the ease of in the monitoring at the real-time display interface of terminal, the present embodiment to each in each display window being pre-designed A primary control carries out succession encapsulation, self-defined control corresponding with primary control is generated, without repeatedly being inherited Encapsulation.
It is understood that after generating self-defined control, can use these self-defined controls layout in this step Different display windows is formed, so that terminal is shown.
S12, poll determine the self-defined control of current display window.
Specifically, the control poll units of state-event monitor can be held from the decorview node of current display window Beginning poll determine current display window have which self-defined control.
S13, the status change data for obtaining self-defined control.
After control poll units determine the self-defined control of current display window, the status monitoring of state-event monitor Unit obtains the status change data of each self-defined control.Wherein, the acquisition modes of status change data can be adjusted back, be broadcasted Mode.
In the present embodiment, self-defined control is inherited from primary control, then when state-event changes, customized control Part can generate primary variation and customized variation, that is, status change data includes primary changes data and customized change Change data.
S14, state-event is determined according to status change data.
In this step, state change number that the event converting unit of state-event monitor is obtained according to Condition Monitoring Unit The ongoing event of current display window is determined according to (primary changes data and customized delta data), and determines the event State.
In state-event monitoring method provided in this embodiment, by monitor terminal current display interface it is each customized The state change of control determines event and state-event that system currently carries out, to allow users to based on current event shape The exploitation of state progress system application.
Embodiment 2:
As shown in Fig. 2, the present embodiment provides a kind of state-event monitoring method, with the event shape provided in embodiment 1 State monitoring method is similar.Wherein, it is preferred that obtain the state change number of Custom Space in the present embodiment by call-back manner According to.Below for obtaining the status change data of Custom Space by call-back manner, the state-event of the present embodiment is supervised Survey method is specifically described.
The state-event monitoring method includes the following steps:
S21, succession encapsulation is carried out to each primary control in each display window being pre-designed, generate and primary control The corresponding self-defined control of part.
This step and the S11 in embodiment 1 are almost the same, specifically refer to embodiment 1, this will not be detailed here.
Wherein, specifically, the self-defined control in the present embodiment is provided with call back function interface, for state-event prison It surveys device and call back function is arranged to self-defined control by the call back function interface, to obtain self-defined control using call back function Status change data.
S22, poll determine the self-defined control of current display window.
Specifically, the control poll units of state-event monitor can be held from the decorview node of current display window Beginning poll determine current display window have which self-defined control.
S23, the status change data that self-defined control is obtained by call-back manner.
Wherein, status change data includes primary changes data and customized delta data.
In this step, by the call back function interface of a self-defined control to each self-defined control of current display window Corresponding call back function is arranged in binding, to obtain the status change data of each self-defined control by call back function.
Specifically, step S23 includes the following steps:
S231, Condition Monitoring Unit readjustment distribution module be step S22 in control poll units determine each of make by oneself Adopted control distributes corresponding call back function.Wherein, call back function includes:Primordial condition call back function (callback_ ) and customized state callbacks function (callback_extends) original.That is, each self-defined control is assigned one A primordial condition call back function and a customized state callbacks function.
S232, Condition Monitoring Unit control bundle module by the call back function distributed in step S231 and each customized control Part binding is generated with the primordial condition function (widgetid_callback_original) of self-defined control ID and customized State callbacks function (widgetid_callback_extends).
S233, Condition Monitoring Unit readjustment setup module will distribute, binding after call back function pass through self-defined control Call back function interface be arranged to self-defined control.
It is returned that is, binding setting primordial condition to each self-defined control of current display window by call back function interface Letter of transfer number, to obtain the primary changes data of each self-defined control by the primordial condition call back function;Meanwhile by adjusting back letter Customized state callbacks function is arranged to the binding of each self-defined control of current display window in number interface, with customized by this State callbacks function obtains the customized delta data of each self-defined control.
After self-defined control sets call back function, when the variation of self-defined control generating state, primary shape can be passed through State call back function and customized state callbacks function feedback states delta data, such as following data:
S24, state-event is determined according to status change data.
The event converting unit of state-event monitor can receive the status change data of all self-defined controls, and should Status change data is converted into corresponding event.
In this step, state change number that the event converting unit of state-event monitor is obtained according to Condition Monitoring Unit The ongoing event of current display window is determined according to (primary changes data and customized delta data), and determines the event State.
Wherein, the step of status change data receives can be realized by following code:
Wherein, different according to the event monitored, event transfer function is also different.After making a phone call, other side is answered For this event, the event of answering can be determined whether by monitoring the variation of control 2 in Fig. 3.
Event transfer function code is as follows:
So far, the monitoring to the state-event of current display interface is completed in the present embodiment.User can pass through above-mentioned side The monitoring to state-event is realized, so that solving Android mobile phone in the prior art can not monitor whether other side has answered;Address list 10 contact names of middle display, if moved up a row, user can not obtain first name information;Increasing in system program Situations such as having added too many user to broadcast, caused system busy, message can not be accidentally received in.Wherein, according to user institute The difference of the event of monitoring, corresponding self-defined control, event converting unit etc. are also had nothing in common with each other.
It is further preferred that in the present embodiment, after having monitored the state-event of current display interface, and current display window After mouth is not as display window, state-event monitoring method further includes:
S25, call back function bound in self-defined control is released.
In this step, is released by the call back function lifting unit of state-event monitor and returned bound in self-defined control Letter of transfer number deletes the call back function being arranged in self-defined control, to reduce EMS memory occupation.
After terminal enters next display interface, repeating step S22 to step S25 be can be realized to new display interface The monitoring of state-event.
In state-event monitoring method provided in this embodiment, the current display interface of terminal is monitored by call-back manner The state change of each self-defined control, so that it is determined that event and state-event that system currently carries out, and then allow users to base The exploitation of system application is carried out in current event state.
Embodiment 3:
As shown in figure 4, the present embodiment provides a kind of state-event monitors, including:Customized unit, control poll list Member, Condition Monitoring Unit and event converting unit.
Wherein, customized unit is for carrying out succession envelope to each primary control in each display window being pre-designed Dress generates self-defined control corresponding with primary control.
Control poll units determine the self-defined control of current display window for poll, and self-defined control is by system Primary control is inherited encapsulation and is generated.
Condition Monitoring Unit is used to obtain the status change data of self-defined control.
Event converting unit is used to determine state-event according to status change data.
Preferably, Condition Monitoring Unit is specifically used for, and the status change data of self-defined control is obtained by call-back manner.
It is further preferred that self-defined control is provided with call back function interface;Condition Monitoring Unit is specifically used for, by returning Adjust function interface that corresponding call back function is set to the binding of each self-defined control of current display window, to pass through call back function Obtain the status change data of each self-defined control.
Preferably, Condition Monitoring Unit includes:Adjust back distribution module, control bundle module, readjustment setup module.
Wherein, the corresponding readjustment of each self-defined control distribution that readjustment distribution module is used to determine for control poll units Function.The call back function and each customized control bundle that control bundle module is used to distribute, generate and have self-defined control ID Primordial condition function and customized state callbacks function.Call back function after readjustment setup module is used to distribute, bind passes through The call back function interface of self-defined control is arranged to self-defined control.
Preferably, state-event monitor further includes:Call back function lifting unit, for when current display window not as After display window, the call back function of self-defined control binding is released.
In state-event monitor provided in this embodiment, each customized control of the current display interface by monitoring terminal The state change of part determines event and state-event that system currently carries out, to allow users to based on current event state The exploitation of carry out system application.
It is understood that the principle that embodiment of above is intended to be merely illustrative of the present and the exemplary implementation that uses Mode, however the present invention is not limited thereto.For those skilled in the art, essence of the invention is not being departed from In the case where mind and essence, various changes and modifications can be made therein, these variations and modifications are also considered as protection scope of the present invention.

Claims (10)

1. a kind of state-event monitoring method, which is characterized in that including:
Succession encapsulation is carried out to each primary control in each display window being pre-designed, is generated and the primary control phase Corresponding self-defined control;
Poll determines the self-defined control of current display window;
Obtain the status change data of the self-defined control;
State-event is determined according to the status change data.
2. state-event monitoring method according to claim 1, which is characterized in that
The status change data includes primary changes data and customized delta data;
Described the step of state-event is determined according to the status change data, including:
According to the primary changes data and customized delta data, corresponding event is determined, and determine the shape of the event State.
3. state-event monitoring method according to claim 1, which is characterized in that the acquisition self-defined control The step of status change data, specifically includes:
The status change data of the self-defined control is obtained by call-back manner.
4. state-event monitoring method according to claim 3, which is characterized in that
The self-defined control is provided with call back function interface;
The status change data step for obtaining the self-defined control with the first predetermined manner specifically includes:
Corresponding call back function is set to the binding of each self-defined control of current display window by the call back function interface, To obtain the status change data of each self-defined control by the call back function.
5. state-event monitoring method according to claim 4, which is characterized in that
The call back function includes:Primordial condition call back function and customized state callbacks function;
The status change data includes primary changes data and customized delta data;
It is described that corresponding readjustment is arranged to the binding of each self-defined control of current display window by the call back function interface The step of function, status change data to obtain each self-defined control by the call back function, specifically includes:
Corresponding primordial condition is set to the binding of each self-defined control of current display window by the call back function interface Call back function, to obtain the primary changes data of each self-defined control by the primordial condition call back function;
Corresponding customized shape is set to the binding of each self-defined control of current display window by the call back function interface State call back function, to obtain the customized delta data of each self-defined control by the customized state callbacks function.
6. state-event monitoring method according to claim 4, which is characterized in that further include:
After the current display window is not as display window, the call back function of the self-defined control binding is released.
7. a kind of state-event monitor, which is characterized in that including:
Customized unit is generated for carrying out succession encapsulation to each primary control in each display window being pre-designed Self-defined control corresponding with the primary control;
Control poll units determine the self-defined control of current display window for poll, and the self-defined control is by system Primary control inherit encapsulation generate;
Condition Monitoring Unit, for obtaining the status change data of the self-defined control;
Event converting unit, for determining state-event according to the status change data.
8. state-event monitor according to claim 7, which is characterized in that
Condition Monitoring Unit is specifically used for, and the status change data of the self-defined control is obtained by call-back manner.
9. state-event monitor according to claim 8, which is characterized in that
The self-defined control is provided with call back function interface;
The Condition Monitoring Unit is specifically used for, and is tied up by call back function interface to each self-defined control of current display window Corresponding call back function is set surely, to obtain the status change data of each self-defined control by the call back function.
10. state-event monitor according to claim 9, which is characterized in that further include:
Call back function lifting unit, for releasing the customized control after the current display window is not as display window The call back function of part binding.
CN201810719745.1A 2018-07-03 2018-07-03 Event state monitoring method and event state monitor Active CN108920333B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810719745.1A CN108920333B (en) 2018-07-03 2018-07-03 Event state monitoring method and event state monitor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810719745.1A CN108920333B (en) 2018-07-03 2018-07-03 Event state monitoring method and event state monitor

Publications (2)

Publication Number Publication Date
CN108920333A true CN108920333A (en) 2018-11-30
CN108920333B CN108920333B (en) 2022-04-22

Family

ID=64423716

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810719745.1A Active CN108920333B (en) 2018-07-03 2018-07-03 Event state monitoring method and event state monitor

Country Status (1)

Country Link
CN (1) CN108920333B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110321180A (en) * 2019-04-17 2019-10-11 浙江工业大学 A method of avoiding status poll in software design
CN112511663A (en) * 2020-11-20 2021-03-16 广州朗国电子科技有限公司 IP conflict detection method and device based on android system and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090064006A1 (en) * 2007-08-30 2009-03-05 Indran Naick Techniques for Performing Tasks Associated with Custom Folder Controls
CN103176635A (en) * 2011-12-22 2013-06-26 腾讯科技(深圳)有限公司 Multi-control touch method and system
CN104461892A (en) * 2014-12-15 2015-03-25 北京国双科技有限公司 User-defined control acquiring method and device
CN105824611A (en) * 2015-10-20 2016-08-03 广东亿迅科技有限公司 Rapid development system based on Android intelligent operation platform

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090064006A1 (en) * 2007-08-30 2009-03-05 Indran Naick Techniques for Performing Tasks Associated with Custom Folder Controls
CN103176635A (en) * 2011-12-22 2013-06-26 腾讯科技(深圳)有限公司 Multi-control touch method and system
CN104461892A (en) * 2014-12-15 2015-03-25 北京国双科技有限公司 User-defined control acquiring method and device
CN105824611A (en) * 2015-10-20 2016-08-03 广东亿迅科技有限公司 Rapid development system based on Android intelligent operation platform

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110321180A (en) * 2019-04-17 2019-10-11 浙江工业大学 A method of avoiding status poll in software design
CN112511663A (en) * 2020-11-20 2021-03-16 广州朗国电子科技有限公司 IP conflict detection method and device based on android system and storage medium

Also Published As

Publication number Publication date
CN108920333B (en) 2022-04-22

Similar Documents

Publication Publication Date Title
EP1668839B1 (en) Method, telecommuncations system and telecommunications handset for wireless communication and telecommunication in a "smart home" environment
CN109347934B (en) Message pushing method and system, server, storage medium and electronic device
US20040058644A1 (en) Relay device, information transmission device, and information transmission method
CN108833521A (en) Information push method, device, system, computer equipment and storage medium
CN112055078B (en) Data transmission method, device, computer equipment and storage medium
CN104869049B (en) Terminal information sending method and system
CN113765930B9 (en) Control method for multiparty call, client and server
CN108920333A (en) State-event monitoring method, state-event monitor
CN108650667A (en) Terminal scheduling method and apparatus
CN105227893A (en) Based on terminal call admission method and the system of on-line meeting
CN110289928A (en) Emergency public broadcasting method and system under 5G network
CN110336681A (en) A kind of matching process, device, electronic equipment and storage medium
CN104980290A (en) Method for establishing groups and server
CN104469664A (en) Bluetooth device information processing method and device
CN107454274A (en) Method and apparatus for distributing seat
CN103986824A (en) Data display method and system of electronic equipment
CN101964776A (en) Method, client and system for customizing IMS (Information Management System) service
CN110012051A (en) Notify method for pushing, device, terminal device, server and system
CN102739877A (en) End user information sharing method, calling method, and server
CN112672352A (en) Network distribution method for intelligent equipment, mesh relay node, intelligent equipment and server
CN110995780A (en) API calling method and device, storage medium and electronic equipment
CN109756497B (en) Method and system for transmitting call message, forwarding server and readable storage medium
CN108282752B (en) Method, system, device and storage medium for group callback in broadband cluster system
CN103974224A (en) Credit control method and equipment
WO2016206229A1 (en) System and method for telephone traffic test

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