From 48eee8636dc4200b316ad1f276fb2f59baaa837f Mon Sep 17 00:00:00 2001 From: Tomasz Marciniak Date: Tue, 26 Jul 2016 08:26:29 +0200 Subject: [PATCH] [Widgetservice] Adjusted error types to the native api. Change-Id: I24e18695d466dd4b4beb39f1d414ff81db52b328 Signed-off-by: Tomasz Marciniak --- .../device_api/mobile/tizen/widgetservice.html | 50 +++++++-------------- .../device_api/wearable/tizen/widgetservice.html | 52 ++++++++-------------- 2 files changed, 34 insertions(+), 68 deletions(-) diff --git a/org.tizen.web.apireference/html/device_api/mobile/tizen/widgetservice.html b/org.tizen.web.apireference/html/device_api/mobile/tizen/widgetservice.html index e324c51..5527294 100644 --- a/org.tizen.web.apireference/html/device_api/mobile/tizen/widgetservice.html +++ b/org.tizen.web.apireference/html/device_api/mobile/tizen/widgetservice.html @@ -411,7 +411,7 @@ The tizen.widgetservice object provides access to the Widget service AP with error type SecurityError, if the application does not have the privilege to use this function.

  • - with error type InvalidValuesError, if any of the input parameters contain an invalid value. + with error type NotFoundError, if widget with given id does not exist.

  • with error type IOError, if a DB operation has failed. @@ -465,11 +465,11 @@ The errorCallback is launched with these error types:

    • -InvalidValuesError - If any of the input parameters contain an invalid value.
    • -
    • IOError - If a DB operation has failed.
    • AbortError - If the operation cannot be finished properly.
    • +
    • +NotFoundError - If the device has no widgets or if a widget with the given id does not exist

    @@ -563,7 +563,7 @@ AbortError - If the operation cannot be finished properly.

  • with error type SecurityError, if the application does not have the privilege to use this function.

  • - with error type InvalidValuesError, if any of the input parameters contain an invalid value. + with error type NotFoundError, if widget with given id does not exist.

  • with error type IOError, if a DB operation has failed. @@ -618,14 +618,9 @@ AbortError - If the operation cannot be finished properly.

  • Exceptions:

    -
    • WebAPIException
        -
      • +

        • WebAPIException
          • with error type TypeMismatchError, if any input parameter is not compatible with the expected type for that parameter. -

          • -
          • - with error type InvalidValuesError, if any of the input parameters contain an invalid value. -

          • -
          +

    @@ -769,14 +764,9 @@ Precondition: Widget tag in the config.xml file includes the "nodisplay" attribu

    Exceptions:

    -
    • WebAPIException
        -
      • - with error type InvalidValuesError, if any of the input parameters contain an invalid value. -

      • -
      • +

        • WebAPIException
          • with error type AbortError, if the operation cannot be finished properly. -

          • -
          +

    @@ -819,8 +809,13 @@ The errorCallback is launched with these error types: AbortError - If the operation cannot be finished properly.
  • NotFoundError - If the Web application which is calling this method did not add any widgets to the screen.
  • +
  • +SecurityError - If the widget does not belong to the package of the web application which is calling this method.
  • +

    Remark : + This method can only be used with widgets and applications which belong to the same package. Therefore, the widget should belong to the package of the Web application which calls this method. +

    Parameters:

      @@ -896,7 +891,7 @@ NotFoundError - If the Web application which is calling this method did not add

      Exceptions:

      • WebAPIException
        • - with error type InvalidValuesError, if any of the input parameters contain an invalid value. + with error type TypeMismatchError, if any input parameter is not compatible with the expected type for that parameter.

        • with error type AbortError, if the operation cannot be finished properly. @@ -1022,9 +1017,6 @@ AbortError - If the operation cannot be finished properly.

        • with error type TypeMismatchError, if any input parameter is not compatible with the expected type for that parameter.

        • - with error type InvalidValuesError, if any input parameters do not contain a valid value. -

        • -
        • with error type AbortError, if the operation cannot be finished properly.

        @@ -1077,17 +1069,9 @@ AbortError - If the operation cannot be finished properly.

    Exceptions:

    -
    • WebAPIException
        -
      • - with error type NotFoundError, if listener with given watchId not exists. -

      • -
      • - with error type InvalidValuesError, if any input parameters do not contain a valid value. -

      • -
      • +

        • WebAPIException
          • with error type AbortError, if the operation cannot be finished properly. -

          • -
          +

    @@ -1451,8 +1435,6 @@ The errorCallback is launched with these error types:

    • -InvalidValuesError - If any of the input parameters contain an invalid value
    • -
    • IOError - If a DB operation has failed
    • AbortError - If the operation cannot be finished properly.
    • diff --git a/org.tizen.web.apireference/html/device_api/wearable/tizen/widgetservice.html b/org.tizen.web.apireference/html/device_api/wearable/tizen/widgetservice.html index 26e8a79..8782d4f 100644 --- a/org.tizen.web.apireference/html/device_api/wearable/tizen/widgetservice.html +++ b/org.tizen.web.apireference/html/device_api/wearable/tizen/widgetservice.html @@ -411,7 +411,7 @@ The tizen.widgetservice object provides access to the Widget service AP with error type SecurityError, if the application does not have the privilege to use this function.

    • - with error type InvalidValuesError, if any of the input parameters contain an invalid value. + with error type NotFoundError, if widget with given id does not exist.

    • with error type IOError, if a DB operation has failed. @@ -465,11 +465,11 @@ The errorCallback is launched with these error types:

      • -InvalidValuesError - If any of the input parameters contain an invalid value.
      • -
      • IOError - If a DB operation has failed.
      • AbortError - If the operation cannot be finished properly.
      • +
      • +NotFoundError - If the device has no widgets or if a widget with the given id does not exist

    @@ -563,7 +563,7 @@ AbortError - If the operation cannot be finished properly. with error type SecurityError, if the application does not have the privilege to use this function.

  • - with error type InvalidValuesError, if any of the input parameters contain an invalid value. + with error type NotFoundError, if widget with given id does not exist.

  • with error type IOError, if a DB operation has failed. @@ -618,14 +618,9 @@ AbortError - If the operation cannot be finished properly.

  • Exceptions:

    -
    • WebAPIException
        -
      • +

        • WebAPIException
          • with error type TypeMismatchError, if any input parameter is not compatible with the expected type for that parameter. -

          • -
          • - with error type InvalidValuesError, if any of the input parameters contain an invalid value. -

          • -
          +

    @@ -769,14 +764,9 @@ Precondition: Widget tag in the config.xml file includes the "nodisplay" attribu

    Exceptions:

    -
    • WebAPIException
        -
      • - with error type InvalidValuesError, if any of the input parameters contain an invalid value. -

      • -
      • +

        • WebAPIException
          • with error type AbortError, if the operation cannot be finished properly. -

          • -
          +

    @@ -817,8 +807,15 @@ The errorCallback is launched with these error types:
    • AbortError - If the operation cannot be finished properly.
    • +
    • +NotFoundError - If the Web application which is calling this method did not add any widgets to the screen.
    • +
    • +SecurityError - If the widget does not belong to the package of the web application which is calling this method.
    +

    Remark : + This method can only be used with widgets and applications which belong to the same package. Therefore, the widget should belong to the package of the Web application which calls this method. +

    Parameters:

      @@ -894,7 +891,7 @@ AbortError - If the operation cannot be finished properly.

      Exceptions:

      • WebAPIException
        • - with error type InvalidValuesError, if any of the input parameters contain an invalid value. + with error type TypeMismatchError, if any input parameter is not compatible with the expected type for that parameter.

        • with error type AbortError, if the operation cannot be finished properly. @@ -1020,9 +1017,6 @@ AbortError - If the operation cannot be finished properly.

        • with error type TypeMismatchError, if any input parameter is not compatible with the expected type for that parameter.

        • - with error type InvalidValuesError, if any input parameters do not contain a valid value. -

        • -
        • with error type AbortError, if the operation cannot be finished properly.

        @@ -1075,17 +1069,9 @@ AbortError - If the operation cannot be finished properly.

    Exceptions:

    -
    • WebAPIException
        -
      • - with error type NotFoundError, if listener with given watchId not exists. -

      • -
      • - with error type InvalidValuesError, if any input parameters do not contain a valid value. -

      • -
      • +

        • WebAPIException
          • with error type AbortError, if the operation cannot be finished properly. -

          • -
          +

    @@ -1449,8 +1435,6 @@ The errorCallback is launched with these error types:

    • -InvalidValuesError - If any of the input parameters contain an invalid value
    • -
    • IOError - If a DB operation has failed
    • AbortError - If the operation cannot be finished properly.
    • -- 2.7.4