Class OpenUrl

  • All Implemented Interfaces:
    AutoCompletionAction

    public class OpenUrl
    extends Object
    implements AutoCompletionAction
    An auto-completion action type which directly opens the given URL rather than changing the search page. This is useful when the user is selecting a completion which itself is representative of a result (e.g. a person's name in a staff-directory context).
    • Field Detail

      • urlToOpen

        @NonNull
        private @NonNull URI urlToOpen
    • Constructor Detail

      • OpenUrl

        public OpenUrl​(String url)
                throws IllegalArgumentException
        Convenience constructor which converts the given string to a URI. The caller must ensure the string is a valid string representation of a URI.
        Throws:
        IllegalArgumentException - If the given string it not a valid URI (i.e. it violates RFC 2396)
      • OpenUrl

        public OpenUrl​(@NonNull
                       @NonNull URI urlToOpen)
    • Method Detail

      • getUrlToOpen

        @NonNull
        public @NonNull URI getUrlToOpen()
      • canEqual

        protected boolean canEqual​(Object other)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object