Report if the key given as an argument is a legal xsl:output key.

@param key non-null reference to key name.

@return true if key is legal.
170075
public static boolean isLegalPropertyKey(String key)
  {

    return (key.equals(OutputKeys.CDATA_SECTION_ELEMENTS)
            || key.equals(OutputKeys.DOCTYPE_PUBLIC)
            || key.equals(OutputKeys.DOCTYPE_SYSTEM)
            || key.equals(OutputKeys.ENCODING)
            || key.equals(OutputKeys.INDENT)
            || key.equals(OutputKeys.MEDIA_TYPE)
            || key.equals(OutputKeys.METHOD)
            || key.equals(OutputKeys.OMIT_XML_DECLARATION)
            || key.equals(OutputKeys.STANDALONE)
            || key.equals(OutputKeys.VERSION)
            || (key.length() > 0) 
                  && (key.charAt(0) == '{') 
                  && (key.lastIndexOf('{') == 0)
                  && (key.indexOf('}') > 0)
                  && (key.lastIndexOf('}') == key.indexOf('}')));
  }
2873
public boolean containsKey(Object key) {
        return isValidKey(key) && vals[((Enum<?>)key).ordinal()] != null;
    }
402453
public boolean containsKey(int key) {
        Entry tab[] = table;

        int index = (key & 0x7FFFFFFF) % tab.length;
        for (Entry e = tab[index]; e != null; e = e.next) {
            if (e.key == key) {
                return true;
            }
        }
        
        return false;
    }
366921
private static boolean isApplicationHeader(String key) {
    // Don't allow HTTP/2 pseudo headers or content-type to be added by the application.
    return (!key.startsWith(":")
            && !CONTENT_TYPE_KEY.name().equalsIgnoreCase(key))
            && !USER_AGENT_KEY.name().equalsIgnoreCase(key);
  }
1305668
@SuppressWarnings("ReferenceEquality")
  public boolean hasTemplateKey(TemplateType templateKey) {
    // Note: match by identity, not equality
    for (TemplateType entry : templateKeys) {
      if (entry == templateKey) {
        return true;
      }
    }
    return false;
  }
284309
public boolean getBoolean(String key) {
    if (containsKey(key)) {
      return "true".equalsIgnoreCase(get(key));
    } else {
      throw new IllegalArgumentException("Missing key " + key + ".");
    }
  }
583490
@VisibleForTesting
  public boolean containsKey(K key) {
    Preconditions.checkNotNull(key, "key can not be null");
    return mCache.containsKey(key);
  }
79665
public boolean containsKey(final int key)
    {
        boolean found = false;
        @DoNotSub final int setNumber = Hashing.hash(key, mask);
        @DoNotSub final int setBeginIndex = setNumber << setSizeShift;

        for (@DoNotSub int i = setBeginIndex, setEndIndex = setBeginIndex + setSize; i < setEndIndex; i++)
        {
            if (null == values[i])
            {
                break;
            }

            if (key == keys[i])
            {
                found = true;
                break;
            }
        }

        return found;
    }
80781
public static boolean verifyLuhn (String key)
    {
        // If there is a non digit, or it is all zeros.
        if (StringUtil.isBlank(key) || key.matches(".*\\D.*") ||
            key.matches("^[0]+$")) {
            return false;
        }

        return (getLuhnRemainder(key) == 0);
    }
1315351
public synchronized boolean containsKey(Object key) {
		if(size == 0) {
			return false;
		} else {
			try {
				XAttributeMap map = deserialize();
				return map.containsKey(key);
			} catch (IOException e) {
				e.printStackTrace();
				return false;
			}
		}
	}
1160993
public <T> boolean containsKey(Key<T> key) {
        if (key == null) {
            throw new IllegalArgumentException("key must not be null");
        }
        return data.containsKey(key.getName());
    }
938469
public static boolean isValidParamKey(String paramkey) {
        char c = paramkey.charAt(0);
        return c != RpcConstants.HIDE_KEY_PREFIX && c != RpcConstants.INTERNAL_KEY_PREFIX;
    }
851750
public boolean isSet(PropertyKey key) {
    if (isSetByUser(key)) {
      return true;
    }
    // In case key is not the reference to the original key
    return PropertyKey.fromString(key.toString()).getDefaultValue() != null;
  }
394720
public boolean containsKey(String key) {
    key = key.toLowerCase();
    key = key.trim();
    return map.containsKey(key);
  }
1253799
def _valid_key(self, key):
        
        if not isinstance(key, str):
            return False
        elif hasattr({}, key):
            return False
        elif key in self._special_names:
            return False
        else:
            return self._valid_key_pattern.match(key)
1203030
@Override
	public boolean containsKey(final Object key) {
		return propsMap.containsKey(key) ? true : defaults != null && defaults.containsKey(key);
	}
70324
private char checkKey(Object key) {
	if (key == null) {
	    throw new NullPointerException("key cannot be null");
	} else if (!(key instanceof Character)) {
	    throw new IllegalArgumentException("key must be an Character");
	}
	else {
	    return ((Character)key).charValue();
	}
    }