Most of the roof-mount billboards you see are from a bygone era, and have not been legally allowed to be built in decades. One of the earliest forms of outdoor were building these one-of-a-kind structures out of angle iron on top of buildings. Most cities later outlawed them due to fire safety – if the building burns the billboard collapses through the roof and normally takes out everything on the way down. In Dallas, for example, they had to once let a three-story office building burn to the ground because the fire marshal would not let the firemen go inside because the roof-mount billboard might come crashing down and kill everyone. Most of these are grandfathered.
That being said, you can still buy or take over management of roof-mount billboards. You just can’t normally build any new ones. But it would not hurt to call Stockton’s city hall and ask them if they are illegal or not. Every city’s rules are different, and just because some cities like Dallas ban them does not mean that everybody has.