In my opinion, the floating junction box would be a violation of 370-23. I don't see anything in this article that would allow the box to be supported by cable. This is the same article that bans homemade extension cords that use (un)handy boxes or 4x4 boxes or just about any other common box with a receptacle installed in them.
Before the days of the inexpensive circuit tracer, a customer paid me about $200 to find a loose connection in one of these boxes. I admit I'm slow on the uptake sometimes, but it took awhile for me to understand that someone would perpetrate such a dastardly deed.
Tom