Determines whether an instance of a specified type can be assigned to an instance of the current type. The type to compare with the current type. true if any of the following conditions is true: and the current instance represent the same type. is derived either directly or indirectly from the
(ScriptType c)
| 1078 | /// <paramref name="c" /> is derived either directly or indirectly from the current instance. <paramref name="c" /> is derived directly from the current instance if it inherits from the current instance; <paramref name="c" /> is derived indirectly from the current instance if it inherits from a succession of one or more classes that inherit from the current instance. The current instance is an interface that <paramref name="c" /> implements. |
| 1079 | /// <c>false</c> if none of these conditions are true, or if <paramref name="c" /> is <see cref="Null"/>.</returns> |
| 1080 | public bool IsAssignableFrom(ScriptType c) |
| 1081 | { |
| 1082 | if (IsInterface) |
| 1083 | return c.HasInterface(this); |
| 1084 | while (c != Null) |
| 1085 | { |
| 1086 | if (c == this) |
| 1087 | return true; |
| 1088 | c = c.BaseType; |
| 1089 | } |
| 1090 | return false; |
| 1091 | } |
| 1092 | |
| 1093 | /// <summary> |
| 1094 | /// Determines whether the specified attribute was defined for this type. |
no test coverage detected