Checks that the case is okay for the source.
976641
boolean checkSource(PathImpl sourceDir, String javaName)
  {
    try {
      while (javaName != null && ! javaName.equals("")) {
        int p = javaName.indexOf('/');
        String head;
      
        if (p >= 0) {
          head = javaName.substring(0, p);
          javaName = javaName.substring(p + 1);
        }
        else {
          head = javaName;
          javaName = null;
        }

        String []names = sourceDir.list();
        int i;
        for (i = 0; i < names.length; i++) {
          if (names[i].equals(head))
            break;
        }

        if (i == names.length)
          return false;

        sourceDir = sourceDir.lookup(head);
      }
    } catch (IOException e) {
      log.log(Level.FINE, e.toString(), e);
      
      return false;
    }

    return true;
  }
1290774
public function assertContains($needle, $ignoreCase = false, $checkForObjectIdentity = true, $checkForNonObjectIdentity = false) {
        $this->callAssertMethod(__FUNCTION__, [
            'expected' => $needle,
            'additionalParams' => [
                $ignoreCase,
                $checkForObjectIdentity,
                $checkForNonObjectIdentity,
            ],
        ]);
    }
527851
function checkOld (id, ts) {
    return false
    if(sources[id] && sources[id] >= ts) return true
    sources[id] = ts
  }
1100064
def compliance(self, value):
        """"""
        if (self.api_version < '2.0'):
            self.profile = value
        else:
            try:
                self.profile[0] = value
            except AttributeError:
                # handle case where profile not initialized as array
                self.profile = [value]
494399
static boolean isBadCase(String name)
    {
        EnumItem<NS> nrEnumItem = dictionary.get(name);
        if (nrEnumItem == null) return false;
        return nrEnumItem.containsLabel(NS.Z);
    }
108574
@Pure
	public static boolean isCaseSensitiveFilenameSystem() {
		switch (OperatingSystem.getCurrentOS()) {
		case AIX:
		case ANDROID:
		case BSD:
		case FREEBSD:
		case NETBSD:
		case OPENBSD:
		case LINUX:
		case SOLARIS:
		case HPUX:
			return true;
			//$CASES-OMITTED$
		default:
			return false;
		}
	}
343498
public static boolean containsIgnoreCase(final String source, final String target) {

    if (source != null && target != null) {
      return indexOfIgnoreCase(source, target) != INDEX_OF_NOT_FOUND;
    } else {
      return false;
    }
  }
1216063
def isValid( self ):
        
        check = nativestring(self._filepathEdit.text()).split(os.path.pathsep)[0]
        if ( self.filepathMode() == XFilepathEdit.Mode.SaveFile ):
            check = os.path.dirname(check)
        
        return os.path.exists(check)
1083272
def _check_valid(key, val, valid):
    """"""
    if val not in valid:
        raise ValueError('%s must be one of %s, not "%s"'
                         % (key, valid, val))
1311913
public function hasValidSourceFile()
    {
        $sourcefile = $this->getSourceFile();

        return (true === is_readable($sourcefile) && false === is_dir($sourcefile));
    }
106796
public boolean isChecksumValid() {
        if(checksum == 0)
            return true;

        int crc = CRCUtils.getCRC(getHeader());
        if(data != null && data.length > 0) {
            crc = CRCUtils.getCRC(data, crc);
        }

        return (checksum == crc);
    }
669345
public synchronized boolean contains(EvidenceType type, Evidence e) {
        if (null != type) {
            switch (type) {
                case VENDOR:
                    return vendors.contains(e);
                case PRODUCT:
                    return products.contains(e);
                case VERSION:
                    return versions.contains(e);
                default:
                    break;
            }
        }
        return false;
    }
1275272
static boolean isBadCase(String name)
    {
        EnumItem<NR> nrEnumItem = dictionary.get(name);
        if (nrEnumItem == null) return false;
        return nrEnumItem.containsLabel(NR.A);
    }
881404
def valid(a, b):
    """"""
    return ~(np.isnan(a) | np.isinf(a) | np.isnan(b) | np.isinf(b))
641011
function isBoundaryCase(frac){
    var e2 = options.epsilon * options.epsilon;
    return e2 >= (frac-1)*(frac-1) || e2 >= frac*frac;
  }
698974
def valid_result(self, r):
        '''
            
        '''
        source_mapping_elements = [elem['source_mapping']['filename_absolute'] for elem in r['elements'] if 'source_mapping' in elem]
        if r['elements'] and all((any(path in src_mapping for path in self._paths_to_filter) for src_mapping in source_mapping_elements)):
            return False
        return not r['description'] in [pr['description'] for pr in self._previous_results]
978885
def _valid(m, comment=VALID_RESPONSE, out=None):
    '''
    
    '''
    return _set_status(m, status=True, comment=comment, out=out)