WorksWithAttribute
Namespace: Wisej.AI
Assembly: Wisej.AI
Represents an attribute that specifies the compatibility of a SmartAdapter with a SmartEndpoint.
- C#
- VB.NET
public class WorksWithAttribute : Attribute
Public Class WorksWithAttribute
Inherits Attribute
This attribute is used to indicate that a SmartAdapter works with a specific SmartEndpoint. It can be applied multiple times to specify compatibility with different SmartEndpoint types.
Constructors
WorksWithAttribute(type, allowed)
Initializes a new instance of the WorksWithAttribute class with the specified type and allowed status.
| Name | Type | Description |
|---|---|---|
| type | Type | The type that the class works with. Must be a subclass of SmartEndpoint. |
| allowed | Boolean | Indicates whether the type is allowed. Default is true. |
Throws:
- ArgumentNullException
Thrown when the type is
null. - ArgumentException Thrown when the type is not a subclass of SmartEndpoint.
WorksWithAttribute(type, allowed)
Initializes a new instance of the WorksWithAttribute class with the specified type name and allowed status.
| Name | Type | Description |
|---|---|---|
| type | String | The name of the type that the class works with. Must be a subclass of SmartEndpoint. |
| allowed | Boolean | Indicates whether the type is allowed. Default is true. |
Throws:
- ArgumentNullException
Thrown when the type is
null. - ArgumentException Thrown when the type is not a subclass of SmartEndpoint.
Properties
Allowed
Boolean: Gets a value indicating whether the SmartEndpoint is allowed.
Type
Type: Gets the SmartEndpoint that the attribute allows or disallows.
TypeName
String: Gets the type name of the SmartEndpoint that the attribute allows or disallows.