Thomas Vachuska

Modifying uitab archetype to allow it to co-exist/overlay the ui archetype.

Change-Id: I5fd8408aaaf461e29e757389d4acbd94647cd1c5
......@@ -11,7 +11,7 @@ type=${1:-bundle}
[ $type = app ] && archetype=bundle || archetype=$type
if [ "$1" = "-?" -o "$1" = "-h" -o "$1" = "--help" ]; then
echo "usage: $(basename $0) {app|bundle|ui|cli|api} groupId artifactId version package mvn-options"
echo "usage: $(basename $0) {app|bundle|ui|uitab|cli|api} groupId artifactId version package mvn-options"
echo " All arguments are optional"
exit 1
fi
......
......@@ -37,7 +37,7 @@ import java.util.List;
* Skeletal ONOS UI Table-View application component.
*/
@Component(immediate = true)
public class AppUiComponent {
public class AppUiTableComponent {
private final Logger log = LoggerFactory.getLogger(getClass());
......@@ -52,12 +52,13 @@ public class AppUiComponent {
// Factory for UI message handlers
private final UiMessageHandlerFactory messageHandlerFactory =
() -> ImmutableList.of(
new AppUiMessageHandler()
new AppUiTableMessageHandler()
);
// Application UI extension
protected UiExtension extension =
new UiExtension.Builder(getClass().getClassLoader(), uiViews)
.resourcePath("sampleTable")
.messageHandlerFactory(messageHandlerFactory)
.build();
......
......@@ -35,7 +35,7 @@ import java.util.List;
/**
* Skeletal ONOS UI Table-View message handler.
*/
public class AppUiMessageHandler extends UiMessageHandler {
public class AppUiTableMessageHandler extends UiMessageHandler {
private static final String SAMPLE_TABLE_DATA_REQ = "sampleTableDataRequest";
private static final String SAMPLE_TABLE_DATA_RESP = "sampleTableDataResponse";
......
......@@ -42,8 +42,18 @@
<step name="Reinstall-App-With-UI" requires="^,~Verify-CLI"
exec="onos-app ${OCI} reinstall! target/test-app-1.2.3.oar"/>
<step name="Verify-UI" requires="^"
exec="onos-check-views $ou{OCI} id=sample"/>
<step name="Create-App-UI-Table-Overlay" requires="Reinstall-App-With-UI"
exec="onos-create-app uitab org.test.app test-app 1.2.3 org.test.app -DinteractiveMode=false"/>
<step name="Build-App-With-UI-Table" requires="^"
exec="mvn clean install"/>
<step name="Reinstall-App-With-UI-Table" requires="^,~Verify-UI"
exec="onos-app ${OCI} reinstall! target/test-app-1.2.3.oar"/>
<step name="Verify-UI-Table" requires="^"
exec="onos-check-views ${OCI} id=sample"/>
<step name="Uninstall-App" requires="^"
exec="onos-app ${OCI} uninstall org.foo.app"/>
</group>
......