Last active
August 7, 2020 22:37
-
-
Save ankitvijay/92a351ac0c4056858ef844feec7ae6f9 to your computer and use it in GitHub Desktop.
Part 5 - Inheritance Example 1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public abstract class StatesPaymentType : PaymentType | |
{ | |
public static readonly PaymentType Bitcoin = new BitCoinType(); | |
private class BitCoinType : PaymentType | |
{ | |
public BitCoinType() : base(3, "Bitcoin") | |
{ | |
} | |
public override string Code => "BT"; | |
} | |
protected StatesPaymentType(int value, string name = null) : base(value, name) | |
{ | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment