Montrer UIPickerView champ de texte est sélectionné, puis se cacher après avoir sélectionné

Je suis en train de créer une zone de texte que lorsqu'il est sélectionné, un UIPickerView s'ouvre avec le choix pour sélectionner à partir. Une fois sélectionné, le UIPickerView de peaux et de l'élément sélectionné est affiché dans la zone de texte. J'ai essayé différents morceaux de code que j'ai trouvé en ligne, mais je ne peux pas le faire fonctionner. Si quelqu'un peut proposer un code complet de cette ou de me dire ce que je fais de mal dans mon code, ce serait super génial. Merci beaucoup.

Voici mon code:

@IBOutlet var textfieldBizCat: UITextField!
@IBOutlet var pickerBizCat: UIPickerView! = UIPickerView()

var bizCat = ["Cat One", "Cat Two", "Cat Three"]


override func viewDidLoad() {
    super.viewDidLoad()

    var bizCatCount = bizCat.count

    self.textfieldBizCat.inputView = pickerView

}

//returns the number of 'columns' to display.
func numberOfComponentsInPickerView(pickerView: UIPickerView!) -> Int{
    return 1
}

//returns the # of rows in each component..
func pickerView(pickerView: UIPickerView!, numberOfRowsInComponent component: Int) -> Int{
    return bizCat.count
}

func pickerView(pickerView: UIPickerView!, titleForRow row: Int, forComponent component: Int) -> String! {
    return bizCat[row]
}

func pickerView(pickerView: UIPickerView!, didSelectRow row: Int, inComponent component: Int)
{
    textfieldBizCat.text = "\(bizCat[row])"

}