Interface GadgetLocationTranslator


public interface GadgetLocationTranslator
Version 3.4 added the ability to define a custom URI location for gadget specs.

This means developers are no longer restricted to the default plugin-sensitive URI format, are free to defined custom URI and move gadgets between plugins while maintaining backward compatible URI.

This service provides a mean of translating from old public-facing identifier to an internally recognisable identifier.

Since:
3.4
  • Method Summary

    Modifier and Type
    Method
    Description
    Translate public-facing gadget spec key to internal plugin gadget spec key.
    Translate public-facing gadget spec URI to internal plugin gadget spec URI.
  • Method Details

    • translate

      Translate public-facing gadget spec key to internal plugin gadget spec key.
      Parameters:
      key - The gadget spec key to be translated.
      Returns:
      Either the translated key or the same given key.
    • translate

      URI translate(URI uri)
      Translate public-facing gadget spec URI to internal plugin gadget spec URI.
      Parameters:
      uri - The gadget spec uri to be translated.
      Returns:
      Either the translated uri or the same given uri.