LogicBuilder.Attributes
2.0.6
Prefix Reserved
dotnet add package LogicBuilder.Attributes --version 2.0.6
NuGet\Install-Package LogicBuilder.Attributes -Version 2.0.6
<PackageReference Include="LogicBuilder.Attributes" Version="2.0.6" />
<PackageVersion Include="LogicBuilder.Attributes" Version="2.0.6" />
<PackageReference Include="LogicBuilder.Attributes" />
paket add LogicBuilder.Attributes --version 2.0.6
#r "nuget: LogicBuilder.Attributes, 2.0.6"
#:package LogicBuilder.Attributes@2.0.6
#addin nuget:?package=LogicBuilder.Attributes&version=2.0.6
#tool nuget:?package=LogicBuilder.Attributes&version=2.0.6
LogicBuilder.Attributes
LogicBuilder.Attributes is a .NET Standard 2.0 library that provides declarative attributes for automatic configuration of methods, fields, properties, and constructor parameters in LogicBuilder applications.
Overview
This library enables developers to annotate their C# code with metadata that LogicBuilder uses to dynamically generate client-side and server-side workflows. By applying these attributes to your domain model, you can control how properties, methods, and parameters are presented and validated in the LogicBuilder visual designer.
Installation
dotnet add package LogicBuilder.Attributes
Attributes
CommentsAttribute
Provides descriptive comments for variables that appear in the LogicBuilder designer.
Applies to: Fields, Properties, Parameters
[Comments("User's email address for notifications")] public string Email { get; set; }
ControlAttribute
Defines the UI control to be used in the business application for a field or property.
Applies to: Fields, Properties
[Control("EmailInput")] public string Email { get; set; }
DomainAttribute
Specifies a comma-delimited list of valid values for a field, property, or parameter.
Applies to: Fields, Properties, Parameters
[Domain("Active,Inactive,Pending")] public string Status { get; set; }
ErrorMessageAttribute
Configures a generic error message for field or property validation.
Applies to: Fields, Properties
[ErrorMessage("Email address is required")] public string Email { get; set; }
FunctionGroupAttribute
Categorizes methods into functional groups within LogicBuilder.
Applies to: Methods
Values: FunctionGroup.Standard, FunctionGroup.DialogForm
[FunctionGroup(FunctionGroup.Standard)] public void ProcessOrder(Order order) { }
ListEditorControlAttribute
Specifies the control type for editing list parameters in LogicBuilder.
Applies to: Parameters, Fields, Properties
Values: ListControlType.ListForm, ListControlType.HashSetForm, ListControlType.Connectors
[ListEditorControl(ListControlType.HashSetForm)] public HashSet<string> Tags { get; set; }
ParameterEditorControlAttribute
Defines the editor control for method parameters in LogicBuilder.
Applies to: Parameters
Values:
ParameterControlType.SingleLineTextBoxParameterControlType.MultipleLineTextBoxParameterControlType.DropDownParameterControlType.TypeAutoCompleteParameterControlType.DomainAutoCompleteParameterControlType.PropertyInputParameterControlType.ParameterSourcedPropertyInputParameterControlType.ParameterSourceOnlyParameterControlType.Form
public void UpdateProfile([ParameterEditorControl(ParameterControlType.MultipleLineTextBox)] string bio) { }
VariableEditorControlAttribute
Specifies the editor control for fields and properties in LogicBuilder.
Applies to: Fields, Properties
Values:
VariableControlType.SingleLineTextBoxVariableControlType.MultipleLineTextBoxVariableControlType.DropDownVariableControlType.TypeAutoCompleteVariableControlType.DomainAutoCompleteVariableControlType.PropertyInputVariableControlType.Form
[VariableEditorControl(VariableControlType.DropDown)] [Domain("Small,Medium,Large")] public string Size { get; set; }
NameValueAttribute
Defines additional custom name-value pairs for fields, properties, or parameters. This attribute can be applied multiple times.
Applies to: Fields, Properties, Parameters
[NameValue("MinLength", "5")] [NameValue("MaxLength", "100")] public string Username { get; set; }
Example Usage
using LogicBuilder.Attributes;
public class User { [Comments("Unique identifier for the user")] [VariableEditorControl(VariableControlType.SingleLineTextBox)] public string UserId { get; set; }
[Comments("User's email address")]
[ErrorMessage("A valid email address is required")]
[VariableEditorControl(VariableControlType.SingleLineTextBox)]
[NameValue("ValidationPattern", "^[^@]+@[^@]+\\.[^@]+$")]
public string Email { get; set; }
[Comments("Current account status")]
[Domain("Active,Inactive,Suspended")]
[VariableEditorControl(VariableControlType.DropDown)]
public string Status { get; set; }
[FunctionGroup(FunctionGroup.Standard)]
public void ActivateAccount(
[Comments("Activation code sent to user")]
[ParameterEditorControl(ParameterControlType.SingleLineTextBox)]
string activationCode)
{
// Implementation
}
}
Target Framework
- .NET Standard 2.0
Related Projects
- LogicBuilder - The visual workflow designer that consumes these attributes
Contributing
Contributions are welcome!
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Refactoring to accelerate DevOps.