W3C Forms teleconference May 26, 2010

* Present

John Boyer, IBM
Leigh Klotz, Xerox
Nick van den Bleeken, Inventive Designers
Philip Fennell, MarkLogic
Steven Pemberton, CWI/W3C
Charlie Wiecha, IBM
Erik Bruchez, Orbeon

* Agenda

http://lists.w3.org/Archives/Public/public-forms/2010May/0021.html http://lists.w3.org/Archives/Public/public-forms/2010May/0023.html http://lists.w3.org/Archives/Public/public-forms/2010May/0024.html

* Rechartering

http://lists.w3.org/Archives/Public/public-forms/2010May/0018.html

Steven Pemberton: Alain Couthuries has been invited and as an expert and should be here next week.
Steven Pemberton: I've contacted. Cordis, Jadu, and EMC. Anyone know anyone at Alfresco, Alfresco, or Atlassian, Ample SDK? Joern Turner?
Leigh Klotz: I'll contact Joern.
Steven Pemberton: Kurt Cagle and Dan McCreary?
John Boyer: Yes, I'll contact them.
Steven Pemberton: Now HP and Adobe said they would be joining.
Charlie Wiecha: I will contact Scott at HP.
Leigh Klotz: Larry at Adobe.
Steven Pemberton: I will contact Larry. Anyone else?
Charlie Wiecha: And Yahoo.
Steven Pemberton: I will contact Adobe.
Charlie Wiecha: And ask Raman.

Steven Pemberton: Now is the ideal time to ask new members to join.

* Action Items

http://lists.w3.org/Archives/Public/public-forms/2010Mar/0017.html

Nick van: No new list yet.

* Problem with multiple pages switch/case

http://lists.w3.org/Archives/Public/www-forms/2010Apr/0005.html http://lists.w3.org/Archives/Public/www-forms/2010May/0019.html Anyone speak French?

Leigh Klotz: I'll look at it.

* proposal for new submission replace mode new

http://lists.w3.org/Archives/Public/www-forms/2010May/0018.html

Leigh Klotz: I wonder why he didn't ask for show=new on submission.
John Boyer: This is already in the backlog.
Leigh Klotz: xsltforms has show=new. Or do we want a bigger re-design.
John Boyer: Then you need replace=none.
Nick van: I'm not sure if you want to tackle the replace frames problem or replace div problem.
John Boyer: That's how we got targetref so we could use target for iframes.
Leigh Klotz: xframes
John Boyer: It is in xforms 1.2 features.
Leigh Klotz: Is there more guidance for implementation experimentation?
John Boyer: http://www.w3.org/MarkUp/Forms/wiki/Submission_Embedding
Leigh Klotz: So we can ask Joern to help design it if he joins the WG.
Erik Bruchez: Is the request the same as the target attribute?
John Boyer: The previous link has Leigh writing up target=new.
Erik Bruchez: I was a proponent of target because HTML uses it. We should do it the same way. We have xf:load which doesn't allow specifying the target window frame, but that's wrong too.
Leigh Klotz: Maybe the HTML integration could add that.
Erik Bruchez: You could go either way; just say you don't mandate what target means.
Leigh Klotz: Language about frames would go in the integration.
Leigh Klotz: So the feature is just @target. Do you say @replace?
Erik Bruchez: We do replace=all and target=id in our implementation.
Nick van: You could show the XML.
Erik Bruchez: replace=all returns whatever the submission returns.
Steven Pemberton: But you have to bounce it off a server.
Erik Bruchez: If you want to show the instance, your service returns the xml.
Steven Pemberton: Then you have to have a server.
Erik Bruchez: It's not a different replace, it's replace none.
John Boyer: target=instance retrofitted. targetref is the ref in the instance.
Erik Bruchez: target should have meaning for replace=all only.
Leigh Klotz: Erik, you already have this implemented. Do you have text we can use?
Nick van: http://wiki.orbeon.com/forms/doc/developer-guide/xforms-advanced-submissions#TOC-Specifying-an-HTML-target-window-or
Erik Bruchez: We say it only makes sense for replace=all.
John Boyer: How do you indicate a new window? new or _new?
Erik Bruchez: _blank as in HTML4. It's not beautiful but you have predefined values, _blank, _self, _parent, _top, or a named window.
Leigh Klotz: Yes, those are features of the host language.
Steven Pemberton: A named window is created or replaced.
Leigh Klotz: So the answer to Joern is to use target.
John Boyer: We can give him the link to the Submission Embedding wiki page.
Leigh Klotz: Let's put in a link to Erik's documentation under a heading "Current Implementations."
John Boyer: And HTML4.
Leigh Klotz: HTML4 defines some of the values, but any host language could do that.
Steven Pemberton: Who will answer.
Leigh Klotz: John if he wants to or me.

Action 2010-05-26.1: Leigh Klotz to respond to http://lists.w3.org/Archives/Public/www-forms/2010May/0018.html

* @iterate

http://lists.w3.org/Archives/Public/public-forms/2010May/0005.html

