Rocky; When you use ui:prototype, you define a custom element than can then be inserted into any ui:instanceView or ui:prototype.

Take a look at the following and see if this helps any:
  http://www.topquadrant.com/technology/sparql-web-pages-swp/swp-in-topbraid/

particularly part 2.

-- Scott

On 3/5/2014, 10:00 AM, Wiethorn, Robert wrote:

Hello, I’m wanting to override the presentation of a Subclass’s content (via ui:instance) by passing an object/uri/variable from its Parent Class, and return some content back to the Parent Class.

I don’t know enough about the methods and functions I can use to accomplish this.

 

Discussion:

I have a WebApp.

On my main Class (ParentClass), I’m creating my HTML, and iterating through the SPARQL results and building a table to display the Results.

I’m using a ui:ForEach to manage the flow.

 

?this is the Parent Object

? this has Subclasses : ?Attribute(s)

 

 

For each ?attribute, call its class definition, and build the presentation.

 

Question: From a parent Class, how do I call a particular ui:instance on a subclass, pass it an Object/URI/string value. Process the content, and return some content?

 

Example: Parent Class:

            <ui:forEach ui:resultSet="{#

                    SELECT ?attribute

                    WHERE {

                        ?this smart:hasAttribute ?attribute .

                        ?attribute smart:name ?attributeName .

                        ?attribute smart:displayName ?attributeDisaplayName .

                       

                    } }">

                <tr>

                    <td> Call the SubClass  and Return Formatted HTML </td>

                </tr>

            </ui:forEach>

 

Example SubClass ui:instanceView

<div>

<table name=”subclass Details”>

        <tr>

            <td>Attribute Name</td>

<td></td>

            <td>Values</td>

        </tr>

        <ui:forEach ui:resultSet="{#

                SELECT ?attributeDisplayName ?attributeName

                WHERE {

                    ? attribute smart:displayName ?attributeDisplayName .

                    ? attribute smart:name ?attributeName .

                } }">

            <tr>

                <td>{= ?attributeName }</td>

            <td> : </td>

                <td>{= ?attributeDisplayName }</td>

            </tr>

        </ui:forEach>

    </table>

</div>

 

Thanks,

Rocky

 

--
-- 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 Insight, SPARQLMotion, SPARQL Web Pages 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
---
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

--
-- 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 Insight, SPARQLMotion, SPARQL Web Pages 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
---
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to