Panels - How d you know if a Panel is docked or floating?

Hello,
How can you know programatically if a panel is docked somewhere or if it is floating?
Thank you!