Exemplo n.º 1
0
        /// <summary>
        /// Copy the entity if it matches the filter
        /// </summary>
        /// <param name="filter"></param>
        /// <typeparam name="T"></typeparam>
        protected void Copy <T>(TranslateEntityFilter <T, TSchema> filter)
            where T : TSchema
        {
            var specification = new CopyEntityTranslatorSpecification <T, TSchema>(filter);

            _specification.Add(specification);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Exclude entities of the specified entity type that match the provided filter.
        /// </summary>
        /// <param name="filter"></param>
        /// <typeparam name="T"></typeparam>
        protected void Exclude <T>(TranslateEntityFilter <T, TSchema> filter)
            where T : TSchema
        {
            var specification = new ExcludeEntityTranslateSpecification <T, TSchema>(filter);

            _specification.Add(specification);
        }
Exemplo n.º 3
0
        public CopyEntityTranslator(TranslateEntityFilter <TEntity, TSchema> filter = null)
        {
            _filter = filter;

            _observers = new TranslatorObservable <TSchema>();
        }
Exemplo n.º 4
0
 public ExcludeEntityTranslatorSpecification(TranslateEntityFilter <TEntity, TSchema> filter = null)
 {
     _filter = filter;
 }
Exemplo n.º 5
0
 public CopyEntityTranslateSpecification(TranslateEntityFilter <TEntity, TSchema> filter = null)
 {
     _filter = filter;
 }