// Token: 0x06001236 RID: 4662 RVA: 0x0004D2DC File Offset: 0x0004B4DC
 public PhotoFileEnumerator(PhotosConfiguration configuration, ITracer tracer)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNull("tracer", tracer);
     this.tracer        = tracer;
     this.configuration = configuration;
 }
Пример #2
0
 // Token: 0x060011C1 RID: 4545 RVA: 0x0004A8BC File Offset: 0x00048ABC
 public HttpPhotoRequestBuilder(PhotosConfiguration configuration, ITracer upstreamTracer)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNull("upstreamTracer", upstreamTracer);
     this.configuration = configuration;
     this.tracer        = ExTraceGlobals.UserPhotosTracer.Compose(upstreamTracer);
 }
 public ADPhotoUploadHandler(IRecipientSession session, PhotosConfiguration configuration, IADPhotoReader reader, IADPhotoWriter writer, ITracer upstreamTracer)
 {
     if (session == null)
     {
         throw new ArgumentNullException("session");
     }
     if (configuration == null)
     {
         throw new ArgumentNullException("configuration");
     }
     if (reader == null)
     {
         throw new ArgumentNullException("reader");
     }
     if (writer == null)
     {
         throw new ArgumentNullException("writer");
     }
     if (upstreamTracer == null)
     {
         throw new ArgumentNullException("upstreamTracer");
     }
     this.tracer  = ExTraceGlobals.UserPhotosTracer.Compose(upstreamTracer);
     this.session = session;
     this.photoSizeToUploadToAD = configuration.PhotoSizeToUploadToAD;
     this.reader = reader;
     this.writer = writer;
 }
 public TransparentImagePhotoHandler(PhotosConfiguration configuration, ITracer upstreamTracer)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNull("upstreamTracer", upstreamTracer);
     this.configuration = configuration;
     this.tracer        = upstreamTracer;
 }
 public PhotoRequestLogFactory(PhotosConfiguration configuration, string build)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNullOrEmpty("build", build);
     this.build         = build;
     this.configuration = configuration;
 }
 public PhotoGarbageCollectionLogger(PhotosConfiguration configuration, string logFileName)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNullOrEmpty("logFileName", logFileName);
     this.build = ExchangeSetupContext.InstalledVersion.ToString();
     this.log   = new Log(logFileName, new LogHeaderFormatter(PhotoGarbageCollectionLogger.Schema), "PhotoGarbageCollector");
     this.log.Configure(configuration.GarbageCollectionLoggingPath, configuration.GarbageCollectionLogFileMaxAge, configuration.GarbageCollectionLogDirectoryMaxSize, configuration.GarbageCollectionLogFileMaxSize);
 }
 public PhotoGarbageCollectionScheduler(PhotosConfiguration configuration, IPerformanceDataLogger perfLogger, ITracer tracer)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNull("tracer", tracer);
     this.tracer        = tracer;
     this.configuration = configuration;
     this.collector     = new PhotoGarbageCollector(configuration, perfLogger, tracer);
 }
        public PhotoManagementRetrievalPipeline(PhotosConfiguration configuration, IMailboxSession mailboxSession, IRecipientSession recipientSession, ITracer upstreamTracer)
        {
            MailboxPhotoReader reader  = new MailboxPhotoReader(upstreamTracer);
            MailboxPhotoWriter writer  = new MailboxPhotoWriter(mailboxSession, upstreamTracer);
            ADPhotoReader      reader2 = new ADPhotoReader(upstreamTracer);
            ADPhotoWriter      writer2 = new ADPhotoWriter(recipientSession, upstreamTracer);

            this.pipeline = new MailboxPhotoUploadHandler(mailboxSession, reader, writer, upstreamTracer).Then(new ADPhotoUploadHandler(recipientSession, configuration, reader2, writer2, upstreamTracer));
        }
