Electronic device for searching for file information stored in external device and operation method thereof

An electronic device according to an embodiment disclosed herein may include a display, an input device, a connecting terminal, a storage, and a processor. The processor may be configured to: copy information about files and folders stored in an external device; generate a list of the files and the folders stored in the external device; receive a first user input for selecting one or more of the files or folders included in the list of the files and the folders; copy the selected file or folder from the external device and store the copied file or folder in the storage; and maintain the display of the list of the files and the folders even after the external device is disconnected. Various other embodiments are possible.

CROSS-REFERENCE TO RELATED APPLICATION(S)

This application is based on and claims priority under 35 U.S.C. 119 to Korean Patent Application No. 10-2019-0031762, filed on Mar. 20, 2019, in the Korean Intellectual Property Office, the disclosure of which is herein incorporated by reference in its entirety.

BACKGROUND

One or more embodiments disclosed herein generally relate to an electronic device that can search for file information stored in an external device and an operation method of the electronic device. More specifically, the electronic device is capable of identifying file information by searching for files and folders stored in a currently connected external device and an external device that is not currently connected.

2) Description of Related Art

Since built-in storage of electronic devices, in particular mobile devices, is limited in capacity, various external storage devices may be used. These external storage devices may be connected to the electronic device through various input/output interfaces. Conventionally, in order to identify information stored in an external storage device and execute programs or open files stored in the external storage device, the external storage device needs to be connected through an input/output interface of the electronic device.

SUMMARY

In order for an electronic device to identify information stored in a specific external device among a plurality of external devices, the specific external device and the electronic device needs to remain connected.

When the external device and the electronic device are disconnected, the electronic device may still access the files of the external device if all files and folders of the external device are copied and stored in the electronic device. However, this creates a burden on the storage capacity of the electronic device.

In order to use a file stored in a specific external device among a plurality of external devices, there may be a need to separately store the file to be used.

An electronic device according to an embodiment disclosed herein may include a display; an input device; a connecting terminal; a storage; and a processor operatively connected to the display, the input device, the connecting terminal, and the storage. According to an embodiment, the processor may be configured to: copy information about files and folders stored in an external device when the external device is connected to the electronic device; generate a list of the files and the folders stored in the external device, based on the copied information, and display the generated list of the files and the folders through the display; receive a first user input for selecting some of the files or folders included in the list of the files and the folders; in response to the reception of the first user input, copy the selected file or folder from the external device and store the copied file and folder in the storage; maintain displaying of the list of the files and the folders even if the external device is disconnected, and execute the file or the folder stored in the storage in response to a second user input for executing the file or the folder stored in the storage.

An operation method of an electronic device according to an embodiment disclosed herein may include: copying information about files and folders stored in an external device when the external device is connected to the electronic device; generating a list of the files and the folders stored in the external device, based on the copied information, and displaying the generated list of the files and the folders through a display; receiving a first user input for selecting some of the files or folders included in the list of the files and the folders; in response to reception of the first user input, copying the selected file or folder from the external device and storing the copied file and folder in a storage; maintaining the display of the list of the files and then folders even after the external device is disconnected, and executing the file or folder stored in the storage in response to a second user input for executing the file or the folder stored in the storage.

DETAILED DESCRIPTION

FIG. 2is a diagram illustrating various external devices that are connected to an electronic device according to an embodiment.

Referring toFIG. 2, an electronic device210(e.g., the electronic device101ofFIG. 1) according to an embodiment disclosed herein may be connected to various external devices. The external device may include, for example, external storage device or a portable terminal225including an internal storage. The external storage device may include, for example, an external hard drive221, USB drives222and223, a hard disk224, a micro SD card226, or an SD card227.

According to an embodiment, the electronic device210may be connected to various external devices through a connecting terminal. The electronic device210may identify and use files and folders, for example, stored in an external device when the external device is connected.

According to an embodiment, if an external device is connected, the electronic device210may copy information about the files and folders stored in the external device. For example, the electronic device210may generate a list of files and folders based on the copied information about the files and folders and store the list of files and folders in the electronic device210. According to an embodiment, even if the external device is subsequently disconnected, the electronic device210may identify information about the files and folders stored in the external device by using the generated list of files and folders. According to an embodiment, if a plurality of external devices are connected, the electronic device210may generate a plurality of lists of files and folders each corresponding to each of the plurality of external devices, respectively. Then, even if the plurality of external devices are subsequently disconnected from the electronic device210, the electronic device210may identify information about the files and folders stored in the plurality of external devices by using the generated plurality lists of files and folders corresponding to the plurality of external devices.

