com.gisgraphy.webapp.action

## Class StreetSearchAction

- java.lang.Object
- - com.opensymphony.xwork2.ActionSupport
  - - com.gisgraphy.webapp.action.SearchAction
    - - com.gisgraphy.webapp.action.StreetSearchAction

- All Implemented Interfaces:
    com.opensymphony.xwork2.Action, com.opensymphony.xwork2.LocaleProvider, com.opensymphony.xwork2.TextProvider, com.opensymphony.xwork2.Validateable, com.opensymphony.xwork2.ValidationAware, Serializable

      public class StreetSearchAction
      extends SearchAction

  Street search Action
  Author:
    David Masclet
  See Also:
    Serialized Form

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `String` | `lat`
    `String` | `lng`
    `String` | `radius`

    - ### Fields inherited from class com.gisgraphy.webapp.action.SearchAction

      `DEFAULT_NUMBER_OF_RESULTS_PER_PAGE, errorMessage, POPUP_VIEW`

    - ### Fields inherited from class com.opensymphony.xwork2.ActionSupport

      `LOG`

    - ### Fields inherited from interface com.opensymphony.xwork2.Action

      `ERROR, INPUT, LOGIN, NONE, SUCCESS`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `StreetSearchAction()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `com.gisgraphy.serializer.common.OutputFormat[]` | `getFormats()`
    `String` | `getLat()`
    `String` | `getLng()`
    `String` | `getName()`
    `Map<String,String>` | `getNameOptions()`
    `String` | `getRadius()`
    `protected javax.servlet.http.HttpServletRequest` | `getRequest()`
    `com.gisgraphy.domain.valueobject.StreetSearchResultsDto` | `getStreetSearchResultsDto()`
    `String` | `getStreetType()`
    `com.gisgraphy.street.StreetType[]` | `getStreetTypes()`
    `boolean` | `isAutosubmit()`
    `boolean` | `isDisplayResults()`
    `boolean` | `isDistance()`
    `String` | `search()` Execute a StreetSearch from the request parameters
    `String` | `searchpopup()` Execute a streetSearch from the request parameters
    `void` | `setAutosubmit(boolean autosubmit)`
    `void` | `setDistance(boolean distance)`
    `void` | `setLat(String lat)`
    `void` | `setLng(String lng)`
    `void` | `setName(String name)`
    `void` | `setRadius(String radius)`
    `void` | `setStreetSearchEngine(com.gisgraphy.street.IStreetSearchEngine streetSearchEngine)`
    `void` | `setStreetType(String streetType)`

    - ### Methods inherited from class com.gisgraphy.webapp.action.SearchAction

      `getDefaultNumberOfResultsPerPage, getErrorMessage, getFormat, getFrom, getPlacetypes, getTo, isAdvancedSearch, isIndent, setAdvancedSearch, setFormat, setFrom, setIndent, setTo`

    - ### Methods inherited from class com.opensymphony.xwork2.ActionSupport

      `addActionError, addActionMessage, addFieldError, clearActionErrors, clearErrors, clearErrorsAndMessages, clearFieldErrors, clearMessages, clone, doDefault, execute, getActionErrors, getActionMessages, getErrorMessages, getErrors, getFieldErrors, getLocale, getText, getText, getText, getText, getText, getText, getText, getText, getText, getTexts, getTexts, hasActionErrors, hasActionMessages, hasErrors, hasFieldErrors, hasKey, input, pause, setActionErrors, setActionMessages, setFieldErrors, validate`

    - ### Methods inherited from class java.lang.Object

      `equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### lat

          public String lat

    - #### lng

          public String lng

    - #### radius

          public String radius

  - ### Constructor Detail

    - #### StreetSearchAction

          public StreetSearchAction()

  - ### Method Detail

    - #### isDistance

          public boolean isDistance()

    - #### setDistance

          public void setDistance(boolean distance)

    - #### isDisplayResults

          public boolean isDisplayResults()

      Returns:
        Wether the search has been done and the results should be displayed

    - #### getRequest

          protected javax.servlet.http.HttpServletRequest getRequest()

      Returns:
        the request

    - #### search

          public String search()
                        throws Exception

      Execute a StreetSearch from the request parameters
      Returns:
        SUCCESS if the search is successfull
      Throws:
        `Exception` - in case of errors

    - #### getStreetTypes

          public com.gisgraphy.street.StreetType[] getStreetTypes()

    - #### searchpopup

          public String searchpopup()
                             throws Exception

      Execute a streetSearch from the request parameters
      Returns:
        POPUPVIEW if the search is successfull The view will not be decorated by sitemesh (see decorators.xml)
      Throws:
        `Exception` - in case of errors

    - #### getFormats

          public com.gisgraphy.serializer.common.OutputFormat[] getFormats()

      Returns:
        the available formats for fulltext

    - #### getNameOptions

          public Map<String,String> getNameOptions()

    - #### setStreetSearchEngine

          public void setStreetSearchEngine(com.gisgraphy.street.IStreetSearchEngine streetSearchEngine)

      Parameters:
        `streetSearchEngine` - the streetSearchEngine to set

    - #### getLat

          public String getLat()

      Returns:
        the lat

    - #### setLat

          public void setLat(String lat)

      Parameters:
        `lat` - the lat to set

    - #### getLng

          public String getLng()

      Returns:
        the lng

    - #### setLng

          public void setLng(String lng)

      Parameters:
        `lng` - the lng to set

    - #### getRadius

          public String getRadius()

      Returns:
        the radius

    - #### setRadius

          public void setRadius(String radius)

      Parameters:
        `radius` - the radius to set

    - #### setStreetType

          public void setStreetType(String streetType)

      Parameters:
        `streetType` - the streettype to set

    - #### getStreetType

          public String getStreetType()

      Returns:
        the placetype

    - #### getStreetSearchResultsDto

          public com.gisgraphy.domain.valueobject.StreetSearchResultsDto getStreetSearchResultsDto()

      Returns:
        the response

    - #### isAutosubmit

          public boolean isAutosubmit()

      Returns:
        the autosubmit

    - #### setAutosubmit

          public void setAutosubmit(boolean autosubmit)

      Parameters:
        `autosubmit` - the autosubmit to set

    - #### getName

          public String getName()

      Returns:
        the name

    - #### setName

          public void setName(String name)

      Parameters:
        `name` - the name to set

Copyright © 2015. All rights reserved.