PHP 8.2.31
Preview: Set.php Size: 745 B
/home/nshryvcy/blissfulnepal.com/wp-content/plugins/tourmaster/include/stripe/lib/Util/Set.php

<?php

namespace Stripe\Util;

use IteratorAggregate;
use ArrayIterator;

class Set implements IteratorAggregate
{
    private $_elts;

    public function __construct($members = [])
    {
        $this->_elts = [];
        foreach ($members as $item) {
            $this->_elts[$item] = true;
        }
    }

    public function includes($elt)
    {
        return isset($this->_elts[$elt]);
    }

    public function add($elt)
    {
        $this->_elts[$elt] = true;
    }

    public function discard($elt)
    {
        unset($this->_elts[$elt]);
    }

    public function toArray()
    {
        return array_keys($this->_elts);
    }

    public function getIterator()
    {
        return new ArrayIterator($this->toArray());
    }
}

Directory Contents

Dirs: 0 × Files: 8

Name Size Perms Modified Actions
1.50 KB lrw-r--r-- 2024-05-28 15:48:44
Edit Download
1.63 KB lrw-r--r-- 2024-05-28 15:48:44
Edit Download
488 B lrw-r--r-- 2024-05-28 15:48:44
Edit Download
1.15 KB lrw-r--r-- 2024-05-28 15:48:44
Edit Download
800 B lrw-r--r-- 2024-05-28 15:48:44
Edit Download
3.14 KB lrw-r--r-- 2024-05-28 15:48:44
Edit Download
745 B lrw-r--r-- 2024-05-28 15:48:44
Edit Download
13.83 KB lrw-r--r-- 2024-05-28 15:48:44
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).