getComponent method : VerticalLayout

I have a VerticalLayout. I am not able to use getComponent or getComponentCount, and getComponentIndex methods on it. I get method undefined message when I use them. I saw in the VerticalLayout api that those methods are inherited from AbstractOrderedLayout. Am i missing something?

Sounds like you have two different versions of a Vaadin jar in classpath.