Gaurav,

Sorry to disappoint.  I'm not sure how or why you would port that to
GWT.  Maybe someone else on the list can be of more help to you.

Walden

On Aug 27, 12:15 am, masterGaurav <[EMAIL PROTECTED]> wrote:
> Hi Walden,
>
> Thanks for your response.
>
> I am working on DWT - the GWT port of Dojo Toolkit.
> In Dojo Toolkit, we support widgets based on templates. In templates,
> each node (element) can be referred to by an member variable (instance
> variable) through what is referred to as dojoAttachPoint.
>
> For example, my "Label" widget may have a template as follows:
>
> <span dojoAttachPoint='domNode'><a dojoAttachPoint='anchorNode'></a></
> span>
>
> Once the template-parser parses the templates, it creates two
> variables - domNode and anchorNode - referring to the corresponding
> element-nodes. Now, in the object (read: class) backing the template,
> I can directly refer to these elements by saying, this.anchorNode.
>
> What I am trying to do is providing a support for the same.
>
> One idea that comes to my mind is to create a "HashMap<String,
> Element> attachPoints" and populate the same.
>
> A simple demo at
>  http://eduzine.edujini-labs.com/archives/33-Creating-Custom-Widget-in...
> may give you an idea of what dojoAttachPoint does.
>
> Looking forward to your suggestions!
>
> --
> Happy Hacking,
> Gauravhttp://sf.net/projects/dwthttp://eduzine.edujini-labs.comhttp://blogs.mastergaurav.com
> ------------------------------
>
> On Aug 25, 6:15 pm, walden <[EMAIL PROTECTED]> wrote:
>
>
>
> > Gaurav,
>
> > I think you're trying to do something that GWT does not support, as
> > GWT builds a lot of its value atop the notion of a statically-typed
> > language (Java).
>
> > About your use case: it's not one.  If you would write a use case with
> > a real actor, I'll bet we could find a statically-typed design that
> > would satisfy it.
>
> > Walden
>
> > On Aug 24, 3:11 am,masterGaurav<[EMAIL PROTECTED]> wrote:
>
> > > Hi,
>
> > > I have a scenario wherein I need to refer to methods/fields in the
> > > class that may be created on the fly - similar to how it is possible
> > > in JavaScript.
>
> > > Or, how do I refer to any field/function if I know the object-context
> > > and the property-name at runtime?
>
> > > Would it be mandatory to make the type inherited from
> > > JavaScriptObject? If that's the case, I lose "public constructor" and
> > > non-final methods. :(
>
> > > What's the best way around?
>
> > > The use-case is:
>
> > > I need to load some entries from configuration settings and then
> > > populate the object. The entries may include setting values to
> > > properties. The values may be simple numeric/string/boolean or
> > > reference to functions (function names), and then I need to refer to
> > > those properties/functions dynamically.
>
> > > Thanks in Advance!
>
> > > --
> > > Cheers,
> > > Gaurav Vaishhttp://www.edujini-labs.comhttp://www.mastergaurav.com
> > > ---------------------------------- Hide quoted text -
>
> - Show quoted text -
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to