Пример #9
0
        // Token: 0x0600133F RID: 4927 RVA: 0x0004F5E8 File Offset: 0x0004D7E8
        public PhotoUploadPipeline(PhotosConfiguration configuration, IMailboxSession mailboxSession, IRecipientSession recipientSession, ITracer upstreamTracer)
        {
            MailboxPhotoReader reader  = new MailboxPhotoReader(upstreamTracer);
            MailboxPhotoWriter writer  = new MailboxPhotoWriter(mailboxSession, upstreamTracer);
            ADPhotoReader      reader2 = new ADPhotoReader(upstreamTracer);
            ADPhotoWriter      writer2 = new ADPhotoWriter(recipientSession, upstreamTracer);

            this.pipeline = new PreviewPhotoUploadHandler(mailboxSession, reader, writer, PhotoEditor.Default, upstreamTracer).Then(new ADPhotoUploadHandler(recipientSession, configuration, reader2, writer2, upstreamTracer)).Then(new MailboxPhotoUploadHandler(mailboxSession, reader, writer, upstreamTracer)).Then(new FileSystemPhotoUploadHandler(configuration, new FileSystemPhotoWriter(upstreamTracer), upstreamTracer));
        }
Пример #10
0
 public PrivatePhotoHandler(PhotosConfiguration configuration, IXSOFactory xsoFactory, ITracer upstreamTracer)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNull("xsoFactory", xsoFactory);
     ArgumentValidator.ThrowIfNull("upstreamTracer", upstreamTracer);
     this.configuration = configuration;
     this.xsoFactory    = xsoFactory;
     this.tracer        = upstreamTracer;
 }
 // Token: 0x060012AF RID: 4783 RVA: 0x0004E188 File Offset: 0x0004C388
 public PhotoRequestLog(PhotosConfiguration configuration, string logFileNamePrefix, string build)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNullOrEmpty("logFileNamePrefix", logFileNamePrefix);
     ArgumentValidator.ThrowIfNullOrEmpty("build", build);
     this.build = build;
     this.log   = new Log(logFileNamePrefix, new LogHeaderFormatter(PhotoRequestLog.Schema), "photos");
     this.log.Configure(configuration.PhotoRequestLoggingPath, configuration.PhotoRequestLogFileMaxAge, configuration.PhotoRequestLogDirectoryMaxSize, configuration.PhotoRequestLogFileMaxSize);
 }
 // Token: 0x060011DC RID: 4572 RVA: 0x0004B0D8 File Offset: 0x000492D8
 public LocalServerFallbackToOtherServerPhotoRetrievalPipeline(PhotosConfiguration configuration, string clientInfo, IRecipientSession recipientSession, IXSOFactory xsoFactory, string certificateValidationComponentId, IPhotoServiceLocatorFactory serviceLocatorFactory, IPhotoRequestOutboundWebProxyProvider outgoingRequestProxyProvider, ITracer upstreamTracer)
 {
     this.configuration = configuration;
     this.certificateValidationComponentId = certificateValidationComponentId;
     this.recipientSession             = recipientSession;
     this.serviceLocatorFactory        = serviceLocatorFactory;
     this.outgoingRequestProxyProvider = outgoingRequestProxyProvider;
     this.tracer = upstreamTracer;
     this.localServerPipeline = new LocalServerPhotoRetrievalPipeline(configuration, clientInfo, recipientSession, xsoFactory, upstreamTracer);
 }
Пример #13
0
 // Token: 0x06001227 RID: 4647 RVA: 0x0004CD3C File Offset: 0x0004AF3C
 public OrganizationalPhotoRetrievalPipeline(PhotosConfiguration configuration, string certificateValidationComponentId, string clientInfo, IRecipientSession recipientSession, IPhotoRequestOutboundWebProxyProvider outgoingRequestProxyProvider, IRemoteForestPhotoRetrievalPipelineFactory remoteForestPipelineFactory, IXSOFactory xsoFactory, ITracer tracer)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNullOrEmpty("certificateValidationComponentId", certificateValidationComponentId);
     ArgumentValidator.ThrowIfNullOrEmpty("clientInfo", clientInfo);
     ArgumentValidator.ThrowIfNull("recipientSession", recipientSession);
     ArgumentValidator.ThrowIfNull("outgoingRequestProxyProvider", outgoingRequestProxyProvider);
     ArgumentValidator.ThrowIfNull("remoteForestPipelineFactory", remoteForestPipelineFactory);
     ArgumentValidator.ThrowIfNull("tracer", tracer);
     this.router = new PhotoRequestRouter(configuration, certificateValidationComponentId, clientInfo, recipientSession, new PhotoServiceLocatorFactory(tracer), outgoingRequestProxyProvider, remoteForestPipelineFactory, xsoFactory, tracer);
 }
 // Token: 0x0600130F RID: 4879 RVA: 0x0004EF84 File Offset: 0x0004D184
 public PhotosConfiguration(string exchangeInstallPath, TimeSpan photoFileTimeToLive)
 {
     if (string.IsNullOrEmpty(exchangeInstallPath))
     {
         throw new ArgumentNullException("exchangeInstallPath");
     }
     this.exchangeInstallPath          = exchangeInstallPath;
     this.photoFileTimeToLive          = photoFileTimeToLive;
     this.photosRootDirectoryPath      = PhotosConfiguration.ComputePhotosRootDirectory(exchangeInstallPath);
     this.garbageCollectionLoggingPath = PhotosConfiguration.ComputeGarbageCollectionLoggingPath(exchangeInstallPath);
     this.photoRequestLoggingPath      = PhotosConfiguration.ComputePhotoRequestLoggingPath(exchangeInstallPath);
 }
