Returns true if location is inside map.
@param location
@return
962095
public boolean inMap(Location location)
    {
        for (String map : schedule.getMap())
        {
            if (station.inMap(map, location))
            {
                return true;
            }
        }
        return false;
    }
1336982
private function isMainLocation(Location $location)
    {
        $locationContentInfo = $this->contentHandler->loadContentInfo($location->contentId);

        return $locationContentInfo->mainLocationId === $location->id;
    }
304449
public static LocationEngineResult create(Location location) {
    checkNotNull(location, "location can't be null");
    List<Location> locations = new ArrayList<>();
    locations.add(location);
    return new LocationEngineResult(locations);
  }
635695
public static Location center(Location... location)
    {
        double lat = 0;
        double lon = 0;
        double height = 0;
        for (int ii=0;ii<location.length;ii++)
        {
            lat += location[ii].getLatitude();
            lon += location[ii].getLongitude();
        }
        Location loc = new Location(lat/location.length, lon/location.length);
        return loc;
    }
314183
private static boolean isEmptyOrNull( GitLocation location ) {
    return location == null ||
        (StringUtils.isEmptyOrNull(location.getRepository()) &&
        StringUtils.isEmptyOrNull(location.getBranch()) &&
        StringUtils.isEmptyOrNull(location.getRevision()));
  }
1031810
public boolean contains(RoaringBitmap subset) {
    if(subset.getCardinality() > getCardinality()) {
      return false;
    }
    final int length1 = this.highLowContainer.size;
    final int length2 = subset.highLowContainer.size;
    int pos1 = 0, pos2 = 0;
    while (pos1 < length1 && pos2 < length2) {
      final short s1 = this.highLowContainer.getKeyAtIndex(pos1);
      final short s2 = subset.highLowContainer.getKeyAtIndex(pos2);
      if (s1 == s2) {
        Container c1 = this.highLowContainer.getContainerAtIndex(pos1);
        Container c2 = subset.highLowContainer.getContainerAtIndex(pos2);
        if(!c1.contains(c2)) {
          return false;
        }
        ++pos1;
        ++pos2;
      } else if (Util.compareUnsigned(s1, s2) > 0) {
        return false;
      } else {
        pos1 = subset.highLowContainer.advanceUntil(s2, pos1);
      }
    }
    return pos2 == length2;
  }
265006
@TargetApi(Build.VERSION_CODES.FROYO)
    public static boolean hasGpsLocationFeature(PackageManager manager) {
        return manager.hasSystemFeature(PackageManager.FEATURE_LOCATION_GPS);
    }
75108
public boolean contains(ImmutableRoaringBitmap subset) {
    if(subset.getCardinality() > getCardinality()) {
      return false;
    }
    final int length1 = this.highLowContainer.size();
    final int length2 = subset.highLowContainer.size();
    int pos1 = 0, pos2 = 0;
    while (pos1 < length1 && pos2 < length2) {
      final short s1 = this.highLowContainer.getKeyAtIndex(pos1);
      final short s2 = subset.highLowContainer.getKeyAtIndex(pos2);
      if (s1 == s2) {
        MappeableContainer c1 = this.highLowContainer.getContainerAtIndex(pos1);
        MappeableContainer c2 = subset.highLowContainer.getContainerAtIndex(pos2);
        if(!c1.contains(c2)) {
          return false;
        }
        ++pos1;
        ++pos2;
      } else if (compareUnsigned(s1, s2) > 0) {
        return false;
      } else {
        pos1 = subset.highLowContainer.advanceUntil(s2, pos1);
      }
    }
    return pos2 == length2;
  }
921063
@Override
    public boolean has(int index, Scriptable start)
    {
        if (externalData != null) {
            return (index < externalData.getArrayLength());
        }
        return null != slotMap.query(null, index);
    }
696977
protected boolean isConfigLocation(URI location) {
        String scheme = location.getScheme();
        if (scheme == null) {
            // interpret as place holder
            try {
                String resolvedPlaceholder = getProperty(location.getRawSchemeSpecificPart());
                if (resolvedPlaceholder == null) {
                    return false;
                }
                location = new URI(resolvedPlaceholder);
                scheme = location.getScheme();
            } catch (URISyntaxException e) {
                return false;
            }
        }
        return (scheme != null && SUPPORTED_SCHEMES.contains(scheme.toLowerCase(StringUtil.LOCALE_INTERNAL)));
    }
33947
public boolean isInEqualLocation(Node node2) {
        if (!isNewNode() && !node2.isNewNode()) {
            return getBeginLine() == node2.getBeginLine() && getBeginColumn() == node2.getBeginColumn()
                    && getEndLine() == node2.getEndLine() && getEndColumn() == node2.getEndColumn();
        }
        return false;
    }
203601
protected boolean isSlopDead(Cluster cluster, Set<String> storeNames, Slop slop) {
        // destination node , no longer exists
        if(!cluster.getNodeIds().contains(slop.getNodeId())) {
            return true;
        }

        // destination store, no longer exists
        if(!storeNames.contains(slop.getStoreName())) {
            return true;
        }

        // else. slop is alive
        return false;
    }
444471
public Expression withSourceLocation(SourceLocation location) {
    checkNotNull(location);
    if (location.equals(this.location)) {
      return this;
    }
    return new Expression(resultType, features, location) {
      @Override
      protected void doGen(CodeBuilder adapter) {
        Expression.this.gen(adapter);
      }
    };
  }
680021
@Programmatic
    @Override
    public Location getLocation() {
        final String latLng = getLatLng();
        return latLng != null? Location.fromString(latLng.replace(",",";")): null;
    }
559564
public boolean containsKey(final K1 firstKey, final K2 secondKey) {
		// existence check on inner map
		final HashMap<K2, HashMap<K3, V>> innerMap1 = map.get(firstKey);
		if( innerMap1 == null ) {
			return false;
		}
		
		return innerMap1.containsKey(secondKey);
	}
1109998
public static function is_iplocation($ip, $location)
	{
		$iplocation = false;
		if ($ip && $location)
		{
			if (!($gdb = self::getGeoDBO()))
			{
				return $iplocation;
			}

			$sql = "SELECT COUNT(*) FROM iplocation WHERE ipfrom <= INET_ATON(" . $gdb->quote($ip) . ") AND ipto >= INET_ATON(" . $gdb->quote($ip) . ") AND LOWER(location) = LOWER(" . $gdb->quote($location) . ")";
			$gdb->setQuery($sql);
			$c = $gdb->loadResult();
			if ($c > 0)
			{
				$iplocation = true;
			}
		}
		return $iplocation;
	}
1205748
@Override
    public boolean hasLocation(JavaFileManager.Location location) {
        proc.debug(DBG_FMGR, "hasLocation: location: %s\n", location);
        return stdFileManager.hasLocation(location);
    }