diff options
author | Gonzalo Paniagua Javier <gonzalo.mono@gmail.com> | 2003-03-04 23:27:43 +0300 |
---|---|---|
committer | Gonzalo Paniagua Javier <gonzalo.mono@gmail.com> | 2003-03-04 23:27:43 +0300 |
commit | a05736ef430c6250f017ab0871619f45cee1f5c6 (patch) | |
tree | ba5e36e65ab8a182b3782254290906af9d26cb75 /mcs/class/System/System.ComponentModel | |
parent | 44d61c55f92708f155914d2ac1236e1222607776 (diff) |
2003-03-04 Gonzalo Paniagua Javier <gonzalo@ximian.com>
* list.unix: added RunInstallerAttribute.cs
* System.ComponentModel/RunInstallerAttribute.cs: New file.
svn path=/trunk/mcs/; revision=12193
Diffstat (limited to 'mcs/class/System/System.ComponentModel')
-rw-r--r-- | mcs/class/System/System.ComponentModel/ChangeLog | 4 | ||||
-rwxr-xr-x | mcs/class/System/System.ComponentModel/RunInstallerAttribute.cs | 52 |
2 files changed, 56 insertions, 0 deletions
diff --git a/mcs/class/System/System.ComponentModel/ChangeLog b/mcs/class/System/System.ComponentModel/ChangeLog index 36eead61461..367bb1452c2 100644 --- a/mcs/class/System/System.ComponentModel/ChangeLog +++ b/mcs/class/System/System.ComponentModel/ChangeLog @@ -1,3 +1,7 @@ +2003-03-04 Gonzalo Paniagua Javier <gonzalo@ximian.com> + + * RunInstallerAttribute.cs: New file. + 2003-02-06 Gonzalo Paniagua Javier <gonzalo@ximian.com> * Win32Exception.cs: added 10065 (WSA_EHOSTUNREACH). diff --git a/mcs/class/System/System.ComponentModel/RunInstallerAttribute.cs b/mcs/class/System/System.ComponentModel/RunInstallerAttribute.cs new file mode 100755 index 00000000000..4d1c0f1f71d --- /dev/null +++ b/mcs/class/System/System.ComponentModel/RunInstallerAttribute.cs @@ -0,0 +1,52 @@ +// +// System.ComponentModel.RunInstallerAttribute +// +// Authors: +// Gonzalo Paniagua Javier (gonzalo@ximian.com) +// +// (C) 2003 Ximian, Inc (http://www.ximian.com) +// + +using System; + +namespace System.ComponentModel +{ + [AttributeUsageAttribute(AttributeTargets.Class)] + public class RunInstallerAttribute : Attribute + { + public static readonly RunInstallerAttribute Yes = new RunInstallerAttribute (true); + public static readonly RunInstallerAttribute No = new RunInstallerAttribute (false); + public static readonly RunInstallerAttribute Default = new RunInstallerAttribute (false); + + private bool runInstaller; + + public RunInstallerAttribute (bool runInstaller) + { + this.runInstaller = runInstaller; + } + + public override bool Equals (object obj) + { + if (!(obj is RunInstallerAttribute)) + return false; + + return (((RunInstallerAttribute) obj).runInstaller == runInstaller); + } + + public override int GetHashCode () + { + return base.GetHashCode (); + } + + public override bool IsDefaultAttribute () + { + return (runInstaller == false); // false is the Default + } + + public bool RunInstaller + { + get { return runInstaller; } + } + } +} + |