Piping the Machine: PureMVC Multicore with Pipes and the Finite State Machine (FSM)
This is going to be a walkthrough of making use of PureMVC Multicore (AS3). To help in building a PureMVC Multicore application, we are going to make use of the StateMachine utility for initial setup and configuration as well as the Pipes utility for communication between cores.
So what's up with PureMVC Commands anyway?
That is what Jesse Warden (JesterXL) asks the fine folks over at the PureMVC forums. Cliff gives a good rundown on the why/when/how of PureMVC Commands.
PureMVC's relatively light use of commands, when compared to other widely used MVC frameworks, tends to make one think they are doing something wrong. This isn't really the case. Commands are still viable actors in our applications, but many times the shortest route is the best route. PureMVC doesn't force us to use them, but gives us access when we need to.
I generally use PureMVC Commands for actions that can be initiated from several places, as well as for application startup. I've also found them very useful for popups and AIR window management.
Introspective PureMVC Console
This project is intended to help Flex and AS3 application developers, that use the PureMVC framework for AS3 - simple or multicore version - by providing them deep insights on what happens at the framework level: Notifications, Commands, Mediators and Proxies.
PureMVC is a highly recognized MVC framework, that has also many portages in various languages, and that's now quite widely in Flex applications, though not as much as Cairngorm.
What a fantastic tool. You can really dig deep into your application.
- Monitors the internal flow of PureMVC in real time
- Discover and inspect Mediators
- Inspect Views associated to Mediators
- Discover and inspect Proxies
- Find starting point in source code
- Integrated with KapInspect
Fabrication – Simplified PureMVC multicore modules (and more)
One of the many reasons I love PureMVC is the community of highly intelligent, skilled, object-oriented (oriented) programmers that are constantly using the framework to build new and interesting utilities. This is a by-product of the very nature of PureMVC. Cliff architected the core framework in such a way that is is truly simple, providing a base from which to build new useful structures.
Fabrication, a new utility developed by Darshan Sawardekar is a shining example of this fact. He has taken the PureMVC multi-core apperatus, combined it with Cliff's Pipes utility, and created a wonderfully abstracted means for creating modular PureMVC applications. Not only does this simplify the connection of modules in your application and allow them to communicate seamlessly, but he provides a router/firewall metaphor for controlling the communication as well as undo/redo functionality.
Thanks Darshan, your efforts are appreciated. And as always, thanks Cliff for providing the base from which our community can build and contribute. Cheers.
Continuous scrolling image thumbnail component for Flex.
Here is the beginnings of a full featured open-source continuous scroll thumbnail component for Flex. It is rough right now, but I plan to polish it and make it something useful. This format is really appealing, as it gives the user a seamless view of a gallery, without any jumps or aggravating scroll bars. Up until now I have been using H and V Lists in flex for my thumbnailing, but they are ugly and don't provide as rich of an experience.
The Scroll Panel from AFComponents was my first choice. It is a very nice component, well priced, and would be just what I need, if not for the fact that my project is open-source and using a commercial component sorta kills the whole thing. After scouring the internet I finally stumbled upon the work Peter Wright has put in on a perpetual scrolling list.
I've modified it to accept an XML list of image objects, as well as perform horizontally. It is also functioning as a slideshow, and I want to allow it to go either H or V depending on the need. It should shape up to be a nice reusable component. Much thanks to Peter for supplying the code to get me started.
Renju – AS3 board game built with the PureMVC framework.
This is awesome. Here is a polished board game with nice graphics and sounds - full AI - and best of all, the complete source. This is a great example of PureMVC in action. All of the projects on Actionscript Notes utilize PureMVC, and the owner seems to be generous with the source. Many thanks for that.
PureMVC Python port has been released
I am very excited about the potential of this port. As far as I can tell, there isn't a whole lot out there for MVC and Python. There are a handful of server/web MVC frameworks. Django is the one that I have experience with, and it is a fantastic framework. As is true when comparing PureMVC to most frameworks, however, the PureMVC for Python is dead simple. It is a straight port, implementing PureMVC in the same fashion as we see in the original AS3 version. Structurally it differs from Actionscript - it is Python after all - but fundamentally it is the same.
Many thanks to Toby de Havilland for overcoming some of the initial issues with the port, and getting it up and running. Thanks also to Nathan Levesque for running point on the project and getting the ball rolling with the port
Here it is running the Employee Admin demo on XP and OSX:
5 reasons PureMVC kicks ass
PureMVC is a lightweight MVC framework originally written for Actionscript 3, but which has subsequently been ported to a host of other platforms. I'm a PureMVC fan boy. There is no denying it. Here are few reasons why:
Simplicity
There are a few MVC frameworks available for Actionscript 3. None of them are, well... as pure. PureMVC is simple by design. It doesn't provide you with a lot of bells and whistles. What it does is provide a solid foundation upon which to add your own functionality in limitless ways. The framework itself is simple. 'Make it as simple as possible, but no simpler,' said Albert Einstein. This is one of the core goals of PureMVC.
Community
The PureMVC community is growing. The Architect's Lounge has high signal to noise ratio. Cliff makes a super human effort to personally answer every question that is posted. Among the helpful community members is Chandima Cumaranatunge, the co-author of a book that anybody interested in OO Actionscript should own, Actionscript 3 Design Patterns.
Cliff has created the PureMVC Manifold Project, which provides a well crafted central location for official PureMVC releases, and a host of ports, demos, and utilities developed by the community. This wealth of information provides a high quality code base to use and learn from.
Reusability
As you can see by poking around the Manifold Project, there are a lot of utilities and modules already available. The basic structure of a PureMVC project naturally lends itself to the creation of common classes that can be reused across many projects. Major components don't care who is sitting beside them. They happily wait for their notifications and respond without considering their neighbors. In some circles this would be considered rude, but in a PureMVC application this gives a wonderful, loosely couple application that can be refactored and recycled.
Portability
The port to Python is done! PureMVC is on Flex, Flash, AIR, FlashLite, Python, .NET, Windows Mobile, Silverlight, J2ME, SE, EE, JavaFX, PHP and ColdFusion. This speaks to the simplicity of the framework. It is so fundamental, that most of the ports were just straight translation.
Cliff
Cliff is samurai. He is the benevolent, tireless dictator that any flowering project needs. He is actively engaged with the community. On a daily basis he is on the forums answering questions. The structuring of the ever-expanding pile of resources and information into something useful is daunting task. There it is with the Manifold Project. It is inspiring to see someone so passionate about what they do, and channeling that passion back at anyone interested in learning.
Thanks Cliff, your efforts are greatly appreciated.
VEsession – Flex photography studio management and client ordering application
My wife saw the application that I am working on at work to manage tasks and immediately asked, "Where's mine?"
21st century honey-do list.
So far, this is what I have created. PureMVC is the underlying framework. The photos are loaded from SlideShowPro Director XML galleries. Unforutately, the most recent version of SSP-D won't let you use it as a service in this way. This older version is has all the functionality I need though, so it isn't an issue. Eventually I will implement functionality to eliminate the need for SSP-D with some gallery management. It will be better to keep it all under one roof.
The backend is Django using pyAMF for communications back and forth. Django elminates the pain of CRUD operations and provides an excellent admin interface for free.
My goal is to open source the application and provide it as a PureMVC/Django example.
UPDATED: This version is a little jacked because I am working on a new version. The demo images are way too big and cause the application to scroll in unsightly ways. The new demo is located here, and uses the same credentials as below.
[Here is the demo]
user: demo_client
pass:demo_client

[source]
Do to some, uh, laziness on my part, this will only compile with strict mode turned off The new version does not have this problem.
PureMVC – An overview
Chandima Cumaranatunge has written a great introduction to PureMVC. I'm working on my 2nd 'non-trivial' PureMVC application write now, a photography studio managment/client ordering system. To be fair to Cairngorm, I only evaluated it when my Actionscript knowledge was.. well, less than it is now. At the time I couldn't grasp PureMVC. But in the meantime I have worked and studied a bit and when I came back to PureMVC, the startling simplicity of it, along with Cliff Hall's implementation of familiar design patterns allowed me to build applications that are structurally sound.
On a related note, I picked up Mr. Cumaranatunge's book, Actionscript Design Patterns, a couple of weeks ago. It's a great book.





















