CN105205152B - The method, apparatus and electronic equipment of decision paths and packet name corresponding relationship - Google Patents

The method, apparatus and electronic equipment of decision paths and packet name corresponding relationship Download PDF

Info

Publication number
CN105205152B
CN105205152B CN201510614215.7A CN201510614215A CN105205152B CN 105205152 B CN105205152 B CN 105205152B CN 201510614215 A CN201510614215 A CN 201510614215A CN 105205152 B CN105205152 B CN 105205152B
Authority
CN
China
Prior art keywords
corresponding relationship
path
packet name
data
tables
Prior art date
Application number
CN201510614215.7A
Other languages
Chinese (zh)
Other versions
CN105205152A (en
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 北京金山安全软件有限公司
Priority to CN201510614215.7A priority Critical patent/CN105205152B/en
Publication of CN105205152A publication Critical patent/CN105205152A/en
Application granted granted Critical
Publication of CN105205152B publication Critical patent/CN105205152B/en

Links

Abstract

The embodiment of the present invention discloses the method, apparatus and electronic equipment of a kind of decision paths and packet name corresponding relationship, is related to file clean-up technical field, invents relatively accurately to determine installation kit corresponding to path.The described method includes: reading first path and packet name corresponding relationship from the first tables of data comprising path to be determined and packet name corresponding relationship;It determines in first path and packet name corresponding relationship, the similarity in path and packet name;If in first path and packet name corresponding relationship, the similarity of path and packet name is greater than the first predetermined threshold, then determine that first path and packet name corresponding relationship are set up.It include module used to perform the method in the device of the decision paths and packet name corresponding relationship.The occasion of present invention file clean-up suitable for terminal device.

Description

The method, apparatus and electronic equipment of decision paths and packet name corresponding relationship

Technical field

The present invention relates to garbage files and Stub File Removal Technology field more particularly to a kind of decision paths and packet name are right The method, apparatus and electronic equipment that should be related to.

Background technique

In the storage of active user's mobile phone, due to the development specifications disunity of application program, data storage is all in tumble, causes A large amount of memory spaces are occupied by hash, cause phone memory insufficient, therefore clear up more hashes, release is more More memory spaces become the tight demand of user.

It is mixed and disorderly due to data storage, for certain files of storage, it can not determine that its path is by which or which peace Caused by dress packet, thus make troubles to the cleaning of these files, so that the cleaning of garbage files or Stub File is not thorough enough Bottom, and cleaning efficiency is lower.Therefore, how to determine that installation kit corresponding to the path of file is assistant officer's problem to be solved.

Summary of the invention

In view of this, the embodiment of the present invention provides the method, apparatus and electronics of a kind of decision paths and packet name corresponding relationship Equipment can relatively accurately determine installation kit corresponding to path.

In order to achieve the above objectives, the embodiment of the present invention adopts the following technical scheme that

On the one hand, the embodiment of the present invention provides the method for a kind of decision paths and packet name corresponding relationship, comprising:

From the first tables of data comprising path to be determined and packet name corresponding relationship, it is corresponding with packet name to read first path Relationship;

It determines in first path and packet name corresponding relationship, the similarity in path and packet name;

If in first path and packet name corresponding relationship, the similarity of path and packet name is greater than the first predetermined threshold, then determine First path and packet name corresponding relationship are set up.

Optionally, described from the first tables of data comprising path to be determined and packet name corresponding relationship, read the first via Diameter and packet name corresponding relationship, comprising:

Read the first tables of data comprising path to be determined and packet name corresponding relationship, in the first tables of data path with Packet name corresponding relationship is filtered;

From the path and packet name corresponding relationship retained after filtering, first path and packet name corresponding relationship are read;

Wherein, in the first tables of data path and packet name corresponding relationship be filtered include: will be comprising following any feelings The path of shape is filtered out with packet name corresponding relationship: path and common path exact matching;Path is the self-built path of user.

Optionally, in the determining first path and packet name corresponding relationship, the similarity in path and packet name, comprising: judgement In first path and packet name corresponding relationship, whether path and packet name include common character string;If the path and packet name packet Containing common character string, then the first weighted value is assigned to first path and packet name corresponding relationship;

By in path in the first tables of data and packet name corresponding relationship path and packet name carry out cutting respectively, establish first pair Answer set of relations;The first corresponding relationship of each of the first corresponding relationship concentration, is the cutting vocabulary in path in the first tables of data Corresponding relationship between the cutting vocabulary of packet name corresponding with the path;First corresponding relationship concentrates the first corresponding pass Path is identical as the quantity of packet name corresponding relationship in the quantity of system, and the first tables of data;

The frequency for carrying out the first corresponding relationship established after cutting with packet name corresponding relationship to first path calculates, and Judge whether the frequency of first corresponding relationship is greater than the second predetermined threshold;If it is pre- that the frequency of first corresponding relationship is greater than second Determine threshold value, then judges that first corresponding relationship whether there is in the second corresponding relationship frequency table;Wherein, the described second corresponding pass The frequency of to be in frequency table include the second corresponding relationship and the second corresponding relationship, second corresponding relationship is will in advance really The path and packet name being set in correct path and packet name corresponding relationship carry out the corresponding relationship established after cutting respectively;

If first corresponding relationship exists in the second corresponding relationship frequency table, first corresponding relationship is read second Corresponding frequency in corresponding relationship frequency table;Corresponding to judging first corresponding relationship in the second corresponding relationship frequency table Whether frequency is greater than third predetermined threshold;

If first corresponding relationship frequency corresponding in the second corresponding relationship frequency table is greater than third predetermined threshold, The second weighted value is assigned to first path and packet name corresponding relationship;

First weighted value and the second weighted value are added, obtained in first path and packet name corresponding relationship, road The similarity of diameter and packet name.

Optionally, in the judgement first path and packet name corresponding relationship, whether path and packet name include common word Symbol string, comprising: judge in first path and packet name corresponding relationship, whether subpath and packet name in path include common word Symbol string.

Optionally, the frequency that the first corresponding relationship established after cutting is carried out to first path and packet name corresponding relationship It is calculated, comprising: first established after carrying out cutting with packet name corresponding relationship to first path according to following formula is corresponding to close The frequency of system is calculated:

F1=n/m;

Wherein, F1 is the frequency that the first corresponding relationship established after cutting is carried out to first path and packet name corresponding relationship;

N is to concentrate in the first corresponding relationship, carries out establish after cutting first with to first path and packet name corresponding relationship The sum of the quantity of identical all first corresponding relationships of corresponding relationship;

M is to concentrate in the first corresponding relationship, includes the path cutting vocabulary or packet in first path and packet name corresponding relationship The sum of the quantity of all first corresponding relationships of name cutting vocabulary.

Optionally, from the first tables of data comprising path to be determined and packet name corresponding relationship, first path is read Before packet name corresponding relationship, the method for the decision paths and packet name corresponding relationship, further includes:

Under the user EXEC of mobile terminal, by client application to the creation in path in mobile terminal or Change is monitored;

When monitoring currently has new path to create or have path change in the mobile terminal, newly created road is read Diameter or the path to change obtain the packet name of the application program of the mobile terminal foreground and backstage current active, establish and read Corresponding relationship between the path taken and the packet name of acquisition;

The tables of data for establishing the corresponding relationship between the packet name comprising the path and acquisition read, as described The first tables of data comprising path to be determined and packet name corresponding relationship.

Optionally, from the first tables of data comprising path to be determined and packet name corresponding relationship, first path is read Before packet name corresponding relationship, the method for the decision paths and packet name corresponding relationship, further includes:

Foundation includes to have been determined as second tables of data in correct path Yu packet name corresponding relationship in advance;

Path in second tables of data and the path in packet name corresponding relationship and packet name are subjected to cutting respectively, establish second Set of correspondences;The second corresponding relationship of each of the second corresponding relationship concentration, is the segmenting word in path in the second tables of data The corresponding relationship converged between the cutting vocabulary of packet name corresponding with the path;Second corresponding relationship concentrates second to correspond to Path is identical as the quantity of packet name corresponding relationship in the quantity of relationship, and the second tables of data;

The frequency of the second corresponding relationship each of is concentrated to calculate the second corresponding relationship according to following formula:

F2=j/k;

Wherein, F2 is the frequency that the second corresponding relationship concentrates one of them the second corresponding relationship;

J is to concentrate in the second corresponding relationship, all second corresponding passes identical with one of them described second corresponding relationship The sum of quantity of system;

K be the second corresponding relationship concentrate, comprising in one of them described second corresponding relationship path cutting vocabulary or The sum of the quantity of all second corresponding relationships of packet name cutting vocabulary.

According to the frequency of the second corresponding relationship of each of the second corresponding relationship concentration being calculated, described second pair is established It should be related to frequency table.

Optionally, described establish includes the second data for having been determined as correct path Yu packet name corresponding relationship in advance Table, comprising: under the root user mode of mobile terminal, to the creation in path in mobile terminal or changed by client application Change is monitored;

When monitoring currently has new path to create or have path change in the mobile terminal, newly created road is read Diameter or the path to change obtain the packet name of the application program of the mobile terminal foreground and backstage current active, establish and read Corresponding relationship between the path taken and the packet name of acquisition;

The tables of data for establishing the corresponding relationship between the packet name comprising the path and acquisition read, as described It include the second tables of data for having been determined as correct path Yu packet name corresponding relationship in advance.

On the other hand, the embodiment of the present invention provides the device of a kind of decision paths and packet name corresponding relationship, comprising: source data Read module, for reading first path and packet from the first tables of data comprising path to be determined and packet name corresponding relationship Name corresponding relationship;Similarity determining module, for determining in first path and packet name corresponding relationship, path is similar to packet name Degree;Judgment module, if the similarity of path and packet name is greater than the first predetermined threshold in first path and packet name corresponding relationship Value then determines that first path and packet name corresponding relationship are set up.

Optionally, the source data read module, comprising: the first reading submodule includes road to be determined for reading First tables of data of diameter and packet name corresponding relationship;Filter submodule, for being closed to the path in the first tables of data is corresponding with packet name System is filtered;Second reading submodule, for reading first path from the path and packet name corresponding relationship retained after filtering With packet name corresponding relationship;Wherein, the path in the first tables of data is filtered with packet name corresponding relationship include: will be comprising as follows The path of any case is filtered out with packet name corresponding relationship: path and common path exact matching;Path is the self-built road of user Diameter.

Optionally, the similarity determining module, including the first determining submodule, the second determining submodule and cumulative mould Block;Wherein, described first submodule is determined, for judging in first path and packet name corresponding relationship, whether path and packet name are wrapped Contain common character string;It is corresponding with packet name to first path to close if the path and packet name include common character string System assigns the first weighted value;

Described second determines submodule, is used for:

By in path in the first tables of data and packet name corresponding relationship path and packet name carry out cutting respectively, establish first pair Answer set of relations;The first corresponding relationship of each of the first corresponding relationship concentration, is the cutting vocabulary in path in the first tables of data Corresponding relationship between the cutting vocabulary of packet name corresponding with the path;First corresponding relationship concentrates the first corresponding pass Path is identical as the quantity of packet name corresponding relationship in the quantity of system, and the first tables of data;

The frequency for carrying out the first corresponding relationship established after cutting with packet name corresponding relationship to first path calculates, and Judge whether the frequency of first corresponding relationship is greater than the second predetermined threshold;If it is pre- that the frequency of first corresponding relationship is greater than second Determine threshold value, then judges that first corresponding relationship whether there is in the second corresponding relationship frequency table;Wherein, the described second corresponding pass The frequency of to be in frequency table include the second corresponding relationship and the second corresponding relationship, second corresponding relationship is will in advance really The path and packet name being set in correct path and packet name corresponding relationship carry out the corresponding relationship established after cutting respectively;

If first corresponding relationship exists in the second corresponding relationship frequency table, first corresponding relationship is read second Corresponding frequency in corresponding relationship frequency table;Corresponding to judging first corresponding relationship in the second corresponding relationship frequency table Whether frequency is greater than third predetermined threshold;

If first corresponding relationship frequency corresponding in the second corresponding relationship frequency table is greater than third predetermined threshold, The second weighted value is assigned to first path and packet name corresponding relationship;

The accumulator module, for being added to first weighted value and the second weighted value, obtain first path with In packet name corresponding relationship, the similarity in path and packet name.

Optionally, described first submodule is determined, the son for judging in first path and packet name corresponding relationship, in path Whether path and packet name include common character string;If the subpath and packet name in the path include common character String then assigns the first weighted value to first path and packet name corresponding relationship.

Optionally, described second submodule is determined, comprising: the first computational submodule is used for according to following formula to first The frequency that path carries out the first corresponding relationship established after cutting with packet name corresponding relationship is calculated:

F1=n/m;

Wherein, F1 is the frequency that the first corresponding relationship established after cutting is carried out to first path and packet name corresponding relationship;

N is to concentrate in the first corresponding relationship, carries out establish after cutting first with to first path and packet name corresponding relationship The sum of the quantity of identical all first corresponding relationships of corresponding relationship;

M is to concentrate in the first corresponding relationship, includes the path cutting vocabulary or packet in first path and packet name corresponding relationship The sum of the quantity of all first corresponding relationships of name cutting vocabulary.

Optionally, the device of the decision paths and packet name corresponding relationship, further includes: the first monitoring module is used for Under the user EXEC of mobile terminal, the creation or change in path in mobile terminal are supervised by client application Depending on;First building module, for reading when monitoring currently has new path to create or have path change in the mobile terminal The path for taking newly created path or changing obtains the application program of the mobile terminal foreground and backstage current active Packet name establishes the corresponding relationship between the path of reading and the packet name of acquisition;Establish the path comprising reading The tables of data of corresponding relationship between the packet name of acquisition includes path to be determined and packet name corresponding relationship as described The first tables of data.

Optionally, the device of the decision paths and packet name corresponding relationship further includes the second building module, computing module Module is constructed with third;Wherein

Second building module, includes have been determined as correct path and packet name corresponding relationship in advance second for establishing Tables of data;

Computing module, with by the second tables of data path in packet name corresponding relationship path and packet name cut respectively Point, establish the second set of correspondences;The second corresponding relationship of each of the second corresponding relationship concentration, is the second tables of data Road Corresponding relationship between the cutting vocabulary of diameter and the cutting vocabulary of packet name corresponding with the path;Second set of correspondences In the second corresponding relationship quantity, and path is identical as the quantity of packet name corresponding relationship in the second tables of data;

The frequency of the second corresponding relationship each of is concentrated to calculate the second corresponding relationship according to following formula:

F2=j/k;

Wherein, F2 is the frequency that the second corresponding relationship concentrates one of them the second corresponding relationship;

J is to concentrate in the second corresponding relationship, all second corresponding passes identical with one of them described second corresponding relationship The sum of quantity of system;

K be the second corresponding relationship concentrate, comprising in one of them described second corresponding relationship path cutting vocabulary or The sum of the quantity of all second corresponding relationships of packet name cutting vocabulary;

Third constructs module, for the frequency according to the second corresponding relationship of each of the second corresponding relationship concentration being calculated Number, establishes the second corresponding relationship frequency table.

Optionally, the second building module, comprising: the second monitoring submodule, for the root user mould in mobile terminal Under formula, the creation or change in path in mobile terminal are monitored by client application;4th building submodule, is used In when monitoring currently has new path to create or have path change in the mobile terminal, newly created path or hair are read The raw path changed, obtains the packet name of the application program of the mobile terminal foreground and backstage current active, establishes the institute of reading State the corresponding relationship between path and the packet name of acquisition;Establish comprising read the path and acquisition the packet name it Between corresponding relationship tables of data, as it is described include have been determined as correct path and packet name corresponding relationship in advance second Tables of data.

In another aspect, the embodiment of the present invention also provides a kind of electronic equipment, the electronic equipment include: shell, processor, Memory, circuit board and power circuit, wherein circuit board is placed in the space interior that shell surrounds, and processor and memory are set It sets on circuit boards;Power circuit, for each circuit or the device power supply for above-mentioned electronic equipment;Memory can for storing Execute program code;Processor is run by reading the executable program code stored in memory and executable program code Corresponding program, the method for executing decision paths described in aforementioned any embodiment Yu packet name corresponding relationship.

The method, apparatus and electronic equipment of decision paths provided in an embodiment of the present invention and packet name corresponding relationship, by true The similarity in fixed path and packet name corresponding relationship to be determined, and judge whether the similarity is greater than the predetermined threshold value first set, If more than preset threshold value, then determine that first path and packet name corresponding relationship are set up, thus, it is possible to relatively accurately determine Installation kit corresponding to path.

Detailed description of the invention

In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this Some embodiments of invention for those of ordinary skill in the art without creative efforts, can be with Other attached drawings are obtained according to these attached drawings.

Fig. 1 is the flow diagram present invention determine that one embodiment of method of path and packet name corresponding relationship;

Fig. 2 is the first tables of data in the present embodiment comprising path to be determined and packet name corresponding relationship;

Fig. 3 is the flow diagram present invention determine that another embodiment of method of path and packet name corresponding relationship;Fig. 4 is this The second tables of data established in invention decision paths and one embodiment of method of packet name corresponding relationship;

Fig. 5 is present invention determine that the second corresponding relationship established in one embodiment of method of path and packet name corresponding relationship Collection;

Fig. 6 is the second corresponding relationship frequency present invention determine that establishing in one embodiment of method of path and packet name corresponding relationship Number table;

Fig. 7 is present invention determine that the first corresponding relationship established in one embodiment of method of path and packet name corresponding relationship Collection;

Fig. 8 is the structural schematic diagram present invention determine that one embodiment of device of path and packet name corresponding relationship;

Fig. 9 is the structural schematic diagram present invention determine that another embodiment of device of path and packet name corresponding relationship;

Figure 10 is the structural schematic diagram of one embodiment of electronic equipment of the present invention.

Specific embodiment

With reference to the accompanying drawing to the method, apparatus and electronics of a kind of decision paths of the embodiment of the present invention and packet name corresponding relationship Equipment is described in detail.

It will be appreciated that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.Base Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts it is all its Its embodiment, shall fall within the protection scope of the present invention.

Fig. 1 is the flow diagram present invention determine that one embodiment of method of path and packet name corresponding relationship.Referring to Fig. 1, Present invention determine that one embodiment of method in path and packet name corresponding relationship, includes the following steps:

S11, from the first tables of data comprising path to be determined and packet name corresponding relationship, read first path and packet name Corresponding relationship;

Fig. 2 is the first tables of data in the present embodiment comprising path to be determined and packet name corresponding relationship.Referring to Fig. 2, One tables of data can be a two-dimensional data table, wherein including the corresponding relationship in path Yu packet name.

The data in path and packet name corresponding relationship, can first pass through client application in advance in first tables of data, from user The mobile terminals such as mobile phone, tablet computer in collect path and packet name corresponding relationship to be determined, then establish comprising to be determined Path and packet name corresponding relationship tables of data.

In the embodiment of the present invention, the first path and packet name corresponding relationship are any one roads referred in the first tables of data Diameter and packet name corresponding relationship.

S12, it determines in first path and packet name corresponding relationship, the similarity in path and packet name;

It, can be according to the similarity in path and the character string of packet name, to determine path as an alternative embodiment in this step With the similarity of packet name.

If in S13, first path and packet name corresponding relationship, the similarity of path and packet name is greater than the first predetermined threshold, then Determine that first path and packet name corresponding relationship are set up.

The method of decision paths provided in an embodiment of the present invention and packet name corresponding relationship, by determination path to be determined with The similarity of packet name corresponding relationship, and judge whether the similarity is greater than the predetermined threshold value first set, if more than preset Threshold value then determines that first path and packet name corresponding relationship are set up, and thus, it is possible to relatively accurately determine installation corresponding to path Packet.

It, can be to including path to be determined and packet name corresponding relationship in order to improve the accuracy for determining efficiency and judgement Path in tables of data is filtered with packet name corresponding relationship, filters out undesirable path and packet name corresponding relationship.Ginseng See Fig. 3, it is described from the first tables of data comprising path to be determined and packet name corresponding relationship, it reads first path and packet name is right It should be related to (S11), may include:

S111, read the tables of data comprising path to be determined and packet name corresponding relationship, in the tables of data path with Packet name corresponding relationship is filtered.

Wherein, in the tables of data path and packet name corresponding relationship be filtered include: will be comprising the following two kinds situation The path of middle any case is filtered out with packet name corresponding relationship:

(1) path and common path exact matching;

(2) path is the self-built path of user.

S112, from the path and packet name corresponding relationship retained after filtering, read a paths and packet name corresponding relationship.

Fig. 3 is the flow diagram present invention determine that another embodiment of method of path and packet name corresponding relationship.Referring to figure 3, present invention determine that the determining first path is corresponding with packet name in another embodiment of method of path and packet name corresponding relationship In relationship, the similarity (12) in path and packet name be may include steps of:

S121, judge in first path and packet name corresponding relationship, whether path and packet name include common character string.

Under normal conditions, a paths generally include the subpath under common path and common path, such as path In " Tencent QQMusic QzoneMusic ", " Tencent " can be described as common path, " QQMusic QzoneMusic " It can be described as subpath.In order to improve judgement efficiency, the son in the path in the path and packet name corresponding relationship can be only judged In path, if there is the character string common with the packet name.

If S122, the path and packet name include common character string, first path and packet name corresponding relationship are assigned Give the first weighted value.

S123, by path in the first tables of data and packet name corresponding relationship path and packet name carry out cutting respectively, establish First set of correspondences.

First corresponding relationship each of concentrates the first corresponding relationship, be in the first tables of data the cutting vocabulary in path and Corresponding relationship between the cutting vocabulary of packet name corresponding with the path;First corresponding relationship concentrates the first corresponding relationship Quantity, and path is identical as the quantity of packet name corresponding relationship in the first tables of data.

S124, the frequency for carrying out the first corresponding relationship established after cutting with packet name corresponding relationship to first path are counted It calculates.

Frequency is the number that some data occurs in one group of data.It, can be according to such as in this step as an alternative embodiment The frequency that lower formula carries out the first corresponding relationship established after cutting with packet name corresponding relationship to first path calculates:

F1=n/m;

Wherein, F1 is the frequency that the first corresponding relationship established after cutting is carried out to first path and packet name corresponding relationship;

N is to concentrate in the first corresponding relationship, carries out establish after cutting first with to first path and packet name corresponding relationship The sum of the quantity of identical all first corresponding relationships of corresponding relationship;

M is to concentrate in the first corresponding relationship, includes the path cutting vocabulary or packet in first path and packet name corresponding relationship The sum of the quantity of all first corresponding relationships of name cutting vocabulary.

S125, judge whether the frequency of first corresponding relationship is greater than the second predetermined threshold.

If the frequency of S126, first corresponding relationship is greater than the second predetermined threshold, judge first corresponding relationship the It whether there is in two corresponding relationship frequency tables.

It wherein, include the frequency of the second corresponding relationship and the second corresponding relationship in the second corresponding relationship frequency table, Second corresponding relationship be will have been determined as in advance path in correct path and packet name corresponding relationship and packet name respectively into The corresponding relationship established after row cutting.

If S127, first corresponding relationship exist in the second corresponding relationship frequency table, first corresponding relationship is read The corresponding frequency in the second corresponding relationship frequency table.

S128, judge whether first corresponding relationship frequency corresponding in the second corresponding relationship frequency table is greater than third Predetermined threshold.

If S129, first corresponding relationship frequency corresponding in the second corresponding relationship frequency table are greater than the predetermined threshold of third Value then assigns the second weighted value to first path and packet name corresponding relationship.

S130, first weighted value and the second weighted value are added, obtain first path and packet name corresponding relationship In, the similarity in path and packet name.

In the embodiment of the method for aforementioned decision paths and packet name corresponding relationship, optionally, from including road to be determined In first tables of data of diameter and packet name corresponding relationship, before reading first path and packet name corresponding relationship (S11), the judgement road The method of diameter and packet name corresponding relationship can also establish first tables of data as follows:

A1, under the user EXEC of mobile terminal, by client application to the wound in path in mobile terminal It builds or changes and monitored.

Wherein, the user EXEC of the mobile terminal is root user's mould for root user mode Formula can be described as root user mode again;Under normal conditions, after mobile terminal-opening automatically into be user EXEC;It can be by general General family pattern switching can also be switched to user EXEC by root user mode to root user mode.

A2, when monitoring currently has new path creation or has path change in the mobile terminal, read new creation Path or the path that changes, obtain the packet name of the application program of the mobile terminal foreground and backstage current active, build Corresponding relationship between the vertical path read and the packet name of acquisition.

The tables of data of corresponding relationship between the packet name of A3, foundation comprising the path and acquisition read, as First tables of data comprising path to be determined and packet name corresponding relationship.

In current newly created path or there are the path of change, a packet name with current foreground and the application program of background activity Between establish corresponding relationship, so as to reduce the quantity of the corresponding relationship between the path of foundation and packet name, improve subsequent Determine efficiency.The corresponding relationship can be one-to-many relationship, be also possible to many-to-one relationship, it can be by a path It is corresponding with multiple packet names, it is also possible to multiple paths are corresponding with the same packet name.

In the embodiment of the method for aforementioned decision paths and packet name corresponding relationship, optionally, from including road to be determined In first tables of data of diameter and packet name corresponding relationship, before reading first path and packet name corresponding relationship (S11), the judgement road The method of diameter and packet name corresponding relationship can also establish the second corresponding relationship frequency table as follows:

B1, foundation include the second tables of data for having been determined as correct path Yu packet name corresponding relationship in advance.

In this step, as an alternative embodiment, can be established by artificial mode includes to have been determined as in advance correctly Path and packet name corresponding relationship the second tables of data, can also by bury point mode obtain the second tables of data in path and packet name it is right The data that should be related to.

B2, the path in the second tables of data and the path in packet name corresponding relationship and packet name are subjected to cutting respectively, established Second set of correspondences.

Second corresponding relationship each of concentrates the second corresponding relationship, be in the second tables of data the cutting vocabulary in path and Corresponding relationship between the cutting vocabulary of packet name corresponding with the path;Second corresponding relationship concentrates the second corresponding relationship Quantity, and path is identical as the quantity of packet name corresponding relationship in the second tables of data;

B3, the frequency of the second corresponding relationship each of is concentrated to calculate the second corresponding relationship according to following formula:

F2=j/k;

Wherein, F2 is the frequency that the second corresponding relationship concentrates one of them the second corresponding relationship;

J is to concentrate in the second corresponding relationship, all second corresponding passes identical with one of them described second corresponding relationship The sum of quantity of system;

K be the second corresponding relationship concentrate, comprising in one of them described second corresponding relationship path cutting vocabulary or The sum of the quantity of all second corresponding relationships of packet name cutting vocabulary.

B4, the frequency that the second corresponding relationship each of is concentrated according to the second corresponding relationship for being calculated establish described the Two corresponding relationship frequency tables.

In aforementioned decision paths and the embodiment of the method for packet name corresponding relationship, optionally, the foundation includes preparatory Have been determined as second tables of data (B1) in correct path Yu packet name corresponding relationship, comprising:

B11, the creation under the root user mode of mobile terminal, by client application to path in mobile terminal Or changes and monitored;

B12, when monitoring currently has new path creation or has path change in the mobile terminal, read new creation Path or the path that changes, obtain the packet name of the application program of the mobile terminal foreground and backstage current active, build Corresponding relationship between the vertical path read and the packet name of acquisition;

The tables of data of corresponding relationship between the packet name of B13, foundation comprising the path and acquisition read, as Described includes the second tables of data for having been determined as correct path Yu packet name corresponding relationship in advance.

Corresponding relationship in second tables of data can be one-to-many relationship, be also possible to many-to-one relationship, it can It is that a path is corresponding with multiple packet names, it is corresponding with the same packet name is also possible to multiple paths.

Below in tables of data shown in Fig. 2 path and packet name corresponding relationship " qqmusic/cache- > Com.tencent.qqmusic " is illustrated for being determined.

Present embodiment determine that the method in path and packet name corresponding relationship, includes the following steps:

S21, under the root user mode of mobile terminal, by client application to the wound in path in mobile terminal It builds or changes and monitored.

In this step, can creation to the path in multiple mobile terminals or change monitor, it is more to collect Data.

S22, when monitoring currently has new path creation or has path change in the mobile terminal, read new creation Path or the path that changes, obtain the packet name of the application program of the mobile terminal foreground and backstage current active, build Corresponding relationship between the vertical path read and the packet name of acquisition.

Second tables of data of the corresponding relationship between the packet name of S23, foundation comprising the path and acquisition read.

The second tables of data comprising the corresponding relationship that Fig. 4 is established for the corresponding relationship established according to step S22;? 10 paths and packet name corresponding relationship are shared in second tables of data, that is, share 10 datas.

S24, the path in the second tables of data and the path in packet name corresponding relationship and packet name are subjected to cutting respectively, established Second set of correspondences, as shown in Figure 5.

In this step, as unit of vocabulary, remove the "/" in path, " " gone in switch name is accorded at equal intervals, to path Cutting is carried out respectively with packet name.

S25, based on path, the frequency of the second corresponding relationship each of is concentrated to the second corresponding relationship according to following formula Number is calculated:

F2=j/k;

Wherein, F2 is the frequency that the second corresponding relationship concentrates one of them the second corresponding relationship;

J is to concentrate in the second corresponding relationship, all second corresponding passes identical with one of them described second corresponding relationship The sum of quantity of system;

K be the second corresponding relationship concentrate, comprising in one of them described second corresponding relationship path cutting vocabulary or The sum of the quantity of all second corresponding relationships of packet name cutting vocabulary.

S26, the frequency that the second corresponding relationship each of is concentrated according to the second corresponding relationship for being calculated establish described the Two corresponding relationship frequency tables, as shown in Figure 6.

S27, under the user EXEC of mobile terminal device, by client application in mobile terminal device The creation or change in path are monitored.

S28, when monitoring currently has new path creation or has path change in the mobile terminal device, read new The path of creation or the path to change obtain the application program of the mobile terminal device foreground and backstage current active Packet name establishes the corresponding relationship between the path of reading and the packet name of acquisition.

The tables of data of corresponding relationship between the packet name of S29, foundation comprising the path and acquisition read, as First tables of data comprising path to be determined and packet name corresponding relationship.Fig. 2 be establish comprising path to be determined with First tables of data of packet name corresponding relationship.

S30, from the first tables of data, read first path and packet name corresponding relationship " qqmusic/cache- > Com.tencent.qqmusic ", as path to be determined and packet name corresponding relationship.Wherein, " qqmusic/cache " is road Diameter, " com.tencent.qqmusic " are packet name.

S31, judge the path and packet name corresponding relationship " qqmusic/cache- > com.tencent.qqmusic ", In, whether path and packet name include common character string;By judgement, the path and packet name include common character string " qqmusic " assigns the to the path and packet name corresponding relationship " qqmusic/cache- > com.tencent.qqmusic " One weighted value 1.0.

S32, by path in the first tables of data and packet name corresponding relationship path and packet name carry out cutting respectively, establish the One set of correspondences, as shown in Figure 7.

S33, the first corresponding pass established after cutting is carried out to " qqmusic/cache- > com.tencent.qqmusic " The frequency of system is calculated according to following formula, and the frequency for obtaining first corresponding relationship is 2/4=0.5.

Calculation formula are as follows: F1=n/m;

Wherein, F1 is first pair established after carrying out cutting to " qqmusic/cache- > com.tencent.qqmusic " The frequency that should be related to;

N is to concentrate in the first corresponding relationship, is cut with to " qqmusic/cache- > com.tencent.qqmusic " The sum of the quantity for identical all first corresponding relationships of the first corresponding relationship established after point, n=2 in the present embodiment;

M is to concentrate in the first corresponding relationship, includes the road in " qqmusic/cache- > com.tencent.qqmusic " The sum of the quantity of all first corresponding relationships of diameter segmenting word remittance " qqmusic cache ", in the present embodiment, m=4.

S34, judge whether the frequency of first corresponding relationship is greater than the second predetermined threshold 0.4.

S35, by judgement, the frequency of first corresponding relationship is 0.5, is greater than the second predetermined threshold 0.4, judge this first Corresponding relationship whether there is in the second corresponding relationship frequency table.

By judgement, first corresponding relationship " qqmusic cache- > com tencent qqmusic " is corresponding second Exist in relationship frequency table.

S36, first corresponding relationship frequency 1.0 corresponding in the second corresponding relationship frequency table is read.

S37, judge whether first corresponding relationship frequency 1.0 corresponding in the second corresponding relationship frequency table is greater than the Three predetermined thresholds 0.2.

S38, by judgement, first corresponding relationship frequency 1.0 corresponding in the second corresponding relationship frequency table is greater than Third predetermined threshold 0.2 then assigns the second weighted value 0.8 to first path and packet name corresponding relationship.

S39, first weighted value 1.0 is added with the second weighted value 0.8, it is corresponding with packet name obtains first path In relationship, the similarity of path and packet name is 1.8.

S40, by judgement, in first path and packet name corresponding relationship, it is pre- that the similarity 1.8 of path and packet name is greater than first Determine threshold value 1.0, determines that first path and packet name corresponding relationship " qqmusic/cache- > com.tencent.qqmusic " are set up.

Fig. 8 is the structural schematic diagram present invention determine that one embodiment of device of path and packet name corresponding relationship.Referring to Fig. 8, Present invention determine that one embodiment of device in path and packet name corresponding relationship, including source data read module 51, similarity determine mould Block 52 and judgment module 53;Wherein

Source data read module 51, for from the first tables of data comprising path to be determined and packet name corresponding relationship, Read first path and packet name corresponding relationship.

Fig. 2 is the first tables of data in the present embodiment comprising path to be determined and packet name corresponding relationship.Referring to Fig. 2, One tables of data can be a two-dimensional data table, wherein including the corresponding relationship in path Yu packet name.

The data in path and packet name corresponding relationship, can first pass through client application in advance in first tables of data, from user The mobile terminals such as mobile phone, tablet computer in collect path and packet name corresponding relationship to be determined, then establish comprising to be determined Path and packet name corresponding relationship tables of data.

Similarity determining module 52, for determining in first path and packet name corresponding relationship, the similarity in path and packet name.

It, can be according to the similarity in path and the character string of packet name, to determine path and packet name as an alternative embodiment Similarity.

Judgment module 53, if the similarity of path and packet name is greater than first in first path and packet name corresponding relationship Predetermined threshold then determines that first path and packet name corresponding relationship are set up.

The device of decision paths provided in an embodiment of the present invention and packet name corresponding relationship, by determination path to be determined with The similarity of packet name corresponding relationship, and judge whether the similarity is greater than the predetermined threshold value first set, if more than preset Threshold value then determines that first path and packet name corresponding relationship are set up, and thus, it is possible to relatively accurately determine installation corresponding to path Packet.

Fig. 9 is the structural schematic diagram present invention determine that another embodiment of device of path and packet name corresponding relationship.In order to mention Height determines the accuracy of efficiency and judgement, can be to the path in the tables of data comprising path to be determined and packet name corresponding relationship It is filtered with packet name corresponding relationship, filters out undesirable path and packet name corresponding relationship.Referring to Fig. 9, sentence aforementioned In the Installation practice for determining path and packet name corresponding relationship, the source data read module 51, comprising:

First reading submodule 511 includes path and the first tables of data of packet name corresponding relationship to be determined for reading;

Filter submodule 512, for being filtered to the path in the first tables of data with packet name corresponding relationship;Wherein, right It includes: that the path comprising following any case and packet name is right that path in first tables of data is filtered with packet name corresponding relationship It should be related to and filter out:

(1) path and common path exact matching;

(2) path is the self-built path of user.

Second reading submodule 513, for reading first path from the path and packet name corresponding relationship retained after filtering With packet name corresponding relationship.

In the Installation practice of aforementioned decision paths and packet name corresponding relationship, the similarity determining module 52 can be with Determine that submodule 521, second determines submodule 522 and accumulator module 523 including first;Wherein

Described first determines submodule 521, and for judging in first path and packet name corresponding relationship, whether path and packet name It include common character string;If the path and packet name include common character string, corresponding with packet name to first path Relationship assigns the first weighted value.

Under normal conditions, a paths generally include the subpath under common path and common path, such as path In " Tencent QQMusic QzoneMusic ", " Tencent " can be described as common path, " QQMusic QzoneMusic " It can be described as subpath.In order to improve judgement efficiency, the son in the path in the path and packet name corresponding relationship can be only judged In path, if there is the character string common with the packet name.

Described second determines submodule 522, is used for:

By in path in the first tables of data and packet name corresponding relationship path and packet name carry out cutting respectively, establish first pair Answer set of relations;The first corresponding relationship of each of the first corresponding relationship concentration, is the cutting vocabulary in path in the first tables of data Corresponding relationship between the cutting vocabulary of packet name corresponding with the path;First corresponding relationship concentrates the first corresponding pass Path is identical as the quantity of packet name corresponding relationship in the quantity of system, and the first tables of data;

The frequency for carrying out the first corresponding relationship established after cutting with packet name corresponding relationship to first path calculates, and Judge whether the frequency of first corresponding relationship is greater than the second predetermined threshold;If it is pre- that the frequency of first corresponding relationship is greater than second Determine threshold value, then judges that first corresponding relationship whether there is in the second corresponding relationship frequency table;Wherein, the described second corresponding pass The frequency of to be in frequency table include the second corresponding relationship and the second corresponding relationship, second corresponding relationship is will in advance really The path and packet name being set in correct path and packet name corresponding relationship carry out the corresponding relationship established after cutting respectively;

If first corresponding relationship exists in the second corresponding relationship frequency table, first corresponding relationship is read second Corresponding frequency in corresponding relationship frequency table;Corresponding to judging first corresponding relationship in the second corresponding relationship frequency table Whether frequency is greater than third predetermined threshold;

If first corresponding relationship frequency corresponding in the second corresponding relationship frequency table is greater than third predetermined threshold, The second weighted value is assigned to first path and packet name corresponding relationship;

The accumulator module 523 obtains first path for being added to first weighted value and the second weighted value In packet name corresponding relationship, the similarity in path and packet name.

In aforementioned decision paths and the Installation practice of packet name corresponding relationship, optionally, described second determines submodule 522, comprising: the first computational submodule, for being built after carrying out cutting with packet name corresponding relationship to first path according to following formula The frequency of the first vertical corresponding relationship is calculated:

F1=n/m;

Wherein, F1 is the frequency that the first corresponding relationship established after cutting is carried out to first path and packet name corresponding relationship;

N is to concentrate in the first corresponding relationship, carries out establish after cutting first with to first path and packet name corresponding relationship The sum of the quantity of identical all first corresponding relationships of corresponding relationship;

M is to concentrate in the first corresponding relationship, includes the path cutting vocabulary or packet in first path and packet name corresponding relationship The sum of the quantity of all first corresponding relationships of name cutting vocabulary.

In aforementioned decision paths and the Installation practice of packet name corresponding relationship, optionally, the decision paths and packet The device of name corresponding relationship further includes the first monitoring module 54 and the first building module 55;Wherein

First monitoring module 54, under the user EXEC of mobile terminal, by client application to shifting The creation or change in path are monitored in dynamic terminal.

Wherein, the user EXEC of the mobile terminal is root user's mould for root user mode Formula can be described as root user mode again;Under normal conditions, after mobile terminal-opening automatically into be user EXEC;It can be by general General family pattern switching can also be switched to user EXEC by root user mode to root user mode.

First building module 55, for currently having new path creation in the mobile terminal or thering is path to change when monitoring When change, the path reading newly created path or changing obtains answering for the mobile terminal foreground and backstage current active With the packet name of program, the corresponding relationship between the path of reading and the packet name of acquisition is established;It establishes comprising reading The tables of data of corresponding relationship between the path and the packet name of acquisition includes path to be determined and packet name as described First tables of data of corresponding relationship.

In current newly created path or there are the path of change, a packet name with current foreground and the application program of background activity Between establish corresponding relationship, so as to reduce the quantity of the corresponding relationship between the path of foundation and packet name, improve subsequent Determine efficiency.The corresponding relationship can be one-to-many relationship, be also possible to many-to-one relationship, it can be by a path It is corresponding with multiple packet names, it is also possible to multiple paths are corresponding with the same packet name.

In aforementioned decision paths and the Installation practice of packet name corresponding relationship, optionally, the decision paths and packet The device of name corresponding relationship further includes the second building module 56, computing module 57 and third building module 58;Wherein

Second building module 56 includes have been determined as correct path and packet name corresponding relationship in advance for establishing Two tables of data.As an alternative embodiment, can be established by artificial mode include have been determined as in advance correct path with Second tables of data of packet name corresponding relationship can also obtain path and packet name corresponding relationship in the second tables of data by burying point mode Data.

Computing module 57, for by the second tables of data path and packet name corresponding relationship in path and packet name respectively into The second set of correspondences is established in row cutting;The second corresponding relationship of each of the second corresponding relationship concentration, is the second tables of data Corresponding relationship between the cutting vocabulary in middle path and the cutting vocabulary of packet name corresponding with the path;Described second corresponding pass Path is identical as the quantity of packet name corresponding relationship in the quantity of the second corresponding relationship, and the second tables of data in assembly;

The frequency of the second corresponding relationship each of is concentrated to calculate the second corresponding relationship according to following formula:

F2=j/k;

Wherein, F2 is the frequency that the second corresponding relationship concentrates one of them the second corresponding relationship;

J is to concentrate in the second corresponding relationship, all second corresponding passes identical with one of them described second corresponding relationship The sum of quantity of system;

K be the second corresponding relationship concentrate, comprising in one of them described second corresponding relationship path cutting vocabulary or The sum of the quantity of all second corresponding relationships of packet name cutting vocabulary;

Third constructs module 58, for according to the second corresponding relationship of each of the second corresponding relationship concentration being calculated Frequency establishes the second corresponding relationship frequency table.

In aforementioned decision paths and the Installation practice of packet name corresponding relationship, optionally, the second building module 56, Include:

Second monitoring submodule 561, under the root user mode of mobile terminal, by client application to shifting The creation or change in path are monitored in dynamic terminal;

4th building submodule 562 currently has new path to create or have road for working as to monitor in the mobile terminal When diameter changes, the path reading newly created path or changing obtains the mobile terminal foreground and backstage current active Application program packet name, establish the corresponding relationship between the path of reading and the packet name of acquisition;It establishes comprising reading The tables of data of corresponding relationship between the path taken and the packet name of acquisition, as it is described include to have been determined as in advance Second tables of data in correct path and packet name corresponding relationship.

Corresponding relationship in second tables of data can be one-to-many relationship, be also possible to many-to-one relationship, it can It is that a path is corresponding with multiple packet names, it is corresponding with the same packet name is also possible to multiple paths.

Figure 10 is the structural schematic diagram of one embodiment of electronic equipment of the present invention.Referring to Figure 10, electronic equipment of the present invention is implemented Example includes: shell 81, processor 82, memory 83, circuit board 84 and power circuit 85, wherein circuit board 84 is placed in shell 81 space interiors surrounded, processor 82 and memory 83 are arranged on circuit board 84;Power circuit 85, for being above-mentioned electronics The each circuit or device of equipment are powered;Memory 83 is for storing executable program code;Processor 82 is by reading storage The executable program code stored in device runs program corresponding with executable program code, for executing aforementioned decision paths Step described in method any embodiment with packet name corresponding relationship.

Electronic equipment provided in an embodiment of the present invention, it is similar to packet name corresponding relationship by determination path to be determined Degree, and judge whether the similarity is greater than the predetermined threshold value first set and then determines first path if more than preset threshold value It is set up with packet name corresponding relationship, thus, it is possible to relatively accurately determine installation kit corresponding to path.

The electronic equipment exists in a variety of forms, including but not limited to:

(1) mobile communication equipment: the characteristics of this kind of equipment is that have mobile communication function, and to provide speech, data Communication is main target.This Terminal Type includes: smart phone (such as iPhone), multimedia handset, functional mobile phone and low Hold mobile phone etc..

(2) super mobile personal computer equipment: this kind of equipment belongs to the scope of personal computer, there is calculating and processing function Can, generally also have mobile Internet access characteristic.This Terminal Type includes: PDA, MID and UMPC equipment etc., such as iPad.

(3) portable entertainment device: this kind of equipment can show and play multimedia content.Such equipment include: audio, Video player (such as iPod), handheld device, e-book and intelligent toy and portable car-mounted navigation equipment.

(4) server: providing the equipment of the service of calculating, and the composition of server includes that processor, hard disk, memory, system are total Line etc., server is similar with general computer architecture, but due to needing to provide highly reliable service, in processing energy Power, stability, reliability, safety, scalability, manageability etc. are more demanding.

(5) other electronic devices with data interaction function.

Those of ordinary skill in the art will appreciate that realizing all or part of the process in above-described embodiment method, being can be with Relevant hardware is instructed to complete by computer program, the program can be stored in a computer-readable storage medium In, the program is when being executed, it may include such as the process of the embodiment of above-mentioned each method.Wherein, the storage medium can be magnetic Dish, CD, read-only memory (Read-Only Memory, ROM) or random access memory (RandomAccess Memory, RAM) etc..

The above description is merely a specific embodiment, but scope of protection of the present invention is not limited thereto, any In the technical scope disclosed by the present invention, any changes or substitutions that can be easily thought of by those familiar with the art, all answers It is included within the scope of the present invention.Therefore, protection scope of the present invention should be subject to the protection scope in claims.

Claims (15)

1. a kind of method of decision paths and packet name corresponding relationship characterized by comprising
From the first tables of data comprising path to be determined and packet name corresponding relationship, first path pass corresponding with packet name is read System;
It determines in first path and packet name corresponding relationship, the similarity in path and packet name;
If in first path and packet name corresponding relationship, the similarity of path and packet name is greater than the first predetermined threshold, then first is determined Path and packet name corresponding relationship are set up;
Wherein, in the determining first path and packet name corresponding relationship, the similarity in path and packet name, comprising:
Judge in first path and packet name corresponding relationship, whether path and packet name include common character string;If the path Include common character string with packet name, then assigns the first weighted value to first path and packet name corresponding relationship;
By in path in the first tables of data and packet name corresponding relationship path and packet name carry out cutting respectively, establish first and corresponding close Assembly;First corresponding relationship each of concentrates the first corresponding relationship, be in the first tables of data the cutting vocabulary in path and with Corresponding relationship between the cutting vocabulary of the corresponding packet name in the path;First corresponding relationship concentrates the first corresponding relationship Path is identical as the quantity of packet name corresponding relationship in quantity, and the first tables of data;
The frequency for carrying out the first corresponding relationship established after cutting with packet name corresponding relationship to first path calculates, and judges Whether the frequency of first corresponding relationship is greater than the second predetermined threshold;If the frequency of first corresponding relationship is greater than the second predetermined threshold Value, then judge that first corresponding relationship whether there is in the second corresponding relationship frequency table;Wherein, the second corresponding relationship frequency It include the frequency of the second corresponding relationship and the second corresponding relationship in number table, second corresponding relationship is to have been determined as in advance Path and packet name in correct path and packet name corresponding relationship carry out the corresponding relationship established after cutting respectively;
If first corresponding relationship exists in the second corresponding relationship frequency table, it is corresponding second to read first corresponding relationship Corresponding frequency in relationship frequency table;Judge first corresponding relationship frequency corresponding in the second corresponding relationship frequency table Whether third predetermined threshold is greater than;
If first corresponding relationship frequency corresponding in the second corresponding relationship frequency table is greater than third predetermined threshold, to the One path and packet name corresponding relationship assign the second weighted value;
First weighted value and the second weighted value are added, obtained in first path and packet name corresponding relationship, path with The similarity of packet name.
2. the method for decision paths according to claim 1 and packet name corresponding relationship, which is characterized in that it is described from comprising to In the path of judgement and the first tables of data of packet name corresponding relationship, first path and packet name corresponding relationship are read, comprising:
Read the first tables of data comprising path to be determined and packet name corresponding relationship, in the first tables of data path and packet name Corresponding relationship is filtered;
From the path and packet name corresponding relationship retained after filtering, first path and packet name corresponding relationship are read;
Wherein, in the first tables of data path and packet name corresponding relationship be filtered include: will be comprising following any case Path is filtered out with packet name corresponding relationship:
Path and common path exact matching;
Path is the self-built path of user.
3. the method for decision paths according to claim 1 and packet name corresponding relationship, which is characterized in that
In the judgement first path and packet name corresponding relationship, whether path and packet name include common character string, comprising: are sentenced In disconnected first path and packet name corresponding relationship, whether subpath and packet name in path include common character string.
4. the method for decision paths according to claim 1 and packet name corresponding relationship, which is characterized in that described to the first via The frequency that diameter carries out the first corresponding relationship established after cutting with packet name corresponding relationship is calculated, comprising:
The frequency for the first corresponding relationship that first path and packet name corresponding relationship establish after cutting according to following formula into Row calculates:
F1=n/m;
Wherein, F1 is the frequency that the first corresponding relationship established after cutting is carried out to first path and packet name corresponding relationship;
N is to concentrate in the first corresponding relationship, corresponding with to first established after first path and the progress cutting of packet name corresponding relationship The sum of the quantity of identical all first corresponding relationships of relationship;
M be the first corresponding relationship concentrate, comprising first path in packet name corresponding relationship path cutting vocabulary or packet name cut Segment the sum of the quantity of all first corresponding relationships converged.
5. the method for decision paths according to claim 1 and packet name corresponding relationship, which is characterized in that from comprising wait sentence In first tables of data in fixed path and packet name corresponding relationship, before reading first path and packet name corresponding relationship, the judgement The method in path and packet name corresponding relationship, further includes:
Creation or change under the user EXEC of mobile terminal, by client application to path in mobile terminal It is monitored;
When monitoring currently has new path creation or has path change in the mobile terminal, read newly created path or The path to change obtains the packet name of the application program of the mobile terminal foreground and backstage current active, establishes reading Corresponding relationship between the path and the packet name of acquisition;
Foundation includes the tables of data of the corresponding relationship between the packet name for the path and acquisition read, and includes as described First tables of data in path and packet name corresponding relationship to be determined.
6. the method for decision paths according to claim 1 and packet name corresponding relationship, which is characterized in that from comprising wait sentence In first tables of data in fixed path and packet name corresponding relationship, before reading first path and packet name corresponding relationship, the judgement The method in path and packet name corresponding relationship, further includes:
Foundation includes to have been determined as second tables of data in correct path Yu packet name corresponding relationship in advance;
Path in second tables of data and the path in packet name corresponding relationship and packet name are subjected to cutting respectively, it is corresponding to establish second Set of relations;Second corresponding relationship each of concentrates the second corresponding relationship, be in the second tables of data the cutting vocabulary in path and Corresponding relationship between the cutting vocabulary of packet name corresponding with the path;Second corresponding relationship concentrates the second corresponding relationship Quantity, and path is identical as the quantity of packet name corresponding relationship in the second tables of data;
The frequency of the second corresponding relationship each of is concentrated to calculate the second corresponding relationship according to following formula:
F2=j/k;
Wherein, F2 is the frequency that the second corresponding relationship concentrates one of them the second corresponding relationship;
J is to concentrate in the second corresponding relationship, all second corresponding relationships identical with one of them described second corresponding relationship The sum of quantity;
K is to concentrate in the second corresponding relationship, includes the path cutting vocabulary or packet name in one of them described second corresponding relationship The sum of the quantity of all second corresponding relationships of cutting vocabulary;
According to the frequency of the second corresponding relationship of each of the second corresponding relationship concentration being calculated, the described second corresponding pass is established It is frequency table.
7. the method for decision paths according to claim 6 and packet name corresponding relationship, which is characterized in that the foundation includes There is the second tables of data for having been determined as correct path Yu packet name corresponding relationship in advance, comprising:
Under the root user mode of mobile terminal, by client application to the creation in path in mobile terminal or change into Row monitoring;
When monitoring currently has new path creation or has path change in the mobile terminal, read newly created path or The path to change obtains the packet name of the application program of the mobile terminal foreground and backstage current active, establishes reading Corresponding relationship between the path and the packet name of acquisition;
Foundation includes the tables of data of the corresponding relationship between the packet name for the path and acquisition read, and includes as described There is the second tables of data for having been determined as correct path Yu packet name corresponding relationship in advance.
8. the device of a kind of decision paths and packet name corresponding relationship characterized by comprising
Source data read module, for from the first tables of data comprising path to be determined and packet name corresponding relationship, reading the One path and packet name corresponding relationship;
Similarity determining module, for determining in first path and packet name corresponding relationship, the similarity in path and packet name;
Judgment module, if the similarity of path and packet name is greater than the first predetermined threshold in first path and packet name corresponding relationship Value then determines that first path and packet name corresponding relationship are set up;
The similarity determining module, including the first determining submodule, the second determining submodule and accumulator module;Wherein
Described first determines submodule, for judging in first path and packet name corresponding relationship, path and packet name whether include Common character string;If the path and packet name include common character string, first path and packet name corresponding relationship are assigned Give the first weighted value;
Described second determines submodule, is used for:
By in path in the first tables of data and packet name corresponding relationship path and packet name carry out cutting respectively, establish first and corresponding close Assembly;First corresponding relationship each of concentrates the first corresponding relationship, be in the first tables of data the cutting vocabulary in path and with Corresponding relationship between the cutting vocabulary of the corresponding packet name in the path;First corresponding relationship concentrates the first corresponding relationship Path is identical as the quantity of packet name corresponding relationship in quantity, and the first tables of data;
The frequency for carrying out the first corresponding relationship established after cutting with packet name corresponding relationship to first path calculates, and judges Whether the frequency of first corresponding relationship is greater than the second predetermined threshold;If the frequency of first corresponding relationship is greater than the second predetermined threshold Value, then judge that first corresponding relationship whether there is in the second corresponding relationship frequency table;Wherein, the second corresponding relationship frequency It include the frequency of the second corresponding relationship and the second corresponding relationship in number table, second corresponding relationship is to have been determined as in advance Path and packet name in correct path and packet name corresponding relationship carry out the corresponding relationship established after cutting respectively;
If first corresponding relationship exists in the second corresponding relationship frequency table, it is corresponding second to read first corresponding relationship Corresponding frequency in relationship frequency table;Judge first corresponding relationship frequency corresponding in the second corresponding relationship frequency table Whether third predetermined threshold is greater than;
If first corresponding relationship frequency corresponding in the second corresponding relationship frequency table is greater than third predetermined threshold, to the One path and packet name corresponding relationship assign the second weighted value;
The accumulator module obtains first path and packet name for being added to first weighted value and the second weighted value In corresponding relationship, the similarity in path and packet name.
9. the device of decision paths according to claim 8 and packet name corresponding relationship, which is characterized in that the source data is read Modulus block, comprising:
First reading submodule includes path and the first tables of data of packet name corresponding relationship to be determined for reading;
Filter submodule, for being filtered to the path in the first tables of data with packet name corresponding relationship;
Second reading submodule, for reading first path and packet name from the path and packet name corresponding relationship retained after filtering Corresponding relationship;
Wherein, in the first tables of data path and packet name corresponding relationship be filtered include: will be comprising following any case Path is filtered out with packet name corresponding relationship:
Path and common path exact matching;
Path is the self-built path of user.
10. the device of decision paths according to claim 8 and packet name corresponding relationship, which is characterized in that
Described first determines submodule, for judging in first path and packet name corresponding relationship, subpath and packet name in path It whether include common character string;If the subpath and packet name in the path include common character string, to first Path and packet name corresponding relationship assign the first weighted value.
11. the device of decision paths according to claim 8 and packet name corresponding relationship, which is characterized in that described second really Stator modules, comprising:
First computational submodule, for establish after cutting to first path and packet name corresponding relationship according to following formula The frequency of one corresponding relationship is calculated:
F1=n/m;
Wherein, F1 is the frequency that the first corresponding relationship established after cutting is carried out to first path and packet name corresponding relationship;
N is to concentrate in the first corresponding relationship, corresponding with to first established after first path and the progress cutting of packet name corresponding relationship The sum of the quantity of identical all first corresponding relationships of relationship;
M be the first corresponding relationship concentrate, comprising first path in packet name corresponding relationship path cutting vocabulary or packet name cut Segment the sum of the quantity of all first corresponding relationships converged.
12. the device of decision paths according to claim 8 and packet name corresponding relationship, which is characterized in that described device is also Include:
First monitoring module, under the user EXEC of mobile terminal, by client application to mobile terminal The creation or change in middle path are monitored;
First building module, for when monitoring currently has new path creation or has path change in the mobile terminal, The path reading newly created path or changing obtains the application program on the mobile terminal foreground and backstage current active Packet name, establish the corresponding relationship between the path of reading and the packet name of acquisition;Establish the road comprising reading The tables of data of corresponding relationship between diameter and the packet name of acquisition includes path to be determined pass corresponding with packet name as described First tables of data of system.
13. the device of decision paths according to claim 8 and packet name corresponding relationship, which is characterized in that described device is also Module is constructed including the second building module, computing module and third;Wherein
Second building module, includes the second data for having been determined as correct path Yu packet name corresponding relationship in advance for establishing Table;
Computing module, for by the second tables of data path in packet name corresponding relationship path and packet name cut respectively Point, establish the second set of correspondences;The second corresponding relationship of each of the second corresponding relationship concentration, is the second tables of data Road Corresponding relationship between the cutting vocabulary of diameter and the cutting vocabulary of packet name corresponding with the path;Second set of correspondences In the second corresponding relationship quantity, and path is identical as the quantity of packet name corresponding relationship in the second tables of data;
The frequency of the second corresponding relationship each of is concentrated to calculate the second corresponding relationship according to following formula:
F2=j/k;
Wherein, F2 is the frequency that the second corresponding relationship concentrates one of them the second corresponding relationship;
J is to concentrate in the second corresponding relationship, all second corresponding relationships identical with one of them described second corresponding relationship The sum of quantity;
K is to concentrate in the second corresponding relationship, includes the path cutting vocabulary or packet name in one of them described second corresponding relationship The sum of the quantity of all second corresponding relationships of cutting vocabulary;
Third constructs module, the frequency of the second corresponding relationship of each of the second corresponding relationship concentration being calculated for basis, Establish the second corresponding relationship frequency table.
14. the device of decision paths according to claim 13 and packet name corresponding relationship, which is characterized in that second structure Model block, comprising:
Second monitoring submodule, under the root user mode of mobile terminal, by client application to mobile terminal The creation or change in middle path are monitored;
4th building submodule currently has new path to create or have path change for working as to monitor in the mobile terminal When, the path reading newly created path or changing obtains the application on the mobile terminal foreground and backstage current active The packet name of program establishes the corresponding relationship between the path of reading and the packet name of acquisition;Establish the institute comprising reading The tables of data for stating the corresponding relationship between path and the packet name of acquisition, as it is described include in advance have been determined as correctly Second tables of data in path and packet name corresponding relationship.
15. a kind of electronic equipment, which is characterized in that the electronic equipment includes: shell, processor, memory, circuit board and electricity Source circuit, wherein circuit board is placed in the space interior that shell surrounds, and processor and memory setting are on circuit boards;Power supply Circuit, for each circuit or the device power supply for above-mentioned electronic equipment;Memory is for storing executable program code;Processing Device runs program corresponding with executable program code by reading the executable program code stored in memory, for holding The method of the described in any item decision paths of row claim 1-7 and packet name corresponding relationship.
CN201510614215.7A 2015-09-23 2015-09-23 The method, apparatus and electronic equipment of decision paths and packet name corresponding relationship CN105205152B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510614215.7A CN105205152B (en) 2015-09-23 2015-09-23 The method, apparatus and electronic equipment of decision paths and packet name corresponding relationship

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510614215.7A CN105205152B (en) 2015-09-23 2015-09-23 The method, apparatus and electronic equipment of decision paths and packet name corresponding relationship

Publications (2)

Publication Number Publication Date
CN105205152A CN105205152A (en) 2015-12-30
CN105205152B true CN105205152B (en) 2019-04-02

Family

ID=54952835

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510614215.7A CN105205152B (en) 2015-09-23 2015-09-23 The method, apparatus and electronic equipment of decision paths and packet name corresponding relationship

Country Status (1)

Country Link
CN (1) CN105205152B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102999606A (en) * 2012-11-21 2013-03-27 东莞宇龙通信科技有限公司 Software deleting method and device
CN103176828A (en) * 2013-03-29 2013-06-26 北京奇虎科技有限公司 Method and device of deleting application program residual files
CN103995774A (en) * 2014-05-16 2014-08-20 北京金山网络科技有限公司 Method and device for detecting software installation package
CN104021005A (en) * 2013-03-01 2014-09-03 联想(北京)有限公司 Information processing method and device

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103677876A (en) * 2012-09-12 2014-03-26 中兴通讯股份有限公司 Manufacturing and installing method, device and system of software installation package
CN103559299B (en) * 2013-11-14 2017-02-15 贝壳网际(北京)安全技术有限公司 File cleaning method, and a mobile terminal apparatus

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102999606A (en) * 2012-11-21 2013-03-27 东莞宇龙通信科技有限公司 Software deleting method and device
CN104021005A (en) * 2013-03-01 2014-09-03 联想(北京)有限公司 Information processing method and device
CN103176828A (en) * 2013-03-29 2013-06-26 北京奇虎科技有限公司 Method and device of deleting application program residual files
CN103995774A (en) * 2014-05-16 2014-08-20 北京金山网络科技有限公司 Method and device for detecting software installation package

Also Published As

Publication number Publication date
CN105205152A (en) 2015-12-30

Similar Documents

Publication Publication Date Title
EP2787591A2 (en) System and Method for Determining Proximity
WO2004077273A3 (en) Photosharing server filters for automatic storage and sharing of digital files
CN105354196A (en) Information pushing method and information pushing apparatus
JP5108964B2 (en) Apparatus and method for calculating the battery allotted time for the mobile station
WO2005119496A3 (en) Dependency graph-based aggregate asset status reporting methods and apparatus
CN104239195B (en) A method of processing an electronic device and the power consumption of the electronic device
CN103294530B (en) A terminal device and method for application management terminal device
CN104182545A (en) Application program recommending method and device
US20170329785A1 (en) Application recommendation method, server, and computer readable medium
US20170322981A1 (en) Method and device for social platform-based data mining
CN107852410B (en) Dissect rogue access point
US20090083299A1 (en) Method and apparatus for managing a contact list
RU2013120086A (en) Aggregation device location information and a way to aggregate information about the location
CN103873630A (en) Contact person information management method and device
CN102693229B (en) Software analysis, the recommended method to analyze the device and the device is recommended
KR101685564B1 (en) Social network grouping method and system, and computer storage medium
CN105262155B (en) Method and apparatus for charging Species
US9473619B2 (en) Systems and methods for contacts management
CA2765111C (en) Method and system for estimating age of a user based on mass data
JP5713301B2 (en) Battery charging method and mobile terminal
CN103294809B (en) A user group matching method and device
CN104281510A (en) Application program power consumption degree obtaining method and system, and energy saving method and system
CN104252478B (en) An application recommended method, related equipment and systems
US20160267501A1 (en) Calculation method and apparatus for user retention ratio
WO2008102681A1 (en) Circuit operation worst condition decision system, method, and program

Legal Events

Date Code Title Description
C06 Publication
C10 Entry into substantive examination
GR01 Patent grant