Abstract:
An application name modification method, said method comprising: selecting a target application and, by means of a preset application inlet, modifying the application name of the selected target application; obtaining original information regarding the selected target application, and linking together and storing the obtained original information regarding said target application and the modified new application name. Additionally disclosed are an application name modification device and a computer-readable storage medium.

Description:
TECHNICAL FIELD 
       [0001]    The disclosure relates to application processing in an android platform, and in particular to a method and device for modifying an application label, and a non-transitory computer-readable storage medium. 
       BACKGROUND 
       [0002]    Customization has always been popular in mobile terminal users. With rapid development of smart mobile platforms, particularly open android platforms launched by Google, there are increasing demands of terminal users for customization. To facilitate applications, a user may expect to be able to change an application name to be displayed as needed, just as in an operating system in a Personal Computer (PC). 
         [0003]    In related art, changing an application name displayed may be supported by some software, usually with a root permission required, or effectively only by software on a current desktop. A user-changed application name displayed will no longer work upon desktop changing. 
       SUMMARY 
       [0004]    Embodiments herein provide a method and device for modifying an application label, and a non-transitory computer-readable storage medium, such that a user is allowed to modify an application label as needed in any desktop without needing a specific permission. 
         [0005]    A technical solution according to an embodiment herein may be implemented as follows. 
         [0006]    According to an embodiment herein, a method for modifying an application label includes: 
         [0007]    receiving a selected target application, and modifying, via a pre-set application gateway, an application label of the selected target application to be a new application label; and 
         [0008]    obtaining original information on the selected target application, and storing the new application label in association with the obtained original information on the target application. 
         [0009]    The storing the new application label in association with the obtained original information on the target application may include: storing the new application label in a list of applications together with the obtained original information on the target application. 
         [0010]    The original information on the target application may include a package name and a class name that uniquely identify the target application. 
         [0011]    The storing the new application label in association with the obtained original information on the target application may include: constructing a mapping structure, and storing, in the mapping structure, the new application label, the obtained package name and the obtained class name of the target application respectively as application items. 
         [0012]    A mapping structure may serve as a node of application items in the list of applications. 
         [0013]    The modifying, via a pre-set application gateway, an application label of the selected target application to be a new application label may include: 
         [0014]    receiving the input new application label via the application gateway, and sending an acknowledgment message including the new application label. 
         [0015]    The obtaining original information on the selected target application, and storing the new application label in association with the obtained original information on the target application may include: 
         [0016]    after receiving the acknowledgment message, obtaining the package name and the class name of the selected target application; reading data in nodes of application items; in response to determining that there is, in the read data, a matching application with a package name and a class name that match the obtained package name and the obtained class name, replacing an application label of the matching application in the data in the nodes of application items with the new application label, and displaying the new application label; in response to determining that there is, in the read data, no matching application with a package name and a class name that match the obtained package name and the obtained class name, constructing a mapping structure, storing, in the mapping structure, the new application label included in the acknowledgment message together with the obtained package name and the obtained class name, and placing the mapping structure in the list of applications as a new node of application items. 
         [0017]    The reading data in nodes of application items may include: in response to determining that a number of read nodes of application items is 0, ending a current operation; in response to determining that a number of read nodes of application items is greater than 0, reading data in each of the nodes of application items and matching a package name and a class name of an application in the read data to the obtained package name and the obtained class name, until a matching application is found or until the matching has been performed for each of the nodes of application items. 
         [0018]    According to an embodiment herein, a device for modifying an application label includes an application gateway unit and a mapping unit. 
         [0019]    The application gateway unit may be configured for: after a target application is selected, modifying an application label of the selected target application to be a new application label according to an input. 
         [0020]    The mapping unit may be configured for obtaining original information on the selected target application, and storing the new application label in association with the obtained original information on the target application. 
         [0021]    The mapping unit may be configured for storing the new application label in association with the obtained original information on the target application by: storing the new application label in a list of applications together with the obtained original information on the target application. 
         [0022]    The original information on the target application may include a package name and a class name that uniquely identify the target application. 
         [0023]    The mapping unit may be configured for storing the new application label in association with the obtained original information on the target application by: constructing a mapping structure, and storing, in the mapping structure, the new application label, the obtained package name and the obtained class name of the target application respectively as application items. A mapping structure may serve as a node of application items in the list of applications. 
         [0024]    The device may further include an application display unit configured for receiving and displaying the new application label. 
         [0025]    The application gateway unit may be configured for modifying the application label of the selected target application to be the new application label according to the input by: receiving the input new application label, and sending an acknowledgment message including the new application label. 
         [0026]    The mapping unit may be configured for: after receiving the acknowledgment message, obtaining the package name and the class name of the selected target application; reading data in nodes of application items; in response to determining that there is, in the read data, a matching application with a package name and a class name that match the obtained package name and the obtained class name, replacing an application label of the matching application in the data in the nodes of application items with the new application label, and sending a modification message including the new application label to the application display unit. 
         [0027]    The application display unit may be configured for displaying the new application label according to the modification message. 
         [0028]    The mapping unit may be configured for reading the data in the nodes of application items by: in response to determining that a number of read nodes of application items is 0, ending a current operation; in response to determining that a number of read nodes of application items is greater than 0, reading the data in the nodes of application items node by node. 
         [0029]    According to an embodiment herein, a non-transitory computer-readable storage medium includes instructions for executing the method for modifying an application label. With the method and device for modifying an application label and the non-transitory computer-readable storage medium according to embodiments herein, a target application is selected, and an application label (applabel) of the selected target application is modified, via a pre-set application gateway, to be a new application label; and original information on the selected target application is obtained, and the new application label is stored in association with the obtained original information on the target application. Correspondingly, when the target application is to be used, after a user selects the target application, an operating system of a terminal will obtain the original information on the target application according to the new application label stored in association with the original information on the target application to complete a subsequent operation on the target application. Thus, with embodiments herein, a user is allowed to modify an application label as needed in any desktop without impacting normal use of an application and without the need for a specific permission, thereby reflecting a personal style of the user and improving user experience. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0030]      FIG. 1  is a flowchart of a method for modifying an application label according to an embodiment herein. 
           [0031]      FIG. 2  is a specific flowchart of a method for modifying an application label according to an embodiment herein. 
           [0032]      FIG. 3  is a diagram of a structure of a device for modifying an application label according to an embodiment herein. 
       
    
    
     DETAILED DESCRIPTION 
       [0033]    With embodiments herein, a target application is selected, and an application label of the selected target application is modified, via a pre-set application gateway, to be a new application label; and original information on the selected target application is obtained, and the new application label is stored in association with the obtained original information on the target application. 
         [0034]    Correspondingly, when an application with a modified application label is to be used, after a user selects the target application, an operating system of a terminal will obtain the original information on the target application according to the new application label stored in association with the original information on the target application to complete a subsequent operation on the target application. An application to be used may be an application to be opened or to be run. 
         [0035]    The pre-set application gateway may be an application gateway set on a desktop of the terminal. The user may enter an application label modification interface such as by clicking on the application gateway. The interface may contain an acknowledgement option. Alternatively, an option may be set in the terminal. A window may pop up when the option is selected. The modified new application label may be input in the window. The window may further contain an acknowledgement option. For example, when the user needs to modify an application label of an application, the user may select the target application via an applist interface on the desktop of the terminal. A modification dialog will pop up when the user touches an icon corresponding to the application. The dialog may contain an input box for inputting a new application label. The dialog may further include an acknowledgement button and a cancel button. 
         [0036]    The new application label may be stored in association with the original information on the target application by: storing the new application label together with the original information on the target application, such as in a list of applications (applist). The original information on each application and the new application label corresponding to the each application may serve as a list item in the list of applications. The original information on the target application may include at least a package name and a class name that uniquely identify the target application. 
         [0037]    The disclosure is further elaborated below with reference to the drawings and embodiments. 
         [0038]      FIG. 1  is a flowchart of a method for modifying an application label according to an embodiment herein. As shown in  FIG. 1 , the method for modifying an application label according to an embodiment herein includes steps as follows. 
         [0039]    In S 100 , a target application is selected, and an application label of the selected target application is modified, via a pre-set application gateway, to be a new application label. 
         [0040]    A user may select a target application of which an application label needs to be modified, and then input a new application label of the selected target application via a pre-set application gateway. Refer description above for the application gateway. 
         [0041]    In S 101 , original information on the selected target application is obtained, and the new application label is stored in association with the obtained original information on the target application. 
         [0042]    The new application label may be stored in association with the obtained original information on the target application by: storing the new application label in a list of applications together with the obtained original information on the target application. The original information on the target application may include a package name and a class name that uniquely identify the target application. 
         [0043]    The new application label may be stored in association with the obtained original information on the target application by: constructing a mapping structure, and storing, in the mapping structure, the new application label, the obtained package name and the obtained class name of the target application respectively as application items (appitems). A mapping structure may serve as a node of application items in the list of applications. A mapping structure may be stored in a data partition set in the terminal. The data partition may be placed in any storage space in the terminal other than where the terminal&#39;s own original system operating data are stored. Therefore, when the user restores factory default settings of the terminal, the terminal will delete the mapping structure during automatic removal of application data. 
         [0044]    In practical application, the original information on the target application may be obtained and the new application label may be stored in association with the obtained original information on the target application by a package manager in the terminal. After the user selects the target application and inputs the new application label of the target application via the set application gateway, an acknowledgement message will be sent when the user clicks on an acknowledgement option to trigger the package manager. The acknowledgement message may include the new application label. The package manager may obtain the original information on the target application via an upper application package information managing interface provided thereof. The package manager may obtain the package name and the class name uniquely identifying the target application, construct a mapping structure, store, in the mapping structure, the new application label together with the obtained package name and the obtained class name, and then place the mapping structure in the list of applications. 
         [0045]    Before the mapping structures is constructed, the method may include steps as follows. Data in each node of application items in the list of applications may be traversed. It may be determined whether there is, in the data in the nodes of application items in the list of applications, a matching application with original information matching the obtained original information of the target application. If so, it means that information relevant to the target application has been stored in the list of applications, and it is only required to replace an application label of the matching application in the data in the nodes of application items with the new application label. If not, it means that the target application is not included in the list of applications, and a mapping structure may then be constructed, the new application label may be stored, together with the obtained package name and the obtained class name, in the constructed mapping structure, and then the mapping structure may be placed in the list of applications. 
         [0046]    The package manager may be a standard service located at a frame layer of the operating system of the terminal. The package manager may be for packaging all data structures based on loading information. The package manager may provide various upper application package information managing interfaces may be provided. Aforementioned operation according to an embodiment herein may extend function of the package manager. 
         [0047]    In practical application, when an application with a modified application label is to be used, after the user selects the target application by clicking on it, the package manager of the operating system of the terminal will obtain the original information on the target application according to the new application label stored in association with the original information on the target application to complete a subsequent operation on the target application. 
         [0048]      FIG. 2  is a specific flowchart of a method for modifying an application label according to an embodiment herein. As shown in  FIG. 2 , the method for modifying an application label according to an embodiment herein may include steps as follows. 
         [0049]    In S 200 , a target application may be selected, and an application label of the selected target application may be modified, via a pre-set application gateway, to be a new application label. 
         [0050]    In S 201 , a package name and a class name of the selected target application may be obtained. 
         [0051]    In S 202 , the new application label may be stored in a list of applications together with the obtained package name and the obtained class name of the target application. 
         [0052]    A mapping structure corresponding to the selected target application may have to be constructed first. The new application label, the package name, and the class name of the target application may then be stored in the mapping structure respectively as application items. 
         [0053]    The package name, the class name, and the new application label of each target application may serve as a node of application items in the list of applications. That is to say, a node of application items may be a mapping structure. A diagram of a structure of a mapping structure of a target application according to an embodiment herein may be as follows. 
         [0000]    
       
         
               
               
               
             
           
               
                   
                   
               
             
             
               
                   
                   
                 &lt;applist&gt; 
               
               
                   
                   
                   &lt;appitem&gt; 
               
               
                   
                   
                     &lt;packagename&gt;&lt;/ packagename&gt; 
               
               
                   
                   
                     &lt;classname&gt;&lt;/ classname&gt; 
               
               
                   
                   
                     &lt;applabel&gt;&lt;/ applabel&gt; 
               
               
                   
                   
                   &lt;/ appitem&gt; 
               
               
                   
                   
                 &lt;/ applist&gt; 
               
               
                   
                   
               
             
          
         
       
     
         [0054]    Optionally, in S 203 , the application label of the target application may be replaced with the new application label, and the new application label may be displayed. 
         [0055]    A user may select a target application, input a new application label, and send an acknowledgment message including the new application label. After the acknowledgment message is received, the package name and the class name of the selected target application may be obtained. The data in the nodes of application items may be read. It may be determined whether the obtained package name and the obtained class name of the target application match a package name and a class name of an application in data in a node of application items. If so, the package name and the class name of the matching application in the data in the matching node of application items may be replaced with the new application label, and the new application label may be displayed. When the obtained package name and the obtained class name of the target application match the package name and the class name of no application in the data in the nodes of application items, a mapping structure may be created, the new application label included in the acknowledgment message may be stored, together with the obtained package name and the obtained class name, in the mapping structure, and the mapping structure may be placed in the list of applications as a new node of application items. 
         [0056]    The data in the nodes of application items may be read as follows. When a number of read nodes of application items is 0, a current operation may be ended. When a number of read nodes of application items is greater than 0, the data in each of the nodes of application items may be read, and a package name and a class name of an application in the read data may be compared to the obtained package name and the obtained class name, until a matching application is found or until the matching has been performed on each of the nodes of application items. 
         [0057]    An embodiment herein also provides a non-transitory computer-readable storage medium, including instructions for executing the method for modifying an application label.  FIG. 3  is a diagram of a structure of a device for modifying an application label according to an embodiment herein. As shown in  FIG. 3 , the device for modifying an application label includes an application gateway unit  40  and a mapping unit  41 . 
         [0058]    The application gateway unit  40  may be configured for: after a target application is selected, modifying an application label of the selected target application to be a new application label according to an input. 
         [0059]    The application gateway unit  40  may be pre-arranged in the mobile terminal, such as in a setting module of the mobile terminal, or as a separate functional module. 
         [0060]    The mapping unit  41  may be configured for obtaining original information on the selected target application, and storing the new application label in association with the obtained original information on the target application. 
         [0061]    The mapping unit  41  may be implemented by a package manager. 
         [0062]    The mapping unit  41  may be configured for storing the new application label in association with the obtained original information on the target application by: storing the new application label in a list of applications together with the obtained original information on the target application. The original information on the target application may include a package name and a class name that uniquely identify the target application. 
         [0063]    The mapping unit  41  may be configured for storing the new application label in association with the obtained original information on the target application by: constructing a mapping structure, and storing, in the mapping structure, the new application label, the obtained package name and the obtained class name of the target application respectively as application items. A mapping structure may serve as a node of application items in the list of applications. 
         [0064]    In order to replace the application label of the target application and display the new application label of the target application, the device for modifying an application label may further include an application display unit  42  configured for receiving and displaying the new application label. 
         [0065]    The application gateway unit  40  may be configured for: after the target application has been selected, receiving the input new application label, and sending an acknowledgment message including the new application label. 
         [0066]    The mapping unit  41  may be configured for: after receiving the acknowledgment message, obtaining the package name and the class name of the selected target application; reading data in nodes of application items in the list of applications; in response to determining that there is, in the read data in a node of application items, a matching application with a package name and a class name that match the obtained package name and the obtained class name, replacing an application label of the matching application in the data in the nodes of application items with the new application label, and sending a modification message including the new application label to the application display unit  42 . The application display unit  42  may be configured for displaying the new application label after receiving the modification message. 
         [0067]    The mapping unit  41  may be configured for: in response to determining that a number of read nodes of application items is 0, ending a current operation; in response to determining that a number of read nodes of application items is greater than 0, reading data in each of the nodes of application items and matching a package name and a class name of an application in the read data to the obtained package name and the obtained class name, until a matching application is found or until the matching has been performed for each of the nodes of application items. 
         [0068]    In practical application, the application gateway unit  40 , the mapping unit  41 , and the application display unit  42  may be implemented by a Central Processing Unit (CPU), a Micro Processor Unit (MPU), a Digital Signal Processor (DSP), a Field-Programmable Gate Array (FPGA) or the like located in the terminal. 
         [0069]    Those skilled in the art will know that an embodiment herein may provide a method, device, system, or computer program product. Therefore, an embodiment herein may take on a form of hardware, software, or a combination thereof. In addition, an embodiment herein may take on a form of a computer program product implemented on one or more computer available storage media (including but not limited to, magnetic disk memory, optic memory, and the like) containing computer available program codes. 
         [0070]    The disclosure is illustrated with reference to flowcharts and/or block diagrams of the method, device (system) and computer-program product according to embodiments described herein. Note that each flow in the flowcharts and/or each block in the block diagrams as well as combination of flows in the flowcharts and/or blocks in the block diagrams may be implemented by instructions of a computer program. Such instructions may be offered in a processor of a general-purpose computer, a dedicated computer, an embedded processor or other programmable data processing devices to generate a machine, such that a device with a function specified in one or more flows of the flowcharts and/or one or more blocks in the block diagrams is produced by instructions executed by a processor of a computer or other programmable data processing devices. 
         [0071]    These computer-program instructions may also be stored in a non-transitory computer-readable memory capable of guiding a computer or another programmable data processing device to work in a given way, such that the instructions stored in the computer-readable memory generate a manufactured good including an instruction device for implementing a function specified in one or more flows of the flowcharts and/or one or more blocks in the block diagrams. 
         [0072]    These computer-program instructions may also be loaded in a computer or other programmable data processing devices, which thus executes a series of operations thereon to generate computer-implemented processing, such that the instructions executed on the computer or other programmable data processing devices provide the steps for implementing the function specified in one or more flows of the flowcharts or one or more blocks in the block diagrams. 
         [0073]    What described are merely embodiments of the disclosure and are not intended to limit the protection scope of the disclosure. 
       INDUSTRIAL APPLICABILITY 
       [0074]    With the method and device for modifying an application label and the non-transitory computer-readable storage medium according to embodiments herein, a target application is selected, and an application label of the selected target application is modified, via a pre-set application gateway, to be a new application label; and original information on the selected target application is obtained, and the new application label is stored in association with the obtained original information on the target application. A user is allowed to modify an application label as needed in any desktop without impacting normal use of an application and without the need for a specific permission.