/// <summary> /// Constructor /// </summary> public CacheLifecycleManager( ILogger <CacheLifecycleManager> logger, SyncEntityCache entityCache, uSyncEventService eventService) { this.logger = logger; this.entityCache = entityCache; this.eventService = eventService; }
/// <summary> /// Base constructor, should never be called directly /// </summary> protected ContentHandlerBase( ILogger <ContentHandlerBase <TObject, TService> > logger, IEntityService entityService, AppCaches appCaches, IShortStringHelper shortStringHelper, SyncFileService syncFileService, uSyncEventService mutexService, uSyncConfigService uSyncConfigService, ISyncItemFactory syncItemFactory) : base(logger, entityService, appCaches, shortStringHelper, syncFileService, mutexService, uSyncConfigService, syncItemFactory) { }
/// <summary> /// Initializes a new instance of the <see cref="uSyncContentService"/> class. /// </summary> /// <param name="logger">The logger.</param> /// <param name="contentService">The content service.</param> /// <param name="appCaches">The application caches.</param> /// <param name="entityService">The entity service.</param> /// <param name="shortStringHelper">The short string helper.</param> /// <param name="uSyncFileService">The u synchronize file service.</param> /// <param name="uSyncEventService">The u synchronize event service.</param> /// <param name="uSyncConfigService">The u synchronize configuration service.</param> /// <param name="syncItemFactory">The synchronize item factory.</param> public uSyncContentService(ILogger <ContentHandler> logger, IContentService contentService, AppCaches appCaches, IEntityService entityService, IShortStringHelper shortStringHelper, SyncFileService usyncFileService, uSyncEventService usyncEventService, uSyncConfigService usyncConfigService, ISyncItemFactory syncItemFactory) { _logger = logger; _contentService = contentService; _appCaches = appCaches; _entityService = entityService; _shortStringHelper = shortStringHelper; _usyncFileService = usyncFileService; _usyncEventService = usyncEventService; _usyncConfigService = usyncConfigService; _syncItemFactory = syncItemFactory; }
/// <summary> /// Initializes a new instance of the <see cref="uSyncMediaTypeService"/> class. /// </summary> /// <param name="logger">The logger.</param> /// <param name="mediaTypeService">The media type service.</param> /// <param name="appCaches">The application caches.</param> /// <param name="entityService">The entity service.</param> /// <param name="shortStringHelper">The short string helper.</param> /// <param name="uSyncFileService">The u synchronize file service.</param> /// <param name="uSyncEventService">The u synchronize event service.</param> /// <param name="uSyncConfigService">The u synchronize configuration service.</param> /// <param name="syncItemFactory">The synchronize item factory.</param> public uSyncMediaTypeService(ILogger <MediaTypeHandler> logger, IMediaTypeService mediaTypeService, AppCaches appCaches, IEntityService entityService, IShortStringHelper shortStringHelper, SyncFileService uSyncFileService, uSyncEventService uSyncEventService, uSyncConfigService uSyncConfigService, ISyncItemFactory syncItemFactory) { _logger = logger; _mediaTypeService = mediaTypeService; _appCaches = appCaches; _entityService = entityService; _shortStringHelper = shortStringHelper; _uSyncFileService = uSyncFileService; _uSyncEventService = uSyncEventService; _uSyncConfigService = uSyncConfigService; _syncItemFactory = syncItemFactory; }
/// <inheritdoc/> public SyncHandlerBase( ILogger <SyncHandlerBase <TObject, TService> > logger, IEntityService entityService, AppCaches appCaches, IShortStringHelper shortStringHelper, SyncFileService syncFileService, uSyncEventService mutexService, uSyncConfigService uSyncConfig, ISyncItemFactory syncItemFactory) : base(logger, appCaches, shortStringHelper, syncFileService, mutexService, uSyncConfig, syncItemFactory) { this.entityService = entityService; }
/// <inheritdoc/> public MediaHandler( ILogger <MediaHandler> logger, IEntityService entityService, IMediaService mediaService, AppCaches appCaches, IShortStringHelper shortStringHelper, SyncFileService syncFileService, uSyncEventService mutexService, uSyncConfigService uSyncConfigService, ISyncItemFactory syncItemFactory) : base(logger, entityService, appCaches, shortStringHelper, syncFileService, mutexService, uSyncConfigService, syncItemFactory) { this.mediaService = mediaService; }
/// <inheritdoc/> public DomainHandler( ILogger <DomainHandler> logger, IEntityService entityService, IDomainService domainService, AppCaches appCaches, IShortStringHelper shortStringHelper, SyncFileService syncFileService, uSyncEventService mutexService, uSyncConfigService configService, ISyncItemFactory syncItemFactory) : base(logger, entityService, appCaches, shortStringHelper, syncFileService, mutexService, configService, syncItemFactory) { this.domainService = domainService; }
/// <inheritdoc/> public TemplateHandler( ILogger <TemplateHandler> logger, IEntityService entityService, IFileService fileService, AppCaches appCaches, IShortStringHelper shortStringHelper, SyncFileService syncFileService, uSyncEventService mutexService, uSyncConfigService uSyncConfig, ISyncItemFactory syncItemFactory) : base(logger, entityService, appCaches, shortStringHelper, syncFileService, mutexService, uSyncConfig, syncItemFactory) { this.fileService = fileService; }
/// <inheritdoc/> public RelationTypeHandler( ILogger <RelationTypeHandler> logger, IEntityService entityService, IRelationService relationService, AppCaches appCaches, IShortStringHelper shortStringHelper, SyncFileService syncFileService, uSyncEventService mutexService, uSyncConfigService uSyncConfigService, ISyncItemFactory syncItemFactory) : base(logger, entityService, appCaches, shortStringHelper, syncFileService, mutexService, uSyncConfigService, syncItemFactory) { this.relationService = relationService; }
/// <summary> /// Constructor - loaded via DI /// </summary> public ContentTypeHandler( ILogger <ContentTypeHandler> logger, IEntityService entityService, IContentTypeService contentTypeService, AppCaches appCaches, IShortStringHelper shortStringHelper, SyncFileService syncFileService, uSyncEventService mutexService, uSyncConfigService uSyncConfig, ISyncItemFactory syncItemFactory) : base(logger, entityService, appCaches, shortStringHelper, syncFileService, mutexService, uSyncConfig, syncItemFactory) { this.contentTypeService = contentTypeService; }
/// <inheritdoc/> public DictionaryHandler( ILogger <DictionaryHandler> logger, IEntityService entityService, ILocalizationService localizationService, AppCaches appCaches, IShortStringHelper shortStringHelper, SyncFileService syncFileService, uSyncEventService mutexService, uSyncConfigService uSyncConfigService, ISyncItemFactory syncItemFactory) : base(logger, entityService, appCaches, shortStringHelper, syncFileService, mutexService, uSyncConfigService, syncItemFactory) { this.localizationService = localizationService; }
/// <summary> /// Handler constrcutor Loaded via DI /// </summary> public ContentTemplateHandler( ILogger <ContentTemplateHandler> logger, IEntityService entityService, IContentService contentService, AppCaches appCaches, IShortStringHelper shortStringHelper, SyncFileService syncFileService, uSyncEventService mutexService, uSyncConfigService uSyncConfigService, ISyncItemFactory syncItemFactory) : base(logger, entityService, appCaches, shortStringHelper, syncFileService, mutexService, uSyncConfigService, syncItemFactory) { this.contentService = contentService; // make sure we load up the template serializer - because we need that one, not the normal content one. this.serializer = syncItemFactory.GetSerializer <IContent>("contentTemplateSerializer"); }
/// <summary> /// Constructor, called via DI /// </summary> public ContentHandler( ILogger <ContentHandler> logger, IEntityService entityService, IContentService contentService, AppCaches appCaches, IShortStringHelper shortStringHelper, SyncFileService syncFileService, uSyncEventService mutexService, uSyncConfigService uSyncConfigService, ISyncItemFactory syncItemFactory) : base(logger, entityService, appCaches, shortStringHelper, syncFileService, mutexService, uSyncConfigService, syncItemFactory) { this.contentService = contentService; // make sure we get the default content serializer (not just the first one that loads) this.serializer = syncItemFactory.GetSerializer <IContent>("ContentSerializer"); }
/// <summary> /// Create a new uSyncService (done via DI) /// </summary> public uSyncService( ILogger <uSyncService> logger, IEventAggregator eventAggregator, uSyncConfigService uSyncConfigService, SyncHandlerFactory handlerFactory, SyncFileService syncFileService, uSyncEventService mutexService, AppCaches appCaches) { this._logger = logger; this._eventAggregator = eventAggregator; this._uSyncConfig = uSyncConfigService; this._handlerFactory = handlerFactory; this._syncFileService = syncFileService; this._mutexService = mutexService; this._appCache = appCaches.RuntimeCache; uSyncTriggers.DoExport += USyncTriggers_DoExport; uSyncTriggers.DoImport += USyncTriggers_DoImport; }
/// <summary> /// Generate a pause object /// </summary> public uSyncImportPause(uSyncEventService mutexService) { _mutexService = mutexService; _mutexService.Pause(); }