Can i still do this in AS3?

With AS2 it was possible to attach a movieClip on the stage using the linkage name from an outside source - xml for example

var linkage:String = “LibraryItem”;
this.attachMovieClip(linkage, “instance”,depth );

now, how can I do this in AS3 ?
where the context to add items from library is:

var instance: LibraryItem = new LibaryItem();