@@ 409-419 (lines=11) @@ | ||
406 | * @param string $filename |
|
407 | * @return string FALSE on fail |
|
408 | */ |
|
409 | public function getFile($filename) |
|
410 | { |
|
411 | if ($this->numFiles > 0) { |
|
412 | foreach ($this->files as $information) { |
|
413 | if ($information['name'] == $filename) { |
|
414 | return $information; |
|
415 | } |
|
416 | } |
|
417 | } |
|
418 | return false; |
|
419 | } |
|
420 | ||
421 | /** |
|
422 | * Retrieves information about a directory in the current tar archive |
|
@@ 445-455 (lines=11) @@ | ||
442 | * @param string $filename |
|
443 | * @return bool |
|
444 | */ |
|
445 | public function containsFile($filename) |
|
446 | { |
|
447 | if ($this->numFiles > 0) { |
|
448 | foreach ($this->files as $information) { |
|
449 | if ($information['name'] == $filename) { |
|
450 | return true; |
|
451 | } |
|
452 | } |
|
453 | } |
|
454 | return false; |
|
455 | } |
|
456 | ||
457 | /** |
|
458 | * Check if this tar archive contains a specific directory |