John Boyer: This is different from @while. It's evaluated at a moment in time, and no further activity happens with the result of the while attribute expression. By compression @iterate picks up a nodeset and the nodeset is updated and maintained throughout the lifetime of the looping process. If the iteration process does irritating things to the nodeset, you have to deal with the consequences.
Steven Pemberton: Is this done only on actions.
Erik Bruchez: Yes. This came from exforms. We took @if and @while but not @iterate. @while leads to complicated code. @iterate is more natural in some cases, and is compatible with iteration in XSLT 2.0 / XPath 2.0 ("for"). Here it's different because we run actions. The idea is to put this on actions and have a block of actions. You could put it on setvalue, iterate.
Leigh Klotz: It seems like this would be useful for adding a boolean attribute to a series of repeated items, a common use case.
John Boyer: ...
Erik Bruchez: If you write <setvalue ref=.' iterate=nodeset > then the ref adjusts to being the current node of the iteration.
John Boyer: And @iterate is evaluted after @context?
Erik Bruchez: I think that's how we implemented it.
John Boyer: What happens if you do a synchronous send that replaces the iteration nodeset?
Erik Bruchez: I think you hang onto the nodes; though we could specify something different, for example checking the node presence.
Steven Pemberton: What happens if it isn't present?
Leigh Klotz: You currently make a copy at start time?
Erik Bruchez: It's a sequence. The nodes can be detached as in any DOM. You can detach an ancestor, as in an instance replace. If the @context points to a node, and within the action block and you delete that node or an ancestor (or as John said a submission) you could have something similar. So we already have that problem with @context, and context in general. It may be slightly easier to achieve, but it's possible.
John Boyer: It's not hard but we need to specify; does @iterate run once and snapshot?
Nick van: I think it should be in sync with what @context does and I don't think it's well specified now. Does @context copy? What happens if you modify something in a descendent action.
John Boyer: In my implementation, the action stops running.
Erik Bruchez: By disappear you mean when the instance is replaced, for example?
John Boyer: Yes. Any following actions after a deletion that don't use the context will run, but if they require it, they don't run.
Nick van: What action doesn't use the context.
John Boyer: setfocus.
Erik Bruchez: Here is an example:


<action context=".">
     <delete modeset=".."/>
     <setvalue ref=".">foo</setvalue>
 </action>

Nick van: If you kept the node instead, then you would have it and it would be detached.
Erik Bruchez: It's a bit of a grey zone. XPath 1.1 doesn't say anything. 2.0 doesn't require a document.
John Boyer: XPath 1.0 requires a context node.
Erik Bruchez: It does require a context node, but it doesn't have to be a document.
John Boyer: It's fixed in XPath 2.0, but not 1.0.
Erik Bruchez: So for example, we can still evaluate expressions if nodes aren't in a document (detached). I don't know exactly what happens if you ask for the root of a tree using the XPath 2.0 function. But the bottom line is that you don't need to stop executing actions if nodes are detached, at least in our implementation.
Leigh Klotz: So it's fairly well defined in XPath 2 and not in XPath 1.
John Boyer: It's fairly clear in XPath 1 that it's not a valid data model.
Leigh Klotz: I guess you could get back at the detached nodes and insert them from within the action.
Nick van: We have XPath 1 functions that return nodes from other instance documents. What's the difference?
John Boyer: Every node is in some valid XPath 1.0 data model. I'm trying real hard to change that but...
Nick van: Why isn't it a valid data model in the event case?
John Boyer: We create a new data model on the fly.
Nick van: It begins with a node. Must it be a document?
John Boyer: If you follow ancestors you will eventually reach a root node. It's a grey area. We can make XPath 1.0 do pretty much anything we want as long as it's implementable.
Leigh Klotz: Can't we just make a new one of whatever event makes when you get a detached node?
Nick van: That's what I was thinking.
John Boyer: Sounds good; we could say it generally for loss of context.
Leigh Klotz: XPath 2.0 would just work without that, right?
John Boyer: If you delete a node from a repeat nodeset we want the user interface controls to go away. Deletion has meant that it goes away and nobody holds on to references. We have to define where we hold on to references. Right now we have a simpler processing model.
Nick van: One possibility is that if you delete a node it stops running.
Leigh Klotz: That's what John has implemented.
John Boyer: And correspondingly if you insert nodes into what would match the nodeset, the nodeset is evaluated once and not added.
Erik Bruchez: That's much easier. It would be confusing if it went from 3 to 10 elements.
John Boyer: We agree then to handle delete differently than inserts; it's fine with me, but it's just one way to do it.
Erik Bruchez: It's not just deciding whether one iteration happens or not. In the example I sent, right after the delete, you have an action that uses context, you have to check what happens to the context node. If you have variables in actions, the context is not the only thing that can be impacted by deletion. You have to check the variables. That might be tough.
John Boyer: How do you know when to let go of it?
Nick van: Garbage collection.
John Boyer: We have a declarative language.
Steven Pemberton: Is that different in terms of garbage collection?
John Boyer: You have to know when to stop referring to something. In the repeat case, when you delete the node, does the node hang around because the repeat uses it?
Steven Pemberton: In an action, the action is alive only when it's being executed.
Leigh Klotz: The repeat never dies, so does it hold onto everything it's ever seen.
Erik Bruchez: If you remove one node, the repeat still points to the iteration object. We use the XForms algorithm.
John Boyer: How long to variables live?
Erik Bruchez: In an action or outside?
John Boyer: I don't know, but if a variable holds onto a deleted node, then it's forever.
Erik Bruchez: No, variables have a lifecycle, so you specify when it is evaluated. In an action, it's done when encountered. In an action block, it's only available lexically. If it's in a control, it's evaluated during refresh. So it's the same as a control pointed to a deleted node. So there aren't objects that live forever and point to nodes that have disappeared.

Steven Pemberton: Let's come to a conclusion for this week. John, do you still have troubles?
John Boyer: We have to define what @iterate does.
Steven Pemberton: Are we agreed that the use case is convincing enough?
John Boyer: Yes, absolutely.
Steven Pemberton: It looks like a useful addition with more work to be done.

Philip Fennell: I won't be here next week.

* IRC Minutes

http://www.w3.org/2010/05/26-forms-minutes.html

* Meeting Ends