/// <summary> /// Create proper typed Account from OFX object /// </summary> /// <param name="ofxAccount">OFX BankAccount object</param> /// <returns></returns> public new static Account Create(Protocol.BankAccount ofxAccount) { // Route to proper constructor if (ofxAccount.ACCTTYPE == AccountEnum.SAVINGS) { return(new SavingsAccount(ofxAccount)); } return(new CheckingAccount(ofxAccount)); }
/// <summary> /// Internal constructor so derived classes can have alternate constructors /// </summary> protected BankAccount(Protocol.BankAccount ofxAccount) : base("", true, ofxAccount.ACCTID) { RoutingId = ofxAccount.BANKID; //AccountId = ofxAccount.ACCTID; }
public CheckingAccount(Protocol.BankAccount ofxAccount) : base(ofxAccount) { // Stub - ensures the type is correct even though no extra content from parent }
/// <summary> /// Create proper typed Account from OFX object /// </summary> /// <param name="ofxAccount">OFX BankAccount object</param> /// <returns></returns> public static Account Create(Protocol.BankAccount ofxAccount) { return(BankAccount.Create(ofxAccount)); }