Пример #15
0
 public OwaPhotoRetrievalPipeline(PhotosConfiguration configuration, string certificateValidationComponentId, string clientInfo, IRecipientSession recipientSession, IPhotoRequestOutboundWebProxyProvider outgoingRequestProxyProvider, IRemoteForestPhotoRetrievalPipelineFactory remoteForestPipelineFactory, IXSOFactory xsoFactory, ITracer upstreamTracer)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNullOrEmpty("certificateValidationComponentId", certificateValidationComponentId);
     ArgumentValidator.ThrowIfNullOrEmpty("clientInfo", clientInfo);
     ArgumentValidator.ThrowIfNull("recipientSession", recipientSession);
     ArgumentValidator.ThrowIfNull("outgoingRequestProxyProvider", outgoingRequestProxyProvider);
     ArgumentValidator.ThrowIfNull("remoteForestPipelineFactory", remoteForestPipelineFactory);
     ArgumentValidator.ThrowIfNull("xsoFactory", xsoFactory);
     ArgumentValidator.ThrowIfNull("upstreamTracer", upstreamTracer);
     this.pipeline = new OrganizationalPhotoRetrievalPipeline(configuration, certificateValidationComponentId, clientInfo, recipientSession, outgoingRequestProxyProvider, remoteForestPipelineFactory, xsoFactory, upstreamTracer).Then(new OrganizationalToPrivatePhotoHandlerTransition(upstreamTracer)).Then(new PrivatePhotoHandler(configuration, xsoFactory, upstreamTracer)).Then(new TransparentImagePhotoHandler(configuration, upstreamTracer));
 }
Пример #16
0
 // Token: 0x060011A5 RID: 4517 RVA: 0x00049FA0 File Offset: 0x000481A0
 public HttpPhotoHandler(PhotosConfiguration configuration, IPhotoRequestOutboundSender outboundRequestSender, IPhotoServiceLocator serviceLocator, IPhotoRequestOutboundWebProxyProvider outgoingRequestProxyProvider, ITracer upstreamTracer)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNull("outboundRequestSender", outboundRequestSender);
     ArgumentValidator.ThrowIfNull("serviceLocator", serviceLocator);
     ArgumentValidator.ThrowIfNull("outgoingRequestProxyProvider", outgoingRequestProxyProvider);
     ArgumentValidator.ThrowIfNull("upstreamTracer", upstreamTracer);
     this.configuration                = configuration;
     this.outboundRequestSender        = outboundRequestSender;
     this.serviceLocator               = serviceLocator;
     this.outgoingRequestProxyProvider = outgoingRequestProxyProvider;
     this.tracer = ExTraceGlobals.UserPhotosTracer.Compose(upstreamTracer);
 }
