In X and Y, there is a Pokemon named Agislash. He has a signature ability called Stance Change. It has a description that says: "The Pokemon changes form depending on how it battles." What exactly does that mean? Does it swap Offensive Capabilities with Defensive?
Aegislash changes form dependant upon the moves it uses.
If Aegislash uses a King's Shield, or enters the battle, it goes to Shield Forme. Sheild Forme has higher defense and lower attack.
If Aegislash uses a damaging move, it goes to Blade Forme, swapping its base Attack with it's Defense, causing it to have a higher Attack and lower defense.
It's also note-worthy that moves that call other moves do not change Aegislash's form, even if they call a damaging move.
Stance Change is activated independently of sleep or confusion, and will therefore cause a change in stance even in either case. It can also not be traced, copied with Role Play, suppressed with Gastro Acid, or replaced with Simple Beam, Worry Seed, Entrainment, or Skill Swap. Obtaining Stance Change through Imposter on will not allow the other Pokemon to transform.