PWM controls what you want it to control. What is actually controlled depends on the
feedback system, not on PWM itself.
Normally PWM switches a voltage source on and off and that way it controls the
current flowing from the input to the output, but i wouldnt limit it to that type of
operation.
PWM basically interrupts the flow of current so that the output can be controlled
to some preset value.
For signal generation, PWM is used to vary the signal level so that the output
follows the input near perfectly, except for being chopped up which is later
usually filtered.
The difference between PWM and pure analog is that PWM can often be done using
very little power for complex signals whereas analog would consume lots of power.
Amplifiers built using this technique can produce very clean sine waves while using
much less power than an analog circuit would use.
PWM, pulse width modulation, varies the width of the pulse so that the amplitude can
be controlled. When a low level signal is to be output, a very short pulse width is
generated, but when a high level signal is to be output, a comparatively long pulse width
is generated. The output filter filters these pulses into a smoothly varying wave that
is much like the original input.