The content of the invention
The method and device for identifying, adding and changing the technical problem to be solved in the present invention is to provide a kind of list items,
In the case of ensureing that fileinfo correctly stores in list items, the space shared by fileinfo in storage list items is reduced, is carried
Speed of the high listing file in loading.
A kind of list items identification method, including:
Determine file destination corresponding to target column list item;
The file identification of the target column list item is determined according to the fileinfo of the file destination.
Preferably, the fileinfo according to the file destination determines the file identification of the target column list item, tool
Body is:
Determine the store path of the file destination;
According to the store path, the higher level's catalogue for storing the file destination is obtained as target directory;
By the filename of directory information and file destination corresponding to the target directory, the files-designated as target column list item
Know.
Preferably, it is described by the filename of directory information and file destination corresponding to the target directory, as target column
The file identification of list item, it is specially:
The target directory corresponding directory entry numbering in catalogue allocation table is searched according to the title of the target directory
With corresponding directory entry storage address;
By directory entry numbering, the filename of the directory entry storage address and the file destination, as the mesh
Mark the file identification of list items.
A kind of list items adding method, including:
Determine target location of the target column list item in listed files;
Determine the file identification of target column list item;
The target location file identification of the target column list item being stored in the listed files.
A kind of list items amending method, including:
Determine the file identification of target column list item;
The file identification that list items store in listed files will be replaced replace with the files-designated of the target column list item
Know.
A kind of list items identity device, including:File destination determining module and file identification determining module;
The file destination determining module, for determining file destination corresponding to target column list item;
The file identification determining module, for determining the target column list item according to the fileinfo of the file destination
File identification.
Preferably, the file identification determining module includes:Path determination sub-module, target directory determination sub-module and text
Part mark generation submodule;
The path determination sub-module, for determining the store path of the file destination;
The target directory determination sub-module, for according to the store path, obtaining and storing the upper of the file destination
Level catalogue is as target directory;
The file identification generates submodule, for by the text of directory information and file destination corresponding to the target directory
Part name, the file identification as target column list item.
Preferably, the file identification generation submodule includes:Catalogue distributes table search submodule and file identification preserves
Submodule;
The catalogue distributes table search submodule, exists for searching the target directory according to the title of the target directory
Corresponding directory entry numbering and corresponding directory entry storage address in catalogue allocation table;
The file identification preserves submodule, for by directory entry numbering, the directory entry storage address and described
The filename of file destination, the file identification as the target column list item.
A kind of list items adding set, including:List items position determination module, list items mark determining module and list items
Identify preserving module;
The list items position determination module, for determining target location of the target column list item in listed files;
The list items identify determining module, for determining the file identification of target column list item;
The list items identify preserving module, are arranged for the file identification of the target column list item to be stored in into the file
Target location in table.
A kind of list items change device, including:Replace mark determining module and mark replacement module;
It is described to replace mark determining module, for determining the file identification of replacement list items;
The mark replacement module, institute is replaced with for the file identification that list items store in listed files will to be replaced
State the file identification for replacing list items.
Compared with prior art, the present invention has advantages below:
The present invention, due to only have recorded the information of file destination in list items, is not required to when being identified to list items
The long path address of file destination is re-recorded, therefore can effectively reduce file storage address institute in the file identification of list items
The space of occupancy.
Embodiment
In order to facilitate the understanding of the purposes, features and advantages of the present invention, below in conjunction with the accompanying drawings to the present invention
Embodiment be described in detail.
Referring to Fig. 1, the figure is the flow chart of list items identification method first embodiment provided by the invention.
In the present embodiment, including:
S101:Determine file destination corresponding to target column list item.
S102:The file identification of the target column list item is determined according to the fileinfo of the file destination.
In conventional player, video display window and playlist window are generally divided into.In playlist window
Played file is shown by way of list items.User selects some row in playlist when using player
List item is that can play the file corresponding to the list items.
In the present embodiment, because each list items corresponds to a media file.Therefore, it is first determined object listing
File destination corresponding to.
Because each file has corresponding file attribute information, directory name, catalogue as where file are being grasped
Make corresponding catalog number and the physical storage address of catalogue, the title of file, size, file type etc. in system.Therefore, will
The relevant file attribute information of file destination is stored in the file identification of the list items corresponding to file destination.In the present embodiment
In can preserve the file name of the catalog number of file storage catalogue, storage address and file destination, file can also be preserved
Other information, such as file creation time, file size.
After being identified to list items, list window can be stored the file identification of list items, be adjusted in next time
File identification can corresponding to the list items during file according to list items directly invokes file destination, and no longer need by
Layer accesses the catalogues at different levels in store path.
Due to only have recorded the specific address information of file destination in list items in the present embodiment, it is not necessary to re-record mesh
The long path address of file is marked, therefore can effectively reduce the sky in the file identification of list items shared by file storage address
Between.Meanwhile in file destination corresponding to playlist item, the speed that file destination corresponding to list items loads can also be improved
Degree.
Referring to Fig. 2, the figure is the flow chart of list items identification method second embodiment provided by the invention.
In the present embodiment, S201 steps are identical with the S101 steps of this method first embodiment, are no longer situated between herein
Continue.
The fileinfo according to the file destination determines the file identification of the target column list item, is specially:
S202:Determine the store path of the file destination.
S203:According to the store path, the higher level's catalogue for storing the file destination is obtained as target directory.
S204:By the filename of directory information and file destination corresponding to the target directory, as target column list item
File identification.
Due to the file satellite information of file destination include documentary store path, directory name, file name and
The information such as type.Therefore, it is true according to the file satellite information of file destination it is determined that after file destination corresponding to target column list item
Set the goal the store path of file.
Higher level's catalogue of file destination position is obtained from the store path.Wherein higher level's catalogue can be file destination
The upper level catalogue of position.Assuming that file destination is to be stored in following position:c:Aa a1 1.mp3, then the upper level
Catalogue is a1.
FDT(FDT)It is the title for registration management disk file, type, file attribute, file foundation
Or modification time and date, file the information such as first cluster number and file size form.In an operating system, typically in root mesh
Record under All Files and its subdirectory root FDT(FDT)In all store one " directory entry " or letter
Referred to as " directory entry ".Each directory entry takes 32 bytes, is divided into 8 regions, there is provided the letter of relevant document or subdirectory
Breath.
Therefore, the directory entry information according to corresponding to the directory name of the upper level obtains the directory name, by catalogue
Item information and specific file name are stored in the file identification of target column list item.
.Due to directly passing through these mesh when in use using the bottom identification information that directory information is operating system, user
Record item information can finds corresponding catalogue, in conjunction with the file name of file destination, it is possible to achieve to the quick of file
Directly position, and no longer as traditional mode is needed when calling according to the long path address by successively searching until finding mesh
File is marked, so as to substantially increase the efficiency of ff.
Referring to Fig. 3, the figure is the flow chart of list items identification method 3rd embodiment provided by the invention.
The step of the step of S301-S303 in the present embodiment, is with S201-S203 in identification method second embodiment
It is identical, it is not repeated to introduce herein.
In the present embodiment, it is described by the filename of directory information and file destination corresponding to the target directory, as
The file identification of target column list item, it is specially:
S304:Target directory corresponding directory entry in catalogue allocation table is searched according to the title of the target directory
Numbering and corresponding directory entry storage address;
S305:By directory entry numbering, the filename of the directory entry storage address and the file destination, as mesh
Mark the file identification of list items.
Due in FDT(FDT tables)In the information of file that includes catalogue and wherein store.Such as:Filename
The information such as title, file type, subdirectory type, directory entry numbering.Therefore, can obtain higher level's catalogue title after, according to
The title of higher level's catalogue is in FDT(FDT tables)Directory entry numbering corresponding to middle lookup and the storage address of the directory entry.
The file name of the directory entry found numbering, directory entry storage address and file destination is write into target column list item
File identification in.Wherein, in general, directory entry numbering and directory entry storage address respectively only take up 4 bytes, significantly
Less than traditional long path address.
In invocation target file, the information in file identification by checking target column list item, file destination is found
The directory entry numbering and directory entry storage address of catalogue be present.Mesh is directly found by directory entry numbering and catalogue storage address
Catalogue where marking file, the filename for reusing file destination are matched, and realize the calling to file destination.
Due to using directory entry numbering and bottom mark and bottom address that directory entry storage address is operating system, user
Corresponding catalogue is directly found by directory entry numbering and storage address can when in use, in conjunction with the text of file destination
Part title, it is possible to achieve directly position, no longer first needed as traditional mode when calling according to length to the quick of file
Path address is by successively directory search is until finding file destination, so as to substantially increase the speed of ff and efficiency.
Referring to Fig. 4, the figure is the flow chart of list items adding method first embodiment provided by the invention.
In the present embodiment, including:
S401:Determine target location of the target column list item in listed files.
S402:Determine the file identification of target column list item.
S403:The target location file identification of the target column list item being stored in the listed files.
When using playlist, often it is related to the situation that list items are increased, reduced and changed.
When adding list items in playlist, the target locations of list items can be determined first, for example, it is desired to by mesh
Mark list items are added to first position or N position.
It is determined that behind target location, according to file destination corresponding to target column list item, the files-designated of target column list item is determined
Know.
Wherein, the relevant information of file destination, including file name, store path etc. can be obtained according to file destination.
Again by the store path of file, can obtain file position higher level's catalogue and higher level's catalogue in file directory
Table(FDT tables)In the information such as corresponding directory entry numbering, directory entry address.
Directory entry information corresponding to higher level's catalogue and file name are written to the mark of the fileinfo of target column list item
In knowledge, the mark to file in list items is completed.
When in use, in the file name that can only show each list items of playlist window, row can also be shown
The other information of list item file, such as directory entry are numbered.
User can also store other information in file identification, such as file size, file creation time, file play
The information such as duration, so it can also show other more information in playlist window.
When being stored to list items, it is only necessary to preserve filename, corresponding directory entry numbering and the mesh in list items
Record item storage address.By using this method, can no longer need by the long path of file destination corresponding to list items
Location is preserved, and greatly reduces the space shared by file storage address in list items.
Referring to Fig. 5, the figure is the flow chart of list items amending method first embodiment provided by the invention.
In the present embodiment, including:
S501:Determine the file identification of target column list item.
S502:The file identification that list items store in listed files will be replaced replace with the text of the target column list item
Part identifies.
, can also be to wherein existing list items enter on the basis of the list items in playlist are added
Row modification.Such as:It is what the 4th position stored《Friend》Mp3 file, its corresponding storage location is c:Music friend
Friendly .mp3, it is now desired to be revised as the 4th position《From song》Mp3 file, its corresponding storage location is c:\
Download from song .mp3.
When being replaced modification, it is first determined the file identification of target column list item.
Wherein it is possible to the file according to corresponding to target column list item obtains the fileinfo of file destination, such as:Filename
Title, file store path etc..The directory name of file destination place catalogue is found further according to the store path of file.Pass through mesh
Record title finds directory entry numbering and directory entry storage address in FDT.Directory entry is numbered, directory entry storage
File identification of the file name of address and file destination as target column list item.
The file identification that list items store in listed files will be replaced replace with the files-designated of the target column list item
Know.
After being operated more than, it is just in the content of the 4th position storage《From song》File identification information.
By using this method, when content is replaced in list items, it is only necessary to use the file identification of list items
It is replaced, it is no longer necessary to the information such as the long path address of file destination corresponding to list items are preserved, subtracted significantly
Lack the shared space of list items storage, open playlist window, it is possible to achieve the quick loading of playlist, improve
The comfort level that user uses.
Based on above-mentioned list items mark, addition and the method replaced, present invention also offers list items to identify, add and replace
The system changed, its part is described in detail with reference to specific embodiment.
Referring to Fig. 6, the figure is the theory diagram of list items identity device first embodiment provided by the invention.
In the present embodiment, including:File destination determining module 601 and file identification determining module 602.
The file destination determining module 601, for determining file destination corresponding to target column list item.
The file identification determining module 602, for determining the target column according to the fileinfo of the file destination
The file identification of list item.
In the present embodiment, because each list items corresponds to a media file.Therefore, it is true by file destination first
Cover half block 601 determines the file destination corresponding to target column list item.
Because each file has corresponding file attribute information, directory name, catalogue as where file are being grasped
Make corresponding catalog number and the physical storage address of catalogue in system, the title of file, size, file type etc..Therefore, it is literary
The relevant file attribute information of file destination is stored in the text of the list items corresponding to file destination by part mark determining module 602
In part mark.
File identification determining module 602 can preserve the catalog numbers and ground at different levels of file storage catalogue in the present embodiment
Location, and the file name of file, the directory address and file name of file where only can also preserving file.
After being identified to list items, list window can be stored the file identification of list items, be adjusted in next time
File identification can corresponding to the list items during file destination according to list items directly invokes file destination, and no longer needs
Successively to access the catalogues at different levels in store path.
Due to only have recorded the specific address information of file destination in list items in the present embodiment, it is not necessary to re-record mesh
The long path address of file is marked, therefore can effectively reduce the sky in the file identification of list items shared by file storage address
Between.Meanwhile in file destination corresponding to playlist item, improve the speed of file destination loading.
Referring to Fig. 7, the figure is the theory diagram of list items identity device second embodiment provided by the invention.
In the present embodiment, the file identification determining module 601 includes:Path determination sub-module 701, target directory are true
Stator modules 702 and file identification generation submodule 703.
The path determination sub-module 701, for determining the store path of the file destination.
The target directory determination sub-module 702, for according to the store path, obtaining and storing the file destination
Higher level's catalogue is as target directory.
The file identification generates submodule 703, for by directory information and file destination corresponding to the target directory
Filename, the file identification as target column list item.
Due to the file satellite information of file destination include documentary store path, directory name, file name and
The information such as type.Therefore, it is determined that after file destination corresponding to target column list item, path determination sub-module 701 is according to target text
The file satellite information of part determines the store path of file destination.
Target directory determination sub-module 702 obtains higher level's catalogue of file destination position from the store path.Its
Middle higher level's catalogue can be the upper level catalogue of file destination position.Assuming that file destination is to be stored in following position:c:\
Aa a1 1.mp3, then the upper level catalogue is a1.
FDT(FDT)It is the title for registration management disk file, type, file attribute, file foundation
Or modification time and date, file the information such as first cluster number and file size form.In an operating system, typically in root mesh
Record under All Files and its subdirectory root FDT(FDT)In all store one " directory entry " or letter
Referred to as " directory entry ".Each directory entry takes 32 bytes, is divided into 8 regions, there is provided the letter of relevant document or subdirectory
Breath.
Therefore, file identification generation submodule 703 according to the directory name of the upper level obtain the directory name institute it is right
The directory entry information answered, directory entry information and specific file name are stored in the file identification of target column list item.
Due to directly passing through these catalogues when in use using the bottom identification information that directory information is operating system, user
Item information can finds corresponding catalogue, in conjunction with the file name of file destination, it is possible to achieve to the fast direct of file
Positioning is connect, no longer as traditional mode is needed when calling according to the long path address by successively searching until finding target text
Part, substantially increase the efficiency of ff.
Referring to Fig. 8, the figure is the theory diagram of list items identity device 3rd embodiment provided by the invention.
In the present embodiment, the file identification generation submodule 703 includes:The He of catalogue distribution table search submodule 801
File identification preserves submodule 802;
The catalogue distribution table search submodule 801, for searching the target mesh according to the title of the target directory
Record corresponding directory entry numbering and corresponding directory entry storage address in catalogue allocation table.
The file identification preserves submodule 802, for by directory entry numbering, directory entry storage address and the mesh
Mark the filename of file, the file identification as target column list item.
Due in FDT(FDT tables)In the information of file that includes catalogue and wherein store.Such as:Filename
The information such as title, file type, subdirectory type, directory entry numbering.Therefore, catalogue distribution table search submodule 801 can obtain
After the title for obtaining higher level's catalogue, according to the title of higher level's catalogue in FDT(FDT tables)Directory entry corresponding to middle lookup is compiled
Number and the directory entry storage address.
File identification preserves submodule 802 by the directory entry found numbering, directory entry storage address and file destination
In the file identification of file name write-in target column list item.Wherein, in general, directory entry numbering and directory entry storage
Location respectively only takes up 4 bytes, is significantly smaller than traditional long path address.
In invocation target file, the information in file identification by checking target column list item, file destination is found
The directory entry numbering and directory entry storage address of catalogue be present.Mesh is directly found by directory entry numbering and catalogue storage address
Catalogue where marking file, the filename for reusing file destination are matched, and realize the calling to file destination.
Due to using directory entry numbering and bottom mark and bottom address that directory entry storage address is operating system, user
Corresponding catalogue is directly found by directory entry numbering and storage address can when in use, in conjunction with the text of file destination
Part title, it is possible to achieve directly positioned to the quick of file, first need to preserve the complete of file no longer as traditional mode
Long path, when calling according to the long path address by successively directory search is until finding file destination, so as to greatly improve
The speed and efficiency of ff.
Referring to Fig. 9, the figure is the theory diagram of list items adding set first embodiment provided by the invention.
In the present embodiment, including:List items position determination module 901, list items mark determining module 902 and list items
Identify preserving module 903;
The list items position determination module 901, for determining target location of the target column list item in listed files;
The list items identify determining module 902, for determining the file identification of target column list item;
The list items identify preserving module 903, for the file identification of the target column list item to be stored in into the text
Target location in part list.
When using playlist, often it is related to the situation that list items are increased, reduced and changed.
When adding list items in playlist, list items position determination module 901 determines the target of list items first
Position, for example, it is desired to which target column list item is added into first position or N position.
It is determined that behind target location, list items identify the file destination according to corresponding to target column list item of determining module 902, really
Set the goal the file identifications of list items.
Wherein, the relevant information of file destination, including file name, store path etc. can be obtained according to file destination.
Again by the store path of file, can obtain file position higher level's catalogue and higher level's catalogue in file directory
Table(FDT tables)In the information such as corresponding directory entry numbering, directory entry address.
Directory entry information corresponding to higher level's catalogue and file name are written to target by list items mark preserving module 903
In the mark of the fileinfo of list items, the mark to file in list items is completed.
When in use, in the file name that can only show each list items of playlist window, row can also be shown
The other information of file destination corresponding to list item, such as directory entry are numbered.
User can also store other information in file identification, such as file size, file creation time, file play
The information such as duration, so it can also show other more information in playlist window.
When being stored to list items, it is only necessary to preserve filename, corresponding directory entry numbering and the mesh in list items
Record item storage address.By using the present apparatus, can no longer need to be preserved the long path address of list items file,
Greatly reduce the shared space of list items storage.Meanwhile when opening broadcasting, it is possible to achieve playlist item respective file
Quick loading, improve the comfort level that uses of user.
Referring to Figure 10, the figure is the theory diagram of list items modification device first embodiment provided by the invention.
In the present embodiment, including:Replace mark determining module 1001 and mark replacement module 1002.
It is described to replace mark determining module 1001, for determining the file identification of replacement list items.
The mark replacement module 1002, replaced for the file identification that list items store in listed files will to be replaced
For the file identification of the replacement list items.
, can also be to wherein existing list items enter on the basis of the list items in playlist are added
Row modification.Such as:It is what the 4th position stored《Friend》Mp3 file, its corresponding storage location is c:Music friend
Friendly .mp3, it is now desired to be revised as the 4th position《From song》Mp3 file, its corresponding storage location is c:\
Download from song .mp3.
When being replaced modification, the file identification that mark determining module 1001 determines target column list item first is replaced.
Wherein it is possible to the file according to corresponding to target column list item obtains the fileinfo of file destination, such as:Filename
Title, file store path etc..The directory name of file destination place catalogue is found further according to the store path of file.Pass through mesh
Record title finds directory entry numbering and directory entry storage address in FDT.Directory entry is numbered, directory entry storage
File identification of the file name of address and file destination as target column list item.
Mark replacement module 1002 replaces with the mesh by the file identification that list items store in listed files is replaced
Mark the file identification of list items.
After being operated more than, it is just in the content of the 4th position storage《From song》File identification information.
By using the present apparatus, when content is replaced in list items, it is only necessary to use the file identification of list items
It is replaced, it is no longer necessary to the information such as the long path address of list items file are preserved, greatly reduce list items
The shared space of storage, opening playlist window, it is possible to achieve the quick loading of playlist, improve what user used
Comfort level.
The above described is only a preferred embodiment of the present invention, any formal limitation not is made to the present invention.Though
So the present invention is disclosed above with preferred embodiment, but is not limited to the present invention.It is any to be familiar with those skilled in the art
Member, without departing from the scope of the technical proposal of the invention, all using the methods and technical content of the disclosure above to the present invention
Technical scheme makes many possible changes and modifications, or is revised as the equivalent embodiment of equivalent variations.Therefore, it is every without departing from
The content of technical solution of the present invention, the technical spirit according to the present invention is to any simple modification made for any of the above embodiments, equivalent
Change and modification, still fall within technical solution of the present invention protection in the range of.