| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- <?php
- namespace App\Module\File\Events;
- use Illuminate\Broadcasting\InteractsWithSockets;
- use Illuminate\Foundation\Events\Dispatchable;
- use Illuminate\Queue\SerializesModels;
- /**
- * 文件删除事件
- */
- class FileDeletedEvent
- {
- use Dispatchable, InteractsWithSockets, SerializesModels;
- /**
- * 文件ID
- *
- * @var int
- */
- public int $fileId;
- /**
- * 文件路径
- *
- * @var string
- */
- public string $filePath;
- /**
- * 存储磁盘
- *
- * @var string
- */
- public string $storageDisk;
- /**
- * 创建一个新的事件实例
- *
- * @param int $fileId
- * @param string $filePath
- * @param string $storageDisk
- * @return void
- */
- public function __construct(int $fileId, string $filePath, string $storageDisk)
- {
- $this->fileId = $fileId;
- $this->filePath = $filePath;
- $this->storageDisk = $storageDisk;
- }
- }
|