Changeset 2504 for branches/PluginInfrastructure Refactoring/HeuristicLab.PluginInfrastructure/Attributes/ApplicationAttribute.cs
- Timestamp:
- 11/18/09 18:33:30 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/PluginInfrastructure Refactoring/HeuristicLab.PluginInfrastructure/Attributes/ApplicationAttribute.cs
r2488 r2504 27 27 /// <summary> 28 28 /// This attribute can be used to specify meta data for applications. 29 /// For example to specify name , versionand description of applications.29 /// For example to specify name and description of applications. 30 30 /// </summary> 31 31 [AttributeUsage(AttributeTargets.Class)] 32 public class ApplicationAttribute : System.Attribute {32 public sealed class ApplicationAttribute : System.Attribute { 33 33 private string name; 34 34 /// <summary> 35 /// Gets or setsthe name of the application.35 /// Gets the name of the application. 36 36 /// </summary> 37 37 public string Name { 38 38 get { return name; } 39 set { name = value; }40 39 } 41 42 //private string version;43 ///// <summary>44 ///// Gets or sets the version of the application.45 ///// </summary>46 //public string Version {47 // get { return version; }48 // set { version = value; }49 //}50 40 51 41 private string description; 52 42 /// <summary> 53 /// Gets or setsthe description of the application.43 /// Gets the description of the application. 54 44 /// </summary> 55 45 public string Description { 56 46 get { return description; } 57 set { description = value; }58 47 } 59 48 60 49 private bool restartOnErrors; 61 50 /// <summary> 62 /// Gets or sets the boolean flagwhether the plugin should be automatically restarted when it is closed because of an exception (for services).51 /// Gets whether the plugin should be automatically restarted when it is closed because of an exception (for services). 63 52 /// </summary> 64 53 public bool RestartOnErrors { 65 54 get { return restartOnErrors; } 66 set { restartOnErrors = value; }67 55 } 68 56 … … 72 60 /// </summary> 73 61 public ApplicationAttribute(string name) 74 : this(name, "") {62 : this(name, String.Empty) { 75 63 } 76 64 … … 84 72 } 85 73 86 ///// <summary>87 ///// Initializes a new instance of <see cref="ApplicationAttribute"/>.88 ///// <param name="name">Name of the application</param>89 ///// <param name="description">Description of the application</param>90 ///// <param name="version">Version string of the application</param>91 ///// </summary>92 //public ApplicationAttribute(string name, string description, string version)93 // : this(name, description, version, false) {94 //}95 96 74 /// <summary> 97 75 /// Initializes a new instance of <see cref="ApplicationAttribute"/>. … … 102 80 /// </summary> 103 81 public ApplicationAttribute(string name, string description, bool restartOnErrors) { 82 if (name == null) throw new ArgumentNullException("name", "Application name is null."); 83 if (description == null) throw new ArgumentNullException("description", "Application description is null."); 104 84 this.name = name; 105 85 this.description = description;
Note: See TracChangeset
for help on using the changeset viewer.