Exemple #1
0
 public TaskRepository(ITaskApiClient taskApiClient, IResponseParser responseParser, ITaskCache taskCache, ISyncTracker syncTracker)
 {
     _taskApiClient  = taskApiClient;
     _responseParser = responseParser;
     _taskCache      = taskCache;
     _syncTracker    = syncTracker;
 }
 protected SyncHandlerTreeBase(
     IEntityService entityService,
     IProfilingLogger logger,
     ISyncSerializer <TObject> serializer,
     ISyncTracker <TObject> tracker,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, syncFileService)
 {
 }
Exemple #3
0
 public DictionaryHandler(IEntityService entityService,
                          IProfilingLogger logger,
                          ILocalizationService localizationService,
                          ISyncSerializer <IDictionaryItem> serializer,
                          ISyncTracker <IDictionaryItem> tracker,
                          SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, syncFileService)
 {
     this.localizationService = localizationService;
 }
Exemple #4
0
 protected SyncHandlerLevelBase(
     IEntityService entityService,
     IProfilingLogger logger,
     ISyncSerializer <TObject> serializer,
     ISyncTracker <TObject> tracker,
     AppCaches appCaches,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, syncFileService)
 {
 }
Exemple #5
0
 public DomainHandler(IEntityService entityService,
                      IProfilingLogger logger,
                      IDomainService domainService,
                      ISyncSerializer <IDomain> serializer,
                      ISyncTracker <IDomain> tracker,
                      SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, syncFileService)
 {
     this.domainService = domainService;
 }
