---
title: "FileSystemDirectoryEntry | JavaScript maps SDK"
description: "Documentation for MapTiler SDK"
---

> For AI agents: a documentation index is available at [/llms.txt](https://docs.maptiler.com/llms.txt). Markdown versions of all pages are available by appending .md to any URL.

# Interface FileSystemDirectoryEntry

The **`FileSystemDirectoryEntry`** interface of the File and Directory Entries API represents a directory in a file system. It provides methods which make it possible to access and manipulate the files in a directory, as well as to access the entries within the directory.

[MDN Reference](https://developer.mozilla.org/docs/Web/API/FileSystemDirectoryEntry)

interface FileSystemDirectoryEntry {  
    [filesystem](#filesystem): [FileSystem](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystem/);  
    [fullPath](#fullpath): string;  
    [isDirectory](#isdirectory): boolean;  
    [isFile](#isfile): boolean;  
    [name](#name): string;  
    [createReader](#createreader-1)(): [FileSystemDirectoryReader](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemDirectoryReader/);  
    [getDirectory](#getdirectory-1)(  
        path?: string | null,  
        options?: [FileSystemFlags](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemFlags/),  
        successCallback?: [FileSystemEntryCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntryCallback/),  
        errorCallback?: [ErrorCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.ErrorCallback/),  
    ): void;  
    [getFile](#getfile-1)(  
        path?: string | null,  
        options?: [FileSystemFlags](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemFlags/),  
        successCallback?: [FileSystemEntryCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntryCallback/),  
        errorCallback?: [ErrorCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.ErrorCallback/),  
    ): void;  
    [getParent](#getparent-1)(  
        successCallback?: [FileSystemEntryCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntryCallback/),  
        errorCallback?: [ErrorCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.ErrorCallback/),  
    ): void;  
}

#### Hierarchy ([View Summary](https://docs.maptiler.com/sdk-js/api-reference/hierarchy/#Externals.FileSystemDirectoryEntry))

-   [FileSystemEntry](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/)
    -   FileSystemDirectoryEntry

##### Index

### Properties[](#properties)

[filesystem](#filesystem) [fullPath](#fullpath) [isDirectory](#isdirectory) [isFile](#isfile) [name](#name)

### Methods[](#methods)

[createReader](#createreader) [getDirectory](#getdirectory) [getFile](#getfile) [getParent](#getparent)

## Properties[](#properties-1)

### `Readonly`filesystem[](#filesystem)

filesystem: [FileSystem](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystem/)

The read-only **`filesystem`** property of the FileSystemEntry interface contains a FileSystem object that represents the file system on which the entry resides.

[MDN Reference](https://developer.mozilla.org/docs/Web/API/FileSystemEntry/filesystem)

Inherited from [FileSystemEntry](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/).[filesystem](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/#filesystem)

### `Readonly`fullPath[](#fullpath)

fullPath: string

The read-only **`fullPath`** property of the FileSystemEntry interface returns a string specifying the full, absolute path from the file system's root to the file represented by the entry.

[MDN Reference](https://developer.mozilla.org/docs/Web/API/FileSystemEntry/fullPath)

Inherited from [FileSystemEntry](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/).[fullPath](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/#fullpath)

### `Readonly`isDirectory[](#isdirectory)

isDirectory: boolean

The read-only **`isDirectory`** property of the FileSystemEntry interface is true if the entry represents a directory (meaning it's a FileSystemDirectoryEntry) and false if it's not.

[MDN Reference](https://developer.mozilla.org/docs/Web/API/FileSystemEntry/isDirectory)

Inherited from [FileSystemEntry](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/).[isDirectory](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/#isdirectory)

### `Readonly`isFile[](#isfile)

isFile: boolean

The read-only **`isFile`** property of the FileSystemEntry interface is true if the entry represents a file (meaning it's a FileSystemFileEntry) and false if it's not.

[MDN Reference](https://developer.mozilla.org/docs/Web/API/FileSystemEntry/isFile)

Inherited from [FileSystemEntry](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/).[isFile](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/#isfile)

### `Readonly`name[](#name)

name: string

The read-only **`name`** property of the FileSystemEntry interface returns a string specifying the entry's name; this is the entry within its parent directory (the last component of the path as indicated by the fullPath property).

[MDN Reference](https://developer.mozilla.org/docs/Web/API/FileSystemEntry/name)

Inherited from [FileSystemEntry](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/).[name](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/#name)

## Methods[](#methods-1)

### createReader[](#createreader)

-   createReader(): [FileSystemDirectoryReader](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemDirectoryReader/)[](#createreader-1)
    
    The FileSystemDirectoryEntry interface's method **`createReader()`** returns a FileSystemDirectoryReader object which can be used to read the entries in the directory.
    
    [MDN Reference](https://developer.mozilla.org/docs/Web/API/FileSystemDirectoryEntry/createReader)
    
    #### Returns [FileSystemDirectoryReader](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemDirectoryReader/)
    

### getDirectory[](#getdirectory)

-   getDirectory(  
        path?: string | null,  
        options?: [FileSystemFlags](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemFlags/),  
        successCallback?: [FileSystemEntryCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntryCallback/),  
        errorCallback?: [ErrorCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.ErrorCallback/),  
    ): void[](#getdirectory-1)
    
    The FileSystemDirectoryEntry interface's method **`getDirectory()`** returns a FileSystemDirectoryEntry object corresponding to a directory contained somewhere within the directory subtree rooted at the directory on which it's called.
    
    [MDN Reference](https://developer.mozilla.org/docs/Web/API/FileSystemDirectoryEntry/getDirectory)
    
    #### Parameters
    
    -   `Optional`path: string | null
    -   `Optional`options: [FileSystemFlags](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemFlags/)
    -   `Optional`successCallback: [FileSystemEntryCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntryCallback/)
    -   `Optional`errorCallback: [ErrorCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.ErrorCallback/)
    
    #### Returns void
    

### getFile[](#getfile)

-   getFile(  
        path?: string | null,  
        options?: [FileSystemFlags](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemFlags/),  
        successCallback?: [FileSystemEntryCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntryCallback/),  
        errorCallback?: [ErrorCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.ErrorCallback/),  
    ): void[](#getfile-1)
    
    The FileSystemDirectoryEntry interface's method **`getFile()`** returns a FileSystemFileEntry object corresponding to a file contained somewhere within the directory subtree rooted at the directory on which it's called.
    
    [MDN Reference](https://developer.mozilla.org/docs/Web/API/FileSystemDirectoryEntry/getFile)
    
    #### Parameters
    
    -   `Optional`path: string | null
    -   `Optional`options: [FileSystemFlags](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemFlags/)
    -   `Optional`successCallback: [FileSystemEntryCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntryCallback/)
    -   `Optional`errorCallback: [ErrorCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.ErrorCallback/)
    
    #### Returns void
    

### getParent[](#getparent)

-   getParent(  
        successCallback?: [FileSystemEntryCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntryCallback/),  
        errorCallback?: [ErrorCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.ErrorCallback/),  
    ): void[](#getparent-1)
    
    The FileSystemEntry interface's method **`getParent()`** obtains a FileSystemDirectoryEntry.
    
    [MDN Reference](https://developer.mozilla.org/docs/Web/API/FileSystemEntry/getParent)
    
    #### Parameters
    
    -   `Optional`successCallback: [FileSystemEntryCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntryCallback/)
    -   `Optional`errorCallback: [ErrorCallback](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.ErrorCallback/)
    
    #### Returns void
    
    Inherited from [FileSystemEntry](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/).[getParent](https://docs.maptiler.com/sdk-js/api-reference/interfaces/Externals.FileSystemEntry/#getparent)