According to an embodiment, the electronic device210may identify information about files and folders through a generated list of files and folders. The information about files and folders may include, for example, file names, folder names, tree structures of folders, storage locations, generation times, recent modification times, recent access times, various file attributes, file sizes and/or information on clusters.

According to an embodiment, the list of files and folders corresponding to an external device may be the same as the structure of files and folders stored in the external device.

According to an embodiment, if an external device is connected, the electronic device210may select some files or folders from a generated list of files and folders and store the selected files or folders. For example, if the electronic device210receives a user input for selecting some files or folders included in the list of files and folders, the electronic device210may copy the some files or folders, selected from a list of files and folders, from a connected external device and store the copied some files or folders in the electronic device210. Then, even after the external device is subsequently disconnected, the stored some files or folders may be still be accessed by the electronic device210.

FIG. 3is a block diagram of an electronic device according to an embodiment.

Referring toFIG. 3, an electronic device210according to an embodiment may include a processor310(e.g., the processor120ofFIG. 1), a storage320(e.g., the memory130ofFIG. 1), a display330(e.g., the display device160ofFIG. 1), a connecting terminal340(e.g., the connecting terminal178ofFIG. 1), and/or an input device350(e.g., the input device150ofFIG. 1). Without departing from the spirit of the embodiments disclosed herein, one or more components shown inFIG. 3may be omitted, or additional components that are not shown may be added. The processor310may include a microprocessor or any suitable type of processing circuitry, such as one or more general-purpose processors (e.g., ARM-based processors), a Digital Signal Processor (DSP), a Programmable Logic Device (PLD), an Application-Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), a Graphical Processing Unit (GPU), a video card controller, etc. In addition, it would be recognized that when a general purpose computer accesses code for implementing the processing shown herein, the execution of the code transforms the general purpose computer into a special purpose computer for executing the processing shown herein. Certain of the functions and steps provided in the Figures may be implemented in hardware, software or a combination of both and may be performed in whole or in part within the programmed instructions of a computer. No claim element herein is to be construed under the provisions of 35 U.S.C. § 112(f), unless the element is expressly recited using the phrase “means for.” In addition, an artisan understands and appreciates that a “processor” or “microprocessor” may be hardware in the claimed disclosure. Under the broadest reasonable interpretation, the appended claims are statutory subject matter in compliance with 35 U.S.C. § 101.

According to an embodiment, the processor310may be an element capable of performing calculation related to control and/or communication of respective elements of the electronic device210, or data processing thereof, and may include at least some of the configurations and/or functions of the processor120ofFIG. 1. For example, the processor310may be electrically and operatively connected to the storage320, the display330, the connecting terminal340, and the input device350, which are internal elements of the electronic device210.

According to an embodiment, the storage320may store a list of a plurality of files and folders corresponding to a plurality of external devices, respectively. The list of files and folders may include, for example, information about files and folders included in the corresponding external device. According to an embodiment, the processor310may copy some files or folders, selected from a list of files and folders, from a connected external device and store the copied files or folders in the storage320of the electronic device.

According to an embodiment, the display330may display various screens under the control of the processor310.

According to an embodiment, the connecting terminal340may include a connector through which the electronic device210may be physically or electrically connected to an external device. The connecting terminal340may include, for example, an HDMI connector, a USB connector, an SD card connector, or an audio connector (e.g., a headphone connector). More specifically, the connecting terminal340may physically connect the electronic device210and an external device so as to establish a communication link between the electronic device210and the external device.

According to an embodiment, the input device350may receive a user input or data to be used by the processor310. The input device350may include, for example, a mouse or a keyboard.

According to an embodiment, the processor310may recognize that an external device is connected through the connecting terminal340. The processor310may, for example, identify the connected external device. In this example, the processor310may identify a file system of the connected external device. The file system may refer to, for example, a system that manages the files that are stored in the external device. Examples of file systems include File Allocation Table 16 (FAT16), File Allocation Table 32 (FAT32), New Technology File System (NTFS), Second Extended File System (ext2), and ReiserFS.

According to an embodiment, the processor310may copy information about the files and folders stored in the connected external device. The information about the files and folders may include, for example, file names, folder names, tree structures of folders, storage locations, generation times, recent modification times, recent access times, various file attributes, file sizes and/or information on clusters. According to an embodiment, the processor310may copy information about the files and folders stored in the external device, based on the file system of the external device. For example, if a plurality of areas implementing the file system of the external device in a storage of the external device includes an area containing information about a file list, the processor310according to an embodiment may copy the entire area (block copy) that contains the information about the file list. The information about the file list may contain, for example, information about the files and folders stored in the external device. For example, if the file system of the external device is NTFS, the processor may entirely copy (block copy) the master file table (MFT) area in the storage of the external device. The details of NTFS structure will be described in detail with reference toFIGS. 9 and 10.

