Package org.robovm.apple.uikit
Class UICollectionView
- java.lang.Object
-
- org.robovm.rt.bro.NativeObject
-
- org.robovm.objc.ObjCObject
-
- org.robovm.apple.foundation.NSObject
-
- org.robovm.apple.uikit.UIResponder
-
- org.robovm.apple.uikit.UIView
-
- org.robovm.apple.uikit.UIScrollView
-
- org.robovm.apple.uikit.UICollectionView
-
- All Implemented Interfaces:
CALayerDelegate
,NSCoding
,NSObjectProtocol
,UIAccessibility
,UIAccessibilityIdentification
,UIAppearanceContainer
,UICoordinateSpace
,UIDataSourceTranslating
,UIDynamicItem
,UIFocusEnvironment
,UIFocusItem
,UIFocusItemContainer
,UIFocusItemScrollableContainer
,UISpringLoadedInteractionSupporting
,UITraitEnvironment
,org.robovm.objc.ObjCProtocol
public class UICollectionView extends UIScrollView implements UIDataSourceTranslating, UISpringLoadedInteractionSupporting
- Since:
- Available in iOS 6.0 and later.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
UICollectionView.UICollectionViewPtr
-
Nested classes/interfaces inherited from class org.robovm.apple.uikit.UIScrollView
UIScrollView.UIScrollViewPtr
-
Nested classes/interfaces inherited from class org.robovm.apple.uikit.UIView
UIView.UIViewPtr
-
Nested classes/interfaces inherited from class org.robovm.apple.uikit.UIResponder
UIResponder.UIResponderPtr
-
Nested classes/interfaces inherited from class org.robovm.apple.foundation.NSObject
NSObject.Handle, NSObject.Marshaler, NSObject.NoRetainMarshaler, NSObject.NSKeyValueObserver, NSObject.NSObjectPtr, NSObject.SkipInit
-
Nested classes/interfaces inherited from class org.robovm.objc.ObjCObject
org.robovm.objc.ObjCObject.ObjCObjectPtr, org.robovm.objc.ObjCObject.Super
-
Nested classes/interfaces inherited from interface org.robovm.apple.uikit.UIAccessibility
UIAccessibility.Notifications
-
-
Field Summary
-
Fields inherited from class org.robovm.apple.foundation.NSObject
FLAG_NO_RETAIN
-
-
Constructor Summary
Constructors Modifier Constructor Description UICollectionView()
UICollectionView(CGRect frame)
UICollectionView(CGRect frame, UICollectionViewLayout layout)
UICollectionView(NSCoder decoder)
protected
UICollectionView(NSObject.Handle h, long handle)
protected
UICollectionView(NSObject.SkipInit skipInit)
-
Method Summary
-
Methods inherited from class org.robovm.apple.uikit.UIScrollView
adjustedContentInsetDidChange, alwaysBounceHorizontal, alwaysBounceVertical, bounces, bouncesZoom, canCancelContentTouches, delaysContentTouches, flashScrollIndicators, getAdjustedContentInset, getContentInset, getContentInsetAdjustmentBehavior, getContentLayoutGuide, getContentOffset, getContentSize, getDecelerationRate, getDirectionalPressGestureRecognizer, getFastDecelerationRate, getFrameLayoutGuide, getIndexDisplayMode, getIndicatorStyle, getKeyboardDismissMode, getMaximumZoomScale, getMinimumZoomScale, getNormalDecelerationRate, getPanGestureRecognizer, getPinchGestureRecognizer, getRefreshControl, getScrollIndicatorInsets, getVisibleSize, getZoomScale, isDecelerating, isDirectionalLockEnabled, isDragging, isPagingEnabled, isScrollEnabled, isTracking, isZoomBouncing, isZooming, scrollRectToVisible, scrollsToTop, setAlwaysBounceHorizontal, setAlwaysBounceVertical, setBounces, setBouncesZoom, setCanCancelContentTouches, setContentInset, setContentInsetAdjustmentBehavior, setContentOffset, setContentOffset, setContentSize, setDecelerationRate, setDelaysContentTouches, setDelegate, setDirectionalLockEnabled, setIndexDisplayMode, setIndicatorStyle, setKeyboardDismissMode, setMaximumZoomScale, setMinimumZoomScale, setPagingEnabled, setRefreshControl, setScrollEnabled, setScrollIndicatorInsets, setScrollsToTop, setShowsHorizontalScrollIndicator, setShowsVerticalScrollIndicator, setZoomScale, setZoomScale, showsHorizontalScrollIndicator, showsVerticalScrollIndicator, touchesShouldBegin, touchesShouldCancelInContentView, zoomToRect
-
Methods inherited from class org.robovm.apple.uikit.UIView
addConstraint, addConstraints, addGestureRecognizer, addInteraction, addKeyframe, addLayoutGuide, addMotionEffect, addSubview, animate, animate, animate, animate, animateKeyframes, areAnimationsEnabled, autoresizesSubviews, beginAnimations, bringSubviewToFront, canBecomeFocused, clearsContextBeforeDrawing, clipsToBounds, commitAnimations, convertPointFromCoordinateSpace, convertPointFromView, convertPointToCoordinateSpace, convertPointToView, convertRectFromCoordinateSpace, convertRectFromView, convertRectToCoordinateSpace, convertRectToView, decodeRestorableState, didAddSubview, didHintFocusMovement, didMoveToSuperview, didMoveToWindow, didUpdateFocus, displayLayer, draw, draw, drawLayer, drawViewHierarchy, encode, encodeRestorableState, endEditing, exchangeSubview, exerciseAmbiguityInLayout, focusItemsInRect, gestureRecognizerShouldBegin, getAccessibilityIdentifier, getAction, getAlignmentRectForFrame, getAlignmentRectInsets, getAlpha, getAutoresizingMask, getBackgroundColor, getBottomAnchor, getBounds, getCenter, getCenterXAnchor, getCenterYAnchor, getCollisionBoundingPath, getCollisionBoundsType, getConstraints, getConstraintsAffectingLayout, getContentCompressionResistancePriority, getContentHuggingPriority, getContentMode, getContentScaleFactor, getCoordinateSpace, getDirectionalLayoutMargins, getEffectiveUserInterfaceLayoutDirection, getFirstBaselineAnchor, getFocusItemContainer, getFrame, getFrameForAlignmentRect, getGestureRecognizers, getHeightAnchor, getInheritedAnimationDuration, getInteractions, getIntrinsicContentSize, getLastBaselineAnchor, getLayer, getLayerClass, getLayoutGuides, getLayoutMargins, getLayoutMarginsGuide, getLeadingAnchor, getLeftAnchor, getMaskView, getMotionEffects, getParentFocusEnvironment, getPreferredFocusedView, getPreferredFocusEnvironments, getReadableContentGuide, getResizableSnapshot, getRestorationIdentifier, getRightAnchor, getSafeAreaInsets, getSafeAreaLayoutGuide, getSemanticContentAttribute, getSizeThatFits, getSnapshot, getSubviews, getSuperview, getSystemLayoutSizeFittingSize, getSystemLayoutSizeFittingSize, getTag, getTintAdjustmentMode, getTintColor, getTopAnchor, getTrailingAnchor, getTraitCollection, getTransform, getUserInterfaceLayoutDirection, getUserInterfaceLayoutDirection, getViewForBaselineLayout, getViewForFirstBaselineLayout, getViewForLastBaselineLayout, getViewPrintFormatter, getViewWithTag, getWidthAnchor, getWindow, hasAmbiguousLayout, hitTest, init, insertSubview, insertSubviewAbove, insertSubviewBelow, invalidateIntrinsicContentSize, isAccessibilityIgnoresInvertColors, isDescendantOf, isExclusiveTouch, isFocused, isHidden, isInsetsLayoutMarginsFromSafeArea, isMultipleTouchEnabled, isOpaque, isPointInside, isUserInteractionEnabled, layoutIfNeeded, layoutMarginsDidChange, layoutSublayers, layoutSubviews, needsUpdateConstraints, NoIntrinsicMetric, performSystemAnimation, performWithoutAnimation, preservesSuperviewLayoutMargins, removeConstraint, removeConstraints, removeFromSuperview, removeGestureRecognizer, removeInteraction, removeLayoutGuide, removeMotionEffect, requiresConstraintBasedLayout, safeAreaInsetsDidChange, sendSubviewToBack, setAccessibilityIdentifier, setAccessibilityIgnoresInvertColors, setAlpha, setAnimationBeginsFromCurrentState, setAnimationCurve, setAnimationDelay, setAnimationDelegate, setAnimationDidStopSelector, setAnimationDurationInSeconds, setAnimationRepeatAutoreverses, setAnimationRepeatCount, setAnimationsEnabled, setAnimationStartDate, setAnimationTransition, setAnimationWillStartSelector, setAutoresizesSubviews, setAutoresizingMask, setBackgroundColor, setBounds, setCenter, setClearsContextBeforeDrawing, setClipsToBounds, setContentCompressionResistancePriority, setContentHuggingPriority, setContentMode, setContentScaleFactor, setDirectionalLayoutMargins, setExclusiveTouch, setFrame, setGestureRecognizers, setHidden, setInsetsLayoutMarginsFromSafeArea, setInteractions, setLayoutMargins, setMaskView, setMotionEffects, setMultipleTouchEnabled, setNeedsDisplay, setNeedsDisplay, setNeedsFocusUpdate, setNeedsLayout, setNeedsUpdateConstraints, setOpaque, setPreservesSuperviewLayoutMargins, setRestorationIdentifier, setSemanticContentAttribute, setTag, setTintAdjustmentMode, setTintColor, setTransform, setTranslatesAutoresizingMaskIntoConstraints, setUserInteractionEnabled, shouldUpdateFocus, sizeToFit, tintColorDidChange, traitCollectionDidChange, transition, transition, translatesAutoresizingMaskIntoConstraints, updateConstraints, updateConstraintsIfNeeded, updateFocusIfNeeded, willDrawLayer, willMoveToSuperview, willMoveToWindow, willRemoveSubview
-
Methods inherited from class org.robovm.apple.uikit.UIResponder
areAccessibilityElementsHidden, becomeFirstResponder, canBecomeFirstResponder, canPerformAction, canResignFirstResponder, clearTextInputContextIdentifier, getAccessibilityActivationPoint, getAccessibilityAttributedHint, getAccessibilityAttributedLabel, getAccessibilityAttributedValue, getAccessibilityFrame, getAccessibilityHint, getAccessibilityLabel, getAccessibilityLanguage, getAccessibilityNavigationStyle, getAccessibilityPath, getAccessibilityTraits, getAccessibilityValue, getActionTarget, getInputAccessoryView, getInputAccessoryViewController, getInputAssistantItem, getInputView, getInputViewController, getKeyCommands, getNextResponder, getTextInputContextIdentifier, getTextInputMode, getUndoManager, getUserActivity, isAccessibilityElement, isAccessibilityViewModal, isFirstResponder, motionBegan, motionCancelled, motionEnded, pressesBegan, pressesCancelled, pressesChanged, pressesEnded, reloadInputViews, remoteControlReceived, resignFirstResponder, restoreUserActivityState, setAccessibilityActivationPoint, setAccessibilityAttributedHint, setAccessibilityAttributedLabel, setAccessibilityAttributedValue, setAccessibilityElement, setAccessibilityElementsHidden, setAccessibilityFrame, setAccessibilityHint, setAccessibilityLabel, setAccessibilityLanguage, setAccessibilityNavigationStyle, setAccessibilityPath, setAccessibilityTraits, setAccessibilityValue, setAccessibilityViewModal, setShouldGroupAccessibilityChildren, setUserActivity, shouldGroupAccessibilityChildren, touchesBegan, touchesCancelled, touchesEnded, touchesEstimatedPropertiesUpdated, touchesMoved, updateUserActivityState
-
Methods inherited from class org.robovm.apple.foundation.NSObject
addKeyValueObserver, addKeyValueObserver, afterMarshaled, alloc, autorelease, autorelease, awakeFromNib, conformsToProtocol, copy, description, didChangeValue, didChangeValue, didChangeValues, doDispose, equals, forceSkipInit, getAutoContentAccessingProxy, getClassForCoder, getClassForKeyedArchiver, getKeyValueCoder, getObservationInfo, hash, hashCode, init, isEqual, isKindOfClass, isMemberOfClass, mutableCopy, performSelector, performSelector, performSelector, performSelector, performSelector, performSelector, performSelector, performSelectorInBackground, performSelectorOnMainThread, performSelectorOnMainThread, performSelectorV, performSelectorV, performSelectorV, release, release, removeKeyValueObserver, removeKeyValueObservers, respondsToSelector, retain, retain, retainCount, setObservationInfo, toString, willChangeValue, willChangeValue, willChangeValues
-
Methods inherited from class org.robovm.objc.ObjCObject
addStrongRef, dispose, dispose, finalize, getAssociatedObject, getObjCClass, getPeerObject, getSuper, initObject, logRetainRelease, removeStrongRef, retainCustomObjectFromCb, setAssociatedObject, toObjCObject, toObjCObject, updateStrongRef
-
Methods inherited from interface org.robovm.apple.uikit.UIFocusItemContainer
focusItemsInRect, getCoordinateSpace
-
-
-
-
Constructor Detail
-
UICollectionView
public UICollectionView()
-
UICollectionView
protected UICollectionView(NSObject.Handle h, long handle)
-
UICollectionView
protected UICollectionView(NSObject.SkipInit skipInit)
-
UICollectionView
public UICollectionView(CGRect frame, UICollectionViewLayout layout)
-
UICollectionView
public UICollectionView(NSCoder decoder)
-
UICollectionView
public UICollectionView(CGRect frame)
-
-
Method Detail
-
getCollectionViewLayout
public UICollectionViewLayout getCollectionViewLayout()
-
setCollectionViewLayout
public void setCollectionViewLayout(UICollectionViewLayout v)
-
getDelegate
public UICollectionViewDelegate getDelegate()
- Overrides:
getDelegate
in classUIScrollView
-
setDelegate
public void setDelegate(UICollectionViewDelegate v)
-
getDataSource
public UICollectionViewDataSource getDataSource()
-
setDataSource
public void setDataSource(UICollectionViewDataSource v)
-
getPrefetchDataSource
public UICollectionViewDataSourcePrefetching getPrefetchDataSource()
- Since:
- Available in iOS 10.0 and later.
-
setPrefetchDataSource
public void setPrefetchDataSource(UICollectionViewDataSourcePrefetching v)
- Since:
- Available in iOS 10.0 and later.
-
isPrefetchingEnabled
public boolean isPrefetchingEnabled()
- Since:
- Available in iOS 10.0 and later.
-
setPrefetchingEnabled
public void setPrefetchingEnabled(boolean v)
- Since:
- Available in iOS 10.0 and later.
-
getDragDelegate
public UICollectionViewDragDelegate getDragDelegate()
- Since:
- Available in iOS 11.0 and later.
-
setDragDelegate
public void setDragDelegate(UICollectionViewDragDelegate v)
- Since:
- Available in iOS 11.0 and later.
-
getDropDelegate
public UICollectionViewDropDelegate getDropDelegate()
- Since:
- Available in iOS 11.0 and later.
-
setDropDelegate
public void setDropDelegate(UICollectionViewDropDelegate v)
- Since:
- Available in iOS 11.0 and later.
-
isDragInteractionEnabled
public boolean isDragInteractionEnabled()
- Since:
- Available in iOS 11.0 and later.
-
setDragInteractionEnabled
public void setDragInteractionEnabled(boolean v)
- Since:
- Available in iOS 11.0 and later.
-
getReorderingCadence
public UICollectionViewReorderingCadence getReorderingCadence()
- Since:
- Available in iOS 11.0 and later.
-
setReorderingCadence
public void setReorderingCadence(UICollectionViewReorderingCadence v)
- Since:
- Available in iOS 11.0 and later.
-
getBackgroundView
public UIView getBackgroundView()
-
setBackgroundView
public void setBackgroundView(UIView v)
-
allowsSelection
public boolean allowsSelection()
-
setAllowsSelection
public void setAllowsSelection(boolean v)
-
allowsMultipleSelection
public boolean allowsMultipleSelection()
-
setAllowsMultipleSelection
public void setAllowsMultipleSelection(boolean v)
-
getIndexPathsForSelectedItems
public NSArray<NSIndexPath> getIndexPathsForSelectedItems()
-
hasUncommittedUpdates
public boolean hasUncommittedUpdates()
- Since:
- Available in iOS 11.0 and later.
-
getNumberOfSections
public long getNumberOfSections()
-
getVisibleCells
public NSArray<UICollectionViewCell> getVisibleCells()
-
getIndexPathsForVisibleItems
public NSArray<NSIndexPath> getIndexPathsForVisibleItems()
-
remembersLastFocusedIndexPath
public boolean remembersLastFocusedIndexPath()
- Since:
- Available in iOS 9.0 and later.
-
setRemembersLastFocusedIndexPath
public void setRemembersLastFocusedIndexPath(boolean v)
- Since:
- Available in iOS 9.0 and later.
-
hasActiveDrag
public boolean hasActiveDrag()
- Since:
- Available in iOS 11.0 and later.
-
hasActiveDrop
public boolean hasActiveDrop()
- Since:
- Available in iOS 11.0 and later.
-
isSpringLoaded
public boolean isSpringLoaded()
- Specified by:
isSpringLoaded
in interfaceUISpringLoadedInteractionSupporting
- Since:
- Available in iOS 11.0 and later.
-
setSpringLoaded
public void setSpringLoaded(boolean v)
- Specified by:
setSpringLoaded
in interfaceUISpringLoadedInteractionSupporting
- Since:
- Available in iOS 11.0 and later.
-
setModel
public void setModel(UICollectionViewModel model)
-
getModel
public UICollectionViewModel getModel()
-
init
protected long init(CGRect frame, UICollectionViewLayout layout)
-
registerReusableCellClass
public void registerReusableCellClass(java.lang.Class<? extends UICollectionViewCell> cellClass, java.lang.String identifier)
-
registerReusableCellNib
public void registerReusableCellNib(UINib nib, java.lang.String identifier)
-
registerReusableSupplementaryViewClass
public void registerReusableSupplementaryViewClass(java.lang.Class<? extends UICollectionReusableView> viewClass, UICollectionElementKind elementKind, java.lang.String identifier)
-
registerReusableSupplementaryViewNib
public void registerReusableSupplementaryViewNib(UINib nib, UICollectionElementKind kind, java.lang.String identifier)
-
dequeueReusableCell
public UICollectionReusableView dequeueReusableCell(java.lang.String identifier, NSIndexPath indexPath)
-
dequeueReusableSupplementaryView
public UICollectionReusableView dequeueReusableSupplementaryView(UICollectionElementKind elementKind, java.lang.String identifier, NSIndexPath indexPath)
-
selectItem
public void selectItem(NSIndexPath indexPath, boolean animated, UICollectionViewScrollPosition scrollPosition)
-
deselectItem
public void deselectItem(NSIndexPath indexPath, boolean animated)
-
reloadData
public void reloadData()
-
setCollectionViewLayout
public void setCollectionViewLayout(UICollectionViewLayout layout, boolean animated)
-
setCollectionViewLayout
public void setCollectionViewLayout(UICollectionViewLayout layout, boolean animated, org.robovm.objc.block.VoidBooleanBlock completion)
- Since:
- Available in iOS 7.0 and later.
-
startInteractiveTransition
public UICollectionViewTransitionLayout startInteractiveTransition(UICollectionViewLayout layout, org.robovm.objc.block.VoidBlock2<java.lang.Boolean,java.lang.Boolean> completion)
- Since:
- Available in iOS 7.0 and later.
-
finishInteractiveTransition
public void finishInteractiveTransition()
- Since:
- Available in iOS 7.0 and later.
-
cancelInteractiveTransition
public void cancelInteractiveTransition()
- Since:
- Available in iOS 7.0 and later.
-
getNumberOfItemsInSection
public long getNumberOfItemsInSection(long section)
-
getLayoutAttributesForItem
public UICollectionViewLayoutAttributes getLayoutAttributesForItem(NSIndexPath indexPath)
-
getLayoutAttributesForSupplementaryElement
public UICollectionViewLayoutAttributes getLayoutAttributesForSupplementaryElement(UICollectionElementKind kind, NSIndexPath indexPath)
-
getIndexPathForItem
public NSIndexPath getIndexPathForItem(CGPoint point)
-
getIndexPathForCell
public NSIndexPath getIndexPathForCell(UICollectionViewCell cell)
-
getCellForItem
public UICollectionViewCell getCellForItem(NSIndexPath indexPath)
-
getSupplementaryView
public UICollectionReusableView getSupplementaryView(java.lang.String elementKind, NSIndexPath indexPath)
- Since:
- Available in iOS 9.0 and later.
-
getVisibleSupplementaryViews
public NSArray<UICollectionReusableView> getVisibleSupplementaryViews(java.lang.String elementKind)
- Since:
- Available in iOS 9.0 and later.
-
getIndexPathsForVisibleSupplementaryElements
public NSArray<NSIndexPath> getIndexPathsForVisibleSupplementaryElements(java.lang.String elementKind)
- Since:
- Available in iOS 9.0 and later.
-
scrollToItem
public void scrollToItem(NSIndexPath indexPath, UICollectionViewScrollPosition scrollPosition, boolean animated)
-
insertSections
public void insertSections(NSIndexSet sections)
-
deleteSections
public void deleteSections(NSIndexSet sections)
-
reloadSections
public void reloadSections(NSIndexSet sections)
-
moveSection
public void moveSection(long section, long newSection)
-
insertItems
public void insertItems(NSArray<NSIndexPath> indexPaths)
-
deleteItems
public void deleteItems(NSArray<NSIndexPath> indexPaths)
-
reloadItems
public void reloadItems(NSArray<NSIndexPath> indexPaths)
-
moveItem
public void moveItem(NSIndexPath indexPath, NSIndexPath newIndexPath)
-
performBatchUpdates
public void performBatchUpdates(java.lang.Runnable updates, org.robovm.objc.block.VoidBooleanBlock completion)
-
beginInteractiveMovement
public boolean beginInteractiveMovement(NSIndexPath indexPath)
- Since:
- Available in iOS 9.0 and later.
-
updateInteractiveMovement
public void updateInteractiveMovement(CGPoint targetPosition)
- Since:
- Available in iOS 9.0 and later.
-
endInteractiveMovement
public void endInteractiveMovement()
- Since:
- Available in iOS 9.0 and later.
-
cancelInteractiveMovement
public void cancelInteractiveMovement()
- Since:
- Available in iOS 9.0 and later.
-
presentationSectionIndexForDataSourceSectionIndex
public long presentationSectionIndexForDataSourceSectionIndex(long dataSourceSectionIndex)
- Specified by:
presentationSectionIndexForDataSourceSectionIndex
in interfaceUIDataSourceTranslating
-
dataSourceSectionIndexForPresentationSectionIndex
public long dataSourceSectionIndexForPresentationSectionIndex(long presentationSectionIndex)
- Specified by:
dataSourceSectionIndexForPresentationSectionIndex
in interfaceUIDataSourceTranslating
-
presentationIndexPathForDataSourceIndexPath
public NSIndexPath presentationIndexPathForDataSourceIndexPath(NSIndexPath dataSourceIndexPath)
- Specified by:
presentationIndexPathForDataSourceIndexPath
in interfaceUIDataSourceTranslating
-
dataSourceIndexPathForPresentationIndexPath
public NSIndexPath dataSourceIndexPathForPresentationIndexPath(NSIndexPath presentationIndexPath)
- Specified by:
dataSourceIndexPathForPresentationIndexPath
in interfaceUIDataSourceTranslating
-
performUsingPresentationValues
public void performUsingPresentationValues(java.lang.Runnable actionsToTranslate)
- Specified by:
performUsingPresentationValues
in interfaceUIDataSourceTranslating
-
-