# Interface: `IDriveContentsProcessor` [@jupyterlite/contents](../modules/jupyterlite_contents.md).IDriveContentsProcessor ## Implemented by - [`DriveContentsProcessor`](../classes/jupyterlite_contents.DriveContentsProcessor-1.md) ## Methods ### `get` > > **`get`**(`request`): `Promise`<`undefined` \| { `content`: `any` ; `format`: `FileFormat` }\> Process the request to get the content of a file #### Parameters | Name | Type | Description | | :------ | :------ | :------ | | `request` | [`TDriveRequest`](../modules/jupyterlite_contents.md#tdriverequest)<``"get"``\> | the request | #### Returns `Promise`<`undefined` \| { `content`: `any` ; `format`: `FileFormat` }\> #### Defined in [packages/contents/src/drivecontents.ts:70](https://github.com/jupyterlite/jupyterlite/blob/999c7f0/packages/contents/src/drivecontents.ts#L70) ### `getattr` > > **`getattr`**(`request`): `Promise`<[`IStats`](jupyterlite_contents.IStats.md)\> Process the request to get a node stats #### Parameters | Name | Type | Description | | :------ | :------ | :------ | | `request` | [`TDriveRequest`](../modules/jupyterlite_contents.md#tdriverequest)<``"getattr"``\> | the request | #### Returns `Promise`<[`IStats`](jupyterlite_contents.IStats.md)\> #### Defined in [packages/contents/src/drivecontents.ts:63](https://github.com/jupyterlite/jupyterlite/blob/999c7f0/packages/contents/src/drivecontents.ts#L63) ### `getmode` > > **`getmode`**(`request`): `Promise`<`number`\> Process the request to get the node mode (file or directory) #### Parameters | Name | Type | Description | | :------ | :------ | :------ | | `request` | [`TDriveRequest`](../modules/jupyterlite_contents.md#tdriverequest)<``"getmode"``\> | the request | #### Returns `Promise`<`number`\> #### Defined in [packages/contents/src/drivecontents.ts:42](https://github.com/jupyterlite/jupyterlite/blob/999c7f0/packages/contents/src/drivecontents.ts#L42) ### `lookup` > > **`lookup`**(`request`): `Promise`<[`ILookup`](jupyterlite_contents.DriveFS.ILookup.md)\> Process the request to check if a node exist #### Parameters | Name | Type | Description | | :------ | :------ | :------ | | `request` | [`TDriveRequest`](../modules/jupyterlite_contents.md#tdriverequest)<``"lookup"``\> | the request | #### Returns `Promise`<[`ILookup`](jupyterlite_contents.DriveFS.ILookup.md)\> #### Defined in [packages/contents/src/drivecontents.ts:49](https://github.com/jupyterlite/jupyterlite/blob/999c7f0/packages/contents/src/drivecontents.ts#L49) ### `mknod` > > **`mknod`**(`request`): `Promise`<``null``\> Process the request to create a directory/file #### Parameters | Name | Type | Description | | :------ | :------ | :------ | | `request` | [`TDriveRequest`](../modules/jupyterlite_contents.md#tdriverequest)<``"mknod"``\> | the request | #### Returns `Promise`<``null``\> #### Defined in [packages/contents/src/drivecontents.ts:56](https://github.com/jupyterlite/jupyterlite/blob/999c7f0/packages/contents/src/drivecontents.ts#L56) ### `processDriveRequest` > > **`processDriveRequest`**<`T`\>(`request`): `Promise`<[`TDriveResponse`](../modules/jupyterlite_contents.md#tdriveresponse)<`T`\>\> Process a content request #### Type parameters | Name | Type | | :------ | :------ | | `T` | extends [`TDriveMethod`](../modules/jupyterlite_contents.md#tdrivemethod) | #### Parameters | Name | Type | Description | | :------ | :------ | :------ | | `request` | [`TDriveRequest`](../modules/jupyterlite_contents.md#tdriverequest)<`T`\> | the request | #### Returns `Promise`<[`TDriveResponse`](../modules/jupyterlite_contents.md#tdriveresponse)<`T`\>\> #### Defined in [packages/contents/src/drivecontents.ts:12](https://github.com/jupyterlite/jupyterlite/blob/999c7f0/packages/contents/src/drivecontents.ts#L12) ### `put` > > **`put`**(`request`): `Promise`<``null``\> Process the request to write the content of a file #### Parameters | Name | Type | Description | | :------ | :------ | :------ | | `request` | [`TDriveRequest`](../modules/jupyterlite_contents.md#tdriverequest)<``"put"``\> | the request | #### Returns `Promise`<``null``\> #### Defined in [packages/contents/src/drivecontents.ts:77](https://github.com/jupyterlite/jupyterlite/blob/999c7f0/packages/contents/src/drivecontents.ts#L77) ### `readdir` > > **`readdir`**(`request`): `Promise`<`string`[]\> Process the request to read a directory content #### Parameters | Name | Type | Description | | :------ | :------ | :------ | | `request` | [`TDriveRequest`](../modules/jupyterlite_contents.md#tdriverequest)<``"readdir"``\> | the request | #### Returns `Promise`<`string`[]\> #### Defined in [packages/contents/src/drivecontents.ts:21](https://github.com/jupyterlite/jupyterlite/blob/999c7f0/packages/contents/src/drivecontents.ts#L21) ### `rename` > > **`rename`**(`request`): `Promise`<``null``\> Process the request to rename a file or directory #### Parameters | Name | Type | Description | | :------ | :------ | :------ | | `request` | [`TDriveRequest`](../modules/jupyterlite_contents.md#tdriverequest)<``"rename"``\> | the request | #### Returns `Promise`<``null``\> #### Defined in [packages/contents/src/drivecontents.ts:35](https://github.com/jupyterlite/jupyterlite/blob/999c7f0/packages/contents/src/drivecontents.ts#L35) ### `rmdir` > > **`rmdir`**(`request`): `Promise`<``null``\> Process the request to remove a directory #### Parameters | Name | Type | Description | | :------ | :------ | :------ | | `request` | [`TDriveRequest`](../modules/jupyterlite_contents.md#tdriverequest)<``"rmdir"``\> | the request | #### Returns `Promise`<``null``\> #### Defined in [packages/contents/src/drivecontents.ts:28](https://github.com/jupyterlite/jupyterlite/blob/999c7f0/packages/contents/src/drivecontents.ts#L28)