According to an embodiment, for example, if the plurality of areas implementing the file system of the external device does not include an area containing information about the file list, the processor310may copy information about the files and folders of the external device by repeating file input/output calls (for example, file I/O API calls) for each file stored in the external device.

According to an embodiment, the processor310may generate a list of files and folders based on the copied information about the files and folders. For example, if the area including information about the file list is entirely copied, the processor310may generate a list of files and folders based on the information about the file list included in the copied area. In another example, the processor310may generate a list of files and folders based on the copied information about files and folders copied by repeating file input/output calls for each file stored in the external device.

According to an embodiment, the processor310may display the generated list of files and folders through the display330. The processor310may store, for example, the generated list of files and folders in the storage320.

According to an embodiment, the processor310may receive a user input for selecting some of the files or folders included in the list. For example, the processor310may receive a user input for selecting some of the files or folders included in the list through the input device350(e.g., mouse or keyboard). The processor310according to an embodiment may copy the selected files or folders from the external device in response to reception of the user input, and may store the selected file or folder in the storage320.

According to an embodiment, the processor310may control the display330to maintain displaying of the list even after the external device is disconnected. For example, the processor310may control the display330to display the list so as to allow the user to search for and identify information about the files or folders included in the list even after the external device is disconnected.

According to an embodiment, the processor310may execute or otherwise use or manipulate the files or folders stored in the storage320even after the external device is disconnected. The processor310may execute files or folders stored in the storage320, for example, upon receiving a user input for executing files or folders stored in the storage320even after the external device is disconnected.

According to an embodiment, if an external device is connected, the processor310may determine whether the external device is connected to the electronic device210for the first time. For example, if there is no corresponding list of files and folders for the external device in the storage320, the processor may determine that the external device is connected for the first time. Alternatively, and if there is a list of files and folders corresponding to the external device in the storage320, the processor may determine that the external device has been previously connected.

According to an embodiment, if an external device is disconnected and then reconnected, the processor310may compare the files or folders stored in the storage320with the files or folders currently stored in the external device to determine whether the files or folders stored in the storage320are the same as those stored in the external device. For example, the processor may compare the latest modification times of the files or folders stored in the storage with those of the files or folders currently stored in the external device to determine which files have been modified. Thus, the processor310may determine information about the latest state of the files or folders stored in the storage320, for example, based on the result of the determination.

According to an embodiment, if an external device is disconnected and then reconnected, the processor310may synchronize the files or folders stored in the storage320, based on information on the latest state of the files or folders stored in the storage320determined from the files and folders stored in the external device and a preconfigured synchronization method.

According to an embodiment, if an external device is disconnected and then reconnected, the processor310may change the list of files and folders stored in the electronic device210, based on information about file changes included in the file system of the external device. For example, if the file system is NTFS, the file system (or a processor of the external device) may record, in an update sequence number (USN) journal, all the changes to the volume since the last backup was made. The USN journal may be, for example, a block included in NTFS. The processor310may fetch information about the files and folders stored in the external device, changed after the last saved time point (e.g. the last time the external device was connected to the electronic device210) by using information recorded in the USN journal, and may update the list of files and folders to the latest state by using the fetched information. If using the USN journal, processing speed can be improved since information about all file changes needs not to be identified.

FIG. 4is a view illustrating a screen displayed on an electronic device according to an embodiment.

Referring toFIG. 4, the processor310according to an embodiment may display a screen400for searching for files or folders included in at least one external device through the display330. According to an embodiment, the screen400may include an external device list area410, a file-and-folder list area420, and a search area430.

According to an embodiment, the external device list area410may be an area in which, for example, a list of a plurality of external devices which are currently connected to the electronic device210or which have been connected to the electronic device210at least once in the past is displayed. For example, in the external device list area410, the processor310may distinguish between currently connected external devices and external devices which are not currently connected. More specifically in this example, referring to the area410, the processor310may display currently connected external device 1411in bold and large letters, and may display external device 2413to external device9, which are not currently connected, in thin and small letters. According to another embodiment, the processor310may display a currently connected external device and an external device which is not currently connected in different colors. If the processor310receives, for example, a user input (for example, a click) of selecting one external device from the external device list, the processor310displays, in the file-and-list area420, the list of files and folders corresponding to the selected external device.

According to an embodiment, the processor310may display a list of files and folders corresponding to a selected external device regardless of whether the external device is currently connected or not.

