You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by ah...@apache.org on 2013/11/18 22:03:13 UTC

[18/21] move AS code into a projects/FlexJSUI

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/PropertyWatcher.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/PropertyWatcher.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/PropertyWatcher.as
new file mode 100644
index 0000000..bde39e6
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/PropertyWatcher.as
@@ -0,0 +1,156 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.binding
+{	
+    import org.apache.flex.events.Event;
+    import org.apache.flex.events.IEventDispatcher;
+    import org.apache.flex.events.ValueChangeEvent;
+
+	public class PropertyWatcher extends WatcherBase
+	{
+		public function PropertyWatcher(source:Object, propertyName:String, eventNames:Object, 
+                                            getterFunction:Function)
+		{
+            this.source = source;
+            this.propertyName = propertyName;
+            this.getterFunction = getterFunction;
+            this.eventNames = eventNames;
+            
+		}
+		
+		public var source:Object;
+        public var propertyName:String;
+        public var eventNames:Object;
+        public var getterFunction:Function;
+		
+        protected function changeHandler(event:Event):void
+        {
+            if (event is ValueChangeEvent)
+            {
+                var propName:String = ValueChangeEvent(event).propertyName;
+                
+                if (propName != propertyName)
+                    return;
+            }
+            
+            wrapUpdate(updateProperty);
+            
+            notifyListeners();
+            
+        }
+        
+        //--------------------------------------------------------------------------
+        //
+        //  Overridden methods: Watcher
+        //
+        //--------------------------------------------------------------------------
+        
+        /**
+         *  If the parent has changed we need to update ourselves
+         *  
+         *  @langversion 3.0
+         *  @playerversion Flash 9
+         *  @playerversion AIR 1.1
+         *  @productversion Flex 3
+         */
+        override public function parentChanged(parent:Object):void
+        {
+            if (source && source is IEventDispatcher)
+                removeEventListeners();
+
+            source = parent;
+            
+            if (source)
+                addEventListeners();
+            
+            // Now get our property.
+            wrapUpdate(updateProperty);
+        }
+
+        private function addEventListeners():void
+        {
+            if (eventNames is String)
+                source.addEventListener(eventNames as String, changeHandler);
+            else if (eventNames is Array)
+            {
+                var arr:Array = eventNames as Array;
+                var n:int = arr.length;
+                for (var i:int = 0; i < n; i++)
+                {
+                    var eventName:String = eventNames[i];
+                    source.addEventListener(eventName, changeHandler);           
+                }
+            }
+        }
+        
+        private function removeEventListeners():void
+        {
+            if (eventNames is String)
+                source.removeEventListener(eventNames as String, changeHandler);
+            else if (eventNames is Array)
+            {
+                var arr:Array = eventNames as Array;
+                var n:int = arr.length;
+                for (var i:int = 0; i < n; i++)
+                {
+                    var eventName:String = eventNames[i];
+                    source.removeEventListener(eventName, changeHandler);           
+                }
+            }
+        }
+        
+        /**
+         *  Gets the actual property then updates
+         *  the Watcher's children appropriately.
+         *  
+         *  @langversion 3.0
+         *  @playerversion Flash 9
+         *  @playerversion AIR 1.1
+         *  @productversion Flex 3
+         */
+        private function updateProperty():void
+        {
+            if (source)
+            {
+                if (propertyName == "this")
+                {
+                    value = source;
+                }
+                else
+                {
+                    if (getterFunction != null)
+                    {
+                        value = getterFunction.apply(source, [ propertyName ]);
+                    }
+                    else
+                    {
+                        value = source[propertyName];
+                    }
+                }
+            }
+            else
+            {
+                value = null;
+            }
+            
+            updateChildren();
+        }
+
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/SimpleBinding.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/SimpleBinding.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/SimpleBinding.as
new file mode 100644
index 0000000..bab9378
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/SimpleBinding.as
@@ -0,0 +1,64 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.binding
+{	
+	import flash.events.IEventDispatcher;
+	import flash.events.Event;
+
+	import org.apache.flex.core.IBead;
+	import org.apache.flex.core.IStrand;
+	import org.apache.flex.core.IDocument;
+
+	public class SimpleBinding implements IBead, IDocument
+	{
+		public function SimpleBinding()
+		{
+		}
+		
+		protected var source:IEventDispatcher;
+		protected var document:Object;
+		protected var destination:Object;
+
+		public var sourceID:String;
+		public var sourcePropertyName:String;
+		public var eventName:String;
+		public var destinationPropertyName:String;
+		
+		public function set strand(value:IStrand):void
+		{
+			destination = value;
+            if (sourceID != null)
+    			source = document[sourceID] as IEventDispatcher;
+            else
+                source = document as IEventDispatcher;
+			source.addEventListener(eventName, changeHandler);
+			destination[destinationPropertyName] = source[sourcePropertyName];
+		}
+		
+		public function setDocument(document:Object, id:String = null):void
+		{
+			this.document = document;
+		}
+		
+		private function changeHandler(event:Event):void
+		{
+			destination[destinationPropertyName] = source[sourcePropertyName];
+		}
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/WatcherBase.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/WatcherBase.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/WatcherBase.as
new file mode 100644
index 0000000..47d4286
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/binding/WatcherBase.as
@@ -0,0 +1,236 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package org.apache.flex.binding
+{
+    
+    public class WatcherBase
+    {
+        //--------------------------------------------------------------------------
+        //
+        //  Constructor
+        //
+        //--------------------------------------------------------------------------
+        
+        /**
+         *  Constructor.
+         *  
+         *  @langversion 3.0
+         *  @playerversion Flash 9
+         *  @playerversion AIR 1.1
+         *  @productversion Flex 3
+         */
+        public function WatcherBase()
+        {
+            super();
+        }
+        
+        //--------------------------------------------------------------------------
+        //
+        //  Variables
+        //
+        //--------------------------------------------------------------------------
+        
+        /**
+         *  @private
+         *  The binding objects that are listening to this Watcher.
+         *  The standard event mechanism isn't used because it's too heavyweight.
+         */
+        protected var listeners:Array;
+        
+        /**
+         *  @private
+         *  Children of this watcher are watching sub values.
+         */
+        protected var children:Array;
+        
+        /**
+         *  @private
+         *  The value itself.
+         */
+        public var value:Object;
+        
+        //--------------------------------------------------------------------------
+        //
+        //  Methods
+        //
+        //--------------------------------------------------------------------------
+        
+        /**
+         *  @private
+         *  This is an abstract method that subclasses implement.
+         */
+        public function parentChanged(parent:Object):void
+        {
+        }
+        
+        /**
+         *  @private
+         *  Add a child to this watcher, meaning that the child
+         *  is watching a sub value of ours.
+         */
+        public function addChild(child:WatcherBase):void
+        {
+            if (!children)
+                children = [ child ];
+            else
+                children.push(child);
+            
+            child.parentChanged(this);
+        }
+        
+        /**
+         *  @private
+         *  Add a binding to this watcher, meaning that the binding
+         *  is notified when our value changes.
+         */
+        public function addBinding(binding:GenericBinding):void
+        {
+            if (!listeners)
+                listeners = [ binding ];
+            else
+                listeners.push(binding);
+            
+            binding.valueChanged(value);
+        }
+                
+        /**
+         *  We have probably changed, so go through
+         *  and make sure our children are updated.
+         *  
+         *  @langversion 3.0
+         *  @playerversion Flash 9
+         *  @playerversion AIR 1.1
+         *  @productversion Flex 3
+         */
+        public function updateChildren():void
+        {
+            if (children)
+            {
+                var n:int = children.length;
+                for (var i:int = 0; i < n; ++i)
+                {
+                    children[i].parentChanged(this);
+                }
+            }
+        }
+        
+        /**
+         *  @private
+         */
+        private function valueChanged(oldval:Object):Boolean
+        {
+            if (oldval == null && value == null)
+                return false;
+            
+            var valType:String = typeof(value);
+            
+            // The first check is meant to catch the delayed instantiation case
+            // where a control comes into existence but its value is still
+            // the equivalent of not having been filled in.
+            // Otherwise we simply return whether the value has changed.
+            
+            if (valType == "string")
+            {
+                if (oldval == null && value == "")
+                    return false;
+                else
+                    return oldval != value;
+            }
+            
+            if (valType == "number")
+            {
+                if (oldval == null && value == 0)
+                    return false;
+                else
+                    return oldval != value;
+            }
+            
+            if (valType == "boolean")
+            {
+                if (oldval == null && value == false)
+                    return false;
+                else
+                    return oldval != value;
+            }
+            
+            return true;
+        }
+        
+        /**
+         *  @private
+         */
+        protected function wrapUpdate(wrappedFunction:Function):void
+        {
+            try
+            {
+                wrappedFunction.apply(this);
+            }
+            catch(error:Error)
+            {
+                var n:int = allowedErrorTypes.length;
+                for (var i:int = 0; i < n; i++)
+                {
+                    if (error is allowedErrorTypes[i].type)
+                    {
+                        var handler:Function = allowedErrorTypes[i].handler;
+                        if (handler != null)
+                            value = handler(this, wrappedFunction);
+                        else
+                            value = null;
+                    }
+                }
+                
+                if (allowedErrors.indexOf(error.errorID) == -1)
+                    throw error;
+            }
+        }
+        
+        // Certain errors are normal when executing an update, so we swallow them:
+        public static var allowedErrors:Array = [
+            1006, //   Error #1006: Call attempted on an object that is not a function.
+            1009, //   Error #1009: null has no properties.
+            1010, //   Error #1010: undefined has no properties.
+            1055, //   Error #1055: - has no properties.
+            1069, //   Error #1069: Property - not found on - and there is no default value
+            1507 //   Error #1507: - invalid null argument.
+            ];
+        
+        public static var allowedErrorTypes:Array = [
+            { type: RangeError /*, handler: function(w:WatcherBase, wrappedFunction:Function):Object { return null }*/ }
+            ];
+        
+        /**
+         *  @private
+         */
+        public function notifyListeners():void
+        {
+            if (listeners)
+            {
+                var n:int = listeners.length;
+                
+                for (var i:int = 0; i < n; i++)
+                {
+                    listeners[i].valueChanged(value);
+                }
+            }
+        }
+    }
+    
+}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Application.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Application.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Application.as
new file mode 100644
index 0000000..a126b6f
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Application.as
@@ -0,0 +1,167 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+    import flash.display.DisplayObject;
+    import flash.display.Sprite;
+    import flash.display.StageAlign;
+    import flash.display.StageScaleMode;
+    import flash.events.IOErrorEvent;
+    
+    import org.apache.flex.events.Event;
+    import org.apache.flex.utils.MXMLDataInterpreter;
+    
+    //--------------------------------------
+    //  Events
+    //--------------------------------------
+    
+    /**
+     *  Dispatched at startup.
+     */
+    [Event(name="initialize", type="org.apache.flex.events.Event")]
+    
+    public class Application extends Sprite implements IStrand, IFlexInfo, IParent
+    {
+        public function Application()
+        {
+            super();
+			if (stage)
+			{
+				stage.align = StageAlign.TOP_LEFT;
+				stage.scaleMode = StageScaleMode.NO_SCALE;
+			}
+			
+            loaderInfo.addEventListener(flash.events.Event.INIT, initHandler);
+        }
+
+        private function initHandler(event:flash.events.Event):void
+        {
+            ValuesManager.valuesImpl = valuesImpl;
+            ValuesManager.valuesImpl.init(this);
+
+            dispatchEvent(new Event("initialize"));
+
+            initialView.applicationModel =  model;
+    	    this.addElement(initialView);
+    	    dispatchEvent(new Event("viewChanged"));
+        }
+
+        public var valuesImpl:IValuesImpl;
+
+        public var initialView:ViewBase;
+
+        public var model:Object;
+
+        public var controller:Object;
+
+        public function get MXMLDescriptor():Array
+        {
+            return null;
+        }
+
+    	public function generateMXMLAttributes(data:Array):void
+        {
+			MXMLDataInterpreter.generateMXMLProperties(this, data);
+        }
+        
+        // beads declared in MXML are added to the strand.
+        // from AS, just call addBead()
+        public var beads:Array;
+        
+        private var _beads:Vector.<IBead>;
+        public function addBead(bead:IBead):void
+        {
+            if (!_beads)
+                _beads = new Vector.<IBead>;
+            _beads.push(bead);
+            bead.strand = this;
+        }
+        
+        public function getBeadByType(classOrInterface:Class):IBead
+        {
+            for each (var bead:IBead in _beads)
+            {
+                if (bead is classOrInterface)
+                    return bead;
+            }
+            return null;
+        }
+        
+        public function removeBead(value:IBead):IBead	
+        {
+            var n:int = _beads.length;
+            for (var i:int = 0; i < n; i++)
+            {
+                var bead:IBead = _beads[i];
+                if (bead == value)
+                {
+                    _beads.splice(i, 1);
+                    return bead;
+                }
+            }
+            return null;
+        }
+        
+        public function get info():Object
+        {
+            return {};           
+        }
+        
+        public function addElement(c:Object):void
+        {
+            if (c is IUIBase)
+            {
+                addChild(IUIBase(c).element as DisplayObject);
+                IUIBase(c).addedToParent();
+            }
+            else
+                addChild(c as DisplayObject);
+        }
+        
+        public function addElementAt(c:Object, index:int):void
+        {
+            if (c is IUIBase)
+            {
+                addChildAt(IUIBase(c).element as DisplayObject, index);
+                IUIBase(c).addedToParent();
+            }
+            else
+                addChildAt(c as DisplayObject, index);
+        }
+
+        public function getElementIndex(c:Object):int
+        {
+            if (c is IUIBase)
+                return getChildIndex(IUIBase(c).element as DisplayObject);
+
+            return getChildIndex(c as DisplayObject);
+        }
+        
+        public function removeElement(c:Object):void
+        {
+            if (c is IUIBase)
+            {
+                removeChild(IUIBase(c).element as DisplayObject);
+            }
+            else
+                removeChild(c as DisplayObject);
+        }
+        
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/CSSTextField.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/CSSTextField.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/CSSTextField.as
new file mode 100644
index 0000000..ed1c87b
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/CSSTextField.as
@@ -0,0 +1,59 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import flash.text.TextField;
+	import flash.text.TextFormat;
+	
+	import org.apache.flex.core.ValuesManager;
+		
+	public class CSSTextField extends TextField
+	{
+		public function CSSTextField()
+		{
+			super();
+		}
+		
+		// if used as the display object in a button, parent is null and
+		// the css lookup doesn't work.  This will be used if parent is 
+		// null.
+		public var styleParent:Object;
+		
+		override public function set text(value:String):void
+		{
+			var sp:Object = parent;
+			if (!sp)
+				sp = styleParent;
+			
+			var tf: TextFormat = new TextFormat();
+			tf.font = ValuesManager.valuesImpl.getValue(sp, "fontFamily") as String;
+			tf.size = ValuesManager.valuesImpl.getValue(sp, "fontSize");
+			tf.bold = ValuesManager.valuesImpl.getValue(sp, "fontWeight") == "bold";
+			tf.color = ValuesManager.valuesImpl.getValue(sp, "color");
+			var padding:Object = ValuesManager.valuesImpl.getValue(sp, "padding");
+			if (padding != null)
+			{
+				tf.leftMargin = padding;
+				tf.rightMargin = padding;
+			}
+			defaultTextFormat = tf;
+			super.text = value;
+		}
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IAlertModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IAlertModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IAlertModel.as
new file mode 100644
index 0000000..03707cc
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IAlertModel.as
@@ -0,0 +1,52 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import org.apache.flex.events.IEventDispatcher;
+	
+	public interface IAlertModel extends IEventDispatcher, IBeadModel
+	{
+		function get title():String;
+		function set title(value:String):void;
+		
+		function get htmlTitle():String;
+		function set htmlTitle(value:String):void;
+		
+		function get message():String;
+		function set message(value:String):void;
+		
+		function get htmlMessage():String;
+		function set htmlMessage(value:String):void;
+		
+		function get flags():uint;
+		function set flags(value:uint):void;
+		
+		function get okLabel():String;
+		function set okLabel(value:String):void;
+		
+		function get cancelLabel():String;
+		function set cancelLabel(value:String):void;
+		
+		function get yesLabel():String;
+		function set yesLabel(value:String):void;
+		
+		function get noLabel():String;
+		function set noLabel(value:String):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBead.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBead.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBead.as
new file mode 100644
index 0000000..5367708
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBead.as
@@ -0,0 +1,25 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IBead
+	{
+		function set strand(value:IStrand):void
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadController.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadController.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadController.as
new file mode 100644
index 0000000..fa5a8f8
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadController.as
@@ -0,0 +1,28 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	/** 
+	 *  Marker interface for Controllers
+	 */
+	public interface IBeadController extends IBead
+	{
+		
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadLayout.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadLayout.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadLayout.as
new file mode 100644
index 0000000..662c99c
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadLayout.as
@@ -0,0 +1,28 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	/** 
+	 *  Marker interface for Layouts
+	 */
+	public interface IBeadLayout extends IBead
+	{
+		
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadModel.as
new file mode 100644
index 0000000..b339984
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadModel.as
@@ -0,0 +1,30 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import org.apache.flex.events.IEventDispatcher;
+
+	/** 
+	 *  Marker interface for models
+	 */
+	public interface IBeadModel extends IBead, IEventDispatcher
+	{
+		
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadView.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadView.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadView.as
new file mode 100644
index 0000000..57704b5
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBeadView.as
@@ -0,0 +1,28 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+
+	/** 
+	 *  Marker interface for Views
+	 */
+	public interface IBeadView extends IBead
+	{
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBorderModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBorderModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBorderModel.as
new file mode 100644
index 0000000..334ffd8
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IBorderModel.as
@@ -0,0 +1,27 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+    import flash.geom.Rectangle;
+
+	public interface IBorderModel extends IBead, IBeadModel
+	{
+		function get offsets():Rectangle;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IChrome.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IChrome.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IChrome.as
new file mode 100644
index 0000000..c53a94d
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IChrome.as
@@ -0,0 +1,31 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	/**
+	 * Items that implement IChrome are designating themselves as being attached
+	 * to their parent in a way that's different from normal content. For example,
+	 * to a Container, a child being added that's an IChrome implementor will be
+	 * added outside of the content area.
+	 */
+	public interface IChrome
+	{
+		
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IComboBoxModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IComboBoxModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IComboBoxModel.as
new file mode 100644
index 0000000..f68638b
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IComboBoxModel.as
@@ -0,0 +1,40 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import org.apache.flex.events.IEventDispatcher;
+	
+	public interface IComboBoxModel extends IEventDispatcher, IBeadModel
+	{
+		function get text():String;
+		function set text(value:String):void;
+		
+		function get html():String;
+		function set html(value:String):void;
+		
+		function get dataProvider():Object;
+		function set dataProvider(value:Object):void;
+		
+		function get selectedIndex():int;
+		function set selectedIndex(value:int):void;
+		
+		function get selectedItem():Object;
+		function set selectedItem(value:Object):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IContainer.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IContainer.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IContainer.as
new file mode 100644
index 0000000..630bdbc
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IContainer.as
@@ -0,0 +1,25 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+    public interface IContainer extends IParent
+	{
+		function childrenAdded():void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDataGridModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDataGridModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDataGridModel.as
new file mode 100644
index 0000000..606d938
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDataGridModel.as
@@ -0,0 +1,26 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IDataGridModel extends ISelectionModel
+	{
+		function get labelFields():Object;
+		function set labelFields(value:Object):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDataGridPresentationModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDataGridPresentationModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDataGridPresentationModel.as
new file mode 100644
index 0000000..34a5d84
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDataGridPresentationModel.as
@@ -0,0 +1,31 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import org.apache.flex.events.IEventDispatcher;
+	
+	public interface IDataGridPresentationModel extends IEventDispatcher, IBead
+	{
+		function get columnLabels():Array;
+		function set columnLabels(value:Array):void;
+		
+		function get rowHeight():Number;
+		function set rowHeight(value:Number):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDocument.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDocument.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDocument.as
new file mode 100644
index 0000000..03bdce8
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDocument.as
@@ -0,0 +1,25 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IDocument
+	{
+		function setDocument(document:Object, id:String = null):void
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IFlexInfo.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IFlexInfo.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IFlexInfo.as
new file mode 100644
index 0000000..0bd8357
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IFlexInfo.as
@@ -0,0 +1,29 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+    /**
+     * An object of various properties and values that are not otherwise
+     * linked in by hard class references, like styles, rsls, mixins.
+     */
+	public interface IFlexInfo
+	{
+		function get info():Object
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IImageModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IImageModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IImageModel.as
new file mode 100644
index 0000000..dc924eb
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IImageModel.as
@@ -0,0 +1,28 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import org.apache.flex.events.IEventDispatcher;
+
+	public interface IImageModel extends IEventDispatcher, IBeadModel
+	{
+		function get source():String;
+		function set source(value:String):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRenderer.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRenderer.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRenderer.as
new file mode 100644
index 0000000..5f7f685
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRenderer.as
@@ -0,0 +1,40 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import org.apache.flex.events.IEventDispatcher;
+
+	public interface IItemRenderer extends IEventDispatcher
+	{
+		function get data():Object;
+		function set data(value:Object):void;
+		
+		function get index():int;
+		function set index(value:int):void;
+		
+		function get selected():Boolean;
+		function set selected(value:Boolean):void;
+        
+        function get hovered():Boolean;
+        function set hovered(value:Boolean):void;
+
+        function get down():Boolean;
+        function set down(value:Boolean):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererClassFactory.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererClassFactory.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererClassFactory.as
new file mode 100644
index 0000000..5f8c751
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererClassFactory.as
@@ -0,0 +1,25 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IItemRendererClassFactory extends IBead
+	{
+		function createItemRenderer(parent:IItemRendererParent):IItemRenderer;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererParent.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererParent.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererParent.as
new file mode 100644
index 0000000..0095b2e
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererParent.as
@@ -0,0 +1,29 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import flash.display.DisplayObject;
+	import org.apache.flex.events.IEventDispatcher;
+
+	public interface IItemRendererParent extends IParent, IEventDispatcher
+	{
+		function getItemRendererForIndex(index:int):IItemRenderer;
+		function removeAllElements():void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ILayoutParent.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ILayoutParent.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ILayoutParent.as
new file mode 100644
index 0000000..3604b37
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ILayoutParent.as
@@ -0,0 +1,38 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import flash.display.DisplayObject;
+	import flash.display.DisplayObjectContainer;
+	
+	import org.apache.flex.html.staticControls.supportClasses.Border;
+	import org.apache.flex.html.staticControls.supportClasses.ScrollBar;
+
+	public interface ILayoutParent
+	{
+		function get contentView():DisplayObjectContainer;
+		
+		function get border():Border;
+		
+		function get vScrollBar():ScrollBar;
+		function get hScrollBar():ScrollBar;
+		
+		function get resizableView():DisplayObject;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IMeasurementBead.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IMeasurementBead.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IMeasurementBead.as
new file mode 100644
index 0000000..3e294f4
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IMeasurementBead.as
@@ -0,0 +1,26 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IMeasurementBead extends IBead
+	{
+		function get measuredWidth():Number;
+		function get measuredHeight():Number;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPanelModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPanelModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPanelModel.as
new file mode 100644
index 0000000..24fac27
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPanelModel.as
@@ -0,0 +1,25 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IPanelModel extends IBeadModel, ITitleBarModel
+	{
+
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IParent.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IParent.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IParent.as
new file mode 100755
index 0000000..111c925
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IParent.as
@@ -0,0 +1,28 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+    public interface IParent
+	{
+        function addElement(c:Object):void;
+        function addElementAt(c:Object, index:int):void;
+        function getElementIndex(c:Object):int;
+        function removeElement(c:Object):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUp.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUp.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUp.as
new file mode 100644
index 0000000..4658554
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUp.as
@@ -0,0 +1,25 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+    // marker interface to differentiate popups from other objects
+	public interface IPopUp
+	{
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUpHost.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUpHost.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUpHost.as
new file mode 100755
index 0000000..fc8a89a
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUpHost.as
@@ -0,0 +1,24 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+    public interface IPopUpHost extends IParent
+	{
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRangeModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRangeModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRangeModel.as
new file mode 100644
index 0000000..62e886d
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRangeModel.as
@@ -0,0 +1,38 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IRangeModel extends IBeadModel
+	{
+		function get maximum():Number;
+		function set maximum(value:Number):void;
+		
+		function get minimum():Number;
+		function set minimum(value:Number):void;
+
+		function get snapInterval():Number;
+		function set snapInterval(value:Number):void;
+
+		function get stepSize():Number;
+		function set stepSize(value:Number):void;
+
+		function get value():Number;
+		function set value(value:Number):void;
+}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRollOverModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRollOverModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRollOverModel.as
new file mode 100644
index 0000000..d38aa41
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRollOverModel.as
@@ -0,0 +1,28 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import org.apache.flex.events.IEventDispatcher;
+	
+	public interface IRollOverModel extends IEventDispatcher, IBeadModel
+	{
+		function get rollOverIndex():int;
+		function set rollOverIndex(value:int):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IScrollBarModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IScrollBarModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IScrollBarModel.as
new file mode 100644
index 0000000..2d92999
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IScrollBarModel.as
@@ -0,0 +1,29 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IScrollBarModel extends IRangeModel
+	{
+		function get pageSize():Number;
+		function set pageSize(value:Number):void;
+
+		function get pageStepSize():Number;
+		function set pageStepSize(value:Number):void;
+}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ISelectionModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ISelectionModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ISelectionModel.as
new file mode 100644
index 0000000..cdca279
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ISelectionModel.as
@@ -0,0 +1,34 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import org.apache.flex.events.IEventDispatcher;
+
+	public interface ISelectionModel extends IEventDispatcher, IBeadModel
+	{
+		function get dataProvider():Object;
+		function set dataProvider(value:Object):void;
+		
+		function get selectedIndex():int;
+		function set selectedIndex(value:int):void;
+		
+		function get selectedItem():Object;
+		function set selectedItem(value:Object):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStatesImpl.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStatesImpl.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStatesImpl.as
new file mode 100644
index 0000000..152fe8f
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStatesImpl.as
@@ -0,0 +1,26 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	import org.apache.flex.events.IEventDispatcher;
+
+	public interface IStatesImpl extends IEventDispatcher, IBead
+	{
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStrand.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStrand.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStrand.as
new file mode 100644
index 0000000..8e742e2
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStrand.as
@@ -0,0 +1,27 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IStrand
+	{
+		function addBead(bead:IBead):void;
+		function getBeadByType(classOrInterface:Class):IBead;
+		function removeBead(bead:IBead):IBead;		
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITextModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITextModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITextModel.as
new file mode 100644
index 0000000..478e374
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITextModel.as
@@ -0,0 +1,29 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface ITextModel extends IBeadModel
+	{
+		function get text():String;
+		function set text(value:String):void;
+		
+		function get html():String;
+		function set html(value:String):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITitleBarModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITitleBarModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITitleBarModel.as
new file mode 100644
index 0000000..0f421a1
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITitleBarModel.as
@@ -0,0 +1,32 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface ITitleBarModel extends IBeadModel
+	{
+		function get title():String;
+		function set title(value:String):void;
+		
+		function get htmlTitle():String;
+		function set htmlTitle(value:String):void;
+		
+		function get showCloseButton():Boolean;
+		function set showCloseButton(value:Boolean):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IToggleButtonModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IToggleButtonModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IToggleButtonModel.as
new file mode 100644
index 0000000..560d40c
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IToggleButtonModel.as
@@ -0,0 +1,32 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IToggleButtonModel extends IBeadModel
+	{
+		function get text():String;
+		function set text(value:String):void;
+		
+		function get html():String;
+		function set html(value:String):void;
+		
+		function get selected():Boolean;
+		function set selected(value:Boolean):void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IUIBase.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IUIBase.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IUIBase.as
new file mode 100644
index 0000000..6b36a71
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IUIBase.as
@@ -0,0 +1,27 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IUIBase extends IStrand
+	{
+        function get element():Object;
+        
+		function addedToParent():void;
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/66246d8a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValueToggleButtonModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValueToggleButtonModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValueToggleButtonModel.as
new file mode 100644
index 0000000..c2d6401
--- /dev/null
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValueToggleButtonModel.as
@@ -0,0 +1,32 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+	public interface IValueToggleButtonModel extends IToggleButtonModel
+	{
+		function get value():Object;
+		function set value(newValue:Object):void;
+		
+		function get groupName():String;
+		function set groupName(value:String):void;
+		
+		function get selectedValue():Object;
+		function set selectedValue(newValue:Object):void;
+	}
+}
\ No newline at end of file