public Expression <Copy <TFrom, TTo> > Get(Expression <Func <TFrom, TTo> > parameter) { var from = _parameters.Get("start"); var @in = Expression.ArrayAccess(_parameters.Get("source"), Expression.Convert(from, typeof(int))); var to = _parameters.Get("to"); var @out = Expression.ArrayAccess(_parameters.Get("destination"), Expression.Convert(to, typeof(int))); var inline = new InlineVisitor(parameter.Parameters[0], @in).Visit(parameter.Body) ?? throw new InvalidOperationException("Inline expression was not found"); var label = Expression.Label(); var body = Expression.Block(Expression.PostDecrementAssign(from), Expression.Loop(Expression .IfThenElse(Expression .LessThan(Expression.PreIncrementAssign(from), _parameters.Get("finish")), Expression .Block(Expression.Assign(@out, inline), Expression.PostIncrementAssign(to) ), Expression.Break(label)), label)); var result = Expression.Lambda <Copy <TFrom, TTo> >(body, _input); return(result); }
public ISelect <Type, Type> Get(Type parameter) => _source.Get(parameter) .Then() .Ensure.Input.Is(_valid.Then() .And(_specification.Get(parameter)) .Out()) .Otherwise.UseDefault() .Get();
public ValueTask Get(TIn parameter) { var result = _operation.Get(parameter); if (result.IsFaulted) { var input = new ExceptionParameter <TOut>(result.AsTask().Exception, _select((parameter, result))); _log.Execute(input); } return(result); }
public T[] Get(_ parameter) { var storage = _origin.Get(parameter); var result = _body.Get(new ArrayView <T>(storage.Instance, 0, storage.Length)) .ToArray(); if (storage.Requested) { _return(storage.Instance); } return(result); }
public Store <T> Get(IEnumerable <T> parameter) { switch (parameter) { case T[] array: return(_enter.Get(array)); case ICollection <T> collection: return(_collection.Get(collection)); default: return(_enumerate.Get(parameter.GetEnumerator())); } }
public ConstructorInfo Get(TypeInfo parameter) { var constructors = _constructors.Get(parameter).ToArray(); var length = constructors.Length; for (var i = 0u; i < length; i++) { var constructor = constructors[i]; if (_condition.Get(constructor)) { return(constructor); } } return(null); }
public IAspect <TIn, TOut> Get(Type parameter) { var implementations = _implementations.Get(parameter); var length = implementations.Length; if (implementations.Length > 0) { var store = new DynamicStore <IAspect <TIn, TOut> >(32); for (var i = 0u; i < length; i++) { var registrations = _registrations.Get(implementations[i].GenericTypeArguments); store = store.Add(new Store <IAspect <TIn, TOut> >(registrations)); } return(new CompositeAspect <TIn, TOut>(store.Get().Instance)); } return(EmptyAspect <TIn, TOut> .Default); }
public ISelect <Type, Type> Get(Type parameter) => _valid.Then() .And(_specification.Get(parameter)) .Out() .To(_source.Get(parameter).If);
public static TOut Get <TIn, TOut, TOther>(this ISelect <TIn, TOut> @this, TIn parameter, TOther _) { var @out = @this.Get(parameter); return(@out); }
public static TOut Get <T, TOut>(this ISelect <Assigned <T>, TOut> @this) where T : struct => @this.Get(Assigned <T> .Unassigned);
/**/ public static ISelect <TIn, TTo> Select <TIn, TFrom, TTo>(this ISelect <TIn, TFrom> @this, ISelect <TFrom, TTo> select) => @this.Select(select.Get); public static ISelect <TIn, TTo> Select <TIn, TFrom, TTo>(this ISelect <TIn, TFrom> @this, Func <TFrom, TTo> select) => new Selection <TIn, TFrom, TTo>(@this.Get, select); /**/ public static TOut Get <TIn, TOut, TOther>(this ISelect <TIn, TOut> @this, TIn parameter, TOther _) => @this.Get(parameter);
public static T Get <T>(this ISelect <None, T> @this) => @this.Get(None.Default);
public static TOut Get <TItem, TOut>(this ISelect <Array <TItem>, TOut> @this, TItem parameter) => @this.Get(Model.Sequences.Query.Yield <TItem> .Default.Get(parameter));
public Array <Type> Get(Type parameter) => _implementations.Get(parameter) .Get(_definition) .Open();
public int[] Subject() => _subject.Get(Numbers);
public string Extensive() => _extensive.Get(string.Empty);
public string Multiple() => _multiple.Get(string.Empty);
public string One() => _one.Get(string.Empty);
public string Measure() => _subject.Get(string.Empty);
public string Proposed() => _subject.Get(data);
public int[] Subject() => _subject.Get(Data);
public Array Subject() => _subject.Get(data);
public static T Get <T>(this ISelect <uint, T> @this, int parameter) => @this.Get((uint)parameter);
public static T Get <T>(this ISelect <TypeInfo, T> @this, Type parameter) => @this.Get(parameter.GetTypeInfo());
public static TOut Get <TItem, TOut>(this ISelect <Array <TItem>, TOut> @this, params TItem[] parameters) => @this.Get(parameters);
public Array <IAspect <TIn, TOut> > Get(Array <Type> parameter) { var registrations = _registrations(); var to = registrations.Length; var elements = _stores.Get(to); var source = elements.Instance; var count = 0u; for (var i = 0u; i < to; i++) { var registration = registrations[i]; if (registration.Condition.Get(parameter)) { var instance = registration.Get(parameter); source[count++] = instance is IAspect <TIn, TOut> aspect ? aspect : _adapter.Get(instance); } } return(source.CopyInto(new IAspect <TIn, TOut> [count], 0, count)); }
public ISelect <_, T> Reference() => _tables.Get(_subject.ToDelegateReference());
public Store <T> Get(_ parameter) => _enter.Get(_origin.Get(parameter));