Shikomizue koshirae is the mounting of a sword blade in a walking cane. The last decade they have been popularized by movies (zatoichi) and many anime series but they are very much part of Japanese sword history - in contradiction to the straight ninjato.
In Japanese history there have been several sword hunts where people were forcefully stripped from their possessions.
Oda Nobunaga initiated the first sword hunt to prevent riots and uprisings among peasants and commoners.
Daggers (tanto and wakizashi) were still allowed but only the samurai class was allowed to wear katana sized swords (and daisho) in public.
Much later, during the Meiji restoration, also samurai weren't allowed to carry any sword in public. Possession was still legal but carrying weaponry (both swords and firearms) was forbidden for all except government officers. Much like the current 'Sword and Firearms Law' in many countries these days.
Needless to say, in each of these periods, these restricting actions caused many people to become inventive and the shikomizue is a great example of their discontent.
Below an image I saved some time ago of a yari in shikomizue koshirae. Cool huh?
Another interesting article is written by the folks at UniqueJapan: