示例#1
0
        /// <summary>
        /// Executes the specified options.
        /// </summary>
        /// <param name="options">The options.</param>
        public override void Execute(Options options)
        {
            var users = UserService.List();

            var table = new TextTable("Name", "Email", "ID");

            table.AddSeperator();

            foreach (var user in users)
            {
                table.AddRow(user.Name, user.Email, user.Id);
            }

            Out.WriteLine(table.ToString());
        }
示例#2
0
        /// <summary>
        /// Executes the specified options.
        /// </summary>
        /// <param name="options">The options.</param>
        public override void Execute(Options options)
        {
            var rooms = RoomService.List();

            var table = new TextTable("Name", "Jabber ID");

            table.AddSeperator();

            foreach (var room in rooms)
            {
                table.AddRow(room.Name, room.JabberId);
            }

            Out.WriteLine(table.ToString());
        }