According to an embodiment, the file-and-folder list area420may display, for example, a list of files and folders corresponding to an external device selected in the external device list. The displayed list of files and folders may be, for example, a list of files and folders generated by copying information about the files and folders stored in the selected external device. The processor310according to an embodiment may provide information about the files and folders included in a list of files and folders. The information about the files and folders includes, for example, file names, folder names, tree structures of folders, storage locations, generation times, recent modification times, recent access times, various file attributes, file sizes and/or information on clusters.

According to an embodiment, the processor310may provide check user interfaces (UIs)425and426allowing selection of each of the files and folders included in the list of files and folders, and a global check UI427allowing selection of all of the files and folders included in the list. According to an embodiment, the processor310may provide, in the file-and-folder list area420, a synchronization UI421allowing the user to manual synchronize a particular file or folder included in the list of files and folders, a state display UI423capable of determining and displaying the latest state of the files and folders included in the list, and a UI424capable of identifying whether a particular file or folder is stored. According to an embodiment, the UI424may be displayed only for files and folders currently stored in the storage320of the electronic device210. For example, referring toFIG. 4, in the list of files and folders of external device 1411, it is shown that only file 4 is stored in the storage320. In this case, only UI424corresponding to file 4 is displayed in as “kept.” Alternatively, in the case of file 3, which is not stored in the storage320, the UI identifying if file 3 is stored is not be displayed.

The processor310according to an embodiment may provide a storage UI428for storing a file or a folder selected in the list of files and folders, and a delete UI429for deleting a stored file or folder.

The search area430according to an embodiment may be, for example, an area in which a search function431is performed to enable the user to search for a desired file or folder. The processor310may provide the search function431of a file or folder regardless of whether the plurality of external devices are currently connected or not. For example, the user may search for, through the search function431, information about a file stored in a specific external device that is not currently connected to the electronic device210. In this case, the user may identify in which external device the desired file is stored.

The processor310according to an embodiment may display, in the search area430, a configuration UI433for configuring the synchronization method used to synchronize the information stored in the electronic device201and the information stored in the plurality of external devices. For example, the user may configure a synchronization method for the stored files and folders through the configuration UI433. The synchronization method for the stored files and folders may include, for example, a method for performing synchronization using the latest files stored in an external device and the files stored in the electronic device210, a method for performing synchronization using files stored in an external device, a method for performing synchronization using files stored in the electronic device210, or a method for performing synchronization manually.

According to an embodiment, upon receiving a user input for selecting the storage UI428, the processor310may store, in the storage320, files or folders for which the check UIs425and426are selected in the list. For example, as shown in the example ofFIG. 4, external device 1411is connected to the electronic device210. In this example, if file 1425has been selected from the list of files and folders and a user input for selecting the storage UI428is received, the processor310may copy file 1425from external device 1411and store copied file 1 in the storage320. In this case, the user may execute or use file 1425stored in the storage320in the electronic device210even if the external device 1411is disconnected. When the file 1425is an image or video, the processor310may further generate a thumbnail for the image or video and store the thumbnail. In the case of file 2426for which a check UI is not selected, when the processor receives the user input for selecting the storage UI428, file 2426may not be stored in the storage320because the check UI is not selected. This way, when the external device 1411is disconnected, the user may only view file information (e.g., file storage location and file name) of the file 2426, and would not be able to access file 2426itself.

According to an embodiment, upon receiving a user input for selecting the state display UI423, the processor310may compare files stored in the storage320with the corresponding files stored in the external device, so as to determine the latest state. For example, assume that the processor310has copied file 1425from the external device 1411and stored the file in the storage320. The external device 1411is then disconnected, and file 1425stored in the storage320is subsequently used and modified. In this case, if the external device 1411is reconnected to the electronic device210, file 1 stored in the external device 1411and file 1 stored in the electronic device210may include different content. The processor310may compare information (for example, the latest modification time) of file 1 stored in the external device with information (the latest modification time) of file 1 stored in the electronic device210, so as to determine the latest state. In the above example, the processor310may determine that file 1 stored in the electronic device210is the latest file. According to an embodiment, the processor310may compare files stored in the external device with files stored in the electronic device210to determine whether files stored in the electronic device210are the latest or whether the files stored in the external device are the latest. The processor310may also determine whether the files stored in the external device are deleted or are the same as the files stored in the electronic device.

According to an embodiment, if the external device is reconnected to the electronic device210, the processor310may perform automatic synchronization using a preconfigured method in response to detection of the reconnection, or may perform manual synchronization by receiving a user input for selecting the synchronization UI421. According to an embodiment, manual synchronization may be performed individually for each file and folder included in the list of files and folders. According to an embodiment, upon receiving a user input for selecting the synchronization UI421, the processor310may perform synchronization of stored files or folders based on a preconfigured synchronization method. For example, it will be assumed that the synchronization method is configured as a method for performing synchronization using the latest files among the files stored in the external device and the files stored in the electronic device210. If the files stored in the external device are the latest files, the processor310may update the files stored in the storage320with the files stored in the external device. The processor310according to an embodiment may display the synchronization UI421in the case where files stored in the electronic device210and the corresponding files stored in the external device are not identical to each other.