Пример #17
0
 public MailboxPhotoHandler(PhotosConfiguration configuration, string clientInfo, IMailboxPhotoReader reader, IRecipientSession recipientSession, ITracer upstreamTracer, IXSOFactory xsoFactory)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNullOrEmpty("clientInfo", clientInfo);
     ArgumentValidator.ThrowIfNull("reader", reader);
     ArgumentValidator.ThrowIfNull("recipientSession", recipientSession);
     ArgumentValidator.ThrowIfNull("upstreamTracer", upstreamTracer);
     ArgumentValidator.ThrowIfNull("xsoFactory", xsoFactory);
     this.tracer           = ExTraceGlobals.UserPhotosTracer.Compose(upstreamTracer);
     this.configuration    = configuration;
     this.xsoFactory       = xsoFactory;
     this.reader           = reader;
     this.clientInfo       = clientInfo;
     this.recipientSession = recipientSession;
 }
Пример #18
0
 public CachingPhotoHandler(IFileSystemPhotoWriter writer, PhotosConfiguration configuration, ITracer upstreamTracer)
 {
     if (writer == null)
     {
         throw new ArgumentNullException("writer");
     }
     if (configuration == null)
     {
         throw new ArgumentNullException("configuration");
     }
     if (upstreamTracer == null)
     {
         throw new ArgumentNullException("upstreamTracer");
     }
     this.tracer = ExTraceGlobals.UserPhotosTracer.Compose(upstreamTracer);
     this.writer = writer;
     this.sizesToCacheOnFileSystem    = configuration.SizesToCacheOnFileSystem;
     this.photosRootDirectoryFullPath = configuration.PhotosRootDirectoryFullPath;
 }
 public FileSystemPhotoHandler(PhotosConfiguration configuration, IFileSystemPhotoReader reader, ITracer upstreamTracer)
 {
     if (configuration == null)
     {
         throw new ArgumentNullException("configuration");
     }
     if (reader == null)
     {
         throw new ArgumentNullException("reader");
     }
     if (upstreamTracer == null)
     {
         throw new ArgumentNullException("upstreamTracer");
     }
     this.tracer         = ExTraceGlobals.UserPhotosTracer.Compose(upstreamTracer);
     this.upstreamTracer = upstreamTracer;
     this.photosRootDirectoryFullPath = configuration.PhotosRootDirectoryFullPath;
     this.photoFileTimeToLive         = configuration.PhotoFileTimeToLive;
     this.sizesToCacheOnFileSystem    = configuration.SizesToCacheOnFileSystem;
     this.reader = reader;
 }
Пример #20
0
 public PhotoRequestRouter(PhotosConfiguration configuration, string certificateValidationComponentId, string clientInfo, IRecipientSession recipientSession, IPhotoServiceLocatorFactory serviceLocatorFactory, IPhotoRequestOutboundWebProxyProvider outgoingRequestProxyProvider, IRemoteForestPhotoRetrievalPipelineFactory remoteForestPipelineFactory, IXSOFactory xsoFactory, ITracer upstreamTracer)
 {
     ArgumentValidator.ThrowIfNull("configuration", configuration);
     ArgumentValidator.ThrowIfNullOrEmpty("certificateValidationComponentId", certificateValidationComponentId);
     ArgumentValidator.ThrowIfNullOrEmpty("clientInfo", clientInfo);
     ArgumentValidator.ThrowIfNull("recipientSession", recipientSession);
     ArgumentValidator.ThrowIfNull("serviceLocatorFactory", serviceLocatorFactory);
     ArgumentValidator.ThrowIfNull("outgoingRequestProxyProvider", outgoingRequestProxyProvider);
     ArgumentValidator.ThrowIfNull("remoteForestPipelineFactory", remoteForestPipelineFactory);
     ArgumentValidator.ThrowIfNull("xsoFactory", xsoFactory);
     ArgumentValidator.ThrowIfNull("upstreamTracer", upstreamTracer);
     this.configuration = configuration;
     this.certificateValidationComponentId = certificateValidationComponentId;
     this.clientInfo                   = clientInfo;
     this.recipientSession             = recipientSession;
     this.serviceLocatorFactory        = serviceLocatorFactory;
     this.outgoingRequestProxyProvider = outgoingRequestProxyProvider;
     this.remoteForestPipelineFactory  = remoteForestPipelineFactory;
     this.xsoFactory                   = xsoFactory;
     this.tracer = upstreamTracer;
 }
