Name

contains, does not contain, is in, is not in

Synopsis

containment

containment

Syntax

string1 contains string2
string2 is in string1
list1 contains list2
list2 is in list1
record1 contains record2
record2 is inrecord1

Description

Tests whether the first operand contains the second. The is in synonyms reverse the operand order of the contains synonyms—that is, with is in, the second operand comes physically before the first operand (as deliberately shown in the syntax listings), but it is still the second operand. This is relevant in the rules for implicit coercions.

Get AppleScript: The Definitive Guide, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.