Hi Guil,

getting back to this old thread just to let you know that we have integrated 
SPARQLMotion into SWP so that the syntax below is working in 3.6.0 final. In a 
nutshell, SPARQLMotion scripts can now be written either stand-alone with the 
graphical notation, or embedded into SWP pages. SWP can then also be used for 
the control logic such as ui:if, ui:forEach etc. I believe this creates a very 
powerful combination that will open us SWP for many new use cases. It also 
means that writing SM modules remains a good investments, as the code will be 
more easily reusable within web applications.

Regards
Holger


On Feb 16, 2012, at 5:32 PM, Holger Knublauch wrote:

> 
> On Feb 15, 2012, at 9:33 PM, Guilherme Scomparim wrote:
> The approach that I am trying to get to is to increase the flexibility so 
> that SWP itself can be the control structure, e.g. using ui:if to branch into 
> "behavior". For this reason I believe something like the following should 
> work:
> 
> <ui:if ui:condition="{= bound(?fileName) }">
>    <sml:ImportTextFile sm:outputVariable="text" sml:sourceFileName="{= 
> ?fileName }">
>        <div>Here is your file: <textarea>{= ?text }</textarea></div>
>    </sml:ImportTextFile>
> </ui:if>
> 
> If the SML modules were instances of ui:Element then they could be used just 
> like that, because they follow the same syntax. I would need to implement a 
> wrapper that can invoke the corresponding SM code when such an element is 
> used. The children of such sml: nodes would see all the new variable bindings 
> as would have the output RDF graph as SWP context graph.
> 
> 
>> I am going to explain a bit of what I am trying to do, and you can
>> even point me to another direction if what I am doing is not correct.
>> 
>> Now, I am designing a portal application that is all based in SWP,
>> using HTML5 and Javascript. Really looking forward to use SVG when
>> inline becomes available.
>> 
>> The reason I am using SWP is because  my entire logic is dynamically
>> captured in my executable models and I really need to have access to
>> resources like SPIN Functions, Templates, Magic Variables and SM to
>> run inferences
> 
> Would be
> 
> <ui:setContext ui:queryGraph="...">
>    <sml:ApplyTopSPIN>
>        <div>Now the inferences are visible, we are in queryGraph + 
> inferences</div>
>    </sml:ApplyTopSPIN>
> </ui:setContext>
> 
> 
>> because the entire sequence of pages, the content of
>> pages  and events are going to be dynamically created using SPARQL
>> Queries { } based in state changes. I am also not an experienced Java
>> programmer to build an application using APIs, so I am keen t wait for
>> its full development.
>> 
>> This application has some similarities of what TQ have developed in
>> Flex for ensemble, where I defined HTML  components like Forms,
>> Fields, Buttons, Menus, Events, Session, LoginForm etc . The meta-data
>> views instances are then stored in each separated executable models by
>> domain that import the components in the .ui model.

-- 
You received this message because you are subscribed to the Google
Group "TopBraid Suite Users", the topics of which include Enterprise Vocabulary 
Network (EVN), TopBraid Composer,
TopBraid Live, TopBraid Ensemble, SPARQLMotion and SPIN.
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/topbraid-users?hl=en

Reply via email to