Пример #21
0
 public FileSystemPhotoUploadHandler(PhotosConfiguration configuration, IFileSystemPhotoWriter writer, ITracer upstreamTracer)
 {
     if (configuration == null)
     {
         throw new ArgumentNullException("configuration");
     }
     if (!new DirectoryInfo(configuration.ExchangeInstallPath).Exists)
     {
         throw new ArgumentException("configuration.ExchangeInstallPath");
     }
     if (writer == null)
     {
         throw new ArgumentNullException("writer");
     }
     if (upstreamTracer == null)
     {
         throw new ArgumentNullException("upstreamTracer");
     }
     this.tracer         = ExTraceGlobals.UserPhotosTracer.Compose(upstreamTracer);
     this.upstreamTracer = upstreamTracer;
     this.writer         = writer;
     this.photosRootDirectoryFullPath = configuration.PhotosRootDirectoryFullPath;
     this.sizesToCacheOnFileSystem    = configuration.SizesToCacheOnFileSystem;
 }
        // Token: 0x0600136D RID: 4973 RVA: 0x00050574 File Offset: 0x0004E774
        public string ComputeExpiresHeader(DateTime utcNow, HttpStatusCode statusCode, PhotosConfiguration configuration)
        {
            if (statusCode <= HttpStatusCode.NotModified)
            {
                if (statusCode != HttpStatusCode.OK)
                {
                    switch (statusCode)
                    {
                    case HttpStatusCode.Found:
                    case HttpStatusCode.NotModified:
                        break;

                    case HttpStatusCode.SeeOther:
                        goto IL_64;

                    default:
                        goto IL_64;
                    }
                }
                return(UserAgentPhotoExpiresHeader.FormatTimestampForExpiresHeader(utcNow.Add(configuration.UserAgentCacheTimeToLive)));
            }
            if (statusCode == HttpStatusCode.NotFound)
            {
                return(UserAgentPhotoExpiresHeader.FormatTimestampForExpiresHeader(utcNow.Add(configuration.UserAgentCacheTimeToLiveNotFound)));
            }
            if (statusCode != HttpStatusCode.InternalServerError)
            {
            }
IL_64:
            return(string.Empty);
        }
 public LocalForestOtherServerPhotoRetrievalPipeline(PhotosConfiguration configuration, string certificateValidationComponentId, IPhotoServiceLocator serviceLocator, IRecipientSession recipientSession, IPhotoRequestOutboundWebProxyProvider outgoingRequestProxyProvider, ITracer upstreamTracer)
 {
     this.pipeline = new HttpPhotoHandler(configuration, this.CreateOutboundSender(certificateValidationComponentId, upstreamTracer), serviceLocator, outgoingRequestProxyProvider, upstreamTracer).Then(new ADPhotoHandler(new ADPhotoReader(upstreamTracer), recipientSession, upstreamTracer));
 }
 // Token: 0x0600135A RID: 4954 RVA: 0x00050277 File Offset: 0x0004E477
 public SelfPhotoRetrievalPipeline(PhotosConfiguration configuration, string clientInfo, IRecipientSession recipientSession, IXSOFactory xsoFactory, ITracer upstreamTracer)
 {
     this.pipeline = new MailboxPhotoHandler(configuration, clientInfo, new MailboxPhotoReader(upstreamTracer), recipientSession, upstreamTracer, xsoFactory).Then(new ADPhotoHandler(new ADPhotoReader(upstreamTracer), recipientSession, upstreamTracer));
 }
Пример #25
0
 // Token: 0x060011E2 RID: 4578 RVA: 0x0004B1F4 File Offset: 0x000493F4
 public LocalServerPhotoRetrievalPipeline(PhotosConfiguration configuration, string clientInfo, IRecipientSession recipientSession, IXSOFactory xsoFactory, ITracer upstreamTracer)
 {
     this.pipeline = new FileSystemPhotoHandler(configuration, new FileSystemPhotoReader(upstreamTracer), upstreamTracer).Then(new MailboxPhotoHandler(configuration, clientInfo, new MailboxPhotoReader(upstreamTracer), recipientSession, upstreamTracer, xsoFactory)).Then(new ADPhotoHandler(new ADPhotoReader(upstreamTracer), recipientSession, upstreamTracer)).Then(new CachingPhotoHandler(new FileSystemPhotoWriter(upstreamTracer), configuration, upstreamTracer)).Then(new DiagnosticsPhotoHandler(upstreamTracer));
 }