Returns True if name matches one of the patterns.
164525
def match(self, name):
        
        for pat in self.pats:
            if fnmatch.fnmatch(name, pat):
                return True

        return False
112756
def matches_pattern(self, other):
        """"""
        ismatch = False
        if isinstance(other, Userdata):
            for key in self._userdata:
                if self._userdata[key] is None or other[key] is None:
                    ismatch = True
                elif self._userdata[key] == other[key]:
                    ismatch = True
                else:
                    ismatch = False
                    break
        return ismatch
379105
def pattern(name, pattern):
  
  pattern.setName(name)
  astracing.maybe_trace(pattern)
  return pattern
767865
public static boolean matches(String pattern, String value) {
        Pattern p = Pattern.compile(pattern);
        Matcher m = p.matcher(value);
        return m.matches();
    }
617400
public static boolean contains(String name, Iterable<String> patterns) {
        String nameUpper = name.toUpperCase();
        for (String pattern : patterns) {
            String patternUpper = pattern.toUpperCase();
            if (nameUpper.equals(patternUpper) || nameUpper.contains(patternUpper)) {
                return true;
            }
        }

        return false;
    }
936849
def match(self, selector, index):
        """"""

        pseudo = None
        m = self.re_pseudo_name.match(selector, index)
        if m:
            name = util.lower(css_unescape(m.group('name')))
            pattern = self.patterns.get(name)
            if pattern:
                pseudo = pattern.match(selector, index)
                if pseudo:
                    self.matched_name = pattern

        return pseudo
54988
def match_pattern(self, path):
        
        for pattern in self.__pattern:
            if len(fnmatch.filter([path], pattern)) > 0:
                return True
        return False
768407
@Override
    public boolean matches(Source src) {
        String name = src.getOrigin().getName().toLowerCase();
        if (FilenameUtils.isExtension(name, "textile")) {
            return true;
        }
        return false;
    }
775479
protected static boolean isNameValid(String name) {
    Preconditions.checkNotNull(name);
    name = name.toLowerCase();
    return VALID_DB_TABLE_NAME_PATTERN_1.matcher(name).matches()
        && VALID_DB_TABLE_NAME_PATTERN_2.matcher(name).matches();
  }
1283095
def filter_wildcard(names, pattern):
    
    return tuple(name for name in names
                 if fnmatch.fnmatch(name, pattern))
601686
def _name_matches(name, matches):
    '''
    
    '''
    for m in matches:
        if name.endswith(m):
            return True
        if name.lower().endswith('_' + m.lower()):
            return True
        if name.lower() == m.lower():
            return True
    return False
1253382
def is_builtin_name(name):
  """"""
  if name.startswith('__') and name.endswith('__'):
    return ALL_LOWER_CASE_RE.match(name[2:-2]) is not None
  return False
872017
def match(self, pattern):
        """"""

        m = pattern.match(self._string, self._index)
        if m:
            self._index = m.end()
        return m
815085
public static @Nonnull Predicate nameContains(final @Nonnull Pattern pattern) {
        return new Predicate() {
            @Override
            public boolean isValid(@Nonnull ProcessThread<?, ?, ?> thread) {
                return pattern.matcher(thread.getName()).find();
            }
        };
    }
1123516
def has_regex_namespace_name(self, namespace: str, name: str) -> bool:
        """"""
        return self.has_regex_namespace(namespace) and self.namespace_to_pattern[namespace].match(name)
1124555
def match_files(files, pattern: Pattern):
    """"""

    for name in files:
        if re.match(pattern, name):
            yield name
178867
public static boolean isMemberName(String name)
  {
    if(name == null) {
      return false;
    }
    Matcher matcher = MEMBER_NAME_PATTERN.matcher(name);
    return matcher.find();
  }