Beispiel #1
0
        EntityTranslateContext(IReadOnlyContextCollection contextCollection, EntityResult <TSchema> source, TInput input, bool hasInput, int?index = default(int?))
            : base(contextCollection)
        {
            Source = source;

            HasInput = hasInput;
            Input    = input;
            Index    = index;
        }
Beispiel #2
0
        ArrayContextCollection(IReadOnlyContextCollection parent, IContextValue context, IContextValue[] contexts)
            : base(parent)
        {
            _parent = parent;

            _contexts    = new IContextValue[contexts.Length + 1];
            _contexts[0] = context;
            Array.Copy(contexts, 0, _contexts, 1, contexts.Length);
        }
Beispiel #3
0
        public ResultTranslateResult(TranslateContext <TSchema> context, TResult result, Type resultType, bool isTranslated = true)
        {
            _result     = result;
            _resultType = resultType;

            IsTranslated = isTranslated;

            _context         = context;
            _contextSnapshot = context.CurrentContext;
        }
Beispiel #4
0
        public ResultTranslateResult(TranslateContext <TSchema> context, bool isTranslated = true)
        {
            _result     = default(TResult);
            _resultType = typeof(TResult);

            IsTranslated = isTranslated;

            _context         = context;
            _contextSnapshot = context.CurrentContext;
        }
Beispiel #5
0
 public BaseContext(IReadOnlyContextCollection parent)
 {
     _contextCache = new ContextCache(parent);
 }
Beispiel #6
0
 public EmptyContextCollection(IReadOnlyContextCollection parent = null)
     : base(parent)
 {
 }
Beispiel #7
0
 public SingleContextCollection(IContextValue context, IReadOnlyContextCollection parent = null)
     : base(parent)
 {
     _context = context;
     _parent  = parent;
 }
Beispiel #8
0
 protected BaseContextCollection(IReadOnlyContextCollection parent)
 {
     _parent = parent;
 }
Beispiel #9
0
 public ArrayContextCollection(IReadOnlyContextCollection parent, params IContextValue[] contexts)
     : base(parent)
 {
     _contexts = contexts;
     _parent   = parent;
 }
Beispiel #10
0
 public ContextCache(IReadOnlyContextCollection parent)
 {
     _collection = new EmptyContextCollection(parent);
 }