package{
import flash.display.Sprite;
public class Main extends Sprite{
public function Main(){
var reCase:RegExp = new RegExp("abc", "ig");
var sVal:String = "aBcdefabCdefABC";
var aMatch:Array = reCase.exec(sVal);
trace(aMatch + " - " + reCase.lastIndex);
aMatch = reCase.exec(sVal);
trace(aMatch + " - " + reCase.lastIndex);
aMatch = reCase.exec(sVal);
trace(aMatch + " - " + reCase.lastIndex);
aMatch = reCase.exec(sVal);
trace(aMatch + " - " + reCase.lastIndex);
aMatch = reCase.exec(sVal);
trace(aMatch + " - " + reCase.lastIndex);
}
}
}
|