Example #1
0
        private void AddCreator(IAdapterCreator creator)
        {
            if (m_adapterCreators == null)
            {
                m_adapterCreators = new List <IAdapterCreator>();
            }

            m_adapterCreators.Add(creator);
        }
Example #2
0
        /// <summary>
        /// Adds an adapter creator for the type. Adapter creators extend the adaptability
        /// of instances of the node type, and are queried by the implementation of IAdaptable.</summary>
        /// <param name="creator">Adapter creator</param>
        public void AddAdapterCreator(IAdapterCreator creator)
        {
            if (m_extensions == null)
            {
                FreezeExtensions();
            }

            AddCreator(creator);
        }
Example #3
0
 /// <summary>
 /// Constructor with collection and adapter creator</summary>
 /// <param name="collection">IObservableCollection of underlying list type</param>
 /// <param name="adapterCreator">IAdapterCreator to create adapter for collection</param>
 public AdaptableViewModelCollection(IObservableCollection <T> collection, IAdapterCreator adapterCreator)
     : base(collection)
 {
     m_adapterCreator = adapterCreator;
 }