"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.builder = void 0; const path = require("path"); const fs_macchiato_1 = require("@nodelib/fs.macchiato"); class EntryBuilder { constructor() { this._isFile = true; this._isDirectory = false; this._isSymbolicLink = false; this._entry = { name: '', path: '', dirent: new fs_macchiato_1.Dirent() }; } path(filepath) { this._entry.name = path.basename(filepath); this._entry.path = filepath; return this; } file() { this._isFile = true; this._isDirectory = false; return this; } directory() { this._isDirectory = true; this._isFile = false; return this; } symlink() { this._isSymbolicLink = true; return this; } stats() { this._entry.stats = new fs_macchiato_1.Stats(); return this; } build() { this._entry.dirent = new fs_macchiato_1.Dirent({ name: this._entry.name, isFile: this._isFile, isDirectory: this._isDirectory, isSymbolicLink: this._isSymbolicLink }); return this._entry; } } function builder() { return new EntryBuilder(); } exports.builder = builder;