Animer le défilement de UIScrollView avec CoreAnimation

Désolé pour une grande question, la vraie question sont gras en bas, maintenant quelques explications.

Je suis l'utiliser CoreAnimation dans mon projet pour animer des objets en mouvement de ce genre.

CABasicAnimation *moveAnimation;        
moveAnimation=[CABasicAnimation animationWithKeyPath:@"position"];      
moveAnimation.duration = 2.0;       
moveAnimation.repeatCount=1;        
moveAnimation.autoreverses=NO;  
moveAnimation.delegate = self;
moveAnimation.fromValue = [NSValue valueWithCGPoint:[crawler.layer position]];
moveAnimation.fillMode = kCAFillModeForwards;
moveAnimation.removedOnCompletion = NO;
CGPoint p;
moveAnimation.toValue = [NSValue valueWithCGPoint:CGPointMake(100, 100)];
[crawler.layer addAnimation:moveAnimation forKey:@"moveAnimation"];

Et maintenant, j'ai besoin d'animer le défilement de certains UIScrollView. Je ne peux pas utiliser setContentOffset:(CGPoint)contentOffset animated:(BOOL)animated méthode, car il ne peut pas personnaliser l'animation durée.

Je peux le faire comme ça

CGContextRef context = UIGraphicsGetCurrentContext();
[UIView beginAnimations:nil context:context];
[UIView setAnimationCurve:UIViewAnimationCurveLinear];
[UIView setAnimationDuration:2];
[UIView setAnimationDelegate:self];
scrollView.contentOffset = CGPointMake(scrollView.contentOffset.x + 200, scrollView.contentOffset.y);
[UIView commitAnimations];

mais ce n'est pas CoreAnimation, et à l'aide de 2 différents types de techniques d'animation dans une application n'est pas une bonne pratique, je pense.

Est-il un moyen d'utiliser un CoreAnimation pour animer le défilement de UIScrollView contenu de points personnalisés avec animation personnalisée durée?
P. S. Désolé pour le mauvais anglais.

source d'informationauteur Padavan