Set bottom shadow of particular view in swift

@IBOutlet var viewBottomShadow: UIView!
viewBottomShadow.layer.shadowColor = UIColor.black.cgColor
viewBottomShadow.layer.shadowOffset = CGSize(width: 5, height: -5)
viewBottomShadow.layer.shadowOpacity = 0.5
viewBottomShadow.layer.shadowRadius = 3.0
viewBottomShadow.layer.masksToBounds = false
self.view.layoutIfNeeded()