From 047da2699508768e37c50c693ac853c084c500aa Mon Sep 17 00:00:00 2001 From: Jay Sharma Date: Tue, 15 Sep 2015 17:09:59 +0530 Subject: [PATCH] Updated REServer Andriod application. - Updated REServer application for the new bundles : BMI and DI bundles. - Updated the .xml file for the bundles. Change-Id: I924f1a17bd2c3f5368e3275b5a019cc2759da7a2 Signed-off-by: Jay Sharma Reviewed-on: https://gerrit.iotivity.org/gerrit/2519 Tested-by: jenkins-iotivity Reviewed-by: Madan Lanka --- .../assets/lib/ResourceContainerConfig.xml | 38 ++- .../REServer/res/layout/list_group.xml | 15 + .../android/REServer/res/layout/list_item.xml | 16 ++ .../res/layout/resource_container.xml | 44 ++- .../REServer/res/layout/server_builder.xml | 11 +- .../layout/userinputfortemperaturevalue.xml | 50 ++-- .../sampleserver/ResourceContainer.java | 214 +++++++++----- .../ResourceContainerActivity.java | 272 +++++++++++++----- .../example/sampleserver/ServerBuilder.java | 6 +- .../ServerBuilderAutoActivity.java | 2 +- 10 files changed, 457 insertions(+), 211 deletions(-) create mode 100644 service/resource-encapsulation/examples/android/REServer/res/layout/list_group.xml create mode 100644 service/resource-encapsulation/examples/android/REServer/res/layout/list_item.xml diff --git a/service/resource-encapsulation/examples/android/REServer/assets/lib/ResourceContainerConfig.xml b/service/resource-encapsulation/examples/android/REServer/assets/lib/ResourceContainerConfig.xml index df59562b8..3ba52a2d7 100644 --- a/service/resource-encapsulation/examples/android/REServer/assets/lib/ResourceContainerConfig.xml +++ b/service/resource-encapsulation/examples/android/REServer/assets/lib/ResourceContainerConfig.xml @@ -1,28 +1,38 @@ - + oic.bundle.discomfortIndexSensor - data/data/com.example.sampleresourceserver/files/libSoftSensorBundle.so + data/data/com.example.sampleresourceserver/files/libDISensorBundle.so 1.0.0 DiscomfortIndexSensor1 oic.softsensor - - discomfortIndex - int - + + discomfortIndex + int + + + humidity + double + + + temperature + double + - - humidity - double - - - temperature - double - + + humidity + double + oic.sensor.humidity + + + temperature + double + oic.sensor.temperature + diff --git a/service/resource-encapsulation/examples/android/REServer/res/layout/list_group.xml b/service/resource-encapsulation/examples/android/REServer/res/layout/list_group.xml new file mode 100644 index 000000000..4bb77b921 --- /dev/null +++ b/service/resource-encapsulation/examples/android/REServer/res/layout/list_group.xml @@ -0,0 +1,15 @@ + + + + + + \ No newline at end of file diff --git a/service/resource-encapsulation/examples/android/REServer/res/layout/list_item.xml b/service/resource-encapsulation/examples/android/REServer/res/layout/list_item.xml new file mode 100644 index 000000000..12416528b --- /dev/null +++ b/service/resource-encapsulation/examples/android/REServer/res/layout/list_item.xml @@ -0,0 +1,16 @@ + + + + + + \ No newline at end of file diff --git a/service/resource-encapsulation/examples/android/REServer/res/layout/resource_container.xml b/service/resource-encapsulation/examples/android/REServer/res/layout/resource_container.xml index 0fa92f4ca..50456c475 100644 --- a/service/resource-encapsulation/examples/android/REServer/res/layout/resource_container.xml +++ b/service/resource-encapsulation/examples/android/REServer/res/layout/resource_container.xml @@ -3,7 +3,7 @@ android:layout_width="match_parent" android:layout_height="match_parent" > -