Continuing the topic Advises for beginners I am going to talk about the most comfortable way to incapsulate server’s methods calls. Let’s call it ServiceBase pattern. It is a base class for all your possible services (bunch of methods which correspond to the server ones):
Category:
To Flex Or Not To Flex
In this article I would like to share my experience in application development using Flex to make it easier for you to choose to use or not to use it in particular situations. Far too often it appears that using Flex is not only unwelcome because of time limits but can also be damaging to the project.
First let’s overview application types to search for the fertile field for starting Flex development. Apparently we can already divide the applications we are interested in into desktop and web-top applications. Web applications may be usual (casual) or RIA, and each of them may have either front-end (surface site) or back-end (admin panel). We must never forget that they may be internet type for casual men of the web and intranet type for corporative users. With the help of Adobe AIR Flex became available on desktop but its usage comply with the same requirements as it does on web.
My Two Cents About Mate Flex Framework
Until the last moment I have been very sceptic about every Flex framework I have seen. I have not paid too much attention to Cairngorm or PureMVC but I was aware of their specifics. For example I don’t really like a global accessibility of View which appears to be available everywhere in code of a project which is written using Cairngorm. Also I was stuck with amount of mediator classes in PureMVC which cause growing up of the code’s size. That is why I have never used something except default component and event model of Flex Framework.
I was impressed by great feedbacks of RIA-gurus and decided to find out that is the matter. Don’t expect, I am not going to write about Mate’s model behavior but I will write only a few sentences. Mate is really cool!
I think the success of Mate relates to the fact that framework is not ported but exclusively written for Flex. It uses the main (maybe not very correct) principals and peculiarities of Flex Framework, such as:
- Inheritance of all visual components from EventDispatcher which give us possibility to use bubbling-events as transport messages between View and Model.
- Binding for IOC (Inversion of Controls).
- MXML for describing in simple way dependency declarations between application’s layers.
All I have described above works with your custom classes and components without mandatory inheriting of fatiguable abstract classes for commands, mediators, models etc. And for afters Mate Framework is extensible by custom plugins.
Altogether you could get the first impression after reading Mate documentation not longer then one hour. Reviewing of the source code confirms that framework’s authors are good professionals who turned back Flex’s issues to benefits. Let’s use it.
ResizeableLayoutBox Component
There is an example.
The component ResizeableLayoutBox is used for creating a GUI like dockable IDE. It must be used with CollapsablePanel which give us a possibility to expand and collapse panels.
Current realization of the component supports either a vertical (Accordion way) positioning or a horizontal one. Size of the panel can be changed by dragging it’s header by the mouse. While resizing such properties as minWidth, maxWidth, minHeight, maxHeight are considered.
Classes are located in Go!Verla Library.
PatternRectangularBorder Component
There is an example.
The component PatternRectangularBorder can be used as background for such containers as Application, Canvas, HBox, VBox, Form etc. It based on RectangularBorder and BitmapData classes from Flex 2 SDK and works more natural then CSS image patterns in WSBackgroundPixelSkin component.
The component supports base Container’s style property background-image, also it extends that one by a new style property background-repeat which is usually used in HTML CSS. Possible values are
- repeat
- repeat-x
- repeat-y
I was unable to extend RectangularBorder because it’s totally private so copy-past way is a solution here for me.
The class is located in Go!Verla Library.
List of related links

