Actual code for this Command is under Microsoft.SharePoint.Powershell.dll and I used "ILSpy" to see the code under these command. which is this.
using Microsoft.SharePoint.Administration;
using Microsoft.SharePoint.PowerShell.Resources;
using System;
using System.Management.Automation;
namespace Microsoft.SharePoint.PowerShell
{
[Cmdlet("Move", "SPUser", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.High)]
internal sealed class SPCmdletMoveUser : SPCmdlet
{
private SPUserPipeBind m_UserPipeBind;
private SPUser m_User;
private string m_OldAlias;
private string m_NewAlias;
private SwitchParameter m_IgnoreSid;
[Alias(new string[]
{
"UserAlias"
}), Parameter(Mandatory = true, ValueFromPipeline = true, Position = 0), ValidateNotNull]
public SPUserPipeBind Identity
{
get
{
return this.m_UserPipeBind;
}
set
{
this.m_UserPipeBind = value;
}
}
[Parameter(Mandatory = true), ValidateNotNullOrEmpty]
public string NewAlias
{
get
{
return this.m_NewAlias;
}
set
{
this.m_NewAlias = value;
}
}
[Parameter(Mandatory = false)]
public SwitchParameter IgnoreSID
{
get
{
return this.m_IgnoreSid;
}
set
{
this.m_IgnoreSid = value;
}
}
protected override string ConfirmationMessage
{
get
{
if (this.m_User == null)
{
return this.m_OldAlias;
}
return this.m_User.ToString();
}
}
protected override void InternalValidate()
{
if (this.Identity != null)
{
this.m_User = this.Identity.Read();
this.m_OldAlias = ((this.m_User != null) ? this.m_User.LoginName : this.Identity.RawIdentity);
}
if (string.IsNullOrEmpty(this.m_OldAlias))
{
base.WriteError(new PSArgumentNullException("Identity", StringResourceManager.GetResourceString("SPUserPipeBindRequired", new object[0])), ErrorCategory.InvalidArgument, null);
base.SkipProcessCurrentRecord();
}
}
protected override void InternalProcessRecord()
{
SPFarm localOrThrow = SPFarm.LocalOrThrow;
localOrThrow.MigrateUserAccount(this.m_OldAlias, this.NewAlias, !this.IgnoreSID.IsPresent);
}
}
}