Interface ClientType

All Known Implementing Classes:
ClientTypeImpl

public interface ClientType
If you need to handle a case which uses for example almost the same code for frontend (public) and backend (admin), you can use this service in order to get the type of the client where this request comes from. It may be "unknown" if the request header is not sent from client.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    Admin application.
    static final String
    All requests (that do not overwrite the default client type) from the new client
    static final String
    Public, e.g.
    static final String
    All requests from a legacy action
    static final String
    REST call (determined using the servletPath of the rest servlet)
    static final String
    If it is not known where this request comes from (i.e.
    static final String
    All requests (that do not overwrite the default client type) from the new client widgets
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the client type.
    void
    Internal only.
    This may be used to run code in another ClientType.
  • Field Details

  • Method Details

    • getType

      String getType()
      Returns the client type. Use defined constants from this interface.
    • setType

      void setType(String type)
      Internal only. Please do not use unless you know what you are doing.
    • withClientType

      Invoker withClientType(String type)
      This may be used to run code in another ClientType.