SearchView

class SearchView : UIView, UITextFieldDelegate

The view for search Bar

Properties

  • This is a UItextField used to input the search content

    Declaration

    Swift

    @IBOutlet
    var inputField: UITextField!
  • Undocumented

    Declaration

    Swift

    var suggestions: [String]

Methods

  • Cusomise the view

    Declaration

    Swift

    func customisation()
  • HIde search View

    Declaration

    Swift

    @IBAction
    func hideSearchView(_: Any)

Delegate

  • Asks the delegate if the text field should process the pressing of the return button.

    Declaration

    Swift

    func textFieldShouldReturn(_ textField: UITextField) -> Bool

    Parameters

    textField

    The text field whose return button was pressed.

    Return Value

    true if the text field should implement its default behavior for the return button; otherwise, false.

View LifeCycle

  • Prepares the receiver for service after it has been loaded from an Interface Builder archive, or nib file.

    Declaration

    Swift

    override func awakeFromNib()