Entries for month: January 2009

Using Metro - A Transfer ORM Audit Observer

Metro , Transfer , Ideas , ColdFusion , ColdSpring 1 Comment »

The Transfer ORM Event Model provides an API for notifying components in your application of events in the Transfer object life cycle. You can use it to setup your component dependencies as demonstrated by Brian Kotek's TDOBeanInjectorObserver (part of his ColdSpring Utils library), or set specific properties on the Transfer object prior to creating or updating the object (see Bob Silverberg's post on the subject). Depending on your application needs, you can also tap into other Transfer events to create an audit trail and history for specific classes in your model. That's where the idea for the TransferAuditObserver (which is included in the Metro security package) was born. Setting CreateDate or LastModifiedDate properties on an object didn't sit well with me, because the observer was acting on the object state. Instead, I wanted an observer that recorded the events and state of of the object when those events were fired. Therefore, the TransferAuditObserver registers itself to listen for AfterCreate, AfterUpdate and BeforeDelete events, depending on a simple configuration map.

Read more...

Metro 0.3.1 Released

Metro , Transfer , ColdFusion , ColdSpring 1 Comment »

While in the process of generating documentation for Metro (using Mark Mandel's excellent Colddoc), I realized that I am generally remiss about using hint. Therefore, I embarked on a mission of adding hints to the Metro library. During the course of this exercise, I chose to re-factor a few items that I wasn't completely happy with. The result is Metro 0.3.1.

Read more...

Using Metro - Decorators and Validation

Metro , Transfer , ColdFusion , jQuery 4 Comments »

In the first part of Using Metro, I reviewed the Service and Gateway portion of the Metro security package. In this post, I'll describe the core Metro Decorator and Validator as well as the jQuery plugin I use for client side validation.

Read more...

Metro 0.3 Released

Metro No Comments »

The latest version of Metro is now available on RIAForge. Here's the skinny on what has changed.

  1. Added an audit package
    I've been using a Transfer AfterCreate and AfterUpdate observer to track changed to Transfer objects that I wish to track. Since this has become a common part of some of the apps I'm building, I decided to include it in Metro.
  2. Updated the core Service and Gateway to add getByProperty() support
    I ran into a use case for this on a new project and decided to add it to simplify things.
  3. Fixed a bug in core Decorator related to validation rule creation
    This update fixes a problem created when no min and max arguments are passed to addRule().
  4. Updated the security package to add "Active" attribute to User
    Another use case addition. In order to provide a little more security to user registration, I added and Active flag to the User object.

Powered by Mango Blog. Design and Icons by N.Design Studio
RSS Feeds