public void SupperToChild() { Childer c = new Childer() { SName = "父类", CName = "子类" }; SToC(c); }
public void SupperToChild() { Childer c = new Childer() {SName = "父类", CName = "子类"}; SToC(c); }
private void SToC(Supper s) { Childer c = (Childer)s; Console.WriteLine(c.CName); }