docs/Script API/classes/Backend_Script_API._internal_.default.html
Becca is a backend cache of all notes, branches, and attributes. There's a similar frontend cache Froca, and share cache Shaca.
allNoteSetCacheattributeIndexattributesbrancheschildParentToBranchetapiTokensloadednotesoptions
addNotedecryptProtectedNotesdirtyNoteSetCachefindAttributesfindAttributesWithPrefixgetAllNoteSetgetAttachmentgetAttachmentOrThrowgetAttachmentsgetAttributegetAttributeOrThrowgetBlobgetBranchgetBranchFromChildAndParentgetBranchOrThrowgetEntitygetEtapiTokengetEtapiTokensgetNotegetNoteOrThrowgetNotesgetOptiongetRecentNotesFromQuerygetRevisiongetRevisionOrThrowgetRevisionsFromQuerygetRootreset
new default(): default
allNoteSetCache: null | NoteSet
attributeIndex: Record<string, BAttribute[]>
Points from attribute type-name to list of attributes
attributes: Record<string, BAttribute>
branches: Record<string, BBranch>
childParentToBranch: Record<string, BBranch>
etapiTokens: Record<string, BEtapiToken>
loaded: boolean
options: Record<string, BOption>
addNote(noteId: string, note: BNote): void
decryptProtectedNotes(): void
dirtyNoteSetCache(): void
Should be called when the set of all non-skeleton notes changes (added/removed)
findAttributes(type: string, name: string): BAttribute[]
findAttributesWithPrefix(type: string, name: string): BAttribute[]
getAllNoteSet(): NoteSet
getAttachment(attachmentId: string, opts?: AttachmentOpts): null | BAttachment
getAttachmentOrThrow(attachmentId: string, opts?: AttachmentOpts): BAttachment
getAttachments(attachmentIds: string[]): BAttachment[]
getAttribute(attributeId: string): null | BAttribute
getAttributeOrThrow(attributeId: string): BAttribute
getBlob(entity: { blobId?: string }): null | BBlob
getBranch(branchId: string): null | BBranch
getBranchFromChildAndParent(
childNoteId: string,
parentNoteId: string,
): null | BBranch
getBranchOrThrow(branchId: string): BBranch
getEntity<T extends AbstractBeccaEntity<T>>(
entityName: string,
entityId: string,
): null | AbstractBeccaEntity<T>
getEtapiToken(etapiTokenId: string): null | BEtapiToken
getEtapiTokens(): BEtapiToken[]
getNote(noteId: string): null | BNote
getNoteOrThrow(noteId: string): BNote
getNotes(noteIds: string[], ignoreMissing?: boolean): BNote[]
getOption(name: string): null | BOption
getRecentNotesFromQuery(query: string, params?: string[]): BRecentNote[]
getRevision(revisionId: string): null | BRevision
getRevisionOrThrow(revisionId: string): BRevision
getRevisionsFromQuery(query: string, params?: string[]): BRevision[]
getRoot(): null | BNote
reset(): void
Member Visibility
ThemeOSLightDark
Constructors constructor Properties allNoteSetCacheattributeIndexattributesbrancheschildParentToBranchetapiTokensloadednotesoptions Methods addNotedecryptProtectedNotesdirtyNoteSetCachefindAttributesfindAttributesWithPrefixgetAllNoteSetgetAttachmentgetAttachmentOrThrowgetAttachmentsgetAttributegetAttributeOrThrowgetBlobgetBranchgetBranchFromChildAndParentgetBranchOrThrowgetEntitygetEtapiTokengetEtapiTokensgetNotegetNoteOrThrowgetNotesgetOptiongetRecentNotesFromQuerygetRevisiongetRevisionOrThrowgetRevisionsFromQuerygetRootreset