# Class PrivateFile

#### Hierarchy

- BaseFile
  - PrivateFile

- Defined in fs/v1/PrivateFile.ts:35

#####
Index

### Constructors

constructor

### Properties

content
crypto
depot
header
history
key
mmpt
readOnly

### Methods

getName
put
putDetailed
updateContent
updateParentNameFilter
create
fromBareNameFilter
fromInfo
fromLatestName
fromName
instanceOf

## Constructors

### constructor

- new PrivateFile(__namedParameters: ConstructorParams): PrivateFile

- #### Parameters

  - ##### __namedParameters: ConstructorParams

  #### Returns PrivateFile

  Overrides BaseFile.constructor

  - Defined in fs/v1/PrivateFile.ts:45

## Properties

### content

content: Uint8Array

Inherited from BaseFile.content

- Defined in fs/base/file.ts:9

### crypto

crypto: Crypto.Implementation

- Defined in fs/v1/PrivateFile.ts:37

### depot

depot: Depot.Implementation

- Defined in fs/v1/PrivateFile.ts:38

### header

header: PrivateFileInfo

- Defined in fs/v1/PrivateFile.ts:40

### history

history: default

- Defined in fs/v1/PrivateFile.ts:41

### key

key: Uint8Array

- Defined in fs/v1/PrivateFile.ts:42

### mmpt

mmpt: default

- Defined in fs/v1/PrivateFile.ts:43

### readOnly

readOnly: boolean

Inherited from BaseFile.readOnly

- Defined in fs/base/file.ts:10

## Methods

### getName

- getName(): Promise<PrivateName>

- #### Returns Promise<PrivateName>

  - Defined in fs/v1/PrivateFile.ts:160

### put

- put(): Promise<CID<unknown, number, number, Version>>

- #### Returns Promise<CID<unknown, number, number, Version>>

  Inherited from BaseFile.put

  - Defined in fs/base/file.ts:17

### putDetailed

- putDetailed(): Promise<PrivateAddResult>

- #### Returns Promise<PrivateAddResult>

  Overrides BaseFile.putDetailed

  - Defined in fs/v1/PrivateFile.ts:195

### updateContent

- updateContent(content: Uint8Array): Promise<PrivateFile>

- #### Parameters

  - ##### content: Uint8Array

  #### Returns Promise<PrivateFile>

  Overrides BaseFile.updateContent

  - Defined in fs/v1/PrivateFile.ts:178

### updateParentNameFilter

- updateParentNameFilter(parentNameFilter: BareNameFilter): Promise<PrivateFile>

- #### Parameters

  - ##### parentNameFilter: BareNameFilter

  #### Returns Promise<PrivateFile>

  - Defined in fs/v1/PrivateFile.ts:166

### `Static` create

- create(crypto: Crypto.Implementation, depot: Depot.Implementation, mmpt: default, content: Uint8Array, parentNameFilter: BareNameFilter, key: Uint8Array): Promise<PrivateFile>

- #### Parameters

  - ##### crypto: Crypto.Implementation

  - ##### depot: Depot.Implementation

  - ##### mmpt: default

  - ##### content: Uint8Array

  - ##### parentNameFilter: BareNameFilter

  - ##### key: Uint8Array

  #### Returns Promise<PrivateFile>

  - Defined in fs/v1/PrivateFile.ts:65

### `Static` fromBareNameFilter

- fromBareNameFilter(crypto: Crypto.Implementation, depot: Depot.Implementation, mmpt: default, bareNameFilter: BareNameFilter, key: Uint8Array): Promise<PrivateFile>

- #### Parameters

  - ##### crypto: Crypto.Implementation

  - ##### depot: Depot.Implementation

  - ##### mmpt: default

  - ##### bareNameFilter: BareNameFilter

  - ##### key: Uint8Array

  #### Returns Promise<PrivateFile>

  - Defined in fs/v1/PrivateFile.ts:98

### `Static` fromInfo

- fromInfo(crypto: Crypto.Implementation, depot: Depot.Implementation, mmpt: default, key: Uint8Array, info: Maybe<DecryptedNode>): Promise<PrivateFile>

- #### Parameters

  - ##### crypto: Crypto.Implementation

  - ##### depot: Depot.Implementation

  - ##### mmpt: default

  - ##### key: Uint8Array

  - ##### info: Maybe<DecryptedNode>

  #### Returns Promise<PrivateFile>

  - Defined in fs/v1/PrivateFile.ts:131

### `Static` fromLatestName

- fromLatestName(crypto: Crypto.Implementation, depot: Depot.Implementation, mmpt: default, name: PrivateName, key: Uint8Array): Promise<PrivateFile>

- #### Parameters

  - ##### crypto: Crypto.Implementation

  - ##### depot: Depot.Implementation

  - ##### mmpt: default

  - ##### name: PrivateName

  - ##### key: Uint8Array

  #### Returns Promise<PrivateFile>

  - Defined in fs/v1/PrivateFile.ts:109

### `Static` fromName

- fromName(crypto: Crypto.Implementation, depot: Depot.Implementation, mmpt: default, name: PrivateName, key: Uint8Array): Promise<PrivateFile>

- #### Parameters

  - ##### crypto: Crypto.Implementation

  - ##### depot: Depot.Implementation

  - ##### mmpt: default

  - ##### name: PrivateName

  - ##### key: Uint8Array

  #### Returns Promise<PrivateFile>

  - Defined in fs/v1/PrivateFile.ts:120

### `Static` instanceOf

- instanceOf(obj: unknown): obj is PrivateFile

- #### Parameters

  - ##### obj: unknown

  #### Returns obj is PrivateFile

  - Defined in fs/v1/PrivateFile.ts:57

Generated using TypeDoc