You know why we don't have battery-powered trains? It's because having battery-powered trains would be a silly idea. When you have something that just goes from point A to point B over and over, it makes more sense to make electricity available over the entire stretch, and Siemens is going to try that idea out with trucks on highways.
If you think about it, cargo trucks are quite a lot like trains, in that they make many repetitive trips between a small set of destinations. Buses are also a good example of this: they follow pre-defined routes over and over. In the long term, it costs a huge amount of fuel to keep this up, which is why commuter trains, subways, and many metro bus systems instead rely on a centralized power source that sends fuel out through wires in the form of electricity.
There are lots of different advantages to distributing energy like this: you only have to worry about one "engine." The vehicle themselves are cheaper to produce and easier to maintain. They're also more efficient, since they're not lugging either fuel tanks or batteries around with them all the time. It's good for you (you save money) and good for the environment, with the added bonus that it's easy to transition between energy sources (oil, solar, wind, or whatever).
The downside, of course, is that setting up a distributed electrical system from scratch is a huge infrastructure investment, but Siemens thinks that it might make sense to do on specific stretches of highway, and they're going to test it out in California. Trucks would be outfitted with pantographs (the same thing that high-speed trains use to connect to overhead wires), and they'd be able to use them to connect to overhead power wires automatically. Once the connection is made, an electric motor in the truck seamlessly takes over from the truck's diesel engine, and the two power sources can switch back and forth if the truck needs to switch lanes for some reason. There are no batteries in the truck itself, but it can still brake regeneratively and send power back into the system to be used by other vehicles.
Siemens already has a system in the works over in Germany, and it's planning another test system in Long Beach along a relatively short but heavily traveled routes. It's not going to be cheap, but even if drivers themselves have to pay for the system over time, it seems likely that the money they'll save on fuel will more than offset any usage tolls.