-
Notifications
You must be signed in to change notification settings - Fork 1
CarouselViewController
James Barrow edited this page Jan 29, 2017
·
1 revision
Declaration
Swift
enum Direction: Int
---
<br>
### collectionView
**Declaration**
> <sub>**Swift**</sub>
> ```swift
@IBOutlet public weak var collectionView: UICollectionView!
Declaration
Swift
@IBOutlet public weak var pageControl: UIPageControl?
---
<br>
### numberOfPages
**Declaration**
> <sub>**Swift**</sub>
> ```swift
public var numberOfPages: Int
Declaration
Swift
open override func viewDidLoad()
---
<br>
### willAnimateRotation(to:duration:)
**Declaration**
> <sub>**Swift**</sub>
> ```swift
open override func willAnimateRotation(to toInterfaceOrientation: UIInterfaceOrientation, duration: TimeInterval)
## UICollectionViewDataSource and UICollectionViewDelegate
Declaration
Swift
open func numberOfSections(in collectionView: UICollectionView) -> Int
---
<br>
### collectionView(_:numberOfItemsInSection:)
**Declaration**
> <sub>**Swift**</sub>
> ```swift
open func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int
Declaration
Swift
open func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell
---
<br>
## UICollectionViewDelegateFlowLayout <br>
### collectionView(_:layout:sizeForItemAt:)
**Declaration**
> <sub>**Swift**</sub>
> ```swift
open func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize
Declaration
Swift
open override func viewWillTransition(to size: CGSize, with coordinator: UIViewControllerTransitionCoordinator)
---
<br>
## UIPageControl Methods <br>
### pageControlDidChange(_:)
**Declaration**
> <sub>**Swift**</sub>
> ```swift
public final func pageControlDidChange(_ sender: UIPageControl)
## UIScrollViewDelegate Methods
Declaration
Swift
open func scrollViewDidScroll(_ scrollView: UIScrollView)
---
<br>
### scrollViewDidEndDecelerating(_:)
**Declaration**
> <sub>**Swift**</sub>
> ```swift
open func scrollViewDidEndDecelerating(_ scrollView: UIScrollView)
## Animation Methods
Declaration
Swift
private func degreesToRadians(angle: CGFloat) -> CGFloat
---
<br>
### animate(view:percent:pageNumber:)
**Declaration**
> <sub>**Swift**</sub>
> ```swift
private func animate(view: UIView, percent: CGFloat, pageNumber: Int)