CakeFest 2024: The Official CakePHP Conference

RarArchive::close

rar_close

(PECL rar >= 2.0.0)

RarArchive::close -- rar_closeClose RAR archive and free all resources

Açıklama

Nesne yönelimli kullanım (method):

public RarArchive::close(): bool

Yordamsal kullanım:

rar_close(RarArchive $rarfile): bool

Close RAR archive and free all allocated resources.

Bağımsız Değişkenler

rarfile

A RarArchive object, opened with rar_open().

Dönen Değerler

Başarı durumunda true, başarısızlık durumunda false döner.

Sürüm Bilgisi

Sürüm: Açıklama
PECL rar 2.0.0 The RAR entries returned by RarArchive::getEntry() and RarArchive::getEntries() are now invalidated when calling this method. This means that all instance methods called for such entries and not guaranteed to succeed.

Örnekler

Örnek 1 Nesne yönelimli kullanım

<?php
$rar_arch
= RarArchive::open('latest_winrar.rar');
echo
$rar_arch."\n";
$rar_arch->close();
echo
$rar_arch."\n";
?>

Yukarıdaki örnek şuna benzer bir çıktı üretir:

RAR Archive "D:\php_rar\trunk\tests\latest_winrar.rar"
RAR Archive "D:\php_rar\trunk\tests\latest_winrar.rar" (closed)

Örnek 2 Yordamsal kullanım

<?php
$rar_arch
= rar_open('latest_winrar.rar');
echo
$rar_arch."\n";
rar_close($rar_arch);
echo
$rar_arch."\n";
?>

add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top