Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions src/com/adobe/utils/StringUtil.as
Original file line number Diff line number Diff line change
Expand Up @@ -235,5 +235,24 @@ package com.adobe.utils
//todo: this needs a unit test
return (s != null && s.length > 0);
}


/**
* Returns true if and only if the input string contains the specified sequence value.
*
* @param input The string in which we are searching for the sequence
* @param sequence The string to search for
*
* @returns true if input contains sequence, false otherwise
*
* @langversion ActionScript 3.0
* @playerversion Flash 9.0
* @tiptext
*/
public static function contains(input:String, sequence:String):Boolean
{
return input != null && input.indexOf(sequence) >= 0;
}

}
}