Exemple #6
0
 public MacroHandler(IEntityService entityService,
                     IProfilingLogger logger,
                     IMacroService macroService,
                     ISyncSerializer <IMacro> serializer,
                     ISyncTracker <IMacro> tracker,
                     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, syncFileService)
 {
     this.macroService = macroService;
 }
 public SyncHandlerBase(
     IEntityService entityService,
     IProfilingLogger logger,
     ISyncSerializer <TObject> serializer,
     ISyncTracker <TObject> tracker,
     AppCaches appCaches,
     SyncFileService syncFileService)
     : this(entityService, logger, serializer, tracker, appCaches, null, syncFileService)
 {
 }
 protected SyncHandlerContainerBase(
     IEntityService entityService,
     IProfilingLogger logger,
     ISyncSerializer <TObject> serializer,
     ISyncTracker <TObject> tracker,
     AppCaches appCaches,
     ISyncDependencyChecker <TObject> checker,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
 {
 }
Exemple #9
0
 public MediaHandler(
     IEntityService entityService,
     IProfilingLogger logger,
     IMediaService mediaService,
     ISyncSerializer <IMedia> serializer,
     ISyncTracker <IMedia> tracker,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, syncFileService)
 {
     this.mediaService   = mediaService;
     this.itemObjectType = UmbracoObjectTypes.Media;
 }
Exemple #10
0
 public ContentTemplateHandler(
     IEntityService entityService,
     IProfilingLogger logger,
     IContentService contentService,
     ContentTemplateSerializer serializer, // concreate because we want to make sure we get the blueprint one.
     ISyncTracker <IContent> tracker,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, syncFileService)
 {
     this.contentService = contentService;
     this.itemObjectType = UmbracoObjectTypes.DocumentBlueprint;
 }
 public ContentTemplateHandler(
     IEntityService entityService,
     IProfilingLogger logger,
     IContentService contentService,
     ContentTemplateSerializer serializer, // concreate because we want to make sure we get the blueprint one.
     ISyncTracker <IContent> tracker,
     AppCaches appCaches,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, syncFileService)
 {
     this.contentService = contentService;
 }
 protected DictionaryHandler(IEntityService entityService,
                             IProfilingLogger logger,
                             ILocalizationService localizationService,
                             ISyncSerializer <IDictionaryItem> serializer,
                             ISyncTracker <IDictionaryItem> tracker,
                             AppCaches appCaches,
                             ISyncDependencyChecker <IDictionaryItem> checker,
                             SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
 {
     this.localizationService = localizationService;
 }
Exemple #13
0
 public MacroHandler(IEntityService entityService,
                     IProfilingLogger logger,
                     IMacroService macroService,
                     ISyncSerializer <IMacro> serializer,
                     ISyncTracker <IMacro> tracker,
                     AppCaches appCaches,
                     ISyncDependencyChecker <IMacro> checker,
                     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
 {
     this.macroService = macroService;
 }
Exemple #14
0
 protected DomainHandler(IEntityService entityService,
                         IProfilingLogger logger,
                         IDomainService domainService,
                         ISyncSerializer <IDomain> serializer,
                         ISyncTracker <IDomain> tracker,
                         AppCaches appCaches,
                         ISyncDependencyChecker <IDomain> checker,
                         SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
 {
     this.domainService = domainService;
 }
Exemple #15
0
        public ContentHandler(
            IEntityService entityService,
            IProfilingLogger logger,
            IContentService contentService,
            ISyncSerializer <IContent> serializer,
            ISyncTracker <IContent> tracker,
            SyncFileService syncFileService)
            : base(entityService, logger, serializer, tracker, syncFileService)
        {
            this.contentService = contentService;

            this.itemObjectType = UmbracoObjectTypes.Document;
        }
 public ContentTypeHandler(
     IEntityService entityService,
     IProfilingLogger logger,
     IContentTypeService contentTypeService,
     ISyncSerializer <IContentType> serializer,
     ISyncTracker <IContentType> tracker,
     AppCaches appCaches,
     ISyncDependencyChecker <IContentType> checker,
     SyncFileService fileService)
     : base(entityService, logger, serializer, tracker, appCaches, checker, fileService)
 {
     this.contentTypeService = contentTypeService;
 }
Exemple #17
0
 public DataTypeHandler(
     IEntityService entityService,
     IDataTypeService dataTypeService,
     IProfilingLogger logger,
     ISyncSerializer <IDataType> serializer,
     ISyncTracker <IDataType> tracker,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, syncFileService)
 {
     this.dataTypeService   = dataTypeService;
     this.itemObjectType    = UmbracoObjectTypes.DataType;
     this.itemContainerType = UmbracoObjectTypes.DataTypeContainer;
 }
 protected MemberTypeHandler(
     IEntityService entityService,
     IProfilingLogger logger,
     IMemberTypeService memberTypeService,
     ISyncSerializer <IMemberType> serializer,
     ISyncTracker <IMemberType> tracker,
     AppCaches appCaches,
     ISyncDependencyChecker <IMemberType> checker,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
 {
     this.memberTypeService = memberTypeService;
 }
Exemple #19
0
 public DataTypeHandler(
     IEntityService entityService,
     IDataTypeService dataTypeService,
     IProfilingLogger logger,
     ISyncSerializer <IDataType> serializer,
     ISyncDependencyChecker <IDataType> checker,
     ISyncTracker <IDataType> tracker,
     AppCaches appCaches,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
 {
     this.dataTypeService = dataTypeService;
 }
Exemple #20
0
 public TemplateHandler(
     IEntityService entityService,
     IProfilingLogger logger,
     IFileService fileService,
     ISyncSerializer <ITemplate> serializer,
     ISyncTracker <ITemplate> tracker,
     AppCaches appCaches,
     ISyncDependencyChecker <ITemplate> checker,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
 {
     this.fileService = fileService;
 }
 public LanguageHandler(
     IEntityService entityService,
     IProfilingLogger logger,
     ILocalizationService localizationService,
     ISyncSerializer <ILanguage> serializer,
     ISyncTracker <ILanguage> tracker,
     AppCaches appCaches,
     ISyncDependencyChecker <ILanguage> checker,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
 {
     this.localizationService = localizationService;
 }
Exemple #22
0
        public LanguageHandler(
            IEntityService entityService,
            IProfilingLogger logger,
            ILocalizationService localizationService,
            ISyncSerializer <ILanguage> serializer,
            ISyncTracker <ILanguage> tracker,
            SyncFileService syncFileService)
            : base(entityService, logger, serializer, tracker, syncFileService)
        {
            this.localizationService = localizationService;

            this.itemObjectType    = UmbracoObjectTypes.Language;
            this.itemContainerType = UmbracoObjectTypes.Unknown;
        }
Exemple #23
0
 protected MediaHandler(
     IEntityService entityService,
     IProfilingLogger logger,
     IMediaService mediaService,
     ISyncSerializer <IMedia> serializer,
     ISyncTracker <IMedia> tracker,
     AppCaches appCaches,
     ISyncDependencyChecker <IMedia> checker,
     SyncFileService syncFileService)
     : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
 {
     this.mediaService   = mediaService;
     performDoubleLookup = UmbracoVersion.LocalVersion.Major != 8 || UmbracoVersion.LocalVersion.Minor < 4;
 }
        public ContentHandler(
            IEntityService entityService,
            IProfilingLogger logger,
            IContentService contentService,
            ISyncSerializer <IContent> serializer,
            ISyncTracker <IContent> tracker,
            AppCaches appCaches,
            ISyncDependencyChecker <IContent> checker,
            SyncFileService syncFileService)
            : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
        {
            this.contentService = contentService;

            performDoubleLookup = UmbracoVersion.LocalVersion.Major != 8 || UmbracoVersion.LocalVersion.Minor < 4;
        }
 public SyncHandlerBase(
     IEntityService entityService,
     IProfilingLogger logger,
     ISyncSerializer <TObject> serializer,
     ISyncTracker <TObject> tracker,
     AppCaches appCaches,
     ISyncDependencyChecker <TObject> dependencyChecker,
     SyncFileService syncFileService)
     : base(logger, appCaches,
            serializer,
            tracker.AsEnumerableOfOne(),
            dependencyChecker.AsEnumerableOfOne(),
            syncFileService)
 {
     this.entityService = entityService;
 }
Exemple #26
0
        public TemplateHandler(
            IEntityService entityService,
            IProfilingLogger logger,
            IFileService fileService,
            ISyncSerializer <ITemplate> serializer,
            ISyncTracker <ITemplate> tracker,
            SyncFileService syncFileService)
            : base(entityService, logger, serializer, tracker, syncFileService)
        {
            this.fileService = fileService;

            this.itemObjectType = UmbracoObjectTypes.Template;

            // this might need some work - because its not a container thing ?
            this.itemContainerType = UmbracoObjectTypes.Unknown;
        }
        protected MemberTypeHandler(
            IEntityService entityService,
            IProfilingLogger logger,
            IMemberTypeService memberTypeService,
            ISyncSerializer <IMemberType> serializer,
            ISyncTracker <IMemberType> tracker,
            AppCaches appCaches,
            ISyncDependencyChecker <IMemberType> checker,
            SyncFileService syncFileService)
            : base(entityService, logger, serializer, tracker, appCaches, checker, syncFileService)
        {
            this.memberTypeService = memberTypeService;

            this.Enabled = false;
            // turn it off it appears to break things in current build
        }
        public SyncHandlerBase(
            IEntityService entityService,
            IProfilingLogger logger,
            ISyncSerializer <TObject> serializer,
            ISyncTracker <TObject> tracker,
            AppCaches appCaches,
            ISyncDependencyChecker <TObject> dependencyChecker,
            SyncFileService syncFileService)
        {
            this.logger = logger;

            this.entityService = entityService;

            this.serializer        = serializer;
            this.tracker           = tracker;
            this.dependencyChecker = dependencyChecker;

            this.syncFileService = syncFileService;

            this.runtimeCache = appCaches.RuntimeCache;

            handlerType = GetType();
            var meta = handlerType.GetCustomAttribute <SyncHandlerAttribute>(false);

            if (meta == null)
            {
                throw new InvalidOperationException($"The Handler {handlerType} requires a {typeof(SyncHandlerAttribute)}");
            }

            Name          = meta.Name;
            Alias         = meta.Alias;
            DefaultFolder = meta.Folder;
            Priority      = meta.Priority;
            IsTwoPass     = meta.IsTwoPass;
            Icon          = string.IsNullOrWhiteSpace(meta.Icon) ? "icon-umb-content" : meta.Icon;
            EntityType    = meta.EntityType;

            TypeName = serializer.ItemType;

            this.itemObjectType    = uSyncObjectType.ToUmbracoObjectType(EntityType);
            this.itemContainerType = uSyncObjectType.ToContainerUmbracoObjectType(EntityType);

            GetDefaultConfig(Current.Configs.uSync());
            uSyncConfig.Reloaded += BackOfficeConfig_Reloaded;
        }
Exemple #29
0
        public MemberTypeHandler(
            IEntityService entityService,
            IProfilingLogger logger,
            IMemberTypeService memberTypeService,
            ISyncSerializer <IMemberType> serializer,
            ISyncTracker <IMemberType> tracker,
            SyncFileService syncFileService)
            : base(entityService, logger, serializer, tracker, syncFileService)
        {
            this.memberTypeService = memberTypeService;

            this.itemObjectType = UmbracoObjectTypes.MemberType;

            // this is also set in base, but explity here so you know
            //    no folders for membertypes
            this.itemContainerType = UmbracoObjectTypes.Unknown;

            this.Enabled = false;
            // turn it off it appears to break things in current build
        }
Exemple #30
0
        public SyncHandlerBase(
            IEntityService entityService,
            IProfilingLogger logger,
            ISyncSerializer <TObject> serializer,
            ISyncTracker <TObject> tracker,
            SyncFileService syncFileService)
        {
            this.logger = logger;


            this.entityService = entityService;

            this.serializer = serializer;
            this.tracker    = tracker;

            this.syncFileService = syncFileService;

            var thisType = GetType();
            var meta     = thisType.GetCustomAttribute <SyncHandlerAttribute>(false);

            if (meta == null)
            {
                throw new InvalidOperationException($"The Handler {thisType} requires a {typeof(SyncHandlerAttribute)}");
            }

            Name          = meta.Name;
            Alias         = meta.Alias;
            DefaultFolder = meta.Folder;
            Priority      = meta.Priority;
            IsTwoPass     = meta.IsTwoPass;
            Icon          = string.IsNullOrWhiteSpace(meta.Icon) ? "icon-umb-content" : meta.Icon;


            GetDefaultConfig(Current.Configs.uSync());
            uSyncConfig.Reloaded += BackOfficeConfig_Reloaded;
        }