【Swift4】UIBarButtonSystemItem一覧

ナビゲーションバーに配置するUIBarButtonSystemItem一覧メモ。

## ボタン一覧
定型的なアクションに対応したボタンは以下のとおり。

|case|アイコン|
|:--:|:--:|
|done|<img width="60" alt="done.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/096e7d3c-13ff-5345-b75f-34c7318d46a9.png">|
|cancel|<img width="55" alt="cancel.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/80471d1f-45c0-7c58-98b9-cfd625b639fa.png">|
|edit|<img width="60" alt="edit.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/41af7f1e-05bf-2af8-a2cd-1cfa64d7d7d9.png">|
|save|<img width="60" alt="save.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/ee60907f-5710-76fa-db66-f4ba16a6e706.png">|
|add|<img width="60" alt="add.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/2a433b9f-bd3e-5b5e-3ec3-f493fca3620d.png">|
|compose|<img width="60" alt="compose.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/0c96b949-a3d2-4c73-b84d-f815ad62c58a.png">|
|reply|<img width="60" alt="reply.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/897c96b8-2052-bd15-1151-19c8d6ab8c01.png">|
|action|<img width="60" alt="action.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/05d169d9-97d3-9370-7d25-ab256777d4cb.png">|
|organize|<img width="60" alt="organize.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/a06d077f-8f87-984b-2dd7-f3917bb0dff7.png">|
|bookmarks|<img width="60" alt="bookmarks.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/42156f17-d483-76eb-00e9-4a0c01c7dbb7.png">|
|search|<img width="60" alt="search.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/6894518e-d775-1a78-0e36-fe40b33829ef.png">|
|refresh|<img width="60" alt="refresh.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/f3bf2eef-15b7-c51d-3efb-17869bba2213.png">|
|stop|<img width="60" alt="stop.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/baeadead-f80d-a48c-e44b-2a7063b15459.png">|
|camera|<img width="60" alt="camera.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/a059bfdb-7c0a-8911-3ba2-e816702915b1.png">|
|trash|<img width="60" alt="trash.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/47db634f-32bd-8a9d-f25f-f2b7b4f48999.png">|
|pause|<img width="60" alt="pause.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/c7f30130-5d00-b868-4b47-e31829530451.png">|
|rewind|<img width="60" alt="rewind.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/0cf47e7b-cad8-39ca-c70d-ee0adfba6416.png">|
|fastFoward|<img width="60" alt="fastForward.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/8c6a82a5-e7d4-8a29-c2ba-7f426f19cc69.png">|
|undo|<img width="60" alt="undo.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/31c9f8cc-5841-be62-fe06-840605e7589d.png">|
|redo|<img width="60" alt="redo.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/013fd929-8852-09c9-9461-87a6548fad1a.png">|

## 設置方法
### storyboardから
<img width="498" alt="UIBarButtonSystemItem.png" src="https://qiita-image-store.s3.amazonaws.com/0/238595/b7127881-4f98-a48e-5783-2d83f330a74a.png">

### コードから
```swift
let addButton = UIBarButtonItem(barButtonSystemItem: .add, target: self, action: #selector(insertNewObject(_:)))
navigationItem.rightBarButtonItem = addButton
```

## 参考
https://developer.apple.com/documentation/uikit/uibarbuttonsystemitem