      * @throws org.yellcorp.lib.display.inject.DisplayMetadataError
      *         If a metadata parameter is invalid.
      */
-    public static function inject(container:DisplayObjectContainer, target:*):void
-    {
+    public static function inject(container:DisplayObjectContainer, target:*, domain:ApplicationDomain = null):void
+    {
+        if (!domain)
+        {
+            domain = ApplicationDomain.currentDomain;
+        }
+
         var type:XML = describeType(target);
 
         var displayMetadata:XMLList = type.*.(

    }


    private static function construct(adapter:String, displayObject:*):*
    {
        var clazz:Object = getDefinitionByName(adapter);
        return new clazz(displayObject);
    }
}


            if (args.adapter !== null)
            {
                child = construct(args.adapter, child, domain);
            }

            target[property.@name] = child;
