public sealed class MyConsole
    {
        private readonly Indexable<int, ConsoleColor> _standardColors = new Indexable<int, ConsoleColor>(i => ConsoleColor.Blue);
        public Indexable<int, ConsoleColor> StandardColors
        {
            get
            {
                return _standardColors;
            }
        }
    }

    class Program
    {
        static void Main(string[] args) 
        { 
            var console = new MyConsole();
            var color = console.StandardColors[10];
        }
    }

Last edited Jan 5, 2012 at 9:37 PM by ananth, version 1

Comments

No comments yet.