Code Slinger: A DP Blog


Posted At: May 18, 2010 2:05 PM | Posted By: Michael Labriola
Related Categories: Adobe Flex

First, let me say I am sorry. A year or so ago, I wrote these VectorCollection classes. They are not spectacular works of art, they are very basic implementations required to use Vector inside of Flex components which are looking for IList and ICollectionView for their dataProviders. Vector has some performance advantages in some cases (for more details, take a look here. ) but overall, the big advantage to me is type safety. I know what should be in the Vector and flash knows if I mess that up. On the whole, these are simple implementations that don’t solve every problem I would love to solve if I had the Flash Player source and some time, but they will allow you to use Vectors more directly in Flex. So, if you find them useful, then enjoy. private var source:Vector.<uint>; source = new Vector.<uint>; private var vc:VectorListCollection; vc = new VectorListCollection( source ); var sort:Sort = new Sort(); var field:SortField = new SortField( null, false, false, true ); sort.fields = [field]; vc.sort = sort; vc.refresh(); File Available Here Cheers, Mike

Share and Enjoy:
  • Print
  • Digg
  • StumbleUpon
  • Facebook
  • Twitter
  • PDF
  • RSS
  • email
  • Technorati

Comments (2)

2 thoughts on “VectorCollection”

Fatal error: Call to undefined function twentyfifteen_comment_nav() in /var/www/vhosts/92/242500/webspace/httpdocs/ on line 33