1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
Класс File
Граф наследования:File:
File IErrorable FileEntry IFileStream Errorable FileSystemEntry

Открытые члены

 openLoad ()
 openWrite ()
 read (int $length)
 write (string $content)
 close ()
Открытые члены унаследованные от File
 __construct ($path, $siteId=null)
 open ($mode)
 isExists ()
 getContents ()
 putContents ($data, $flags=self::REWRITE)
 getSize ()
 seek ($position)
 isWritable ()
 isReadable ()
 readFile ()
 markWritable ()
 delete ()
 getContentType ()
Открытые члены унаследованные от FileEntry
 getExtension ()
 putContents ($data)
 getFileSize ()
 isDirectory ()
 isFile ()
 isLink ()
Открытые члены унаследованные от FileSystemEntry
 isSystem ()
 getName ()
 getDirectoryName ()
 getPath ()
 getDirectory ()
 getCreationTime ()
 getLastAccessTime ()
 getModificationTime ()
 getPermissions ()
 getPhysicalPath ()
 rename ($newPath)
Открытые члены унаследованные от IErrorable
 addError (Main\Error $error)
 addErrors (array $errors)
 hasErrors ()
Открытые члены унаследованные от Errorable
 getErrors ()
 getErrorByCode ($code)

Открытые статические члены

static generateTemporalFile (string $prefix, string $suffix='.tmp', int $timeToLive=3)
Открытые статические члены унаследованные от File
static isFileExists ($path)
static getFileContents ($path)
static putFileContents ($path, $data, $flags=self::REWRITE)
static deleteFile ($path)

Дополнительные унаследованные члены

Поля данных унаследованные от File
const REWRITE = 0
const APPEND = 1
Защищенные статические члены унаследованные от FileSystemEntry
static getDocumentRoot ($siteId)
Защищенные данные унаследованные от File
 $filePointer
Защищенные данные унаследованные от FileSystemEntry
 $path
 $originalPath
 $pathPhysical
 $siteId
bool $exists = null

Подробное описание

См. определение в файле file.php строка 9

Методы

◆ close()

close ( )

Closes the file.

Возвращает
void
Исключения
Main

IO\FileNotOpenedException

Переопределяет метод предка File.

См. определение в файле file.php строка 110

◆ generateTemporalFile()

generateTemporalFile ( string $prefix,
string $suffix = '.tmp',
int $timeToLive = 3 )
static

Creates temporal file.

Аргументы
string$prefixName prefix.
string$suffixName suffix.
int$timeToLiveHours to keep files alive.
Возвращает
static

См. определение в файле file.php строка 23

◆ openLoad()

openLoad ( )

Opens file for reading.

Возвращает
bool

См. определение в файле file.php строка 39

◆ openWrite()

openWrite ( )

Opens file for writing.

Возвращает
bool

См. определение в файле file.php строка 54

◆ read()

read ( int $length)

Read file.

Аргументы
int$lengthAmount bytes to read.
Возвращает
string

См. определение в файле file.php строка 69

◆ write()

write ( string $content)

Write file.

Аргументы
string$contentData to write.
Возвращает
int
Исключения
Main

IO\FileNotOpenedException

Исключения
Main

IO\IoException

См. определение в файле file.php строка 88


Объявления и описания членов класса находятся в файле:
  • C:/bitrix/modules/translate/lib/io/file.php