Referring toFIG. 4, it can be seen that only the external device 1411is currently connected to the electronic device210, and the external devices 2 to 9 are not connected to the electronic device210. The file-and-folder list screen400displays the list of files and folders corresponding to external device 1411.

The processor310according to an embodiment may receive a user input for selecting some files or folders included in the list of files and folders. Referring to file 1425and file 2426displayed in area420, it may be identified that file 1425is selected and file 2426is not selected. Thereafter, if the processor310receives a user input for selecting the storage UI428for storing the selected file or folder, the processor310may store only the selected file 1425in the storage230. File 1425stored in the storage230may be executed in and used by the electronic device210even if the external device 1411is disconnected.

FIG. 5is a flowchart500illustrating an operation of an electronic device according to an embodiment.

Referring to the operation flowchart500, the processor310according to an embodiment may detect that an external device is connected through the connecting terminal340, in operation510. The processor310may, for example, identify a connected external device. For example, the processor310may establish a communication link between the external device and the electronic device210based on the connection of the external device through the connecting terminal340. In one example, the communication link may allow for wired and/or wireless communication.

In operation520, the processor310according to an embodiment may copy information about files and folders stored in the external device. For example, the processor310may entirely copy (block copy) a storage area containing information about files and folders stored in the external device, where the area is one of a plurality of areas implementing the file system of the external device. In more specific examples, if the file system of the external device is NTFS, the processor may copy the MFT area, and if the file system of the external device is FAT32, the processor may copy the FAT area. Information about files and folders may include, for example, file names, folder names, tree structures of folders, storage locations, generation times, recent modification times, recent access times, various file attributes, file sizes and/or information on clusters.

In operation530, the processor310according to an embodiment may generate a list of files and folders stored in the external device, based on the copied information. For example, the processor310may display the generated list of files and folders through the display330and store the generated list files and folders in the storage320.

In operation540, the processor310according to an embodiment may receive a user input for selecting some of the files or folders included in the list of files and folders.

In operation550, the processor310according to an embodiment may store the selected files or folders in the storage320. For example, the processor310may copy the selected files or folders from the external device and store the copied files or folders in the storage320.

In operation560, the processor310according to an embodiment may detect disconnection of the external device.

In operation570, the processor310according to an embodiment may maintain displaying of the list of files and folders through the display330even after the external device is disconnected. According to an embodiment, even if the external device is disconnected, the list of files and folders corresponding to the external device may be displayed by the electronic device210, and information about the files and folders included in the list of files and folders may be identified. For example, the processor310may disconnect the communication link between the electronic device210and the external device when the external device is disconnected.

In operation580, the processor310according to an embodiment may execute the files or folders stored in the storage320even after the external device is disconnected. For example, if the processor310receives a user input for executing the files or folders stored in the storage320even after the external device is disconnected, the processor310may execute or use or otherwise manipulate the files or folders stored in the storage320in response to the user input. According to an embodiment, the user input for executing the files or folders stored in the storage320may be input on a user interface displaying the list of files and folders.

FIG. 6is a flowchart600illustrating an operation of an electronic device according to an embodiment.

Referring to the operation flowchart600, the processor310according to an embodiment may detect that an external device is connected through the connecting terminal340, in operation601. For example, the processor310may establish a communication link between the external device and the electronic device210based on the connection with the external device.

In operation603, the processor310according to an embodiment may identify the type of the file system of the connected external device. The type of the file system may include, for example, NTFS, FAT32, FAT16, ext2, and ReiserFS.

In operation605, the processor310according to an embodiment may determine whether an area including information about a file list exists, based on the identified type of file system. The information about the file list is, for example, information required for generating the list of files and folders stored in the external device, and may include information about all the files and folders existing on a volume. For example, if the file system of the external device is NTFS, since the MFT area, which is an area including the information about the file list, exists, the processor310may determine that the result of operation605is YES. In another example, if the file system of the external device is FAT32, since the FAT area, which is an area including the information about the file list, exists, the processor310may determine that the result of operation605is YES. If the external device is a device having its own operating system (for example, if the external device is a portable terminal running the Android operating system), the processor310may determine that there is no area including information about the file list.

If it is determined that there is an area including information about the file list, the process branches to operation607and the processor310may copy the area including the information about the file list. The processor310may, for example, block copy the entirety of the area including the information about the file list.

