WO2018161580A1 - 广播的控制方法、装置、存储介质及电子设备 - Google Patents

广播的控制方法、装置、存储介质及电子设备 Download PDF

Info

Publication number
WO2018161580A1
WO2018161580A1 PCT/CN2017/106770 CN2017106770W WO2018161580A1 WO 2018161580 A1 WO2018161580 A1 WO 2018161580A1 CN 2017106770 W CN2017106770 W CN 2017106770W WO 2018161580 A1 WO2018161580 A1 WO 2018161580A1
Authority
WO
WIPO (PCT)
Prior art keywords
broadcast
application
queue
receiver queue
registration
Prior art date
Application number
PCT/CN2017/106770
Other languages
English (en)
French (fr)
Inventor
裴润升
付亮晶
林志泳
吴汝煜
张俊
Original Assignee
广东欧珀移动通信有限公司
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 广东欧珀移动通信有限公司 filed Critical 广东欧珀移动通信有限公司
Publication of WO2018161580A1 publication Critical patent/WO2018161580A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72484User interfaces specially adapted for cordless or mobile telephones wherein functions are triggered by incoming communication events

Definitions

  • the embodiments of the present invention relate to the technical field of a broadcast mechanism, and in particular, to a broadcast control method, apparatus, storage medium, and electronic device.
  • broadcasting is a mechanism widely used to transfer information between applications.
  • the Android system notifies each application component of some system events, such as geographical change, low battery, and incoming call information, by issuing a broadcast message. These messages are usually called system broadcast messages.
  • Third-party applications can also send broadcast messages, which are called custom broadcast messages.
  • illegal applications In order to achieve some illegal purposes, illegal applications often receive self-starting by receiving various broadcasts in the background. Since the illegal application needs to occupy the broadcast queue for receiving the broadcast, the response of other applications to the broadcast is delayed, which affects the response time of other programs to the broadcast message. In addition, an illegal program starting in the background will cause system power consumption and resource consumption.
  • the embodiment of the present application provides a broadcast control method, device, storage medium, and electronic device, which can reduce system power consumption and improve resource utilization.
  • an embodiment of the present application provides a method for controlling a broadcast, where the method includes:
  • the recipient queue is optimized according to the determined illegally registered broadcast application.
  • the embodiment of the present application further provides a broadcast control apparatus, where the apparatus includes:
  • a quantity acquisition module of the broadcast type configured to acquire the number of broadcast types received by the first application registration
  • An illegal registration broadcast application determining module configured to determine whether the number of the broadcast types is greater than a first threshold; if the number of the broadcast types is greater than a first threshold, determining the first application as an illegal registration broadcast application;
  • a receiver queue obtaining module configured to acquire a receiver queue of the target broadcast
  • the receiver queue optimization module optimizes the receiver queue according to the determined illegal registration broadcast application.
  • the embodiment of the present application further provides a storage medium, where the storage medium stores a plurality of instructions, and the instructions are adapted to be loaded by a processor to perform a broadcast control method according to the first aspect. .
  • an embodiment of the present application provides an electronic device, including a memory and a processor, where the memory stores a plurality of instructions, and the processor loads the instructions in the memory to perform the following steps:
  • the recipient queue is optimized according to the determined illegally registered broadcast application.
  • the embodiment of the present application provides a broadcast control method, device, storage medium, and electronic device, which can reduce system power consumption and improve resource utilization.
  • FIG. 1 is an application scenario diagram of a method for controlling broadcast provided by an embodiment of the present application.
  • FIG. 1b is a flowchart of a method for controlling broadcast provided by an embodiment of the present application.
  • FIG. 2 is another flowchart of a method for controlling broadcast provided by an embodiment of the present application.
  • FIG. 3 is still another flowchart of a method for controlling broadcast provided by an embodiment of the present application.
  • FIG. 4 is a schematic structural diagram of a broadcast control apparatus according to an embodiment of the present application.
  • FIG. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
  • the embodiment of the present application provides a broadcast control method, including the following steps:
  • the recipient queue is optimized according to the determined illegally registered broadcast application.
  • optimizing the receiver queue according to the determined illegal registration broadcast application comprises:
  • the recipient queue is optimized according to the determined illegal registration broadcast application.
  • optimizing the receiver queue according to the determined illegal registration broadcast application comprises:
  • optimizing the receiver queue according to the determined illegal registration broadcast application comprises:
  • An associated application that has data interaction with the illegally registered broadcast application is deleted in the recipient queue.
  • optimizing the receiver queue according to the determined illegal registration broadcast application comprises:
  • the illegal registration broadcast application is in the preset application list, the illegal registration broadcast application is retained in the receiver queue.
  • optimizing the receiver queue according to the determined illegal registration broadcast application comprises:
  • the determined reception order of the illegally registered broadcast application is postponed in the receiver queue.
  • the method further includes:
  • the method for controlling the broadcast provided by the embodiment of the present application may be implemented by the broadcast control device provided by the embodiment of the present application.
  • the device may be implemented by software and/or hardware, and may be integrated into an electronic device.
  • the device can be a smart phone, a tablet, a palmtop, a laptop, and the like.
  • the specific control application of the broadcast control method in the embodiment of the present application may be as shown in FIG. 1a, for example, receiving the target broadcast of the electronic device, as an example of the control device of the broadcast provided by the embodiment of the present application.
  • application A, application B, and application C can obtain the number of broadcast types registered and received by each application, determine whether the number of broadcast types registered by each application is greater than the first threshold, and register the received broadcast type.
  • the application whose number is greater than the first threshold is determined to be an illegal registration broadcast application, and the recipient queue is optimized according to the determined illegal registration broadcast application.
  • the application A may be deleted in the receiver queue of the target broadcast, or the receiving order of the application A may be postponed in the receiver queue of the target broadcast, for example, The receiving order of application A is extended to application B or application C.
  • the broadcast control method provided by the embodiment of the present application compares the number of broadcast types received by the application with a certain value, and when it is greater than the specific value, the application is considered to be an illegal registration broadcast application, and the illegal registration is performed.
  • the broadcast application is in a broadcast receiver queue, the broadcast receiver queue is optimized to solve the problem that the illegal application receives the broadcast message and causes the system power consumption and resource consumption in the background, thereby reducing the system power consumption and improving. The effect of resource utilization.
  • a broadcast control method is provided. As shown in FIG. 1b, the embodiment can be applied to the case where the illegal registration broadcast application receives the self-starting of the registered broadcast message, and the method can be implemented by the embodiment of the present application.
  • the broadcast control device is provided to perform, as shown in FIG. 1b, the broadcast control method includes:
  • the broadcast mechanism is a message subscription/release mechanism
  • the first step in using a message-driven model such as broadcasting is to subscribe to a message, and the subscription broadcast can be to register and receive the broadcast receiver of the application.
  • the broadcast message can be sent to the application that has subscribed to the broadcast message by registering the received broadcast receiver to implement the control function of the application.
  • the self-starting of the application, data storage, and self-shutdown control can be realized.
  • the first application may be a system application or a third-party application. Since the technical solution provided by the embodiment of the present application is mainly for illegally registering a broadcast application, it mainly refers to a third-party application.
  • Broadcast types include, but are not limited to, switching, network switching, audio switching, screen brightness adjustment, and screen unlocking.
  • third-party applications can also publish broadcast messages
  • the broadcast type can also include the types of broadcast messages issued by system applications and third-party applications.
  • the system will issue a broadcast message of this type, which triggers some functions, such as the touch function of the screen, and can also open some applications, such as a boot assistant and anti-virus software.
  • the boot assistant and the anti-virus software subscribe to the broadcast message of the type, and the subscription manner may be that the broadcast receiver of the application in the above example registers and receives the broadcast message of this type.
  • the type of broadcast message subscribed by an application may include multiple, for example, an anti-virus software.
  • the subscribed broadcast message may also subscribe to the network switch type and other system applications and third-party application releases. Multiple types of broadcast messages.
  • the type of application registration to receive the broadcast message can be recorded in the broadcast receiver, and the number of broadcast types registered by the application in the broadcast receiver can be obtained by reading.
  • the number of broadcast types received by the first application registration may be stored in the broadcast receiver of the application, or the number of broadcast types received by each application registration may be stored in the system broadcast management module. In this way, when it is necessary to acquire the number of broadcast types received by the application registration, the data can be directly called.
  • the first threshold may be set before the device leaves the factory, or may be a standard value that is counted according to the amount of big data registered and received by each application in the process of using the device. For example, according to statistics, the number of broadcast types received by the general application is about 20, and the first threshold can be set to 30.
  • the manner of determining may be implemented by a comparator.
  • the illegal registration broadcast application may be configured to receive and receive more types of broadcasts in the system broadcast management module, and once the broadcast messages registered and received by the system broadcast, may be self-started after receiving the broadcast message.
  • the self-starting of the illegally registered broadcast application not only consumes system memory and energy, but also occupies the thread of the broadcast message after registering to receive the broadcast message, so that other applications respond to the broadcast message at a slower speed, and may also cause broadcast messages. The situation in which the thread being sent is congested.
  • the number of broadcast types registered by an application is 68 and the first threshold is set to 30, the number of broadcast types received by the registration of this application is significantly larger than the number of general applications, and this application can be determined. For illegal registration of broadcast applications.
  • the target broadcast can be any broadcast.
  • the target broadcast receiver queue can be obtained in the system broadcast management module.
  • the target broadcast receiver queue contains all the application lists for which the target broadcast is registered for reception.
  • the ActivityManagerService various types of broadcasts are included. All applications register the broadcast receiver to the ActivityManagerService. After the broadcast of interest to the subscriber, when the system or an application needs to publish the broadcast, the sender of the broadcast also sends the broadcast to the ActivityManagerService, and the ActivityManagerService searches for the broadcast. The recipient of this broadcast in the receiver queue then distributes the broadcast to the recipient who registered to receive the broadcast.
  • the broadcast receiver Since the broadcast receiver is in the form of a queue, in the receiver queue, if there is an illegal registration of the broadcast application and the illegal registration of the broadcast application is in the middle of the thread, other applications will obtain the broadcast message and respond. Speed is affected. Therefore, after obtaining the receiver queue, it can be determined whether the receiver queue contains an illegally registered broadcast application.
  • the receiver queue can be optimized.
  • the optimization method includes adjusting the order of the receiver queue.
  • the receiving sequence of the illegally registered broadcast application included in the receiver queue is postponed backward.
  • the advantage of this setting is that the speed of receiving and responding to the broadcast message by other applications can be increased, and one or more illegal registered broadcast applications exist in the receiver queue. Affects the speed at which other applications receive and respond to broadcast messages.
  • the optimization method may also be: in the receiver queue, the illegal registration broadcast application is deleted in the receiver queue, so that it cannot receive the broadcast message and self-start or implement other functions, so that the advantage of setting is that illegal registration of the broadcast application can be avoided.
  • the broadcast receiver queue is optimized to solve the problem that the illegal program receives the broadcast message and starts the system, which may cause system power consumption and resource consumption, thereby reducing system power consumption and improving resource utilization.
  • the broadcast control method includes:
  • the number of receiver queues is the number of applications received for the target broadcast registration. For example, for the type of broadcast that is turned off, the number of registered applications is 135, and the receiver queue is after the broadcast message of this type is turned off. The number of recipients is 135.
  • data statistics and calculations may be performed according to the time when all the recipients receive and/or respond to the broadcast message after the broadcast message is released. For example, when the number of recipients in the receiver queue is 50, the time for all recipients to receive and/or respond to the broadcast is 50 ms, and when the number of recipients in the receiver queue is 100, all recipients receive and/or respond.
  • the broadcast time is 100ms, and when the time exceeds 100ms, the user will obviously feel the system running slower, so the second threshold can be set to 100.
  • the recipient queue when the number of recipients in the receiver queue is greater than a second threshold, ie greater than 100, the recipient queue is optimized according to the determined illegal registration broadcast application.
  • the optimization manner may be to reorder the receiver queues of the above technical solution or delete the illegal registration broadcast application in the receiver queue.
  • the manner of reordering the receiver queues may be: applying the illegal registration broadcast to the receiver queue, and prepending the foreground application in the receiver queue.
  • the second threshold is set to 100
  • the receiver queue is 120
  • the receiver queue is Optimized, after optimization, other applications in the receiver queue can receive and/or respond to broadcast messages.
  • the technical solution provides a method for judging the number of receivers in the receiver queue, and reasonably optimizing the receiver queue according to the judgment result, so that the broadcast receiver queue can be optimized more effectively. It is to be noted that, if the number of receivers in the receiver queue is not greater than the second threshold, the receiver queue may be optimized and not optimized, which is not limited by the technical solution.
  • optimizing the receiver queue according to the determined illegal registration broadcast application includes deleting the determined illegal registration broadcast application in the receiver queue. This setting can solve the problem that the illegal program receives the broadcast message and starts the system, which will cause system power consumption and resource consumption, which can reduce the system power consumption and improve the resource utilization.
  • optimizing the receiver queue according to the determined illegal registration broadcast application includes deleting an associated application that has data interaction with the illegally registered broadcast application in the receiver queue.
  • the associated application that has data interaction with the illegally registered broadcast application may be another application.
  • an application A is determined to be an illegally registered broadcast application because the number of registered broadcast types exceeds a first threshold.
  • Application A has data interaction with another application B while running in the background, and if application B exists in the receiver queue, application B is deleted in the receiver queue.
  • the technical solution further optimizes the receiver queue according to the determined illegal registration broadcast application, so that the benefit of the setting is that the space of the thread of the receiver queue can be greatly saved and the space is improved.
  • the system runs at a speed, and at the same time, it can also reduce the system power consumption and improve the resource utilization.
  • the broadcast control method includes:
  • S350 Determine whether the illegal registration broadcast application in the receiver queue of the target broadcast is in the preset application list. If yes, execute S360, otherwise execute S370.
  • the preset application list may be a list of applications set before the factory or during the use of the user.
  • the preset application list may be a secure registered broadcast application that is authenticated by the system or determined according to the usage habits of the user. For example, an input method, a browser, and an image viewing application.
  • the illegal registration broadcast application is determined according to the number of broadcast categories received by the application registration, when the number of broadcast categories received by the application registration exceeds the first threshold, the application is defined as an illegally registered broadcast application. Therefore, in the process of determining the illegal registration of a broadcast application, it is highly probable that a securely used broadcast application is defined as an illegal broadcast application.
  • the setting of the preset application list can avoid the security, and register to receive more kinds of broadcast applications as illegal registration broadcast applications.
  • the illegal registration broadcast application in the recipient queue of the target broadcast is in the preset application list.
  • the illegal registration broadcast application is retained.
  • an input method is a frequently used application, and the number of broadcast types registered by the input method registration may be 50, and the first threshold is exceeded, it is defined as an illegally registered broadcast application.
  • the input method is in the preset application list, and the input method is retained in the process of optimizing the receiver queue.
  • the technical solution provides a method for protecting a security application in a receiver queue, thereby avoiding the excessive number of broadcast types registered by the security application, thereby making it illegally registered. Broadcast application processing, which causes the device to not work properly.
  • the number of broadcast types received by the registration of the first application is sent to the server, so that the server determines the number according to the number of broadcast types received by the registration of the at least one first application.
  • the first threshold is a setting for the server's big data calculation method to make the calculation result more accurate, and at the same time, the computing burden of the device itself can be reduced, and the running speed of the mobile terminal device can be improved.
  • the embodiment of the present application further provides a broadcast control apparatus, including a broadcast type quantity acquisition module, an illegal registration broadcast application determination module, a receiver queue acquisition module, and a receiver queue optimization module, as follows:
  • a quantity acquisition module of the broadcast type configured to acquire the number of broadcast types received by the first application registration
  • An illegal registration broadcast application determining module configured to determine whether the number of the broadcast types is greater than a first threshold; if the number of the broadcast types is greater than a first threshold, determining the first application as an illegal registration broadcast application;
  • a receiver queue obtaining module configured to acquire a receiver queue of the target broadcast
  • the receiver queue optimization module optimizes the receiver queue according to the determined illegal registration broadcast application.
  • the receiver queue optimization module includes:
  • a receiver quantity determining unit configured to determine whether the number of receivers in the receiver queue is greater than a second threshold
  • a receiver queue optimization unit configured to optimize the receiver queue according to the determined illegal registration broadcast application if the number of recipients in the receiver queue is greater than a second threshold.
  • the receiver queue optimization module includes:
  • An illegal registration broadcast application deletion unit is configured to delete the determined illegal registration broadcast application in the receiver queue.
  • the receiver queue optimization module includes:
  • an associated application deleting unit configured to delete, in the receiver queue, an associated application that has data interaction with the illegally registered broadcast application.
  • the receiver queue optimization module includes:
  • a preset application retention unit configured to reserve the illegally registered broadcast application in the receiver queue if the illegal registration broadcast application is in the preset application list.
  • the receiver queue optimization module includes:
  • the illegal registration broadcast application adjustment unit is configured to postpone the determined reception order of the illegal registration broadcast application in the receiver queue.
  • the broadcast control device further includes:
  • the first threshold determining module is configured to send, to the server, the number of broadcast types received by the registration of the first application, so that the server determines the first threshold according to the number of broadcast types received by the registration of the at least one first application.
  • a broadcast control device is further provided. As shown in FIG. 4, the broadcast control device includes:
  • a broadcast type quantity obtaining module 410 configured to acquire a quantity of a broadcast type that is received by the first application registration
  • the illegal registration broadcast application determining module 420 is configured to determine whether the number of the broadcast types is greater than a first threshold; if the number of the broadcast types is greater than the first threshold, determining the first application as an illegal registration broadcast application;
  • a receiver queue obtaining module 430 configured to acquire a receiver queue of the target broadcast
  • the receiver queue optimization module 440 optimizes the receiver queue according to the determined illegal registration broadcast application.
  • the broadcast receiver queue is optimized to solve the problem that the illegal program receives the broadcast message and starts the system, which may cause system power consumption and resource consumption, thereby reducing system power consumption and improving resource utilization.
  • the receiver queue optimization module 440 includes:
  • a receiver quantity determining unit configured to determine whether the number of receivers in the receiver queue is greater than a second threshold
  • a receiver queue optimization unit configured to optimize the receiver queue according to the determined illegal registration broadcast application if the number of recipients in the receiver queue is greater than a second threshold.
  • the receiver queue optimization module 440 includes:
  • An illegal registration broadcast application deletion unit is configured to delete the determined illegal registration broadcast application in the receiver queue.
  • the receiver queue optimization module 440 includes:
  • an associated application deleting unit configured to delete, in the receiver queue, an associated application that has data interaction with the illegally registered broadcast application.
  • the receiver queue optimization module 440 includes:
  • a preset application retention unit configured to reserve the illegally registered broadcast application in the receiver queue if the illegal registration broadcast application is in the preset application list.
  • the receiver queue optimization module 440 includes:
  • the illegal registration broadcast application adjustment unit is configured to postpone the determined reception order of the illegal registration broadcast application in the receiver queue.
  • the device further includes:
  • the first threshold determining module is configured to send, to the server, the number of broadcast types received by the registration of the first application, so that the server determines the first threshold according to the number of broadcast types received by the registration of the at least one first application.
  • the above products can perform any method provided by the embodiments of the present application, and have the corresponding functional modules and beneficial effects of the execution method.
  • the embodiment of the present application further provides an electronic device, including a processor and a memory, where the memory stores a plurality of instructions, and the processor loads the instructions in the memory to perform the following steps:
  • the recipient queue is optimized according to the determined illegally registered broadcast application.
  • an electronic device which may be a mobile terminal, such as a smart phone, a tablet, or the like.
  • the electronic device may include: a housing (not shown), a memory 801, and a central processing unit (Central). Processing Unit, CPU) 802 (also referred to as a processor, hereinafter referred to as CPU), a computer program, a circuit board (not shown), and a power supply circuit (not shown) stored on the memory 801 and operable on the processor 802 (not shown) Out).
  • CPU Central
  • CPU 802 also referred to as a processor, hereinafter referred to as CPU
  • the circuit board is disposed inside a space enclosed by the casing; the CPU 802 and the memory 801 are disposed on the circuit board; and the power circuit is configured to supply power to each circuit or device of the electronic device
  • the memory 801 is configured to store executable program code; the CPU 802 runs a program corresponding to the executable program code by reading executable program code stored in the memory 801 for execution:
  • the first application Obtaining, by the first application, the number of broadcast types received by the first application, determining whether the number of the broadcast types is greater than a first threshold, and determining, if the number of the broadcast types is greater than the first threshold, the first application as an illegally registered broadcast application Obtaining a receiver queue of the target broadcast; optimizing the recipient queue according to the determined illegally registered broadcast application.
  • the electronic device further includes: a peripheral interface 803, RF (Radio) Frequency, RF) circuit 805, audio circuit 806, speaker 811, power management chip 808, input/output (I/O) subsystem 809, touch screen 812, other input/control devices 810, and external port 804, these components are passed through one or A plurality of communication buses or signal lines 807 are in communication.
  • RF Radio
  • RF Radio Frequency
  • RF radio frequency
  • the illustrated electronic device 800 is merely one example of an electronic device, and that the electronic device 800 can have more or fewer components than those shown in the figures, and that two or more components can be combined, Or it can have different component configurations.
  • the various components shown in the figures can be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and/or application specific integrated circuits.
  • the following is a detailed description of an electronic device for implementing a broadcast control function provided by this embodiment.
  • the electronic device uses a mobile phone as an example.
  • the memory 801 can be accessed by the CPU 802, the peripheral interface 803, etc., and the memory 801 can include a high speed random access memory, and can also include a non-volatile memory, such as one or more magnetic disk storage devices, flash memory devices. Or other volatile solid-state storage devices.
  • a non-volatile memory such as one or more magnetic disk storage devices, flash memory devices. Or other volatile solid-state storage devices.
  • Peripheral interface 803, which can connect the input and output peripherals of the device to CPU 802 and memory 801.
  • the I/O subsystem 809 can connect input and output peripherals on the device, such as touch screen 812 and other input/control devices 810, to peripheral interface 803.
  • the I/O subsystem 809 can include a display controller 8091 and one or more input controllers 8092 for controlling other input/control devices 810.
  • one or more input controllers 8092 receive electrical signals from other input/control devices 810 or transmit electrical signals to other input/control devices 810, and other input/control devices 810 may include physical buttons (press buttons, rocker buttons, etc.) ), dial, slide switch, joystick, click wheel.
  • the input controller 8092 can be connected to any of the following: a keyboard, an infrared port, a USB interface, and a pointing device such as a mouse.
  • the touch screen 812 can be a resistive type, a capacitive inductive type, an infrared type or a surface acoustic wave type.
  • the touch screen 812 can be: external, built-in or integrated.
  • the touch screen 812 can be: a vector pressure sensing technology touch screen, a resistive technology touch screen, a capacitive technology touch screen, an infrared technology touch screen or a surface acoustic wave technology touch screen.
  • the touch screen 812 is an input interface and an output interface between the user terminal and the user, and displays the visual output to the user.
  • the visual output may include graphics, text, icons, videos, and the like.
  • the touch screen 812 sends an electrical signal (such as an electrical signal of the contact surface) triggered by the user on the touch screen to the processor 802.
  • Display controller 8091 in I/O subsystem 809 receives an electrical signal from touch screen 812 or an electrical signal to touch screen 812.
  • the touch screen 812 detects the contact on the touch screen, and the display controller 8091 converts the detected contact into an interaction with the user interface object displayed on the touch screen 812, that is, realizes human-computer interaction, and the user interface object displayed on the touch screen 812 may be running.
  • the icon of the game, the icon of the network to the corresponding network, and the like.
  • the device may also include a light mouse, which is a touch sensitive surface that does not display a visual output, or an extension of a touch sensitive surface formed by the touch screen.
  • the RF circuit 805 is mainly used for establishing communication between the mobile phone and the wireless network (ie, the network side), and realizing data reception and transmission between the mobile phone and the wireless network. For example, sending and receiving short messages, emails, and the like.
  • the audio circuit 806 is mainly used to receive audio data from the peripheral interface 803, convert the audio data into an electrical signal, and transmit the electrical signal to the speaker 811.
  • the speaker 811 is configured to restore the voice signal received by the mobile phone from the wireless network through the RF circuit 805 to sound and play the sound to the user.
  • the power management chip 808 is used for power supply and power management of the hardware connected to the CPU 802, the I/O subsystem, and the peripheral interface.
  • the central processing unit 802 is configured to:
  • the recipient queue is optimized according to the determined illegally registered broadcast application.
  • the optimizing the receiver queue according to the determined illegal registration broadcast application comprises:
  • the recipient queue is optimized according to the determined illegal registration broadcast application.
  • the optimizing the receiver queue according to the determined illegal registration broadcast application comprises:
  • the optimizing the receiver queue according to the determined illegal registration broadcast application comprises:
  • An associated application that has data interaction with the illegally registered broadcast application is deleted in the recipient queue.
  • the optimizing the receiver queue according to the determined illegal registration broadcast application comprises:
  • the illegal registration broadcast application is in the preset application list, the illegal registration broadcast application is retained in the receiver queue.
  • the optimizing the receiver queue according to the determined illegal registration broadcast application comprises:
  • the determined reception order of the illegally registered broadcast application is postponed in the receiver queue.
  • the method further includes:
  • the electronic device may further include a camera, a Bluetooth module, and the like, and details are not described herein.

