Asserts trough keys, must be same number in both arrays

@param array $inKeys
@param array $outKeys

@throws DefinitionException
496386
protected function assertTroughKeys($inKeys, $outKeys)
    {
        if (empty($inKeys) || empty($outKeys)) {
            throw new DefinitionException(sprintf('Invalid keys for relation "%s", must be two arrays with key-value pairs', $this->entity, count($inKeys)));
        }

        if (count($inKeys) !== count($outKeys)) {
            throw new DefinitionException(sprintf('Both key arrays for relation "%s", must have the same number of elements', $this->entity));
        }
    }
439722
protected function assertUniqueIndex($key, $indexes)
    {
        $this->context->assertArrayHasKey($key, $indexes, "The {$this->name} column is not indexed.");
        $this->assertTrue($indexes[$key]->isUnique(), "The {$this->name} is not a unique index.");
    }
708759
@SafeVarargs
    public static <K> Set<K> set(final K... keys) {
        return new LinkedHashSet<K>(Arrays.asList(keys));
    }
58444
public function keysExist(array $keys)
    {
        foreach ($keys as $key) {
            if (!$this->keyExists($key)) {
                return false;
            }
        }
        return true;
    }
267830
function getFromKeys(array $keys)
    {
        $realm = $this->getRealm();


        foreach ($keys as $i => $k)
            $keys[$i] = "'$k'";

        $keys = implode(', ', $keys);

        try {
            $sql = "SELECT * FROM `KVStore` WHERE `realm` = '$realm' and `key` IN ($keys);";

            $stm = $this->pdo->prepare($sql);
            $stm->execute();
            $stm->setFetchMode(\PDO::FETCH_ASSOC);

            $c = $stm->fetchAll();

            foreach ($c as $d) {
                $key     = $d['key'];
                $val     = $this->getDataInterchange()->retrieveBackward( $d['value'] );

                parent::set($key, $val);
                yield $key => $val;
            }

        } catch (\Exception $e) {
            throw new exReadError($e->getMessage(), $e->getCode(), $e);
        }
    }
1193068
private function add_index($test, &$out, &$exts)
    {
        if (!empty($test['index'])) {
            array_push($exts, 'index');
            $out .= ' :index ' . intval($test['index']) . ($test['last'] ? ' :last' : '');
        }
    }
1195645
public static function sets($keys, $createdBy = null)
    {
        if (!is_array($keys)) {
            return false;
        }
        foreach ($keys as $key => $value) {
            static::set($key, $value, $createdBy);
        }
    }
40915
private function ins(&$ary, $keys, $val) 
    {
        $keys ? 
            $this->ins($ary[array_shift($keys)], $keys, $val) :
            $ary = $val;
    }
1137527
public void addFalsePositive(Key[] keys) {
    if (keys == null) {
      throw new NullPointerException("Key[] can not be null");
    }

    for (int i = 0; i < keys.length; i++) {
      addFalsePositive(keys[i]);
    }
  }
1263218
public void setTicketKeys(SessionTicketKey[] keys) {
        if (keys == null) {
            throw new NullPointerException("keys");
        }
        SSLContext.setSessionTicketKeys(ctx, keys);
    }
1365204
public function flashExcept($keys)
    {
        $this->session()->flashInput(
            $this->except(is_array($keys) ? $keys : func_get_args())
        );
    }
55605
public function addKeys(array $keys, $unique=false)
    {
        foreach ($keys as $key)
        {
            $this->addKey($key, $unique);
        }
    }
1190238
private function validateKeys(array $keys)
    {
        foreach (['block_id', 'page_id', 'manager', 'updated_at'] as $key) {
            if (!isset($keys[$key])) {
                throw new \RuntimeException(sprintf('Please define a `%s` key, provided: %s', $key, json_encode(array_keys($keys))));
            }
        }
    }
309722
protected static final <T, K extends Serializable>
    List<K> _keys2Ids(
                    final Collection<Key<T>> keys
                    )
    {
        List<K>  ids = new ArrayList<K>();
        if (keys != null ) {
            for (Key<T>  key : keys) {
                @SuppressWarnings( "unchecked" )
                K  id = (K)key.getId();
                ids.add( id );
            }
        }

        return ids;
    }
814143
function (keys) {
            keys = Array.isArray(keys) ? keys : {};

            return self.input.flash('except', keys);
        }
432936
private function assertKeysArrayValid($keys = null)
    {
        if ((!$keys) ||
            (!is_array($keys)) ||
            (!isset($keys['auth'])) || 
            (!is_array($keys['auth'])) ||
            (!isset($keys['auth']['req'])) || 
            (!is_array($keys['auth']['req'])) ||
            (!isset($keys['auth']['opt'])) || 
            (!is_array($keys['auth']['opt'])) ||
            (!isset($keys['args'])) || 
            (!is_array($keys['args'])) ||
            (!isset($keys['args']['req'])) || 
            (!is_array($keys['auth']['req'])) ||
            (!isset($keys['args']['opt'])) || 
            (!is_array($keys['auth']['opt']))
        ) {
            $msg = 'Invalid API keys provided. (HINT: Each '
                 . 'API class must define a $keys array with '
                 . 'specific key requirements. (HINT: View an /Api/[file] '
                 . 'for an example.)';
            throw new ApiException($msg);
        }
    }
1216914
public static function isAnyKeyNull(array $keys = []): bool
    {
        foreach ($keys as $key) {
            if ($key === null) {
                return true;
            }
        }

        return false;
    }