if (FJ === undefined) alert('fj.js must be included first');
else {
	FJ.UI = Class.create({
		
		CLASSNAME: 'UI',
		
		initialize: function() {
			this._extend_objects();
		},
		
		// add the _elements function to each of the defined objects in 
		// the class that have a _selector variable
		_extend_objects: function() {
			for (var varName in this) {
				var object = this[varName];
				if (object && object['enhance'] || object['degrade'])
					object._elements = function() {
						if (this._elements_arr === undefined) {
							this._elements_arr = $A($$(varName));
						}
						return this._elements_arr;
					}();
			}
		}
		
	});
}