Android provides various types of animations that can apply to a Imageview. The one that applies in your case is Rotateanimation.
Its use is done in 3 steps:
1 - Create an object of type Rotateanimation
//Cria uma animação de rotação desde de 0º a 360º com o eixo de rotação no centro da imagem.
RotateAnimation animation = new RotateAnimation(0f, 360f,
Animation.RELATIVE_TO_SELF, 0.5f,
Animation.RELATIVE_TO_SELF, 0.5f);
2 - Define animation properties.
// 3 segundos.
long tempo = 3000;
//Define que a animação se processa de forma linear
animation.setInterpolator(new LinearInterpolator());
//Define o tempo da animação
animation.setDuration(tempo);
3 - Start it.
imageView.startAnimation(animation);
I did it , but using an XML file , and there I configured it that you typed , but in the java class I used an Animation Object, I used the Load method, and I linked with the XML I created
– Joab