list/Contains

From Garry's Mod
(Difference between revisions)
Jump to: navigation, search
(Created page with "{{Func |Name=Contains |Parent=list |Description=Returns true if the list contains the value. (as a value - not a key) |Realm=Shared |IsClass=No }} {{Arg |type=string |name=lis...")
 
 
(One intermediate revision by one user not shown)
Line 1: Line 1:
 
{{Func
 
{{Func
|Name=Contains
 
|Parent=list
 
 
|Description=Returns true if the list contains the value. (as a value - not a key)
 
|Description=Returns true if the list contains the value. (as a value - not a key)
|Realm=Shared
+
 
 +
For a function that looks for a key and not a value see {{LibraryFunction|list|HasEntry}}.
 +
|Realm=Shared and Menu
 
|IsClass=No
 
|IsClass=No
 
}}
 
}}

Latest revision as of 06:10, 28 June 2019

 list.Contains( )

Contents

Description

Returns true if the list contains the value. (as a value - not a key)

For a function that looks for a key and not a value see list.HasEntry.

Arguments

string list

List to search through

Arguments

any value

The value to test

Returns

boolean

Returns true if the list contains the value, false otherwise
Personal tools
Navigation