Search the keys of the given hash using the specified pattern.

        :param str pattern: Pattern used to match keys.
        :param int count: Limit number of results returned.
        :returns: An iterator yielding matching key/value pairs.
499217
def search(self, pattern, count=None):
        
        return self._scan(match=pattern, count=count)
578636
def find_all(self, pattern):
		
		pos = []
		last_found = -1
		while True:
			last_found = self.current_segment.data.find(pattern, last_found + 1)
			if last_found == -1:
				break
			pos.append(last_found + self.current_segment.start_address)
			
		return pos
130289
def match_all(self, pattern):
        
        pattern = self.pattern_open(pattern)
        search_img = pattern.image
        screen = self.region_screenshot()
        screen = imutils.from_pillow(screen)
        points = ac.find_all_template(screen, search_img, maxcnt=10)
        return points
1362387
public static Set<String> retainMatchingKeys(Counter<String> counter, List<Pattern> matchPatterns) {
    Set<String> removed = new HashSet<String>();
    for (String key : counter.keySet()) {
      boolean matched = false;
      for (Pattern pattern : matchPatterns) {
        if (pattern.matcher(key).matches()) {
          matched = true;
          break;
        }
      }
      if (!matched) {
        removed.add(key);
      }
    }
    for (String key : removed) {
      counter.remove(key);
    }
    return removed;
  }
242650
public function select(string $pattern = '', int $count = 100): \Iterator
    {
        $iterator = null;
        while (true) {
            $ret = $this->handle->hScan($this->name, $iterator, $pattern, $count);
            if (false === $ret) {
                break;
            }
            foreach ($ret as $k => $v) {
                yield [$k => $v];
            }
        }
    }
1041170
def list_keys(self, pattern='*', db=0):
        
        lines = output_lines(self.exec_redis_cli('KEYS', [pattern], db=db))
        return [] if lines == [''] else lines
126116
def search(self, pattern):
        
        try:
            return self.advanced_search(pattern)
        except Exception:
            return self.basic_search(pattern)
135901
def match(self, node):
        
        results = {"node": node}
        return self.pattern.match(node, results) and results
1168107
private static boolean matchesPatternList(final String str, final List<Pattern> patterns) {
        if (patterns != null) {
            for (final Pattern pattern : patterns) {
                if (pattern.matcher(str).matches()) {
                    return true;
                }
            }
        }
        return false;
    }
589726
def all(pattern: SCAN_PATTERN, count: DEFAULT_COUNT)
      redis { |conn| conn.sscan_each(UNIQUE_SET, match: pattern, count: count).to_a }
    end
302775
private List<NumberPattern> getNumberPattern(String pattern) {
    int i = pattern.indexOf(';');
    if (i == -1) {
      return Arrays.asList(
          parseNumberPattern(pattern),
          parseNumberPattern("-" + pattern));
    }
    return Arrays.asList(
        parseNumberPattern(pattern.substring(0, i)),
        parseNumberPattern(pattern.substring(i+1)));
  }
601816
function list_keys($pattern = '')
    {
        $this->load_pgp_driver();
        $result = $this->pgp_driver->list_keys($pattern);

        if ($result instanceof enigma_error) {
            self::raise_error($result, __LINE__);
        }

        return $result;
    }
883657
def scan(self, match="*", count=1000, cursor=0):
        
        if self.serialized:
            cursor, data = self._client.zscan(
                self.key_prefix, cursor=cursor, match=match, count=count)
            return (cursor, list(map(
                lambda x: (self._loads(x[0]), self.cast(x[1])), data)))
        else:
            cursor, data = self._client.zscan(
                self.key_prefix, cursor=cursor, match=match, count=count)
            return (cursor, list(map(
                lambda x: (self._decode(x[0]), self.cast(x[1])), data)))
814309
def iteritems(self, pattern="*"):
        """"""
        for key in self.keys(pattern):
            yield (key, self[key])
827316
def search(pattern, sentence, *args, **kwargs):
    
    return compile(pattern, *args, **kwargs).search(sentence)
85779
static public function select(string $pattern = '*', int $count = 1000): \Iterator
    {
        $iterator = null;
        while (true) {
            $ret = self::handle()->scan($iterator, $pattern, $count);
            if (false == $ret) {
                break;
            }
            foreach ($ret as $item) {
                yield $item;
            }
        }
    }
1209947
static List<String> parsePattern(String pattern) {
    List<String> parameters = new ArrayList<>(4);
    Matcher matcher = PARAM_REGEX.matcher(pattern);
    while (matcher.find()) {
      parameters.add(matcher.group(1));
    }
    return parameters;
  }