The process branches to operation609and the processor310according to an embodiment may generate a list of files and folders based on the copied area including information about the file list. The list of files and folders may be, for example, a list corresponding to the files and folders stored in the external device. If the processor generates the list of files and folders by block copying the entirety of the area including information about the file list, the generated list of files and folders may be identical to the file structure of the external device.

If it is determined in operation605that there is no area including the information about the file list, the process branches to operation613, and the processor310according to an embodiment may generate a list of files and folders by performing input/output requests with respect to the files and folders stored in the external device.

In operation611, the processor310according to an embodiment may store the generated list of files and folders in the storage.

FIG. 7is a flowchart700illustrating an operation of an electronic device according to an embodiment.

Referring to the operation flowchart700, the processor310according to an embodiment may detect that an external device has been reconnected to the electronic device210after the external device was previously disconnected, in operation701.

In operation703, the processor310according to an embodiment may determine whether the file system of the external device is a file system that includes information about file changes. For example, if the file system of the external device is NTFS, the file system of the external device may record, in the USN journal, all changes to a volume since last backup was made. The USN journal is, for example, a block included in NTFS. If the file system of the reconnected external device is NTFS, the processor310may determine that the file system includes information about file changes.

If it is determined that the file system of the external device is a file system including information on file changes, the process branches to operation705and the processor310may use the information on the file changes to generate a list of changed files and folders. For example, if the file system of the external device is NTFS, the processor may fetch information about files and folders that have been changed after the last saved time point, using information recorded in the USN journal, and may generate a list of changed files and folders using the fetched information.

In operation707, the processor310according to an embodiment may change the file and the list stored in the storage320to the latest state, based on the list of the changed files and folders.

In operation703, if it is determined that the file system of the external device is not a file system including information about file changes, the process branches to operation709and the processor310may newly generate a list of files and folders based on the area including information about the file list or file input/output requests. Operation709may be performed by performing some of the operations shown inFIG. 6and for simplicity descriptions thereof are not repeated here. The process branches to operation707, and the processor310may change the list of files and folders stored in the storage320to the latest state based on the generated list of files and folders.

FIG. 8is a flowchart800illustrating an operation of an electronic device according to an embodiment.

FIG. 8is an operation flowchart illustrating a method for synchronizing some of the files or folders stored in the storage320of the electronic device210with the corresponding files or folders stored in an external device if the external device is disconnected and then reconnected to the electronic device210.

Referring to operation800, the processor310according to an embodiment may detect that the external device is reconnected to the electronic device210after the connection of the external device was previously released, in operation810.

In operation820, the processor310according to an embodiment may fetch information about files or folders stored in the storage320. If the external device has been connected previously, certain files or folders may be selected to be stored in the storage320, and copied from the connected electronic device and stored in the storage320. The files or folders stored in the storage320refer to those files and folders. The files or folders stored in the storage320may be stored in the storage320even if the external device is subsequently disconnected.

In operation830, the processor310according to an embodiment may compare information about the files and folders currently stored in the external device with information about the files or folders stored in the storage320. The processor310may determine, for example, if a list of files and folders currently stored in the external device includes files or folders corresponding to the files or folders stored in the storage320. The processor310may compare, for example, information about the recent modification times of files or folders stored in the storage320and information about the recent modification times of files or folders corresponding to the selected files or folders, among the files and folders currently stored in the external device.

In operation840, if the list of files and folders currently stored in the external device includes files or folders corresponding to files or folders stored in the storage320, the processor310according to an embodiment may compare the files or folders stored in the storage with the corresponding files or folders currently stored in the external device, and determine which one is the latest. For example, if the files or folders stored in the storage320do not exist in the list of files and folders currently stored in the external device, the processor310may determine that the files or folders stored in the storage320are stored only in the electronic device210.

In operation850, the processor310according to an embodiment may synchronize the files or folders stored in the storage320, based on information about the latest state of the files or folders stored in the storage320and a preconfigured synchronization method. For example, if the file stored in the storage320is the latest file, and the preconfigured synchronization method is a method of performing synchronization with the latest files stored in the external device and the storage320of the electronic device210, the processor310may change the file stored in the external device to be the same as the file stored in the storage320without changing the file stored in the storage320. In another example, if the file stored in the storage320is the latest file and the preconfigured synchronization method is a method of performing synchronization always with the file stored in the external device, the processor310may change the file stored in the storage320to be the file stored in the external device. The synchronization method may be configured by the user through the configuration UI433ofFIG. 4.

FIG. 9is a diagram illustrating a structure of a file system of an external device according to an embodiment.

FIG. 9is a block diagram showing a structure900of NTFS. Referring toFIG. 9, the NTFS may include a volume boot record (VBR) area910, a master file table (MFT) area920, and a data area930.

