<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Had the same thought. It's @Inject, so I thought @Bind would be more consistent on the data field….but I am fine either way…let's vote :)<div><br><div><div>On 2012-08-13, at 11:26 AM, "Lincoln Baxter, III" <<a href="mailto:lincolnbaxter@gmail.com">lincolnbaxter@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">Should it be @Bind or @Bound?<br><br><div class="gmail_quote">On Mon, Aug 13, 2012 at 10:52 AM, Christian Sadilek <span dir="ltr"><<a href="mailto:christian.sadilek@gmail.com" target="_blank">christian.sadilek@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">just forwarding Lincoln's reply. If there are no objections to @Bind<br>
and @AutoBound, I will go ahead and implement this later today or<br>
tomorrow.<br>
<br>
cheers,<br>
christian<br>
<div class="HOEnZb"><div class="h5"><br>
---------- Forwarded message ----------<br>
From: Lincoln Baxter, III <<a href="mailto:lincolnbaxter@gmail.com">lincolnbaxter@gmail.com</a>><br>
Date: Mon, Aug 13, 2012 at 12:05 AM<br>
Subject: Re: [errai-dev] Errai UI and DataBinding<br>
To: Christian Sadilek <<a href="mailto:christian.sadilek@gmail.com">christian.sadilek@gmail.com</a>><br>
<br>
<br>
I do think we need programmatic control over bindings. I think that<br>
was one of my first questions when we implemented the @Injected<br>
databinder. I agree with you that the current state is a bit too<br>
"magical," and I think that the suggestions you've brough up will help<br>
to eliminate that.<br>
<br>
+1 to individual @Bind and also aggregate @Autobind / @Autobound annotation<br>
<br>
~Lincoln<br>
<br>
On Sun, Aug 12, 2012 at 7:53 PM, Christian Sadilek<br>
<<a href="mailto:christian.sadilek@gmail.com">christian.sadilek@gmail.com</a>> wrote:<br>
><br>
> Hi,<br>
><br>
> I'd like to propose a change to our DataBinding integration in Errai<br>
> UI. Basically, I think we should retire the implicit binding approach<br>
> and introduce a new annotation. So, within a @Templated class that has<br>
> a DataBinder<T> field, we should have the following options:<br>
><br>
> 1. No binding<br>
> @Inject @DataField<br>
> private TextBox date;<br>
><br>
> 2. Binding to model property with matching name<br>
> @Inject @Bind @DataField<br>
> private TextBox date;<br>
><br>
> 3. Binding to model property with matching name using provided converter<br>
> @Inject @Bind(converter=MyDataConverter.class) @DataField<br>
> private TextBox date;<br>
><br>
> 4. Binding to model property with provided name<br>
> @Inject @Bind(property="lastUpdated") @DataField<br>
> private TextBox date;<br>
><br>
> 5. Binding to model property with provided name using provided converter<br>
> @Inject @Bind(property="lastUpdated", converter=MyDataConverter.class)<br>
> @DataField<br>
> private TextBox date;<br>
><br>
> Additionally, we could add an annotation (e.g. @AutoBind) that when<br>
> present on the @Templated class causes our current behaviour. All<br>
> @DataFields will be bound to model properties with matching names.<br>
><br>
> I prefer this approach because just by looking at the code I get all<br>
> the information I need to undersand what's going on. Our current<br>
> approach seems a little too magical :).<br>
><br>
> WDYT?<br>
><br>
> Cheers,<br>
> Christian<br>
> _______________________________________________<br>
> errai-dev mailing list<br>
> <a href="mailto:errai-dev@lists.jboss.org">errai-dev@lists.jboss.org</a><br>
> <a href="https://lists.jboss.org/mailman/listinfo/errai-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/errai-dev</a><br>
<br>
<br>
<br>
<br>
--<br>
Lincoln Baxter, III<br>
<a href="http://ocpsoft.org/" target="_blank">http://ocpsoft.org</a><br>
"Simpler is better."<br>
_______________________________________________<br>
errai-dev mailing list<br>
<a href="mailto:errai-dev@lists.jboss.org">errai-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/errai-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/errai-dev</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Lincoln Baxter, III<br><a href="http://ocpsoft.org/" target="_blank">http://ocpsoft.org</a><br>"Simpler is better."<br>
_______________________________________________<br>errai-dev mailing list<br><a href="mailto:errai-dev@lists.jboss.org">errai-dev@lists.jboss.org</a><br>https://lists.jboss.org/mailman/listinfo/errai-dev<br></blockquote></div><br></div></body></html>