mirror of
https://gitee.com/langsisi_admin/serein-flow
synced 2026-04-04 23:36:35 +08:00
尝试分离NodeModel与依赖包
This commit is contained in:
@@ -1,8 +1,4 @@
|
||||
using Serein.Flow;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
|
||||
namespace Serein.Flow.NodeModel
|
||||
namespace Serein.Flow.NodeModel
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -1,8 +1,4 @@
|
||||
using Serein.Flow.Tool;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
|
||||
|
||||
namespace Serein.Flow.NodeModel
|
||||
{
|
||||
|
||||
@@ -59,7 +55,7 @@ namespace Serein.Flow.NodeModel
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Debug.Write(ex.Message);
|
||||
Console.WriteLine(ex.Message);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1,10 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Serein.Flow.NodeModel
|
||||
namespace Serein.Flow.NodeModel
|
||||
{
|
||||
public class CompositeLoopNode : NodeBase
|
||||
{
|
||||
|
||||
@@ -1,12 +1,5 @@
|
||||
using Serein.Flow;
|
||||
using Newtonsoft.Json;
|
||||
using Serein.Flow.Tool;
|
||||
using Newtonsoft.Json;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Threading.Tasks;
|
||||
using System.Threading;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace Serein.Flow.NodeModel
|
||||
{
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
using Serein.Flow.Tool;
|
||||
using System.Diagnostics;
|
||||
|
||||
namespace Serein.Flow.NodeModel
|
||||
namespace Serein.Flow.NodeModel
|
||||
{
|
||||
/// <summary>
|
||||
/// 单动作节点(用于动作控件)
|
||||
|
||||
@@ -1,8 +1,4 @@
|
||||
using Serein.Flow.SerinExpression;
|
||||
using Serein.Flow.Tool;
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using System.Linq.Expressions;
|
||||
|
||||
namespace Serein.Flow.NodeModel
|
||||
{
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using Serein.Flow.SerinExpression;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Serein.Flow.NodeModel
|
||||
{
|
||||
|
||||
@@ -1,40 +1,12 @@
|
||||
using Serein.Flow.Tool;
|
||||
|
||||
namespace Serein.Flow.NodeModel
|
||||
namespace Serein.Flow.NodeModel
|
||||
{
|
||||
|
||||
public class SingleFlipflopNode : NodeBase
|
||||
{
|
||||
//public override void Execute(DynamicContext context)
|
||||
//{
|
||||
// throw new NotImplementedException("无法以非await/async的形式调用触发器");
|
||||
//}
|
||||
public override object Execute(DynamicContext context)
|
||||
{
|
||||
throw new NotImplementedException("无法以非await/async的形式调用触发器");
|
||||
}
|
||||
|
||||
//public virtual async Task ExecuteAsync(DynamicContext context, Action NextTask = null)
|
||||
//{
|
||||
// if (DelegateCache.GlobalDicDelegates.TryGetValue(MethodDetails.MethodName, out Delegate? del))
|
||||
// {
|
||||
// object?[]? parameters = GetParameters(context, MethodDetails);
|
||||
|
||||
// // 根据 ExplicitDatas.Length 判断委托类型
|
||||
// var func = (Func<object, object[], Task<FlipflopContext>>)del;
|
||||
|
||||
// // 调用委托并获取结果
|
||||
// FlipflopContext flipflopContext = await func.Invoke(MethodDetails.ActingInstance, parameters);
|
||||
|
||||
// if (flipflopContext != null)
|
||||
// {
|
||||
// if (flipflopContext.State == FfState.Cancel)
|
||||
// {
|
||||
// throw new Exception("取消此异步");
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// CurrentState = flipflopContext.State == FfState.Succeed;
|
||||
// context.SetFlowData(flipflopContext.Data);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,14 +1,6 @@
|
||||
using Serein;
|
||||
using Serein.Flow;
|
||||
using Serein.Flow.NodeModel;
|
||||
using Serein.Library.IOC;
|
||||
using System;
|
||||
using Serein.Library.IOC;
|
||||
using System.Collections.Concurrent;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Serein.Flow.Tool;
|
||||
|
||||
|
||||
@@ -1,13 +1,4 @@
|
||||
using Serein;
|
||||
using System;
|
||||
using System.Collections.Concurrent;
|
||||
using System.Collections.Generic;
|
||||
using System.Drawing.Printing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Serein.Flow.Tool
|
||||
namespace Serein.Flow.Tool
|
||||
{
|
||||
|
||||
#region 锁、tsk工具 (已注释)
|
||||
|
||||
@@ -1,10 +1,6 @@
|
||||
using System;
|
||||
using System.Collections.Concurrent;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Collections.Concurrent;
|
||||
using System.Linq.Expressions;
|
||||
using System.Reflection;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Serein.Flow.Tool
|
||||
{
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Concurrent;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Collections.Concurrent;
|
||||
|
||||
namespace Serein.Flow.Tool
|
||||
{
|
||||
|
||||
@@ -1,43 +0,0 @@
|
||||
using Serein.Flow;
|
||||
using System;
|
||||
using System.Collections.Concurrent;
|
||||
using System.Reflection.Metadata.Ecma335;
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
namespace Serein.Flow.Tool
|
||||
{
|
||||
|
||||
|
||||
/* /// <summary>
|
||||
/// 标记一个方法是什么类型,加载dll后用来拖拽到画布中
|
||||
/// </summary>
|
||||
[AttributeUsage( AttributeTargets.Parameter)]
|
||||
public class ObjDetailAttribute : Attribute
|
||||
{
|
||||
public bool Scan { get; set; }
|
||||
public object @object { get; }
|
||||
public DynamicNodeType MethodDynamicType { get; }
|
||||
|
||||
public ObjDetailAttribute(DynamicNodeType methodDynamicType, object tmpObject = null, bool scan = true)
|
||||
{
|
||||
@object = tmpObject;
|
||||
MethodDynamicType = methodDynamicType;
|
||||
Scan = scan;
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
|
||||
/* /// <summary>
|
||||
/// 状态接口
|
||||
/// </summary>
|
||||
public interface IState: IDynamic
|
||||
{
|
||||
/// <summary>
|
||||
/// 返回状态
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
string GetState(DynamicContext context);
|
||||
}*/
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<TargetFramework>net8.0-windows7.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<BaseOutputPath>D:\Project\C#\DynamicControl\SereinFlow\.Output</BaseOutputPath>
|
||||
@@ -9,8 +9,11 @@
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Compile Remove="Flow\**" />
|
||||
<Compile Remove="obj\**" />
|
||||
<EmbeddedResource Remove="Flow\**" />
|
||||
<EmbeddedResource Remove="obj\**" />
|
||||
<None Remove="Flow\**" />
|
||||
<None Remove="obj\**" />
|
||||
</ItemGroup>
|
||||
|
||||
@@ -22,8 +25,4 @@
|
||||
<PackageReference Include="SqlSugarCore" Version="5.1.4.166" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\LibraryIOC\Serein.Library.IOC.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
||||
Reference in New Issue
Block a user