According to an embodiment, the VBR area910may be an area in which various configuration values of the file system are stored.

According to an embodiment, the MFT area920may be a table area including information about all files and directories existing in the volume. The MFT area920may include, for example, a plurality of MFT entries, and a file or directory may have at least one MFT entry. The MFT area920may include, for example, attribute information (e.g., file names, folder names, tree structures of folders, storage locations, generation times, recent modification times, recent access times, various file attributes, file sizes and/or information on clusters) of each file or each folder. The size of the MFT area920is variable.

The data area930according to an embodiment may be an area in which file data is stored.

According to an embodiment, the MFT920may include a plurality of MFT entries, and may store metadata of files stored in the data area930.

Entry numbers 0 to 15 in MFT entries are reserved and serve as metadata files of the file system. $MFT, which is entry number 0 in the MFT entries, is an MFT entry for the MFT area920and may store size, location, and allocation information of the MFT area. $MFTMirr, which is entry number 1 in the MFT entries, may be a backup file of the MFT. For example, $MFTMirr may copy and store the first four entries in $MFT. $LogFile, which is entry number 2 in the MFT entries, may store transaction journal records. For example, $LogFile may record all pieces of information, which affects MFT entries, including generation of new files, a content change, and a file name change. $Volume, which is entry number 3 in the MFT entries, may store the volume label and version. In addition, $UsnJrnl in the MFT entries may be a file in which the change history of files and directories is recorded. The MFT area may include an MFT entry for a general file in which a directory or a file added by a user is stored.

With regard to the structure of an MFT entry corresponding to a general file, a file record according to an embodiment may include an entry header, a standard information area, a file name area ($file name), a data area ($data), and an unused area. The entry header may store, for example, basic information of the MFT entry. The standard information area may include, for example, general information about a latest generation time, an access time, a modification time, and an owner of a file. The standard information area may include USN information, for example. The file name area may include information about a file name and a folder name, for example. The data area may include, for example, information about a file content (e.g., a file size).

According to an embodiment, if the file system of an external device connected through the connecting terminal340is NTFS, the processor310may copy the entirety of the MFT area920to generate a list of files and folders corresponding to the external device.

According to an embodiment, the file system of the external device may be FAT32 (not shown).

