Touch put remove
Submitted by admin on Mon, 2009-09-07 16:30
TagEventTypes: TOUCH, PUT, REMOVE
This Specification example shows the XML to show the user a different message depending on the TagEventType
<?xml version="1.0" encoding="UTF-8"?>
<specification xmlns="http://www.touchatag.com/schema/configurator/specification-1.0">
<application eventModel="PUT_TOUCH_REMOVE">
<command id="default" name="Show balloon message"/>
</application>
<blueprint>
<superblock id="urn:example:touch-put-remove">
<breakdown>
<block id="ts-touchKey" ref="urn:touchatag:block:text-source">
<property name="Value">
<text>TOUCH</text>
</property>
</block>
<block id="ts-putKey" ref="urn:touchatag:block:text-source">
<property name="Value">
<text>PUT</text>
</property>
</block>
<block id="ts-removeKey" ref="urn:touchatag:block:text-source">
<property name="Value">
<text>REMOVE</text>
</property>
</block>
<block id="ts-touchValue" ref="urn:touchatag:block:text-source">
<property name="Value">
<text>a tag has TOUCHed the reader</text>
</property>
</block>
<block id="ts-putValue" ref="urn:touchatag:block:text-source">
<property name="Value">
<text>a tag has been PUT on the reader</text>
</property>
</block>
<block id="ts-removeValue" ref="urn:touchatag:block:text-source">
<property name="Value">
<text>a tag has been REMOVEd from the reader</text>
</property>
</block>
<block id="empty-text2text" ref="urn:touchatag:block:empty-text2text"/>
<block id="add-touch" ref="urn:touchatag:block:add-text2text"/>
<block id="add-put" ref="urn:touchatag:block:add-text2text"/>
<block id="add-remove" ref="urn:touchatag:block:add-text2text"/>
<block id="tag-event" ref="urn:touchatag:block:tag-event-type-to-text"/>
<block id="get-message" ref="urn:touchatag:block:get-text2text"/>
<block id="m" ref="urn:touchatag:block:message"/>
</breakdown>
<wiringscheme>
<wire from="empty-text2text:out" to="add-touch:map-in"/>
<wire from="ts-touchKey:out" to="add-touch:key-in"/>
<wire from="ts-touchValue:out" to="add-touch:value-in"/>
<wire from="add-touch:out" to="add-put:map-in"/>
<wire from="ts-putKey:out" to="add-put:key-in"/>
<wire from="ts-putValue:out" to="add-put:value-in"/>
<wire from="add-put:out" to="add-remove:map-in"/>
<wire from="ts-removeKey:out" to="add-remove:key-in"/>
<wire from="ts-removeValue:out" to="add-remove:value-in"/>
<wire from="add-remove:out" to="get-message:map-in"/>
<shunt from="tag-event-type-in" to="tag-event:in"/>
<wire from="tag-event:out" to="get-message:key-in"/>
<wire from="get-message:out" to="m:in"/>
<shunt from="m:out" to="action-out"/>
</wiringscheme>
</superblock>
</blueprint>
</specification>
Explanation
In this example do notice that we have changed the EventModel in the application node from the default PUT_TOUCH to PUT_TOUCH_REMOVE because we are interested in also the REMOVE TagEventType.