Abstract

本申请实施例公开了一种广播的控制方法、装置、存储介质及电子设备。该方法包括:获取第一应用注册接收的广播类型的数量;判断所述广播类型的数量是否大于第一阈值;如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;获取目标广播的接收者队列;根据确定的所述非法注册广播应用对所述接收者队列进行优化。

Description

广播的控制方法、装置、存储介质及电子设备
本申请要求于2017年3月10日提交中国专利局、申请号为201710140649.7、发明名称为“一种广播的控制方法、装置及移动终端”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请实施例涉及广播机制技术领域,尤其涉及一种广播的控制方法、装置、存储介质及电子设备。
背景技术
在Android系统中,广播是一种广泛运用在应用程序之间传输信息的机制。Android系统通过发出广播消息,来通知各应用组件一些系统事件,如地域变换、电量不足、来电信息等,这些消息通常称为系统广播消息。第三方应用也可以发送广播消息,这些消息称为自定义广播消息。
然而,随着技术的发展,出现了一些非法应用,为达到某种非法目的,非法应用经常在后台通过接收各种各样的广播以实现自启动。由于非法应用对广播的接收需要占用广播队列,使其他应用对广播的响应滞后,影响其他程序对广播消息的响应时间。此外,非法程序在后台启动会造成系统电量消耗和资源消耗。
技术问题
本申请实施例提供一种广播的控制方法、装置、存储介质及电子设备,可以降低系统耗电,提高资源利用率。
技术解决方案
第一方面,本申请实施例提供了一种广播的控制方法,该方法包括:
获取第一应用注册接收的广播类型的数量;
判断所述广播类型的数量是否大于第一阈值;
如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
获取目标广播的接收者队列;
根据确定的所述非法注册广播应用对所述接收者队列进行优化。
第二方面,本申请实施例还提供了一种广播的控制装置,该装置包括:
广播类型的数量获取模块,用于获取第一应用注册接收的广播类型的数量;
非法注册广播应用确定模块,用于判断所述广播类型的数量是否大于第一阈值;如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
接收者队列获取模块,用于获取目标广播的接收者队列;
接收者队列优化模块,根据确定的所述非法注册广播应用对所述接收者队列进行优化。
第三方面,本申请实施例还提供了一种存储介质,所述存储介质中存储有多条指令,所述指令适于由处理器加载以执行如上述第一方面所述的广播的控制方法。
第四方面,本申请实施例提供了一种电子设备,包括存储器和处理器,所述存储器存储有多条指令,所述处理器加载所述存储器中的指令用于执行以下步骤:
获取第一应用注册接收的广播类型的数量;
判断所述广播类型的数量是否大于第一阈值;
如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
获取目标广播的接收者队列;
根据确定的所述非法注册广播应用对所述接收者队列进行优化。
有益效果
本申请实施例提供一种广播的控制方法、装置、存储介质及电子设备,可以降低系统耗电,提高资源利用率。
附图说明
图1a是本申请实施例提供的广播的控制方法的应用场景图。
图1b是本申请实施例提供的广播的控制方法的流程图。
图2是本申请实施例提供的广播的控制方法的另一流程图。
图3是本申请实施例提供的广播的控制方法的又一流程图。
图4是本申请实施例提供的广播的控制装置的结构示意图。
图5为本申请实施例提供的电子设备的结构示意图。
本发明的最佳实施方式
下面结合附图和实施例对本发明作进一步的详细说明。可以理解的是,此处所描述的具体实施例仅仅用于解释本发明,而非对本发明的限定。另外还需要说明的是,为了便于描述,附图中仅示出了与本发明相关的部分而非全部结构。
在更加详细地讨论示例性实施例之前应当提到的是,一些示例性实施例被描述成作为流程图描绘的处理或方法。虽然流程图将各步骤描述成顺序的处理,但是其中的许多步骤可以被并行地、并发地或者同时实施。此外,各步骤的顺序可以被重新安排。当其操作完成时所述处理可以被终止,但是还可以具有未包括在附图中的附加步骤。所述处理可以对应于方法、函数、规程、子例程、子程序等等。
目前的广播方案中,缺乏对非法应用接收广播消息的管控机制,非法应用可以在后台通过接收各种各样的广播消息以实现自启动,从而造成系统电量消耗和资源消耗。
本申请实施例提供了一种广播的控制方法,包括以下步骤:
获取第一应用注册接收的广播类型的数量;
判断所述广播类型的数量是否大于第一阈值;
如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
获取目标广播的接收者队列;
根据确定的所述非法注册广播应用对所述接收者队列进行优化。
一实施例中,根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
判断所述接收者队列中接收者的数量是否大于第二阈值;
如果所述接收者队列中接收者的数量大于第二阈值,则根据确定的所述非法注册广播应用对所述接收者队列进行优化。
一实施例中,根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
在所述接收者队列中删除确定的所述非法注册广播应用。
一实施例中,根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
在所述接收者队列中删除与所述非法注册广播应用存在数据交互的关联应用。
一实施例中,根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
若所述非法注册广播应用在预设应用列表中,则在所述接收者队列中保留所述非法注册广播应用。
一实施例中,根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
在所述接收者队列中将所确定的所述非法注册广播应用的接收顺序向后顺延。
一实施例中,所述方法还包括:
向服务器发送所述第一应用的注册接收的广播类型的数量,以便所述服务器根据至少一个第一应用的注册接收的广播类型的数量确定所述第一阈值。
本申请实施例提供的广播的控制方法,可以由本申请实施例所提供的广播的控制装置来执行,该装置可以由软件和/或硬件的方式来实现,并可集成于电子设备中,该电子设备可以是智能手机、平板电脑、掌上电脑、笔记本电脑等设备。
以本申请实施例提供的广播的控制装置集成于电子设备中为例,本申请实施例的广播的控制方法的一个具体应用场景,可如图1a所示,例如:电子设备的目标广播的接收者队列中,有应用A、应用B和应用C,可以获取每个应用注册接收的广播类型的数量,判断每个应用注册接收的广播类型的数量是否大于第一阈值,将注册接收的广播类型的数量大于第一阈值的应用确定为非法注册广播应用,根据确定的所述非法注册广播应用对所述接收者队列进行优化。比如:确定了应用A为非法注册广播应用,则可以在目标广播的接收者队列中删除应用A,或者可以在目标广播的接收者队列中,将应用A的接收顺序向后顺延,比如,将应用A的接收顺序延至应用B或应用C之后。
本申请实施例提供的广播的控制方法,通过对应用注册接收的广播类型的数量与某一特定值相比较,当大于这一特定值时,则认为该应用为非法注册广播应用,当非法注册广播应用在某一广播接收者队列中时,对该广播接收者队列进行优化,解决了非法应用接收到广播消息在后台自启动造成系统电量消耗和资源消耗问题,可以达到降低系统耗电,提高资源利用率的效果。
在一优选实施例中,提供了一种广播的控制方法,如图1b所示,本实施例可适用非法注册广播应用接收已注册接收的广播消息自启动的情况,该方法可以由本申请实施例所提供的广播的控制装置来执行,如图1b所示,所述广播的控制方法包括:
S110、获取第一应用注册接收的广播类型的数量。
由于广播机制是一种消息订阅/发布机制,因此,使用广播这种消息驱动模型的第一步便是订阅消息,而订阅广播可以是对应用的广播接收器进行注册接收。这样,在广播消息发出时,可以通过注册接收的广播接收器将广播消息发送到已订阅该广播消息的应用,以实现对应用程序的控制作用。其中,可以实现应用程序的自启动、数据存储以及自行关闭等控制。
第一应用可以是系统应用程序,也可以是第三方应用程序,由于本申请实施例所提供的技术方案主要是针对非法注册广播应用,所以主要是指第三方应用程序。
广播类型包括但不限于开关机、网络切换、音频切换、屏幕亮度调节以及屏幕解锁等类型。除此之外,由于第三方应用程序也能够发布广播消息,所以广播类型还可以包括由系统应用程序和第三方应用程序发出的广播消息的类型。示例性的,移动终端开机之后,系统会发布开机这种类型的广播消息,该广播消息会触发一些功能,例如屏幕的触控功能,同时还可以开启一些应用程序,例如某开机助手以及杀毒软件。其中,某开机助手以及杀毒软件就订阅开机这种类型的广播消息,订阅的方式可以是以上述示例中该应用的广播接收器针对这种类型的广播消息进行注册接收。
相应的,一个应用程序订阅的广播消息的类型可以包括多个,例如一个杀毒软件,订阅的广播消息除了开关机类型之外,还可以订阅网络切换类型以及其他系统应用程序和第三方应用程序发布的多种类型的广播消息。应用程序注册接收广播消息的类型可以记录在广播接收器中,可以通过读取方式获得广播接收器中应用程序注册接收的广播类型的数量。
第一应用注册接收的广播类型的数量可以保存在该应用的广播接收器当中,也可以将每一应用注册接收的广播类型的数量存储在系统广播管理模块当中。这样,在需要获取应用注册接收的广播类型的数量时,可以直接进行数据的调用。
S120、判断广播类型的数量是否大于第一阈值。
其中,第一阈值可以是在设备出厂前设置好的,也可以是在设备使用过程中根据各个应用程序注册接收广播类型的数量的大数据统计出来的一个标准值。例如,根据统计,得到一般应用接收的广播类型的数量在20种左右,则第一阈值可以设置为30种。
在获取到应用程序注册接收的广播类型的数量之后,判断其与第一阈值的大小关系,判断方式可以通过比较器来实现。
S130、如果广播类型的数量大于第一阈值,则将第一应用确定为非法注册广播应用。
其中,非法注册广播应用可以是在系统广播管理模块中注册接收较多类型的广播,一旦有其注册接收的广播消息发布,就可以在接收到广播消息之后自启动。非法注册广播应用的自启动不仅消耗系统内存和能源,同时其在注册接收广播消息之后,还会占用广播消息发送的线程,使得其他应用程序响应广播消息的速度变慢,同时还可能导致广播消息发送的线程拥堵的情况。
例如,当某应用注册接收的广播类型的数量为68种,将第一阈值设置为30种,则这一应用的注册接收的广播类型的数量明显大于一般应用的数量,可以将这一应用确定为非法注册广播应用。
S140、获取目标广播的接收者队列。
其中,目标广播可以是任意广播。目标广播接收者队列可以在系统广播管理模块中获取。目标广播接收者队列中,包含了所有对于这一目标广播进行注册接收的应用名单。
例如,在ActivityManagerService(活动管理器服务)中,包含了各种类型的广播。所有应用程序将广播接收器注册到ActivityManagerService中,订阅程序感兴趣的广播之后,当系统或者某应用程序需要发布广播时,广播的发送者同样是把广播发送到ActivityManagerService中,由ActivityManagerService去查找广播的接收者队列中这个广播的接收者,然后把广播分发给注册接收这个广播的接收者。
S150、根据确定的非法注册广播应用对接收者队列进行优化。
由于广播接收者是以队列形式存在线程当中,所以在接收者队列中,如果存在非法注册广播应用且非法注册广播应用在线程中位置靠前,就会导致其他应用获取广播消息并做出响应的速度受到影响。因此,在获取到接收者队列后,可以判断接收者队列是否含有非法注册广播应用,当含有非法注册广播应用时,可以对接收者队列进行优化,优化的方式包括调整接收者队列的顺序,将接收者队列中包含的非法注册广播应用的接收顺序向后顺延,这样设置的好处是可以使其他应用接收和响应广播消息的速度增快,避免接收者队列中存在一个或者多个非法注册广播应用影响其他应用接收和响应广播消息的速度。优化方式还可以是在接收者队列中,将非法注册广播应用在接收者队列中删除,使其不能够接收到广播消息并自启动或者实现其他功能,这样设置的好处是可以避免非法注册广播应用对线程资源的占用,并能够解决非法注册广播应用进行自启动或做出其他响应占用系统资源和耗费能源的问题。
本实施例的技术方案,通过对于应用注册接收的广播类型的数量与某一特定值相比较,当大于这一特定值时,则认为该应用为非法注册广播应用,当非法注册广播应用在某一广播接收者队列中时,对该广播接收者队列进行优化,解决非法程序接收到广播消息在后台启动会造成系统电量消耗和资源消耗问题,可以实现降低系统耗电,提高资源利用率的效果。
在一优选实施例中,提供了另一种广播的控制方法,如图2所示,所述广播的控制方法包括:
S210、获取第一应用注册接收的广播类型的数量。
S220、判断广播类型的数量是否大于第一阈值。
S230、如果广播类型的数量大于第一阈值,则将第一应用确定为非法注册广播应用。
S240、获取目标广播的接收者队列。
S250、判断接收者队列中接收者的数量是否大于第二阈值。
接收者队列的数量就是对于目标广播注册接收应用的数量,例如对于关机这种类型的广播,注册接收的应用的数量是135个,则在关机这种类型的广播消息发布后,接收者队列中接收者的数量就是135个。
对于接收者数量设定的第二阈值,可以是根据广播消息发布后所有接收者全部接收和/或响应广播消息的时间进行数据统计和计算得到的。例如,当接收者队列中接收者数量为50个时,所有接收者接收和/或响应广播的时间为50ms,当接收者队列中接收者数量为100个时,所有接收者接收和/或响应广播的时间为100ms,而在时间超过100ms时,用户会明显感受到系统运行速度变慢,所以,则可以将第二阈值设置为100。
S260、如果接收者队列中接收者的数量大于第二阈值,则根据确定的非法注册广播应用对接收者队列进行优化。
结合上述示例,当接收者队列中接收者的数量大于第二阈值,即大于100时,则根据确定的非法注册广播应用对接收者队列进行优化。优化方式可以为上述技术方案的将接收者队列重新排序或者将非法注册广播应用在接收者队列中删除。其中,将接收者队列重新排序的方式具体可以是:将非法注册广播应用在接收者队列中后置,以及将前台应用程序在接收者队列中前置。
例如,第二阈值设置为100,当接收者队列中接收者数量为120时,在判断接收者数量超过第二阈值之后,获取接收者队列中非法注册广播应用有25个,则对接收者队列进行优化,优化之后接收者队列中其他应用程序就可以正常接收和/或响应广播消息。
在上述技术方案的基础上,本技术方案提供了对接收者队列中接收者数量进行判断,并根据判断结果对接收者队列进行合理优化,可以更加有效的进行广播接收者队列的优化。值得说明的是,如果接收者队列中接收者数量不大于第二阈值时,则可以选择对接收者队列进行优化和不优化,本技术方案不对其做限定。
在上述各个方案的基础上,优选的,根据确定的非法注册广播应用对接收者队列进行优化包括:在所述接收者队列中删除确定的非法注册广播应用。这样设置可以解决非法程序接收到广播消息在后台启动会造成系统电量消耗和资源消耗问题,可以实现降低系统耗电,提高资源利用率的效果。
在上述各个方案的基础上,优选的,根据确定的非法注册广播应用对接收者队列进行优化包括:在所述接收者队列中删除与所述非法注册广播应用存在数据交互的关联应用。
其中,与所述非法注册广播应用存在数据交互的关联应用,可以是其他应用程序,例如某应用程序A由于注册接收广播种类的数量超出了第一阈值,被确定为非法注册广播应用,这一应用程序A在后台运行时与另一应用程序B存在数据交互,在接收者队列中如果存在应用程序B,则将应用程序B在接收者队列中删除。
此技术方案在上述各个技术方案的基础上,对根据确定的非法注册广播应用对接收者队列进行优化进行了进一步的优化,这样设置的好处是可以大幅度节省接收者队列所在线程的空间,提高系统运行速度,同时还可以实现降低系统耗电,提高资源利用率的效果。
在一优选实施例中,提供了又一种广播的控制方法,如图3所示,所述广播的控制方法包括:
S310、获取第一应用注册接收的广播类型的数量。
S320、判断广播类型的数量是否大于第一阈值。
S330、如果广播类型的数量大于第一阈值,则将第一应用确定为非法注册广播应用。
S340、获取目标广播的接收者队列。
S350、判断目标广播的接收者队列中非法注册广播应用是否在预设应用列表中。若是则执行S360,若否则执行S370。
其中,预设应用列表可以是在出厂前或者在用户使用过程中设置的应用列表,预设应用列表中,可以是经过系统认证或者根据用户的使用习惯确定的安全注册广播应用。例如某输入法、某浏览器以及某图片查看应用等。
因为非法注册广播应用是根据应用注册接收的广播种类的数量来确定的,当应用注册接收的广播种类的数量超过第一阈值时,则将该应用定义为非法注册广播应用。所以,在非法注册广播应用的确定过程中,很有可能把安全的经常用到的广播应用定义为非法广播应用。预设应用列表的设置就可以避免将安全的,而又注册接收较多种类的广播应用作为非法注册广播应用来处理。
S360、在接收者队列中保留非法注册广播应用。
当判断目标广播的接收者队列中非法注册广播应用在预设应用列表中时,则保留所述非法注册广播应用。示例性的,由于某输入法为经常用到的应用程序,而该输入法注册接收的广播类型的数量可能是50种,超过了第一阈值30种,则将其定义为非法注册广播应用。而该输入法又在预设应用列表中,在对所述接收者队列进行优化的过程中,保留该输入法。
S370、根据确定的所述非法注册广播应用对所述接收者队列进行优化。
此技术方案在上述各个技术方案的基础上,提供了一种对于安全应用在接收者队列中进行保护的方法,避免了因安全应用注册接收广播类型的数量过多,而使其被作为非法注册广播应用处理,从而导致设备无法正常使用的问题。
在上述各个技术方案的基础上,优选的,向服务器发送所述第一应用的注册接收的广播类型的数量,以便所述服务器根据至少一个第一应用的注册接收的广播类型的数量确定所述第一阈值。这样设置的好处是可以利用服务器的大数据计算方法使计算结果更为准确,同时能够减少设备自身的运算负担,提高移动终端设备运行速度。
本申请实施例还提供了一种广播的控制装置,包括广播类型的数量获取模块、非法注册广播应用确定模块、接收者队列获取模块以及接收者队列优化模块,如下:
广播类型的数量获取模块,用于获取第一应用注册接收的广播类型的数量;
非法注册广播应用确定模块,用于判断所述广播类型的数量是否大于第一阈值;如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
接收者队列获取模块,用于获取目标广播的接收者队列;
接收者队列优化模块,根据确定的所述非法注册广播应用对所述接收者队列进行优化。
一实施例中,所述接收者队列优化模块包括:
接收者数量判断单元,用于判断所述接收者队列中接收者的数量是否大于第二阈值;
接收者队列优化单元,用于如果所述接收者队列中接收者的数量大于第二阈值,则根据确定的所述非法注册广播应用对所述接收者队列进行优化。
一实施例中,所述接收者队列优化模块包括:
非法注册广播应用删除单元,用于在所述接收者队列中删除确定的所述非法注册广播应用。
一实施例中,所述接收者队列优化模块包括:
关联应用删除单元,用于在所述接收者队列中删除与所述非法注册广播应用存在数据交互的关联应用。
一实施例中,所述接收者队列优化模块包括:
预设应用保留单元,用于若所述非法注册广播应用在预设应用列表中,则在所述接收者队列中保留所述非法注册广播应用。
一实施例中,所述接收者队列优化模块包括:
非法注册广播应用调整单元,用于在所述接收者队列中将所确定的所述非法注册广播应用的接收顺序向后顺延。
一实施例中,所述广播的控制装置还包括:
第一阈值确定模块,用于向服务器发送所述第一应用的注册接收的广播类型的数量,以便所述服务器根据至少一个第一应用的注册接收的广播类型的数量确定所述第一阈值。
在一优选实施例中,还提供一种广播的控制装置,如图4所示,所述广播的控制装置,包括:
广播类型的数量获取模块410,用于获取第一应用注册接收的广播类型的数量;
非法注册广播应用确定模块420,用于判断所述广播类型的数量是否大于第一阈值;如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
接收者队列获取模块430,用于获取目标广播的接收者队列;
接收者队列优化模块440,根据确定的所述非法注册广播应用对所述接收者队列进行优化。
本实施例的技术方案,通过对于应用注册接收的广播类型的数量与某一特定值相比较,当大于这一特定值时,则认为该应用为非法注册广播应用,当非法注册广播应用在某一广播接收者队列中时,对该广播接收者队列进行优化,解决非法程序接收到广播消息在后台启动会造成系统电量消耗和资源消耗问题,可以实现降低系统耗电,提高资源利用率的效果。
在上述各方案的基础上,所述接收者队列优化模块440包括:
接收者数量判断单元,用于判断所述接收者队列中接收者的数量是否大于第二阈值;
接收者队列优化单元,用于如果所述接收者队列中接收者的数量大于第二阈值,则根据确定的所述非法注册广播应用对所述接收者队列进行优化。
在上述各方案的基础上,所述接收者队列优化模块440包括:
非法注册广播应用删除单元,用于在所述接收者队列中删除确定的所述非法注册广播应用。
在上述各方案的基础上,所述接收者队列优化模块440包括:
关联应用删除单元,用于在所述接收者队列中删除与所述非法注册广播应用存在数据交互的关联应用。
在上述各方案的基础上,所述接收者队列优化模块440包括:
预设应用保留单元,用于若所述非法注册广播应用在预设应用列表中,则在所述接收者队列中保留所述非法注册广播应用。
在上述各方案的基础上,所述接收者队列优化模块440包括:
非法注册广播应用调整单元,用于在所述接收者队列中将所确定的所述非法注册广播应用的接收顺序向后顺延。
在上述各方案的基础上,所述装置还包括:
第一阈值确定模块,用于向服务器发送所述第一应用的注册接收的广播类型的数量,以便所述服务器根据至少一个第一应用的注册接收的广播类型的数量确定所述第一阈值。
上述产品可执行本申请实施例所提供的任意方法,具备执行方法相应的功能模块和有益效果。
本申请实施例还提供一种电子设备,包括处理器和存储器,所述存储器存储有多条指令,所述处理器加载所述存储器中的指令用于执行以下步骤:
获取第一应用注册接收的广播类型的数量;
判断所述广播类型的数量是否大于第一阈值;
如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
获取目标广播的接收者队列;
根据确定的所述非法注册广播应用对所述接收者队列进行优化。
在一优选实施例中,还提供一种电子设备,该电子设备可以是移动终端,比如可以是智能手机、平板电脑等设备。如图5所示,该电子设备可以包括:壳体(图中未示出)、存储器801、中央处理器(Central Processing Unit,CPU)802(又称处理器,以下简称CPU)、存储在存储器801上并可在处理器802上运行的计算机程序、电路板(图中未示出)和电源电路(图中未示出)。所述电路板安置在所述壳体围成的空间内部;所述CPU802和所述存储器801设置在所述电路板上;所述电源电路,用于为所述电子设备的各个电路或器件供电;所述存储器801,用于存储可执行程序代码;所述CPU802通过读取所述存储器801中存储的可执行程序代码来运行与所述可执行程序代码对应的程序,以用于执行:
获取第一应用注册接收的广播类型的数量;判断所述广播类型的数量是否大于第一阈值;如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;获取目标广播的接收者队列;根据确定的所述非法注册广播应用对所述接收者队列进行优化。
所述电子设备还包括:外设接口803、RF(Radio Frequency,射频)电路805、音频电路806、扬声器811、电源管理芯片808、输入/输出(I/O)子系统809、触摸屏812、其他输入/控制设备810以及外部端口804,这些部件通过一个或多个通信总线或信号线807来通信。
应该理解的是,图示电子设备800仅仅是电子设备的一个范例,并且电子设备800可以具有比图中所示出的更多的或者更少的部件,可以组合两个或更多的部件,或者可以具有不同的部件配置。图中所示出的各种部件可以在包括一个或多个信号处理和/或专用集成电路在内的硬件、软件、或硬件和软件的组合中实现。
下面就本实施例提供的用于实现广播控制功能的电子设备进行详细的描述,该电子设备以手机为例。
存储器801,所述存储器801可以被CPU802、外设接口803等访问,所述存储器801可以包括高速随机存取存储器,还可以包括非易失性存储器,例如一个或多个磁盘存储器件、闪存器件、或其他易失性固态存储器件。
外设接口803,所述外设接口803可以将设备的输入和输出外设连接到CPU802和存储器801。
I/O子系统809,所述I/O子系统809可以将设备上的输入输出外设,例如触摸屏812和其他输入/控制设备810,连接到外设接口803。I/O子系统809可以包括显示控制器8091和用于控制其他输入/控制设备810的一个或多个输入控制器8092。其中,一个或多个输入控制器8092从其他输入/控制设备810接收电信号或者向其他输入/控制设备810发送电信号,其他输入/控制设备810可以包括物理按钮(按压按钮、摇臂按钮等)、拨号盘、滑动开关、操纵杆、点击滚轮。值得说明的是,输入控制器8092可以与以下任一个连接:键盘、红外端口、USB接口以及诸如鼠标的指示设备。
其中,按照触摸屏的工作原理和传输信息的介质分类,触摸屏812可以为电阻式、电容感应式、红外线式或表面声波式。按照安装方式分类,触摸屏812可以为:外挂式、内置式或整体式。按照技术原理分类,触摸屏812可以为:矢量压力传感技术触摸屏、电阻技术触摸屏、电容技术触摸屏、红外线技术触摸屏或表面声波技术触摸屏。
触摸屏812,所述触摸屏812是用户终端与用户之间的输入接口和输出接口,将可视输出显示给用户,可视输出可以包括图形、文本、图标、视频等。可选的,触摸屏812将用户在触屏幕上触发的电信号(如接触面的电信号),发送给处理器802。
I/O子系统809中的显示控制器8091从触摸屏812接收电信号或者向触摸屏812发送电信号。触摸屏812检测触摸屏上的接触,显示控制器8091将检测到的接触转换为与显示在触摸屏812上的用户界面对象的交互,即实现人机交互,显示在触摸屏812上的用户界面对象可以是运行游戏的图标、联网到相应网络的图标等。值得说明的是,设备还可以包括光鼠,光鼠是不显示可视输出的触摸敏感表面,或者是由触摸屏形成的触摸敏感表面的延伸。
RF电路805,主要用于建立手机与无线网络(即网络侧)的通信,实现手机与无线网络的数据接收和发送。例如收发短信息、电子邮件等。
音频电路806,主要用于从外设接口803接收音频数据,将该音频数据转换为电信号,并且将该电信号发送给扬声器811。
扬声器811,用于将手机通过RF电路805从无线网络接收的语音信号,还原为声音并向用户播放该声音。
电源管理芯片808,用于为CPU802、I/O子系统及外设接口所连接的硬件进行供电及电源管理。
在本实施例中,中央处理器802用于:
获取第一应用注册接收的广播类型的数量;
判断所述广播类型的数量是否大于第一阈值;
如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
获取目标广播的接收者队列;
根据确定的所述非法注册广播应用对所述接收者队列进行优化。
进一步的,所述根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
判断所述接收者队列中接收者的数量是否大于第二阈值;
如果所述接收者队列中接收者的数量大于第二阈值,则根据确定的所述非法注册广播应用对所述接收者队列进行优化。
进一步的,所述根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
在所述接收者队列中删除确定的所述非法注册广播应用。
进一步的,所述根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
在所述接收者队列中删除与所述非法注册广播应用存在数据交互的关联应用。
进一步的,所述根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
若所述非法注册广播应用在预设应用列表中,则在所述接收者队列中保留所述非法注册广播应用。
进一步的,所述根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
在所述接收者队列中将所确定的所述非法注册广播应用的接收顺序向后顺延。
进一步的,所述方法还包括:
向服务器发送所述第一应用的注册接收的广播类型的数量,以便所述服务器根据至少一个第一应用的注册接收的广播类型的数量确定所述第一阈值。
需要说明的是,电子设备还可以包括摄像头、蓝牙模块等,在此不再赘述。
注意,上述仅为本发明的较佳实施例及所运用技术原理。本领域技术人员会理解,本发明不限于这里所述的特定实施例,对本领域技术人员来说能够进行各种明显的变化、重新调整和替代而不会脱离本发明的保护范围。因此,虽然通过以上实施例对本发明进行了较为详细的说明,但是本发明不仅仅限于以上实施例,在不脱离本发明构思的情况下,还可以包括更多其他等效实施例,而本发明的范围由所附的权利要求范围决定。