According to an embodiment, the FAT32 may include: a data area including a boot record area, a reserved area, and a FAT area (or FAT #1 and FAT #2), a root directory area, and an unused area.

Among the plurality of areas of the FAT32, the FAT area may be, for example, an area including information for all the files and clusters stored in the corresponding hard disk. For example, whether or not files and directories are allocated may be recorded in the FAT area, and may be recorded in units of clusters. The FAT area may include, for example, a FAT #1 area and a FAT #2 area, where FAT #2 serves as a backup for FAT #1. In this case, FAT #2 may be referred to as a FAT mirror, for example.

According to an embodiment, if the file system of an external device connected through the connecting terminal340is FAT32, the processor310may copy the entirety of the FAT area (FAT #1 and FAT #2) to generate a list of files and folders corresponding to the external device.

An electronic device210according to an embodiment disclosed herein may include a display330, an input device350, a connecting terminal340, a storage320, and a processor310operatively connected to the display330, the input device350, the connecting terminal340, and the storage320, wherein the processor310may be configured to: copy information about files and folders stored in an external device (e.g., external devices221,222,223,224,225,226, and227ofFIG. 2) when the external device is connected to the electronic device210; based on the copied information, generate a list of the files and the folders stored in the external device and display the generated list of the files and the folders through the display330; receive a first user input for selecting some of the files or folders included in the list of the files and the folders; in response to the reception of the first user input, copy the selected file or folder from the external device and store the copied file and folder in the storage320; maintain displaying of the list of the files and the folders even after the external device is disconnected; and execute the file or the folder stored in the storage320in response to a second user input for executing the file or the folder stored in the storage320.

In an electronic device210according to an embodiment disclosed herein, the processor310may be configured to copy an area including the information about the files and the folders stored in the external device among a plurality of areas implementing a file system of the external device.

In an electronic device210according to an embodiment disclosed herein, the processor310may be configured to copy an MFT area if a file system of the external device is NTFS, and to copy an FAT area if the file system of the external device is FAT32.

In an electronic device210according to an embodiment disclosed herein, the information about the files and folders includes file names, folder names, tree structures of folders, storage locations, generation times, recent modification times, recent access times, file attributes, file sizes, and/or information on clusters.

In an electronic device210according to an embodiment disclosed herein, the processor310may be configured to further display whether the external device is currently connected and whether the files and the folders included in the list are stored therein.

In an electronic device210according to an embodiment disclosed herein, the processor310may be configured to further display a search are for searching information included in the list of the files and the folders even after the external device is disconnected.

In an electronic device210according to an embodiment disclosed herein, when the file selected based on the first input is an image file or a video file, the processor310may be configured to store a thumbnail of the selected image file or video file in the storage320.

In an electronic device210according to an embodiment disclosed herein, the processor310may be configured to: when the external device is disconnected and then is connected again to the electronic device210, compare information about the file or the folder stored in the storage230with information about a corresponding file or a corresponding folder currently stored in the external device; determine information about the latest state of the file or the folder stored in the storage320based on a result of the comparison; and synchronize the file or the folder stored in the storage320, based on the determined information about the latest state and a preconfigured synchronization method.

In an electronic device210according to an embodiment disclosed herein, the processor310may be configured to further display information about the latest state of the file or the folder stored in the storage320.

In an electronic device210according to an embodiment disclosed herein, the processor310may be configured to: when the external device is disconnected and then connected again to the electronic device210, identify whether a file system of the external device is a file system that includes information about a file change; and when the file system of the external device is a file system that includes the information about the file change, change the list of the files and the folders based on the information about the file change included in the file system of the external device.

An operation method of the electronic device210according to an embodiment disclosed herein may include: copying information about files and folders stored in an external device (e.g., external devices221,222,223,224,225,226, and227ofFIG. 2) when the external device is connected to the electronic device210; generating a list of the files and the folders stored in the external device, based on the copied information, and displaying the generated list of the files and the folders through the display330; receiving a first user input for selecting some of the files or folders included in the list of the files and the folders; in response to the reception of the first user input, copying the selected file or folder from the external device and storing the copied file and folder in the storage320; maintaining the display of the list of the files and the folders even after the external device is disconnected; and executing the file or folder stored in the storage320in response to a second user input for executing the file or the folder stored in the storage320.

In an operation method of the electronic device210according to an embodiment disclosed herein, the copying of the information about the files and the folders stored in the external device may include copying an area including the information about the files and the folders stored in the external device among a plurality of areas implementing a file system of the external device.

In an operation method of the electronic device210according to an embodiment disclosed herein, the copying of the area may include copying an MFT area if a file system of the external device is NTFS, and copying an FAT area if the file system of the external device is FAT32.

In an operation method of the electronic device210according to an embodiment disclosed herein, the information about the file and folder includes file names, folder names, tree structures of folders, storage locations, generation times, recent modification times, recent access times, file attributes, file sizes, and/or information on clusters.

An operation method of the electronic device210according to an embodiment disclosed herein may further include displaying whether the external device is currently connected and whether the respective files and folders included in the list are stored.

An operation method of the electronic device210according to an embodiment disclosed herein may further include displaying a search area for searching information included in the list of the files and the folders even after the external device is disconnected.

In an operation method of the electronic device210according to an embodiment disclosed herein, when the file selected based on the first input is an image file or a video file, the operation method may further comprise storing a thumbnail of the selected image file or video file in the storage320.

An operation method of the electronic device210according to an embodiment disclosed herein may further include: when the external device is disconnected and then is connected again to the electronic device210, comparing information about the file or the folder stored in the storage230with information about a corresponding file or a corresponding folder currently stored in the external device; determining information about the latest state of the file or the folder stored in the storage320, based on a result of the comparison; and synchronizing the file or the folder stored in the storage320, based on the determined information about the latest state and a preconfigured synchronization method.

An operation method of the electronic device210according to an embodiment disclosed herein may further include, after the determining of information about the latest state of the file or the folder stored in the storage320, displaying the information about the latest state of the file or the folder stored in the storage320through the display330.

An operation method of the electronic device210according to an embodiment disclosed herein may further include: when the external device is disconnected and then connected again to the electronic device210, identifying whether a file system of the external device is a file system that includes information about a file change; and when the file system of the external device is a file system that includes the information about the file change, changing the list of the files and the folders based on the information about the file change included in the file system of the external device.

An electronic device according to an embodiment may display information about files and folders stored in a plurality of external devices even when connections with the plurality of external devices are released.

An electronic device according to an embodiment may copy information (for example, file name, storage location, and folder tree structure) of files and folders stored in a plurality of external devices to a storage of the electronic device and generate a list of files and folders, so as to be able to display information about the files and folders stored in the external device while using less storage capacity of the electronic device as compared to the case where the electronic device stores copies of the files and folders of the plurality of external devices.

An electronic device according to an embodiment may easily identify a storage location in which a specific file is stored, by collectively searching for files stored in a plurality of external devices, without requiring the user to separately search the plurality of external devices individually.