Re: j2s-development] Dynamic Loading of JavaScript files
Brought to you by:
zhourenjian
|
From: Soheil H. Y. <soh...@gm...> - 2006-06-17 03:49:19
|
I did not mean to use a method like the one used in dojo. I was just
arguing about the idea.
Implementing a method for import a Class( import java.util.* -->
j2s_import("java.util.*")), and an implementation for Class.forName(),
is really enough for dynamic loading of java2script. May be
implementing java.reflect.* would be better.
I think using a method like this, will provide us a dynamic loading
method with the developer transparency preserved.
Regards,
Soheil
On 6/15/06, Josson Smith <jo...@sj...> wrote:
> Dynamic loading *.js will be complex things.
>
> And I know that dojo toolkit is using its dynamic loading mechanism of
> JavaScript files.
>
> For Java2Script,
> First, the number of *.js files is somewhat huge already. It is more
> than 200. Setup the connections will require a lot of extra times.
> Second, referencing, sub-referencing, and sub-sub-referencing, ... may
> reference most of the classes. It requires some algorithm to cut off
> those unnecessary sub-referencing until it's necessary.
> Third, Java programmers should not be required to know things about
> dynamic loading of JavaScript.
>
> More discussions are needed.
>
>
> Soheil Hassas Yeganeh wrote:
> > Oh, a very nice doco! I found here :
> > http://ajaxpatterns.org/On-Demand_Javascript
> >
> > On 6/12/06, Soheil Hassas Yeganeh <soh...@gm...> wrote:
> >
> >> Hi,
> >> I've a proposal for loading javascript files, dynamically. Suppose we
> >> have a lot of javascript files generated. As it occures in many
> >> applications many of the javascript files are not used frequently.
> >> So, Now, if we want to run that application we have to import a lot of
> >> js files in the html. This will make the application very slow and
> >> heavy.
> >> So, we need a dynamic javascript loading mechanism. If we have this
> >> mechanism, we can also implement methods like Class.forName().
> >> We can use .z files generated by j2s to dynamically loading need
> >> javascript files for each class.
> >> In other words, we need something like the Bindows' BiScriptLoader.
> >> Regards,
> >> Soheil Hassas Yeganeh
> >>
> >>
> >
> >
> > _______________________________________________
> > j2s-development mailing list
> > j2s...@li...
> > https://lists.sourceforge.net/lists/listinfo/j2s-development
> >
> >
> >
>
>
> --
> Regards
>
> /js
>
>
>
>
> _______________________________________________
> j2s-development mailing list
> j2s...@li...
> https://lists.sourceforge.net/lists/listinfo/j2s-development
>
|