Claims (20)

  1. 一种广播的控制方法,其中,包括:
    获取第一应用注册接收的广播类型的数量;
    判断所述广播类型的数量是否大于第一阈值;
    如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
    获取目标广播的接收者队列;
    根据确定的所述非法注册广播应用对所述接收者队列进行优化。
  2. 根据权利要求1所述的广播的控制方法,其中,所述根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
    判断所述接收者队列中接收者的数量是否大于第二阈值;
    如果所述接收者队列中接收者的数量大于第二阈值,则根据确定的所述非法注册广播应用对所述接收者队列进行优化。
  3. 根据权利要求1或2所述的广播的控制方法,其中,所述根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
    在所述接收者队列中删除确定的所述非法注册广播应用。
  4. 根据权利要求3所述的广播的控制方法,其中,所述根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
    在所述接收者队列中删除与所述非法注册广播应用存在数据交互的关联应用。
  5. 根据权利要求3所述的广播的控制方法,其中,所述根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
    若所述非法注册广播应用在预设应用列表中,则在所述接收者队列中保留所述非法注册广播应用。
  6. 根据权利要求1或2所述的广播的控制方法,其中,所述根据确定的所述非法注册广播应用对所述接收者队列进行优化,包括:
    在所述接收者队列中将所确定的所述非法注册广播应用的接收顺序向后顺延。
  7. 根据权利要求1所述的广播的控制方法,其中,还包括:
    向服务器发送所述第一应用的注册接收的广播类型的数量,以便所述服务器根据至少一个第一应用的注册接收的广播类型的数量确定所述第一阈值。
  8. 一种广播的控制装置,其中,包括:
    广播类型的数量获取模块,用于获取第一应用注册接收的广播类型的数量;
    非法注册广播应用确定模块,用于判断所述广播类型的数量是否大于第一阈值;如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
    接收者队列获取模块,用于获取目标广播的接收者队列;
    接收者队列优化模块,根据确定的所述非法注册广播应用对所述接收者队列进行优化。
  9. 根据权利要求8所述的广播的控制装置,其中,所述接收者队列优化模块包括:
    接收者数量判断单元,用于判断所述接收者队列中接收者的数量是否大于第二阈值;
    接收者队列优化单元,用于如果所述接收者队列中接收者的数量大于第二阈值,则根据确定的所述非法注册广播应用对所述接收者队列进行优化。
  10. 根据权利要求8或9所述的广播的控制装置,其中,所述接收者队列优化模块包括:
    非法注册广播应用删除单元,用于在所述接收者队列中删除确定的所述非法注册广播应用。
  11. 根据权利要求10所述的广播的控制装置,其中,所述接收者队列优化模块包括:
    关联应用删除单元,用于在所述接收者队列中删除与所述非法注册广播应用存在数据交互的关联应用。
  12. 根据权利要求10所述的广播的控制装置,其中,所述接收者队列优化模块包括:
    预设应用保留单元,用于若所述非法注册广播应用在预设应用列表中,则在所述接收者队列中保留所述非法注册广播应用。
  13. 一种存储介质,其中,所述存储介质中存储有多条指令,所述指令适于由处理器加载以执行如权利要求1至7任一项所述的广播的控制方法。
  14. 一种电子设备,其中,包括处理器和存储器,所述存储器存储有多条指令,所述处理器加载所述存储器中的指令用于执行以下步骤:
    获取第一应用注册接收的广播类型的数量;
    判断所述广播类型的数量是否大于第一阈值;
    如果所述广播类型的数量大于第一阈值,则将所述第一应用确定为非法注册广播应用;
    获取目标广播的接收者队列;
    根据确定的所述非法注册广播应用对所述接收者队列进行优化。
  15. 根据权利要求14所述的电子设备,其中,在所述根据确定的所述非法注册广播应用对所述接收者队列进行优化时,所述处理器具体用于执行以下步骤:
    判断所述接收者队列中接收者的数量是否大于第二阈值;
    如果所述接收者队列中接收者的数量大于第二阈值,则根据确定的所述非法注册广播应用对所述接收者队列进行优化。
  16. 根据权利要求14或15所述的电子设备,其中,在根据确定的所述非法注册广播应用对所述接收者队列进行优化时,所述处理器具体用于执行以下步骤:
    在所述接收者队列中删除确定的所述非法注册广播应用。
  17. 根据权利要求16所述的电子设备,其中,在根据确定的所述非法注册广播应用对所述接收者队列进行优化时,所述处理器还用于执行以下步骤:
    在所述接收者队列中删除与所述非法注册广播应用存在数据交互的关联应用。
  18. 根据权利要求16所述的电子设备,其中,在根据确定的所述非法注册广播应用对所述接收者队列进行优化时,所述处理器还用于执行以下步骤:
    若所述非法注册广播应用在预设应用列表中,则在所述接收者队列中保留所述非法注册广播应用。
  19. 根据权利要求14或15所述的电子设备,其中,在根据确定的所述非法注册广播应用对所述接收者队列进行优化时,所述处理器具体用于执行以下步骤:
    在所述接收者队列中将所确定的所述非法注册广播应用的接收顺序向后顺延。
  20. 根据权利要求14所述的电子设备,其中,所述处理器还用于执行以下步骤:
    向服务器发送所述第一应用的注册接收的广播类型的数量,以便所述服务器根据至少一个第一应用的注册接收的广播类型的数量确定所述第一阈值。
