www.pudn.com > Wcell.rar > ConsoleCommandAttribute.cs


/************************************************************************* 
 * 
 *   file		: ConsoleCommandAttribute.cs 
 *   copyright		: (C) The WCell Team 
 *   email		: info@wcell.org 
 *   last changed	: $LastChangedDate: 2008-03-10 08:52:03 +0800 (星期一, 10 三月 2008) $ 
 *   last author	: $LastChangedBy: tobz $ 
 *   revision		: $Rev: 190 $ 
 * 
 *   This program is free software; you can redistribute it and/or modify 
 *   it under the terms of the GNU General Public License as published by 
 *   the Free Software Foundation; either version 2 of the License, or 
 *   (at your option) any later version. 
 * 
 *************************************************************************/ 
 
using System; 
 
namespace WCell.AuthServerConsole.Commands 
{ 
    ///  
    /// Identifies a method that represents a console command 
    ///  
    [AttributeUsage(AttributeTargets.Method, AllowMultiple = true, Inherited = false)] 
    public class ConsoleCommandAttribute : Attribute 
    { 
        private string m_commandString; 
 
        ///  
        /// Default constructor 
        ///  
        /// the command this method represents 
        public ConsoleCommandAttribute(string command) 
        { 
            m_commandString = command; 
        } 
 
        ///  
        /// The command this method represents 
        ///  
        public string CommandString 
        { 
            get { return m_commandString; } 
        } 
    } 
}