Class I18nService

java.lang.Object
com.sodius.oslc.server.services.I18nService

@Path("/i18n") public class I18nService extends Object
Provides internationalization facilities.
Since:
1.3.0
  • Constructor Details

    • I18nService

      public I18nService()
  • Method Details

    • getMessages

      @GET @Path("/messages") @Produces("application/json") public Response getMessages()
      Returns a JSON stream containing all translations contributed by extensions of com.sodius.oslc.server.i18n.messages. The language is determined by inspecting preferred locale obtained with the Locales API and available translations on server side.
      Returns:
      a JSON stream containing all translations.
    • getTerms

      @GET @Path("/terms") @Produces("application/json") public Response getTerms()
      Returns a JSON stream containing strings combining usages of terms and articles.

      For each term, keys are added in the JSON entity for its singular, plural and capitalized values. For each article, keys are added in the JSON entity for its singular, plural and capitalized values combined with each term.

      Returns:
      a JSON stream containing strings for terms and articles.
      Since:
      4.0.0