That may be, M, but if so I'd have expected a somber, not a tragicomic (or wholly comic) song. And the meaning would have been explicitly stated. That's just how pop culture worked in the nineteenth century.
Steve is right about lowbrow period humor. We know, for example, that disabled veterans of the Civil War in an old soldier's home in the 1870s thought "Johnny, I Hardly Knew Ye" was hilarious.
The word has also been out for at least forty years that "Casablanca" is really an allegory of U.S. isolationism, and that Frost's "Stopping by Woods" is actually an allegory of Santa Claus.