这篇文章主要围绕Swift中的过滤器和过滤器filter展开,旨在为您提供一份详细的参考资料。我们将全面介绍Swift中的过滤器的优缺点,解答过滤器filter的相关问题,同时也会为您带来Angula
这篇文章主要围绕Swift 中的过滤器和过滤器filter展开,旨在为您提供一份详细的参考资料。我们将全面介绍Swift 中的过滤器的优缺点,解答过滤器filter的相关问题,同时也会为您带来Angular2 中的过滤器、asp.net core 2.2 中的过滤器/筛选器(上)、ASP.NET Core 中的过滤器(Action过滤器,控制器过滤器,全局应用程序过滤器)、AWESOME SWIFT-swift.libhunt.com-swift类库网站的实用方法。
本文目录一览:- Swift 中的过滤器(过滤器filter)
- Angular2 中的过滤器
- asp.net core 2.2 中的过滤器/筛选器(上)
- ASP.NET Core 中的过滤器(Action过滤器,控制器过滤器,全局应用程序过滤器)
- AWESOME SWIFT-swift.libhunt.com-swift类库网站
Swift 中的过滤器(过滤器filter)
总结
以上是小编为你收集整理的Swift 中的过滤器全部内容。
如果觉得小编网站内容还不错,欢迎将小编网站推荐给好友。
Angular2 中的过滤器
如何解决Angular2 中的过滤器
我有
Product: {code: string,description: string}
productsA: Product[]
productsB: Product[]
我想获取 productsC: Product[] 包含 productsA 的所有产品,这些产品具有除 productsB 的产品代码之外的“代码”
示例:
productsA = [{''c1'',''des1''},{''c2'',''des2''},{''c3'',''des3''}]
productsB = [{''c1'',''des4''}]
I want productsC = [{''c2'',''des3''}]
我该怎么办?
解决方法
您可以使用 differenceBy
的 lodash
来完成。
import * as _ from ''lodash-es'';
yourFunc() {
:
const productsC = _.differenceBy(productsA,productsB,''code'');
:
}
,
我认为您需要 productsA
的所有产品,除了 productsB
包括?
那就给你。
const productA = [{code: ''c1'',description: ''desc1''},{code: ''c2'',description: ''desc2''},{code: ''c3'',description: ''desc3''}];
const productB = [{code: ''c1'',description: ''desc1''}];
const productC = [];
productA.forEach(prodA => {
productB.forEach(prodB => {
if (prodA.code != prodB.code) {
productC.push(prodA);
}
});
});
console.log(productC);
asp.net core 2.2 中的过滤器/筛选器(上)
ASP.NET Core中的过滤器/筛选器
通过使用 ASP.NET Core MVC 中的筛选器,可在请求处理管道中的特定阶段之前或之后运行代码。
注意:本主题不适用于 Razor 页面。 ASP.NET Core 2.1 及更高版本支持适用于 Razor 页面的 IPageFilter 和 IAsyncPageFilter。 有关详细信息,请参阅 Razor 页面的筛选方法。
内置筛选器处理一些任务,例如:
- 授权(防止用户访问未获授权的资源)。
- 确保所有请求都使用 HTTPS。
- 响应缓存(对请求管道进行短路出路,以便返回缓存的响应)。
可以创建自定义筛选器,用于处理横切关注点。过滤器可以避免在action中编写一些重复性的代码。比如异常过滤器可以合并处理异常。
筛选器的工作原理
筛选器在 MVC 操作调用管道(有时称为筛选器管道)内运行。 筛选器管道在 MVC 选择了要执行的操作(controller中的action方法)之后运行。
筛选器类型
每种筛选器类型都在筛选器管道中的不同阶段(上图中的mvc action invocation pipeline)执行。
-
授权筛选器最先运行,用于确定是否已针对当前请求为当前用户授权。 如果请求未获授权,它们可以让管道短路。
//startup:
public void ConfigureServices(IServiceCollection services)
{
services.AddMvc(action =>
{
action.Filters.Add<AuthorizationFilter>();
}).SetCompatibilityVersion(CompatibilityVersion.Version_2_1);
}
//authorizationfilter:
public class AuthorizationFilter : IAsyncAuthorizationFilter
{
private readonly ILoggerFactory loggerFactory;
public AuthorizationFilter(ILoggerFactory loggerFactory)
{
this.loggerFactory = loggerFactory;
}
public Task OnAuthorizationAsync(AuthorizationFilterContext context)
{
var logger = loggerFactory.CreateLogger<AuthorizationFilter>();
logger.LogWarning($"authorization filter is executing now ,target action is :{context.ActionDescriptor.DisplayName}");
return Task.CompletedTask;
}
}
-
资源筛选器是授权后最先处理请求的筛选器。 它们可以在筛选器管道的其余阶段运行之前以及管道的其余阶段完成之后运行代码。 出于性能方面的考虑,可以使用它们来实现缓存或以其他方式让筛选器管道短路。 它们在模型绑定之前运行,所以可以影响模型绑定。
//startup:
public void ConfigureServices(IServiceCollection services)
{
services.AddMvc(action =>
{
action.Filters.Add<AuthorizationFilter>();
action.Filters.Add<ResourceFilter>();
}).SetCompatibilityVersion(CompatibilityVersion.Version_2_1);
}
//resourcefilter:
public class ResourceFilter : IAsyncResourceFilter
{
private readonly ILoggerFactory loggerFactory;
public ResourceFilter(ILoggerFactory loggerFactory)
{
this.loggerFactory = loggerFactory;
}
public async Task OnResourceExecutionAsync(ResourceExecutingContext context, ResourceExecutionDelegate next)
{
var logger = loggerFactory.CreateLogger<ResourceFilter>();
logger.LogWarning($"resource filter is executing now,valueproviderfactories count:{context.ValueProviderFactories.Count}");
var executedContext = await next();
logger.LogWarning($"resource filter is executed now ,result''s type is {executedContext.Result.GetType().Name}");
}
}
-
操作筛选器可以在调用单个操作方法之前和之后立即运行代码。 它们可用于处理传入某个操作的参数以及从该操作返回的结果。
//startup:
public void ConfigureServices(IServiceCollection services)
{
services.AddMvc(action =>
{
action.Filters.Add<ActionsFilter>();
action.Filters.Add<AuthorizationFilter>();
action.Filters.Add<ResourceFilter>();
}).SetCompatibilityVersion(CompatibilityVersion.Version_2_1);
}
//actionsfilter
public class ActionsFilter : IAsyncActionFilter
{
private readonly ILoggerFactory factory;
public ActionsFilter(ILoggerFactory factory)
{
this.factory = factory;
}
public async Task OnActionExecutionAsync(ActionExecutingContext context, ActionExecutionDelegate next)
{
var logger = factory.CreateLogger<ActionsFilter>();
logger.LogWarning($"action filter is executing new ,context.modelstate:{context.ModelState.IsValid}");
var executedContext = await next();
logger.LogWarning($"action filter is executed now,executedContext controller:{executedContext.Controller.ToString()}");
}
}
-
异常筛选器用于在向响应正文写入任何内容之前,对未经处理的异常应用全局策略。
//startup:
public void ConfigureServices(IServiceCollection services)
{
services.AddMvc(action =>
{
action.Filters.Add<ActionsFilter>();
action.Filters.Add<AuthorizationFilter>();
action.Filters.Add<ResourceFilter>();
action.Filters.Add<ExceptionsFilter>();
}).SetCompatibilityVersion(CompatibilityVersion.Version_2_1);
}
//exceptionsfilter:
public class ExceptionsFilter : IAsyncExceptionFilter
{
private readonly ILoggerFactory loggerFactory;
public ExceptionsFilter(ILoggerFactory loggerFactory)
{
this.loggerFactory = loggerFactory;
}
public Task OnExceptionAsync(ExceptionContext context)
{
var logger = loggerFactory.CreateLogger<ExceptionsFilter>();
logger.LogWarning($"some exception''s happened,exception''s message:{context.Exception.Message}");
context.Result=new ObjectResult(context.Exception.Message);//这个异常被处理了一下,以200正常返回。
return Task.CompletedTask;
}
}
上面的日志打印结果可以看出exception filter实在authorization filter和resource filter以及action filter之后执行的它能捕获的异常是在action执行过程中发生的异常。所以,如果在authorization filter或者resource filter中发生异常的话,它是没有办法捕获的,可以做一个测验:将authorization filter中抛出一个异常:
可以看到这个异常是被直接抛出来了,并没有被exception handler中进行处理。接着改在resource filter中抛出一个异常,看看:
同样,在resource filter中抛出的异常exception filter也是处理不了的。也就是说在筛选器管道中,处于exception筛选器执行之前而执行的代码抛出的异常,exception筛选器是处理不了的。要想捕获程序的全局异常,我觉得应该在中间件中定义对异常的捕获。这个结论还没有进行证实,有时间再讨论。
-
结果筛选器可以在执行单个操作结果之前和之后立即运行代码。 仅当操作方法成功执行时,它们才会运行。 对于必须围绕视图或格式化程序的执行的逻辑,它们很有用。
//startup:
public void ConfigureServices(IServiceCollection services)
{
services.AddMvc(action =>
{
action.Filters.Add<ActionsFilter>();
action.Filters.Add<AuthorizationFilter>();
action.Filters.Add<ResourceFilter>();
action.Filters.Add<ExceptionsFilter>();
action.Filters.Add<ResultFilter>();
}).SetCompatibilityVersion(CompatibilityVersion.Version_2_1);
}
//resultfilter:
public class ResultFilter : IAsyncResultFilter
{
private readonly ILoggerFactory loggerFactory;
public ResultFilter(ILoggerFactory loggerFactory)
{
this.loggerFactory = loggerFactory;
}
public async Task OnResultExecutionAsync(ResultExecutingContext context, ResultExecutionDelegate next)
{
var logger = loggerFactory.CreateLogger<ResultFilter>();
logger.LogWarning($"result filter is executing, context.result is :{context.Result.GetType().Name}");
var executedContext = await next();
logger.LogWarning($"result filter is executed ,context.result is {executedContext.Result.GetType().Name}");
}
}
上面的结果是action中没有抛出异常,正常执行的结果,如果在action中抛出异常:
上下对比一下会发现,result filter只会在action正常执行没有抛出异常之后才会执行。exception filter是会捕获action抛出的异常。
下图展示了这些筛选器类型在筛选器管道中的交互方式。
实现
通过不同的接口定义,筛选器同时支持同步和异步实现。例如我上面举的例子全部都是用异步的方式实现的。
可在其管道阶段之前和之后运行代码的同步筛选器定义 OnStageExecuting 方法和 OnStageExecuted 方法。 例如,在调用操作方法之前调用 OnActionExecuting
,在操作方法返回之后调用 OnActionExecuted
。
using FiltersSample.Helper;
using Microsoft.AspNetCore.Mvc.Filters;
namespace FiltersSample.Filters
{
public class SampleActionFilter : IActionFilter
{
public void OnActionExecuting(ActionExecutingContext context)
{
// do something before the action executes
}
public void OnActionExecuted(ActionExecutedContext context)
{
// do something after the action executes
}
}
}
异步筛选器定义单一的 OnStageExecutionAsync 方法。 此方法采用 FilterTypeExecutionDelegate 委托来执行筛选器的管道阶段。 例如,ActionExecutionDelegate
调用该操作方法(如果没有下一个action filter)或下一个操作筛选器(下一个action filter),用户可以在调用它之前和之后执行代码。
可以在单个类中为多个筛选器阶段实现接口。 例如,ActionFilterAttribute 类实现 IActionFilter
和 IResultFilter
,以及它们的异步等效接口。
注意:同步和异步的只需要实现一个就行,如果两个都实现了,会优先执行异步版本的。
篇幅太长,再来一片吧。
ASP.NET Core 中的过滤器(Action过滤器,控制器过滤器,全局应用程序过滤器)
十年河东,十年河西,莫欺少年穷
学无止境,精益求精
今儿是周六,苏州的天空飘着毛毛细雨,气温也下降了不少,上午去了苏州繁花中心,来到二楼,自学了会古筝,逛了逛商场,中午去了肯德基,给孩子买了鸡翅,我和我老婆大人各喝了一杯咖啡。下午回到家,躺在床上刷抖音,刷的时间长了,也就觉得特别无聊,索性看看博客园吧,嘿嘿,于是我买了一瓶100ML的56度牛栏山二锅头,边吃花生米边看,本打算看netcore的中间件,于是百度搜了一些内容,大多数写的中间件都是参考微软教程,看的也是索然无味,有的说中间件类似于AOP,有的说中间件是HTTP请求管道中的一个组件,用于拦截你的http请求并决定是否把你的请求传递给下一个中间件,总的来说,中间件就是一个横向切面编程,也就是所谓的AOP,这里咱们不讨论中间件,我们今天讨论的是和中间件功能类似的过滤器,何为过滤器呢?过滤器和中间件有何细微的差别呢?哈哈,其实本篇博客是转载的别人,原文地址:https://www.cnblogs.com/jlion/p/12394949.html
首先感谢原文作者的贡献,其次我之所以转载这篇博客,一是因为作者写的好,二是因为这些知识和之前的MVC过滤器很类似,再者,我之前也写过过滤器的应用,比如MVC的登录授权过滤器,对MVC的登录授权过滤器有兴趣的小虎斑可参考我的博客:https://www.cnblogs.com/chenwolong/p/Attribute.html 和 https://www.cnblogs.com/chenwolong/p/Token.html 两篇博客。
废话说多了,下面咱们进入正题,如下:
一、前言
在分享ASP.NET Core Filter 使用之前,先来谈谈AOP
,什么是AOP 呢?
AOP
全称Aspect Oriented Programming
意为面向切面编程,也叫做面向方法编程,是通过预编译方式和运行期动态代理的方式实现不修改源代码的情况下给程序动态统一添加功能的技术。
AOP技术利用一种称为“横切”的技术,剖解开封装对象的内部,将影响多个类的公共行为封装到一个可重用的模块中,并将其命名为Aspect
切面。所谓的切面,简单来说就是与业务无关,却为业务模块所共同调用的逻辑,将其封装起来便于减少系统的重复代码,降低模块的耦合度,有利用未来的可操作性和可维护性。
利用AOP可以对业务逻辑各个部分进行隔离,从而使业务逻辑各部分之间的耦合度降低,提高程序的可重用性,同时提高开发效率。
AOP的使用场景主要包括日志记录、性能统计、安全控制、事务处理、异常处理等。
二、Filter-过滤器
Filter是延续ASP.NET MVC的产物,同样保留了五种的Filter,分别是Authorization Filter、Resource Filter、Action Filter、Exception Filter及Result Filter。
通过不同的Filter可以有效处理封包进出的加工,本篇将介绍ASP.NET Core的五种Filter运作方式。
2.1 Filter 介绍
ASP.NET Core 有以下五种Filter 可以使用:
- Authorization Filter:
Authorization是五种Filter中优先级最高的,通常用于验证Request合不合法,不合法后面就直接跳过。 - Resource Filter:Resource是第二优先,会在Authorization之后,Model Binding之前执行。通常会是需要对Model加工处理才用。
- Exception Filter:异常处理的Filter。
- Action Filter:最常使用的Filter,封包进出都会经过它,使用上没什么需要特别注意的。跟Resource Filter很类似,但并不会经过Model Binding。
- Result Filter:当Action完成后,最终会经过的Filter。
三、五大Filter 的应用
这一篇章主要来讲解Asp.Net Core 的五大过滤器的实现及用途.
3.1 Authonization Filter
权限控制过滤器
通过 Authonization Filter 可以实现复杂的权限角色认证
、登陆授权
等操作
实现事例代码如下:
public class AuthonizationFilter :Attribute,IAuthorizationFilter
{
public void OnAuthorization(AuthorizationFilterContext context)
{
//这里可以做复杂的权限控制操作
if (context.HttpContext.User.Identity.Name != "1") //简单的做一个示范
{
//未通过验证则跳转到无权限提示页
RedirectToActionResult content = new RedirectToActionResult("NoAuth", "Exception", null);
context.Result = content;
}
}
}
3.2 Resource Filter
资源过滤器
可以通过Resource Filter 进行资源缓存
、防盗链
等操作。
使用Resource Filter 要求实现IResourceFilter 抽象接口
public class ResourceFilter : Attribute,IResourceFilter
{
public void OnResourceExecuted(ResourceExecutedContext context)
{
// 执行完后的操作
}
public void OnResourceExecuting(ResourceExecutingContext context)
{
// 执行中的过滤器管道
}
}
3.3 Exception Filter
通过Execption Filter 过滤器可以进行全局的异常日志收集
等操作。
使用Execption Filter 要求实现IExceptionFilter
抽象接口IExceptionFilter
接口会要求实现OnException
方法,当系统发生未捕获异常时就会触发这个方法。OnException
方法有一个ExceptionContext
异常上下文,其中包含了具体的异常信息,HttpContext及mvc路由信息。系统一旦出现未捕获异常后,比较常见的做法就是使用日志工具,将异常的详细信息记录下来,方便修正调试。下面是日志记录的实现。
public class ExecptionFilter : Attribute, IExceptionFilter
{
private ILogger<ExecptionFilter> _logger;
//构造注入日志组件
public ExecptionFilter(ILogger<ExecptionFilter> logger)
{
_logger = logger;
}
public void OnException(ExceptionContext context)
{
//日志收集
_logger.LogError(context.Exception, context?.Exception?.Message??"异常");
}
}
3.4 Action Filter
作用:可以通过ActionFilter 拦截 每个执行的方法进行一系列的操作,比如:执行操作日志
、参数验证
,权限控制
等一系列操作。
使用Action Filter 需要实现IActionFilter 抽象接口,IActionFilter
接口要求实现OnActionExecuted
和OnActionExecuting
方法
public class ActionFilter : Attribute, IActionFilter
{
public void OnActionExecuted(ActionExecutedContext context)
{
//执行完成....
}
public void OnActionExecuting(ActionExecutingContext context)
{
//执行中...
}
}
3.5 Result Filter
结果过滤器,可以对结果进行格式化、大小写转换等一系列操作。
使用Result Filter 需要实现IResultFilter 抽象接口,接口要求实现OnResultExecuting
方法 和OnResultExecuted
方法
OnResultExecuting
:Called before the action result executes. 在操作结果执行之前调用OnResultExecuted
:Called after the action result executes. 在操作结果执行之后调用
具体代码实现代码如下:
public class ResultFilter : Attribute, IResultFilter
{
public void OnResultExecuted(ResultExecutedContext context)
{
// 在结果执行之后调用的操作...
}
public void OnResultExecuting(ResultExecutingContext context)
{
// 在结果执行之前调用的一系列操作
}
}
四、Asp.Net Core 过滤器的注册方式
这一篇章主要来分析探讨Asp.Net Core 中过滤器
的三种注册方式Action
、Controller
、全局
。
4.1 Action 注册方式
Action 注册方式是局部注册方式,针对控制器中的某个方法上标注特性的方式进行注册,代码如下:
[AuthonizationFilter()]
public IActionResult Index()
{
return View();
}
4.2 Controller 注册方式
了解过Action 特性注册方式的同学,一定发现了它的不好之处就是我一个控制器里面需要使用同一套Filter 的时候,需要一个一个Action 标注特性注册,是不是很繁琐呢?有没有其他方式进行代替这些繁琐的操作呢?微软给我们提供了简便的控制器标注注册方式,代码如下:
[AuthonizationFilter()]
public class FirstController : Controller
{
private ILogger<FirstController> _logger;
public FirstController(ILogger<FirstController> logger)
{
_logger = logger;
}
public IActionResult Index()
{
return View();
}
}
4.3 全局注册方式
现在有些同学考虑了一些全局的情况,比如我要全局处理系统中的异常,或者收集操作日志等,需要全局注册一个ExceptionFilter
来实现,就不需要每一个Controller 中进行代码注册,方便快捷。代码如下:
public void ConfigureServices(IServiceCollection services)
{
//全局注册异常过滤器
services.AddControllersWithViews(option=> {
option.Filters.Add<ExecptionFilter>();
});
services.AddSingleton<ISingletonService, SingletonService>();
}
4.4 TypeFilter 和 ServiceFilter 注册方式
上面的五大过滤器中事例代码中其中有一个过滤器的代码比较特别,再来回顾ExceptionFilter
过滤器的实现代码:
public class ExecptionFilter : Attribute, IExceptionFilter
{
private ILogger<ExecptionFilter> _logger;
//构造注入日志组件
public ExecptionFilter(ILogger<ExecptionFilter> logger)
{
_logger = logger;
}
public void OnException(ExceptionContext context)
{
//日志收集
_logger.LogError(context.Exception, context?.Exception?.Message??"异常");
}
}
从上面的代码中可以发现 ExceptionFilter 过滤器实现中存在日志服务的构造函数的注入,也就是说该过滤器依赖于其他的日志服务,但是日志服务都是通过DI 注入进来的;再来回顾下上面Action 注册方式或者Controller 注册方式 也即Attribute
特性标注注册方式,本身基础的特性是不支持构造函数的,是在运行时注册进来的,那要解决这种本身需要对服务依赖的过滤器需要使用 TypeFilter
或者ServiceFilter
方式进行过滤器的标注注册。
TypeFilter
和ServiceFilter
的区别。
- ServiceFilter和TypeFilter都实现了IFilterFactory
- ServiceFilter需要对自定义的Filter进行注册,TypeFilter不需要
- ServiceFilter的Filter生命周期源自于您如何注册,而TypeFilter每次都会创建一个新的实例
TypeFilter 使用方式
代码如下:
[TypeFilter(typeof(ExecptionFilter))]
public IActionFilter Index2()
{
return View();
}
通过上面的代码可以发现AuthonizationFilter 是默认的构造器,但是如果过滤器中构造函数中存在参数,需要注入服务那该怎么办呢?,比如上面的ExceptionFilter 代码,就不能使用这种方式进行注册,需要使用服务特性的方式,我们可以选择使用 代码如下:
[TypeFilter(typeof(ExecptionFilter))]
public IActionFilter Index2()
{
return View();
}
ServiceFilter 使用方式
控制器中的代码如下:
[ServiceFilter(typeof(ExecptionFilter))]
public IActionFilter Index2()
{
return View();
}
注册服务的代码如下:
// This method gets called by the runtime. Use this method to add services to the container.
public void ConfigureServices(IServiceCollection services)
{
Console.WriteLine("ConfigureServices");
services.AddControllersWithViews();
//services.AddControllersWithViews(option=> {
// option.Filters.Add<ExecptionFilter>();
//});
//注册过滤器服务,使用ServiceFilter 方式必须要注册 否则会报没有注册该服务的相关异常
services.AddSingleton<ExecptionFilter>();
}
如果你觉得还不错,就请点个赞吧,谢谢。
参考博客:
博客:https://www.cnblogs.com/jlion/p/12394949.html
知乎:https://zhuanlan.zhihu.com/p/112507159
AWESOME SWIFT-swift.libhunt.com-swift类库网站
https://swift.libhunt.com/categories/688-events
29 Events libraries and projects
- ORDERED BY POPULARITY
- ORDER BY DEV ACTIVITY
-
ReactiveCocoa
10.0 7.3 Objective-CReactiveCocoa (RAC) is a Cocoa framework inspired by Functional Reactive Programming. It provides APIs for composing and transforming streams of values over time. -
RxSwift
9.9 8.8 L3 SwiftMicrosoft Reactive Extensions (Rx) for Swift and iOS/OSX platform. -
PromiseKit
9.8 8.7 L5 Swiftasync promise programming lib. -
ReSwift
9.6 6.3 L5 SwiftUnidirectional Data Flow in Swift -
Bond
9.3 8.8 L1 Swifta Swift binding framework. -
BrightFutures
8.3 4.7 L4 Swiftpromise and future lib for swift. -
Katana
8.2 8.7 L4 SwiftSwift apps a la React and Redux. -
ReactorKit
7.8 6.4 SwiftA framework for reactive and unidirectional application architecture. -
ReactKit
7.4 0.0 L3 SwiftSwift Reactive Programming. -
FutureKit
6.4 0.7 L2 SwiftA Swift based Future/Promises Library. -
SwiftEventBus
6.4 3.2 L5 SwiftA publish/subscribe event bus optimized for iOS. -
EmitterKit
5.7 3.5 L5 Swiftan implementation of event emitters and listeners in swift. -
Signals
4.9 3.3 L5 Swiftreplaces delegates and notifications. -
Safe
4.9 0.0 L2 SwiftA modern concurrency and synchronization for Swift. -
snail
4.5 7.1 L5 SwiftAn observables framework for Swift -
Reactor
4.1 2.4 L5 SwiftPowering your RAC architecture. -
VueFlux
3.8 6.8 SwiftUnidirectional Data Flow State Management Architecture -
SignalKit
3.7 0.0 L5 SwiftSwift event and binding framework. -
Observable
3.7 6.2 SwiftThe easiest way to observe values. -
When
3.4 5.4 L5 SwiftA lightweight implementation of Promises in Swift. -
Caravel
3.3 0.0 L2 SwiftA Swift event bus for UIWebView and JS. -
Future
2.5 0.0 L4 SwiftA micro framework providing Future. -
NoticeObserveKit
2.3 0.0 L5 SwiftNoticeObserveKit is type-safe NotificationCenter wrapper that associates notice type with info type. -
Aftermath
1.8 0.0 L5 SwiftStateless message-driven micro-framework in Swift. -
Notificationz
1.6 2.5 L5 SwiftHelping you own NSNotificationCenter by providing a simple, customizable adapter. -
Forbind
1.2 0.0 L4 SwiftFunctional chaining and Promises in Swift. -
ReduxSwift
1.0 0.0 L5 SwiftPredictable state container for Swift apps too -
PureFutures
0.7 0.0 L4 SwiftFutures and Promises library. -
SSEventFlow
0.3 4.4 L5 SwiftA type safe alternative to NSNotification, inspired by Flux.
关于Swift 中的过滤器和过滤器filter的问题就给大家分享到这里,感谢你花时间阅读本站内容,更多关于Angular2 中的过滤器、asp.net core 2.2 中的过滤器/筛选器(上)、ASP.NET Core 中的过滤器(Action过滤器,控制器过滤器,全局应用程序过滤器)、AWESOME SWIFT-swift.libhunt.com-swift类库网站等相关知识的信息别忘了在本站进行查找喔。
本文标签: