You are here

function patterns_api_is_reserved_word in Patterns 7.2

Same name and namespace in other branches
  1. 7 includes/api/api.inc \patterns_api_is_reserved_word()

Returns TRUE if a string is a Patterns reserved word

Parameters

mixed $word: The string to check.

Return value

Boolean, TRUE, if it is a reserved word

1 call to patterns_api_is_reserved_word()
patterns_api_add_section in includes/api/api.inc
Initializes an empty section in a pattern file.

File

includes/api/api.inc, line 37
API for writing pattern files.

Code

function patterns_api_is_reserved_word($word = NULL) {
  if (is_null($word)) {
    return FALSE;
  }
  return in_array($word, patterns_api_reserved_words()) ? TRUE : FALSE;
}