Class AutoCompleteTextField<T extends Serializable>

    • Constructor Detail

      • AutoCompleteTextField

        public AutoCompleteTextField​(String id)
        Constructor
        Parameters:
        id - the markup id
      • AutoCompleteTextField

        public AutoCompleteTextField​(String id,
                                     Class<T> type)
        Constructor
        Parameters:
        id - the markup id
        type - the type of the bean. This parameter should be supplied for the internal converter (getConverter(Class)) to be used.
      • AutoCompleteTextField

        public AutoCompleteTextField​(String id,
                                     com.googlecode.wicket.jquery.core.renderer.ITextRenderer<? super T> renderer)
        Constructor
        Parameters:
        id - the markup id
        renderer - the ITextRenderer
      • AutoCompleteTextField

        public AutoCompleteTextField​(String id,
                                     com.googlecode.wicket.jquery.core.renderer.ITextRenderer<? super T> renderer,
                                     Class<T> type)
        Constructor
        Parameters:
        id - the markup id
        renderer - the ITextRenderer
        type - the type of the bean. This parameter should be supplied for the internal converter (getConverter(Class)) to be used.
      • AutoCompleteTextField

        public AutoCompleteTextField​(String id,
                                     IModel<T> model)
        Constructor
        Parameters:
        id - the markup id
        model - the IModel
      • AutoCompleteTextField

        public AutoCompleteTextField​(String id,
                                     IModel<T> model,
                                     Class<T> type)
        Constructor
        Parameters:
        id - the markup id
        model - the IModel
        type - the type of the bean. This parameter should be supplied for the internal converter (getConverter(Class)) to be used.
      • AutoCompleteTextField

        public AutoCompleteTextField​(String id,
                                     IModel<T> model,
                                     com.googlecode.wicket.jquery.core.renderer.ITextRenderer<? super T> renderer)
        Constructor
        Parameters:
        id - the markup id
        model - the IModel
        renderer - the ITextRenderer
      • AutoCompleteTextField

        public AutoCompleteTextField​(String id,
                                     IModel<T> model,
                                     com.googlecode.wicket.jquery.core.renderer.ITextRenderer<? super T> renderer,
                                     Class<T> type)
        Constructor
        Parameters:
        id - the markup id
        model - the IModel
        renderer - the ITextRenderer
        type - the type of the bean. This parameter should be supplied for the internal converter (getConverter(Class)) to be used.
    • Method Detail

      • getChoices

        protected abstract List<T> getChoices​(String input)
        Gets choices matching the provided input
        Parameters:
        input - String that represent the query
        Returns:
        the list of choices
      • getTemplateToken

        public String getTemplateToken()
        Gets the template script token/id
        Returns:
        the template script token/id
      • getRenderer

        public com.googlecode.wicket.jquery.core.renderer.ITextRenderer<? super T> getRenderer()
        Gets the ITextRenderer
        Returns:
        the ITextRenderer
      • onConfigure

        public void onConfigure​(com.googlecode.wicket.jquery.core.JQueryBehavior behavior)
        Specified by:
        onConfigure in interface com.googlecode.wicket.jquery.core.IJQueryWidget
      • onBeforeRender

        public void onBeforeRender​(com.googlecode.wicket.jquery.core.JQueryBehavior behavior)
        Specified by:
        onBeforeRender in interface com.googlecode.wicket.jquery.core.IJQueryWidget
      • onSelected

        protected void onSelected​(AjaxRequestTarget target)
        Triggered when the user selects an item from results that matched its input
        Parameters:
        target - the AjaxRequestTarget
      • newWidgetBehavior

        public com.googlecode.wicket.jquery.core.JQueryBehavior newWidgetBehavior​(String selector)
        Specified by:
        newWidgetBehavior in interface com.googlecode.wicket.jquery.core.IJQueryWidget
      • newTemplate

        protected com.googlecode.wicket.jquery.core.template.IJQueryTemplate newTemplate()
        Gets a new IJQueryTemplate to customize the rendering
        The IJQueryTemplate.getText() should return a template text of the form "<a>...</a>".
        The properties used in the template text (ie: ${name}) should be identified in the list returned by IJQueryTemplate.getTextProperties()
        Returns:
        null by default