ViewType Provider

It is a procedure that is executed before the ViewProvider, it is in charge of informing it what types of visible objects (or view types) it is going to create. In previous lessons it was not shown because by default the component already has an implementation of this procedure and sends the same viewType parameter to the ViewProvider. The developer can implement his own procedure when it is needed to create different types of visible objects.
The image above shows two examples of the use of the ViewTypeProvider procedure.
The procedure must return view types, they are numbers that will identify each one.