コード例 #1
0
 public ObjectAssembler(StackingLinkedList <Level> state,
                        IRuntimeTypeSource typeSource,
                        IInstanceLifeCycleListener listener,
                        IValueContext context)
 {
     StateCommuter     = new StateCommuter(state, typeSource, listener, context);
     LifecycleListener = listener;
 }
コード例 #2
0
 public ObjectAssembler(StackingLinkedList<Level> state,
     IRuntimeTypeSource typeSource,
     ITopDownValueContext topDownValueContext,
     IInstanceLifeCycleListener listener)
 {
     StateCommuter = new StateCommuter(state, typeSource, topDownValueContext, listener);
     LifecycleListener = listener;
 }
コード例 #3
0
        public void OverrideInstance(object instance)
        {
            StateCommuter.RaiseLevel();
            StateCommuter.Current.Instance = instance;

            var collection = instance as ICollection;

            if (collection != null)
            {
                StateCommuter.Current.Collection = collection;
            }
        }
コード例 #4
0
        public ObjectAssembler(IRuntimeTypeSource typeSource, IValueContext valueContext, Settings settings = null)
            : this(new StackingLinkedList <Level>(), typeSource, GetLifecycleListener(settings), valueContext)
        {
            this.valueContext = valueContext;
            Guard.ThrowIfNull(typeSource, nameof(typeSource));

            TypeSource = typeSource;
            StateCommuter.RaiseLevel();

            rootInstance = settings?.RootInstance;
            var rootInstanceType = rootInstance?.GetType();

            rootInstanceXamlType = rootInstanceType != null?TypeSource.GetByType(rootInstanceType) : null;
        }
コード例 #5
0
        public ObjectAssembler(IWiringContext wiringContext, ITopDownValueContext topDownValueContext, ObjectAssemblerSettings settings = null)
            : this(new StackingLinkedList <Level>(), wiringContext, topDownValueContext)
        {
            Guard.ThrowIfNull(wiringContext, nameof(wiringContext));
            Guard.ThrowIfNull(topDownValueContext, nameof(topDownValueContext));

            this.topDownValueContext = topDownValueContext;
            StateCommuter.RaiseLevel();

            rootInstance = settings?.RootInstance;
            var rootInstanceType = rootInstance?.GetType();

            rootInstanceXamlType = rootInstanceType != null?wiringContext.TypeContext.TypeRepository.GetXamlType(rootInstanceType) : null;
        }
コード例 #6
0
ファイル: ObjectAssembler.cs プロジェクト: furesoft/OmniXAML
 public ObjectAssembler(StackingLinkedList<Level> state, IWiringContext wiringContext, ITopDownValueContext topDownValueContext)
 {
     WiringContext = wiringContext;
     StateCommuter = new StateCommuter(state, wiringContext, topDownValueContext);
 }
コード例 #7
0
 public ObjectAssembler(StackingLinkedList <Level> state, IWiringContext wiringContext, ITopDownValueContext topDownValueContext)
 {
     WiringContext = wiringContext;
     StateCommuter = new StateCommuter(state, wiringContext, topDownValueContext);
 }