-include-libraries will force entire SWCs to be linked in.  (And Beta 3
will have -include, which will do it for individual definitions.)

A better path might be to dynamically load another SWF that contains the
definitions that you want to have "soft" references to.

-rg 

> -----Original Message-----
> From: flexcoders@yahoogroups.com 
> [mailto:[EMAIL PROTECTED] On Behalf Of Vadim Melnik
> Sent: Thursday, March 23, 2006 4:49 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Flex 2.0 b2: 'getClassByName' 
> method of the 'flash.util' package
> 
> Is there some special mxmlc option to prevent optimization, and 
> force compiler to include all classes from classpath or at least 
> imported ones (like "import MyClass;") ? I saw "-compiler.keep-all-
> type-selectors" option, described as "disables the pruning of unused 
> type selectors (advanced)", but don't clearly understand it effect.
> 
> --
> Thanks,
> Vadim Melnik.
> 
> --- In flexcoders@yahoogroups.com, "Peter Farland" <[EMAIL PROTECTED]> 
> wrote:
> >
> > No, you must have a refernence to MyClass somewhere in your code in
> > order for it to be linked in to the SWF at compile time. A string
> > 'myPackage.MyClass' does not constitute a reference. This is not a 
> bug -
> > the compiler must optimize what classes are actually needed to 
> keep the
> > SWF size down.
> >  
> > 
> > -----Original Message-----
> > From: flexcoders@yahoogroups.com 
> [mailto:[EMAIL PROTECTED] On
> > Behalf Of tyombria
> > Sent: Wednesday, March 22, 2006 4:44 AM
> > To: flexcoders@yahoogroups.com
> > Subject: [flexcoders] Flex 2.0 b2: 'getClassByName' method of the
> > 'flash.util' package
> > 
> > Hi, all.
> > 
> > Method 'getClassByName' works correctly only with adobe classes.
> > For example, getClassByName('flash.net.URLLoader') works fine.
> > 
> > I've got a problem with my custom classes.
> > For example:
> > var myClassReference:MyClass = getClassByName('myPackage.MyClass');
> > I get error:
> > Error #1065: Variable MyClass is not defined.
> > 
> > Class exists in classpath or in the library.
> > 
> > If i put somewhere inside declaration block: var myClass:MyClass It
> > (getClassByName) works fine.
> > 
> > Is it a bug?
> > 
> > 
> > 
> > 
> > 
> > --
> > Flexcoders Mailing List
> > FAQ: 
> http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Search Archives:
> > http://www.mail-archive.com/flexcoders%40yahoogroups.com
> > Yahoo! Groups Links
> >
> 
> 
> 
> 
> 
> 
> --
> Flexcoders Mailing List
> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives: 
> http://www.mail-archive.com/flexcoders%40yahoogroups.com 
> Yahoo! Groups Links
> 
> 
> 
>  
> 
> 
> 


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to