SplFileInfo 类

(PHP 5 >= 5.1.2, PHP 7, PHP 8)

简介

SplFileInfo 类为单个文件的用户信息提供了一个高级面向对象的接口。

类概要

class SplFileInfo implements Stringable {
/* 方法 */
public __construct(string $filename)
public getATime(): int|false
public getBasename(string $suffix = ""): string
public getCTime(): int|false
public getGroup(): int|false
public getInode(): int|false
public getMTime(): int|false
public getOwner(): int|false
public getPath(): string
public getPerms(): int|false
public getSize(): int|false
public getType(): string|false
public isDir(): bool
public isExecutable(): bool
public isFile(): bool
public isLink(): bool
public isReadable(): bool
public isWritable(): bool
public openFile(string $mode = "r", bool $useIncludePath = false, ?resource $context = null): SplFileObject
public setFileClass(string $class = SplFileObject::class): void
public setInfoClass(string $class = SplFileInfo::class): void
public __toString(): string
}

变更日志

版本 描述
8.0.0 SplFileInfo 现在实现了 Stringable

目录

添加注释

用户贡献注释

此页面没有用户贡献注释。
To Top