This transformer would be a flyback transformer therefore doesn't need to be driven by anything so hard-to-generate as a sine wave. It can be driven by a "switch" (MOSFET) at it's primary which is connected to DC.
All switching power supplies (hence the name) are driven by either full-on or full-off ("switching") transistors. A "flyback" topology is only one of many possible ways to build a switching power supply, but as it's the simplest, it's the most common in low power supplies.
See the Switch−Mode Power Supply Reference Manual from ON Semiconductor for info on all the other possible ways to build a switching power supply.
https://en.wikipedia.org/wiki/Flyback_transformer#Operation_...