PCT/CN2017/106770 2017-03-10 2017-10-18 广播的控制方法、装置、存储介质及电子设备 WO2018161580A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201710140649.7A CN106851014B (zh) 2017-03-10 2017-03-10 调整广播消息队列的方法、装置及终端
CN201710140649.7 2017-03-10

Publications (1)

Publication Number Publication Date
WO2018161580A1 true WO2018161580A1 (zh) 2018-09-13

Family

ID=59143919

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/106770 WO2018161580A1 (zh) 2017-03-10 2017-10-18 广播的控制方法、装置、存储介质及电子设备

Country Status (2)

Country Link
CN (1) CN106851014B (zh)
WO (1) WO2018161580A1 (zh)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106899943B (zh) * 2017-03-10 2019-12-06 Oppo广东移动通信有限公司 控制广播发送者发送广播消息的方法、装置和终端设备
CN106921947B (zh) * 2017-03-10 2020-09-29 Oppo广东移动通信有限公司 调整广播消息队列的方法、装置及终端
CN106844069A (zh) * 2017-03-10 2017-06-13 广东欧珀移动通信有限公司 调整广播消息队列的方法、装置及终端
CN108093385B (zh) * 2017-12-26 2021-06-01 海信视像科技股份有限公司 蓝牙控制器处理广播包的方法、蓝牙控制器和蓝牙设备
CN109150753B (zh) * 2018-08-01 2022-04-22 新华三技术有限公司 消息分发方法及装置
CN110633161B (zh) * 2019-09-19 2022-09-02 北京安云世纪科技有限公司 一种广播的处理方法及装置
CN116088714A (zh) * 2022-05-26 2023-05-09 荣耀终端有限公司 消息提示框处理方法和相关装置

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120304229A1 (en) * 2011-05-26 2012-11-29 Choi Gowoon Display apparatus for processing multiple applications and method for controlling the same
CN104994481A (zh) * 2015-07-10 2015-10-21 上海斐讯数据通信技术有限公司 一种Android系统中应用程序之间广播消息的收发方法及系统
CN105208590A (zh) * 2015-08-17 2015-12-30 广东欧珀移动通信有限公司 移动终端操作系统卡顿异常的检测恢复方法及移动终端
CN106844070A (zh) * 2017-03-10 2017-06-13 广东欧珀移动通信有限公司 一种广播的控制方法、装置及移动终端
CN106937258A (zh) * 2017-03-10 2017-07-07 广东欧珀移动通信有限公司 一种广播的控制方法、装置及移动终端

