XT.Common 1.1.1

There is a newer version of this package available.
See the version list below for details.
dotnet add package XT.Common --version 1.1.1
NuGet\Install-Package XT.Common -Version 1.1.1
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="XT.Common" Version="1.1.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add XT.Common --version 1.1.1
#r "nuget: XT.Common, 1.1.1"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install XT.Common as a Cake Addin
#addin nuget:?package=XT.Common&version=1.1.1

// Install XT.Common as a Cake Tool
#tool nuget:?package=XT.Common&version=1.1.1

XT.Common

1、介绍

通用程序集,只能添加通用的方法,不要引入第三方pack。

 // nuget删除包
 dotnet nuget delete GeneralCommon 1.0.7 -k oy2oxtcszfkgceqkhvhazt62skfg5dmuncd47jb3pzs4ca -s https://api.nuget.org/v3/index.json

 // nuget推送包
dotnet nuget push GeneralCommon.1.0.7.nupkg -k oy2oxtcszfkgceqkhvhazt62skfg5dmuncd47jb3pzs4ca -s https://api.nuget.org/v3/index.json

2、功能

2.1、AppSettings配置

  • new()初始化,GetObjData<T>()获取对象配置

2.2、特性

  • Page,页面特性,Blazor自动生成页面菜单,用法 用法:Page("/ecs/floor1", "一楼", "mdi-home-floor-1", true)
  • Order,排序特性,用于属性排序

2.3、雪花id生成器

  • 初始化 new IdHelperBootstrapper().SetWorkderId(1).Boot();
  • IdHelper.getId()

2.4、Utils工具

  • ComputerUtil 获取计算机内存cpu等信息。
  • DateTimeUtil 获取星期几等

2.5、Serivce辅助

  • ApiConfigService 使用要求: AddOriginHttpClient注册http服务
  • TimerService 封装定时器

2.6、枚举

  • Sql 分类

2.7、Extension扩展方法

  • Action 封装try catch,Get|Post HttpData,AddServiceInjects注入服务。
  • Byte byte[] 转 ushort[],SetBit设置某个偏移位置的BIT值
  • Enumerable 集合操作
  • Enum 枚举操作
  • Sql sql模板替换
  • Type 反射
  • Xml xml操作
Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (5)

Showing the top 5 NuGet packages that depend on XT.Common:

Package Downloads
XT.Sql

1、使用前需要添加配置,配置对象为 XTDbConfig (支持多库切换) 2、使用时要初始化 , Services.AddSingleton(new AppSettings(builder.Environment.IsDevelopment())); Services.AddXTDbSetup(); 3、使用方式 - 注入XTDbContext,通过SimpleClient来进行操作 - 继承ISugarHandler public interface IPatCellRepository: ISugarHandler<PatCell>, IDependencyRepository { } - 继承SugarHandler public class PatCellRepository : SugarHandler<PatCell>, IPatCellRepository { public PatCellRepository(IUnitOfWork unitOfWork) : base(unitOfWork) { } } 4、数据库连接串 Oracle: DATA SOURCE=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.0.1)(PORT=21)))(CONNECT_DATA=(SERVICE_NAME=XX)));USER ID=XX;Password=XX PostgreSql: Host=192.168.0.1 Port=20; Database=XX; Username=XX; Password=XX; Sqlite DataSource=./test.db

EVE.ECS_Model

Model for System

XT.FeSql

Package Description

XT.WinService

1、添加windows服务 ShareService.AddWinService() 注意:必须集成TimerService或者实现IWindowService接口,必须实现ILogService 使用方式: IServiceProvider.RunWinService(new ServiceInfo { Name = client?.Name, DisplayName = client?.Name, Description = client?.Description })); 2、添加Log4net ShareService.ConfigureLog4net(); LogService中获取Log: log = log4net.LogManager.GetLogger("loginfo"); logError = log4net.LogManager.GetLogger("logerror");

AvaloniaXT

Avalonia App Page Helper Dll , Contains MainWindow,SukiUI,Support AOT

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.1.6 119 4/15/2024
1.1.5 103 3/8/2024
1.1.4 221 12/19/2023
1.1.3 107 12/19/2023
1.1.2 240 12/19/2023
1.1.1 128 11/28/2023
1.1.0 221 11/21/2023