Skip to content

Commit 0da32b8

Browse files
committed
v4.1.12172.0-Beta2
1 parent e9de969 commit 0da32b8

File tree

90 files changed

+1830
-1601
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

90 files changed

+1830
-1601
lines changed

Common/Common.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@
99
<RootNamespace>ITHit.FileSystem.Samples.Common</RootNamespace>
1010
</PropertyGroup>
1111
<ItemGroup>
12-
<PackageReference Include="ITHit.FileSystem" Version="4.0.11399.0-Beta" />
12+
<PackageReference Include="ITHit.FileSystem" Version="4.1.12172.0-Beta2" />
1313
</ItemGroup>
1414
</Project>

Common/FileSystemItemMetadataExt.cs

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ namespace ITHit.FileSystem.Samples.Common
1313
public class FileSystemItemMetadataExt : IFileSystemItemMetadata
1414
{
1515
/// <inheritdoc/>
16-
public byte[] ItemId { get; set; }
16+
public byte[] RemoteStorageItemId { get; set; }
1717

1818
///<inheritdoc/>
1919
public string Name { get; set; }
@@ -37,14 +37,13 @@ public class FileSystemItemMetadataExt : IFileSystemItemMetadata
3737
public DateTimeOffset ChangeTime { get; set; }
3838

3939
/// <summary>
40-
/// Server ETag.
40+
/// Lock info.
4141
/// </summary>
42-
public string ETag { get; set; }
43-
44-
/// <summary>
45-
/// Indicates if the item is locked in the remote storage.
46-
/// </summary>
47-
public bool IsLocked { get; set; } = false;
42+
/// <remarks>
43+
/// If the item is locked, this property contains info about the lock.
44+
/// It is set to null otherwise.
45+
/// </remarks>
46+
public ServerLockInfo Lock { get; set; }
4847

4948
/// <summary>
5049
/// Custom columns data to be displayed in the file manager.

Common/ServerLockInfo.cs

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using System.Text;
4+
5+
namespace ITHit.FileSystem.Samples.Common
6+
{
7+
/// <summary>
8+
/// Information about the lock returned from the remote storage as a result of the lock operation.
9+
/// </summary>
10+
public class ServerLockInfo
11+
{
12+
/// <summary>
13+
/// Lock-token. Must be supplied during the item update and unlock operations.
14+
/// </summary>
15+
public string LockToken { get; set; }
16+
17+
/// <summary>
18+
/// Lock expidation date/time returned by the server.
19+
/// </summary>
20+
public DateTimeOffset LockExpirationDateUtc { get; set; }
21+
22+
/// <summary>
23+
/// Name of the user that locked the item.
24+
/// </summary>
25+
public string Owner { get; set; }
26+
27+
/// <summary>
28+
/// True if the item is locked exclusively. False in case the item has a shared lock.
29+
/// </summary>
30+
public bool Exclusive { get; set; } = true;
31+
}
32+
}

Common/Settings.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -50,15 +50,10 @@ public class Settings
5050
public string ProductName { get; set; }
5151

5252
/// <summary>
53-
/// Automatically lock the file in remote storage when a file handle is being opened for writing, unlock on close.
53+
/// Automatically lock the file in the remote storage when a file handle is being opened for writing, unlock on close.
5454
/// </summary>
5555
public bool AutoLock { get; set; }
5656

57-
/// <summary>
58-
/// Path to the folder that stores custom data associated with files and folders.
59-
/// </summary>
60-
public string ServerDataFolderPath { get; set; }
61-
6257
/// <summary>
6358
/// Communication channel name is used by RPC to establish connection over named pipes.
6459
/// </summary>

Windows/Common/Core/Common.Windows.Core.csproj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,14 @@
77
<Product>IT Hit User File System</Product>
88
<Copyright>IT Hit LTD.</Copyright>
99
<RootNamespace>ITHit.FileSystem.Samples.Common.Windows.Core</RootNamespace>
10+
<Platforms>AnyCPU;x64</Platforms>
1011
</PropertyGroup>
1112
<ItemGroup>
1213
<PackageReference Include="log4net" Version="2.0.13" />
1314
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="5.0.0" />
1415
</ItemGroup>
1516
<ItemGroup>
16-
<PackageReference Include="ITHit.FileSystem.Windows" Version="4.0.11399.0-Beta" />
17+
<PackageReference Include="ITHit.FileSystem.Windows" Version="4.1.12172.0-Beta2" />
1718
<ProjectReference Include="..\..\..\Common\Common.csproj" />
1819
</ItemGroup>
1920
</Project>

Windows/Common/Core/Logger.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
namespace ITHit.FileSystem.Samples.Common.Windows
1212
{
1313
/// <summary>
14-
/// Implements unified logging.
14+
/// Implements logging.
1515
/// </summary>
1616
public class Logger : ILogger
1717
{
@@ -42,7 +42,7 @@ public void LogError(string message, string sourcePath = null, string targetPath
4242
string att = FsPath.Exists(sourcePath) ? FsPath.GetAttString(sourcePath) : null;
4343
string process = null;
4444
byte? priorityHint = null;
45-
long? clientFileId = null;
45+
ulong? clientFileId = null;
4646

4747
if (operationContext != null)
4848
{
@@ -61,7 +61,7 @@ public void LogMessage(string message, string sourcePath = null, string targetPa
6161
string att = FsPath.Exists(sourcePath) ? FsPath.GetAttString(sourcePath) : null;
6262
string process = null;
6363
byte? priorityHint = null;
64-
long? clientFileId = null;
64+
ulong? clientFileId = null;
6565
string size = null;
6666

6767
if (operationContext != null)

Windows/Common/Core/Registrar.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ public static async Task RegisterAsync(string syncRootId, string path, string di
5959

6060

6161
// Adds columns to Windows File Manager.
62-
// Show/hide columns in the "More..." context menu on the columns header.
62+
// Show/hide columns in the "More..." context menu on the columns header in Windows Explorer.
6363
var proDefinitions = storageInfo.StorageProviderItemPropertyDefinitions;
6464
proDefinitions.Add(new StorageProviderItemPropertyDefinition { DisplayNameResource = "Lock Owner" , Id = (int)CustomColumnIds.LockOwnerIcon });
6565
proDefinitions.Add(new StorageProviderItemPropertyDefinition { DisplayNameResource = "Lock Scope" , Id = (int)CustomColumnIds.LockScope });

Windows/Common/Rpc.Proto/Common.Windows.Rpc.Proto.csproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
<Product>IT Hit User File System</Product>
1010
<Copyright>IT Hit LTD.</Copyright>
1111
<RootNamespace>ITHit.FileSystem.Samples.Common.Windows.Rpc.Proto</RootNamespace>
12+
<Platforms>AnyCPU;x64</Platforms>
1213
</PropertyGroup>
1314

1415
<ItemGroup>

Windows/Common/Rpc.Proto/ShellExtension.proto

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ service ShellExtensionRpc {
66
rpc SetLockStatus (ItemsStatusList) returns (EmptyMessage) {}
77
rpc GetLockStatus (ItemsPathList) returns (ItemsStatusList) {}
88
rpc GetThumbnail (ThumbnailRequest) returns (Thumbnail) {}
9+
rpc LogMessage (LogMessageRequest) returns (EmptyMessage) {}
10+
rpc LogError (LogErrorRequest) returns (EmptyMessage) {}
11+
rpc GetItemProperties (ItemPropertyRequest) returns (ItemsPropertyList) {}
912
}
1013

1114
message ItemsPathList {
@@ -25,5 +28,34 @@ message Thumbnail {
2528
bytes image = 1;
2629
}
2730

31+
message LogMessageRequest {
32+
string componentName = 1;
33+
string message = 2;
34+
string sourcePath = 3;
35+
string targetPath = 4;
36+
}
37+
38+
message LogErrorRequest {
39+
string componentName = 1;
40+
string message = 2;
41+
string sourcePath = 3;
42+
string targetPath = 4;
43+
string exSerialized = 5;
44+
}
45+
2846
message EmptyMessage {
2947
}
48+
49+
message ItemProperty {
50+
string iconResource = 1;
51+
int32 id = 2;
52+
string value = 3;
53+
}
54+
55+
message ItemsPropertyList {
56+
repeated ItemProperty properties = 1;
57+
}
58+
59+
message ItemPropertyRequest {
60+
string path = 1;
61+
}

Windows/Common/Rpc/Common.Windows.Rpc.csproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
<Product>IT Hit User File System</Product>
88
<Copyright>IT Hit LTD.</Copyright>
99
<RootNamespace>ITHit.FileSystem.Samples.Common.Windows.Rpc</RootNamespace>
10+
<Platforms>AnyCPU;x64</Platforms>
1011
</PropertyGroup>
1112
<ItemGroup>
1213
<PackageReference Include="log4net" Version="2.0.13" />

0 commit comments

Comments
 (0)