Family Cites Families (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100309997B1 (ko) * 1999-10-11 2001-09-29 윤종용 멀티태스킹 환경에서의 인터태스크 통신 방법
US6728722B1 (en) * 2000-08-28 2004-04-27 Sun Microsystems, Inc. General data structure for describing logical data spaces
US8595748B1 (en) * 2007-12-21 2013-11-26 Ibiquity Digital Corporation Systems and methods for transmitting and receiving large objects via digital radio broadcast
CN103425225B (zh) * 2012-05-16 2015-08-19 腾讯科技(深圳)有限公司 便携数据设备操作系统中的应用程序装置及其运行方法
CN102855148A (zh) * 2012-08-02 2013-01-02 广东欧珀移动通信有限公司 一种基于Android的开机管理方法
CA2895848C (en) * 2012-12-20 2019-01-08 Georgia State University Research Foundation, Inc. Parallel priority queue utilizing parallel heap on many-core processors for accelerating priority-queue-based applications
CN105357648A (zh) * 2015-10-10 2016-02-24 上海斐讯数据通信技术有限公司 向应用程序发送广播消息的方法及Android系统
CN105611046B (zh) * 2015-12-17 2016-11-23 福建六壬网安股份有限公司 一种策略定制的安卓手机安全保护系统及其保护方法
CN105786973A (zh) * 2016-02-02 2016-07-20 重庆秒盈电子商务有限公司 基于大数据技术的数据并发处理方法及系统
CN106201740A (zh) * 2016-06-29 2016-12-07 北京金山安全软件有限公司 一种广播消息管理方法、装置及设备
CN106407021A (zh) * 2016-07-01 2017-02-15 厦门易名科技股份有限公司 一种基于队列的业务请求处理方法
CN106293964A (zh) * 2016-07-29 2017-01-04 青岛海信移动通信技术股份有限公司 一种应用程序的调用方法及装置

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120304229A1 (en) * 2011-05-26 2012-11-29 Choi Gowoon Display apparatus for processing multiple applications and method for controlling the same
CN104994481A (zh) * 2015-07-10 2015-10-21 上海斐讯数据通信技术有限公司 一种Android系统中应用程序之间广播消息的收发方法及系统
CN105208590A (zh) * 2015-08-17 2015-12-30 广东欧珀移动通信有限公司 移动终端操作系统卡顿异常的检测恢复方法及移动终端
CN106844070A (zh) * 2017-03-10 2017-06-13 广东欧珀移动通信有限公司 一种广播的控制方法、装置及移动终端
CN106937258A (zh) * 2017-03-10 2017-07-07 广东欧珀移动通信有限公司 一种广播的控制方法、装置及移动终端

Also Published As

Publication number Publication date
CN106851014B (zh) 2020-06-30
CN106851014A (zh) 2017-06-13

Similar Documents

Publication Publication Date Title
WO2018161580A1 (zh) 广播的控制方法、装置、存储介质及电子设备
WO2018161576A1 (zh) 一种广播的控制方法、装置、存储介质及移动终端
WO2018161585A1 (zh) 电子设备帧率的控制方法、装置、存储介质及电子设备
WO2018076867A1 (zh) 数据备份的删除方法、装置、系统、存储介质和服务器
WO2018161581A1 (zh) 控制广播发送的方法、装置、存储介质及电子设备
WO2018076861A1 (zh) 数据传输的控制方法、装置、存储介质、服务器及系统
WO2018161604A1 (zh) 移动终端的播放控制方法、装置、存储介质及电子设备
WO2018076812A1 (zh) 数据请求的响应方法、装置、存储介质、服务器及系统
WO2018161588A1 (zh) 广播接收者队列调整方法、装置、存储介质及电子设备
WO2018021678A1 (en) Electronic device and method for operating the same
WO2020246822A1 (en) Electronic device and method for switching electronic device between dual standby mode and single standby mode
WO2018076819A1 (zh) 数据的上传方法、装置、存储介质、电子设备及系统
WO2018161593A1 (zh) 广播处理方法、装置、存储介质和终端设备
WO2018076889A1 (zh) 数据备份的方法、装置、系统、存储介质及服务器
WO2017206878A1 (zh) 一种基于唤醒锁的处理方法、装置、存储介质及电子设备
WO2018166199A1 (zh) 定位精度等级调整方法、装置、存储介质及电子设备
WO2017206862A1 (zh) 一种基于亮屏锁的处理方法、装置、存储介质及电子设备
WO2018161602A1 (zh) 电子设备帧率的控制方法、装置、存储介质及电子设备
WO2018161575A1 (zh) 调整广播消息队列的方法、装置、存储介质及终端
WO2018076869A1 (zh) 一种数据备份方法、装置、存储介质和电子设备
WO2018161601A1 (zh) 屏幕背光调节方法、装置、存储介质及电子设备
WO2017206885A1 (zh) 应用程序的关闭方法、装置、存储介质及电子设备
WO2018076829A1 (zh) 终端数据的处理方法、装置、系统、存储介质及服务器
WO2017206865A1 (zh) 一种应用程序的关闭方法、装置、存储介质及电子设备
WO2018076888A1 (zh) 移动终端数据的同步方法、装置及系统、存储介质及移动终端

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17899544

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 17899544

Country of ref document: EP

Kind code of ref document: A1