/// <summary>
 /// Initializes a new instance of the <see cref="GoogleDriveFileSystemProvider"/> class.
 /// </summary>
 /// <param name="serviceProvider">The google drive service provider.</param>
 /// <param name="temporaryDataFactory">The factory to create temporary data objects.</param>
 public GoogleDriveFileSystemProvider(
     [NotNull] IGoogleDriveServiceProvider serviceProvider,
     [NotNull] ITemporaryDataFactory temporaryDataFactory)
 {
     _serviceProvider      = serviceProvider;
     _temporaryDataFactory = temporaryDataFactory;
 }
Exemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="GoogleDriveFileSystemProvider"/> class.
 /// </summary>
 /// <param name="serviceProvider">The google drive service provider.</param>
 /// <param name="temporaryDataFactory">The factory to create temporary data objects.</param>
 /// <param name="options">Options for the Google Drive file system.</param>
 public GoogleDriveFileSystemProvider(
     [NotNull] IGoogleDriveServiceProvider serviceProvider,
     [NotNull] ITemporaryDataFactory temporaryDataFactory,
     [NotNull] IOptions <GoogleDriveOptions> options)
 {
     _serviceProvider      = serviceProvider;
     _temporaryDataFactory = temporaryDataFactory;
     _options = options.Value;
 }
Exemplo n.º 3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="GoogleDriveFileSystem"/> class.
 /// </summary>
 /// <param name="service">The <see cref="DriveService"/> instance to use to access the Google Drive.</param>
 /// <param name="rootFolderInfo">The <see cref="Google.Apis.Drive.v3.Data.File"/> to use as root folder.</param>
 /// <param name="temporaryDataFactory">The factory to create temporary data objects.</param>
 public GoogleDriveFileSystem(
     [NotNull] DriveService service,
     [NotNull] File rootFolderInfo,
     [NotNull] ITemporaryDataFactory temporaryDataFactory)
 {
     _temporaryDataFactory = temporaryDataFactory;
     Service = service;
     Root    = new GoogleDriveDirectoryEntry(this, rootFolderInfo, "/", true);
 }
Exemplo n.º 4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="GoogleDriveFileSystem"/> class.
 /// </summary>
 /// <param name="service">The <see cref="DriveService"/> instance to use to access the Google Drive.</param>
 /// <param name="rootFolderInfo">The <see cref="Google.Apis.Drive.v3.Data.File"/> to use as root folder.</param>
 /// <param name="temporaryDataFactory">The factory to create temporary data objects.</param>
 /// <param name="useBackgroundUpload">Use the Google Drive uploader instead of the background uploader.</param>
 public GoogleDriveFileSystem(
     [NotNull] DriveService service,
     [NotNull] File rootFolderInfo,
     [NotNull] ITemporaryDataFactory temporaryDataFactory,
     bool useBackgroundUpload)
 {
     _temporaryDataFactory = temporaryDataFactory;
     _useBackgroundUpload  = useBackgroundUpload;
     Service = service;
     Root    = new GoogleDriveDirectoryEntry(rootFolderInfo, "/", true);
 }