Futurescale, Inc. PureMVC Home

The PureMVC Framework Code at the Speed of Thought


Over 10 years of community discussion and knowledge are maintained here as a read-only archive.

New discussions should be taken up in issues on the appropriate projects at https://github.com/PureMVC

Pages: [1]
Print
Author Topic: How much does PureMVC add to SWF filesize  (Read 9450 times)
immerzeel
Courseware Beta
Jr. Member
***
Posts: 14


View Profile Email
« on: November 06, 2008, 04:41:06 »

I want to use the framework to make some templates for banners we often have to produce. Banner development is very limiting in filesize (40-50 Kb Sales, 100-1000 Kb Rich-Media).

How much does the framework add to the SWF filesize?

Cheers,

Pascal
Logged
puremvc
Global Moderator
Hero Member
*****
Posts: 2871



View Profile WWW Email
« Reply #1 on: November 06, 2008, 04:47:30 »

About 12k.
-=Cliff>
Logged
marek
Jr. Member
**
Posts: 14



View Profile WWW Email
« Reply #2 on: November 07, 2008, 08:11:29 »

was 21kb for me however I put some extra functionality. to be honest have a problem to understand how compilator manages internal imports. Curious that larger number of internal imports makes app size much bigger or not really. From my experience I just learn to use:

:
import package.subpackage.classA
import package.subpackage.classB
import package.subpackage.classC

instead of

:
import package.subpackage.*
check your code once you done and compare. For me it saves some kb every time I do clear my code.
Logged
immerzeel
Courseware Beta
Jr. Member
***
Posts: 14


View Profile Email
« Reply #3 on: November 08, 2008, 08:13:32 »

I will try to squeeze it in. PureMVC and TweenLite (& TweenGroup) are essential to me, so that is a 16 Kb footprint...

I can live with that.

Thanks guys!
Logged
puremvc
Global Moderator
Hero Member
*****
Posts: 2871



View Profile WWW Email
« Reply #4 on: November 08, 2008, 09:27:39 »

I was just going from memory of seeing it on the filesystem the other day.

The actual sizes for the current Standard and MultiCore versions are:

PureMVC_AS3_2_0_4.swc is 11.4kb
PureMVC_AS3_MultiCore_1_0_5.swc is 11.9kb

Also, doing import com.blah.* rather than com.blah.Class1 doesn't increase file size with any set of mxmlc compilation args that I know. However, explicitly naming the classes rather than globbing is still a good practice that should be advocated. It is a helpful guide to a classes collaborators for someone coming upon the class for the first time.

But if the imports aren't kept up to date when people maintain code, then the value of the import list for familiarizing yourself with a class is greatly diminished if not useless.

So, a practice that should become ingrained in the motor-memory of every developer's fingers is the 'Organize Imports' (Ctrl-Shift-O) command in Flex Builder (or whatever analog your favorite IDE has). This command causes all unused imports to be removed and it sorts them. My hands had learned this in Eclipse years ago when I did Java work. Then it was forgotten during what I think of as the 'Dark Time' when Flex Builder was built on Dreamweaver. Now it's back again, so use it folks!

-=Cliff>
Logged
marek
Jr. Member
**
Posts: 14



View Profile WWW Email
« Reply #5 on: November 10, 2008, 03:02:25 »

Thanks Cliff. Didn't know that. cool feature indeed.
Cheers for info.
Logged
Pages: [1]
Print