Skip to content

Commit 54d9036

Browse files
committed
Update project URL in examples websites to avoid potential conflict.
1 parent 987d539 commit 54d9036

Some content is hidden

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

52 files changed

+5893
-128
lines changed

Dropbox.Api/Auth/AuthError.cs

Lines changed: 109 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,28 @@ public InvalidSelectAdmin AsInvalidSelectAdmin
100100
}
101101
}
102102

103+
/// <summary>
104+
/// <para>Gets a value indicating whether this instance is UserSuspended</para>
105+
/// </summary>
106+
public bool IsUserSuspended
107+
{
108+
get
109+
{
110+
return this is UserSuspended;
111+
}
112+
}
113+
114+
/// <summary>
115+
/// <para>Gets this instance as a UserSuspended, or <c>null</c>.</para>
116+
/// </summary>
117+
public UserSuspended AsUserSuspended
118+
{
119+
get
120+
{
121+
return this as UserSuspended;
122+
}
123+
}
124+
103125
/// <summary>
104126
/// <para>Gets a value indicating whether this instance is Other</para>
105127
/// </summary>
@@ -154,6 +176,12 @@ public override void EncodeFields(AuthError value, enc.IJsonWriter writer)
154176
InvalidSelectAdmin.Encoder.EncodeFields((InvalidSelectAdmin)value, writer);
155177
return;
156178
}
179+
if (value is UserSuspended)
180+
{
181+
WriteProperty(".tag", "user_suspended", writer, enc.StringEncoder.Instance);
182+
UserSuspended.Encoder.EncodeFields((UserSuspended)value, writer);
183+
return;
184+
}
157185
if (value is Other)
158186
{
159187
WriteProperty(".tag", "other", writer, enc.StringEncoder.Instance);
@@ -198,6 +226,8 @@ protected override AuthError Decode(string tag, enc.IJsonReader reader)
198226
return InvalidSelectUser.Decoder.DecodeFields(reader);
199227
case "invalid_select_admin":
200228
return InvalidSelectAdmin.Decoder.DecodeFields(reader);
229+
case "user_suspended":
230+
return UserSuspended.Decoder.DecodeFields(reader);
201231
default:
202232
return Other.Decoder.DecodeFields(reader);
203233
}
@@ -448,6 +478,85 @@ public override InvalidSelectAdmin DecodeFields(enc.IJsonReader reader)
448478
#endregion
449479
}
450480

481+
/// <summary>
482+
/// <para>The user has been suspended.</para>
483+
/// </summary>
484+
public sealed class UserSuspended : AuthError
485+
{
486+
#pragma warning disable 108
487+
488+
/// <summary>
489+
/// <para>The encoder instance.</para>
490+
/// </summary>
491+
internal static enc.StructEncoder<UserSuspended> Encoder = new UserSuspendedEncoder();
492+
493+
/// <summary>
494+
/// <para>The decoder instance.</para>
495+
/// </summary>
496+
internal static enc.StructDecoder<UserSuspended> Decoder = new UserSuspendedDecoder();
497+
498+
/// <summary>
499+
/// <para>Initializes a new instance of the <see cref="UserSuspended" />
500+
/// class.</para>
501+
/// </summary>
502+
private UserSuspended()
503+
{
504+
}
505+
506+
/// <summary>
507+
/// <para>A singleton instance of UserSuspended</para>
508+
/// </summary>
509+
public static readonly UserSuspended Instance = new UserSuspended();
510+
511+
#region Encoder class
512+
513+
/// <summary>
514+
/// <para>Encoder for <see cref="UserSuspended" />.</para>
515+
/// </summary>
516+
private class UserSuspendedEncoder : enc.StructEncoder<UserSuspended>
517+
{
518+
/// <summary>
519+
/// <para>Encode fields of given value.</para>
520+
/// </summary>
521+
/// <param name="value">The value.</param>
522+
/// <param name="writer">The writer.</param>
523+
public override void EncodeFields(UserSuspended value, enc.IJsonWriter writer)
524+
{
525+
}
526+
}
527+
528+
#endregion
529+
530+
#region Decoder class
531+
532+
/// <summary>
533+
/// <para>Decoder for <see cref="UserSuspended" />.</para>
534+
/// </summary>
535+
private class UserSuspendedDecoder : enc.StructDecoder<UserSuspended>
536+
{
537+
/// <summary>
538+
/// <para>Create a new instance of type <see cref="UserSuspended" />.</para>
539+
/// </summary>
540+
/// <returns>The struct instance.</returns>
541+
protected override UserSuspended Create()
542+
{
543+
return new UserSuspended();
544+
}
545+
546+
/// <summary>
547+
/// <para>Decode fields without ensuring start and end object.</para>
548+
/// </summary>
549+
/// <param name="reader">The json reader.</param>
550+
/// <returns>The decoded object.</returns>
551+
public override UserSuspended DecodeFields(enc.IJsonReader reader)
552+
{
553+
return UserSuspended.Instance;
554+
}
555+
}
556+
557+
#endregion
558+
}
559+
451560
/// <summary>
452561
/// <para>The other object</para>
453562
/// </summary>

Dropbox.Api/Dropbox.Api.Portable.csproj

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,13 @@
8888
<Compile Include="Files\CreateFolderArg.cs" />
8989
<Compile Include="Files\CreateFolderError.cs" />
9090
<Compile Include="Files\DeleteArg.cs" />
91+
<Compile Include="Files\DeleteBatchArg.cs" />
92+
<Compile Include="Files\DeleteBatchError.cs" />
93+
<Compile Include="Files\DeleteBatchJobStatus.cs" />
94+
<Compile Include="Files\DeleteBatchResult.cs" />
95+
<Compile Include="Files\DeleteBatchResultEntry.cs" />
9196
<Compile Include="Files\DeleteError.cs" />
97+
<Compile Include="Files\DeleteResult.cs" />
9298
<Compile Include="Files\DeletedMetadata.cs" />
9399
<Compile Include="Files\Dimensions.cs" />
94100
<Compile Include="Files\DownloadArg.cs" />
@@ -125,14 +131,21 @@
125131
<Compile Include="Files\MediaInfo.cs" />
126132
<Compile Include="Files\MediaMetadata.cs" />
127133
<Compile Include="Files\Metadata.cs" />
134+
<Compile Include="Files\PathRootError.cs" />
128135
<Compile Include="Files\PhotoMetadata.cs" />
129136
<Compile Include="Files\PreviewArg.cs" />
130137
<Compile Include="Files\PreviewError.cs" />
131138
<Compile Include="Files\PropertiesError.cs" />
132139
<Compile Include="Files\PropertyGroupUpdate.cs" />
133140
<Compile Include="Files\PropertyGroupWithPath.cs" />
134141
<Compile Include="Files\RelocationArg.cs" />
142+
<Compile Include="Files\RelocationBatchArg.cs" />
143+
<Compile Include="Files\RelocationBatchError.cs" />
144+
<Compile Include="Files\RelocationBatchJobStatus.cs" />
145+
<Compile Include="Files\RelocationBatchResult.cs" />
135146
<Compile Include="Files\RelocationError.cs" />
147+
<Compile Include="Files\RelocationPath.cs" />
148+
<Compile Include="Files\RelocationResult.cs" />
136149
<Compile Include="Files\RemovePropertiesArg.cs" />
137150
<Compile Include="Files\RemovePropertiesError.cs" />
138151
<Compile Include="Files\RestoreArg.cs" />

Dropbox.Api/Dropbox.Api.Portable40.csproj

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,13 @@
112112
<Compile Include="Files\CreateFolderArg.cs" />
113113
<Compile Include="Files\CreateFolderError.cs" />
114114
<Compile Include="Files\DeleteArg.cs" />
115+
<Compile Include="Files\DeleteBatchArg.cs" />
116+
<Compile Include="Files\DeleteBatchError.cs" />
117+
<Compile Include="Files\DeleteBatchJobStatus.cs" />
118+
<Compile Include="Files\DeleteBatchResult.cs" />
119+
<Compile Include="Files\DeleteBatchResultEntry.cs" />
115120
<Compile Include="Files\DeleteError.cs" />
121+
<Compile Include="Files\DeleteResult.cs" />
116122
<Compile Include="Files\DeletedMetadata.cs" />
117123
<Compile Include="Files\Dimensions.cs" />
118124
<Compile Include="Files\DownloadArg.cs" />
@@ -149,14 +155,21 @@
149155
<Compile Include="Files\MediaInfo.cs" />
150156
<Compile Include="Files\MediaMetadata.cs" />
151157
<Compile Include="Files\Metadata.cs" />
158+
<Compile Include="Files\PathRootError.cs" />
152159
<Compile Include="Files\PhotoMetadata.cs" />
153160
<Compile Include="Files\PreviewArg.cs" />
154161
<Compile Include="Files\PreviewError.cs" />
155162
<Compile Include="Files\PropertiesError.cs" />
156163
<Compile Include="Files\PropertyGroupUpdate.cs" />
157164
<Compile Include="Files\PropertyGroupWithPath.cs" />
158165
<Compile Include="Files\RelocationArg.cs" />
166+
<Compile Include="Files\RelocationBatchArg.cs" />
167+
<Compile Include="Files\RelocationBatchError.cs" />
168+
<Compile Include="Files\RelocationBatchJobStatus.cs" />
169+
<Compile Include="Files\RelocationBatchResult.cs" />
159170
<Compile Include="Files\RelocationError.cs" />
171+
<Compile Include="Files\RelocationPath.cs" />
172+
<Compile Include="Files\RelocationResult.cs" />
160173
<Compile Include="Files\RemovePropertiesArg.cs" />
161174
<Compile Include="Files\RemovePropertiesError.cs" />
162175
<Compile Include="Files\RestoreArg.cs" />

Dropbox.Api/Dropbox.Api.csproj

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,13 @@
9393
<Compile Include="Files\CreateFolderArg.cs" />
9494
<Compile Include="Files\CreateFolderError.cs" />
9595
<Compile Include="Files\DeleteArg.cs" />
96+
<Compile Include="Files\DeleteBatchArg.cs" />
97+
<Compile Include="Files\DeleteBatchError.cs" />
98+
<Compile Include="Files\DeleteBatchJobStatus.cs" />
99+
<Compile Include="Files\DeleteBatchResult.cs" />
100+
<Compile Include="Files\DeleteBatchResultEntry.cs" />
96101
<Compile Include="Files\DeleteError.cs" />
102+
<Compile Include="Files\DeleteResult.cs" />
97103
<Compile Include="Files\DeletedMetadata.cs" />
98104
<Compile Include="Files\Dimensions.cs" />
99105
<Compile Include="Files\DownloadArg.cs" />
@@ -130,14 +136,21 @@
130136
<Compile Include="Files\MediaInfo.cs" />
131137
<Compile Include="Files\MediaMetadata.cs" />
132138
<Compile Include="Files\Metadata.cs" />
139+
<Compile Include="Files\PathRootError.cs" />
133140
<Compile Include="Files\PhotoMetadata.cs" />
134141
<Compile Include="Files\PreviewArg.cs" />
135142
<Compile Include="Files\PreviewError.cs" />
136143
<Compile Include="Files\PropertiesError.cs" />
137144
<Compile Include="Files\PropertyGroupUpdate.cs" />
138145
<Compile Include="Files\PropertyGroupWithPath.cs" />
139146
<Compile Include="Files\RelocationArg.cs" />
147+
<Compile Include="Files\RelocationBatchArg.cs" />
148+
<Compile Include="Files\RelocationBatchError.cs" />
149+
<Compile Include="Files\RelocationBatchJobStatus.cs" />
150+
<Compile Include="Files\RelocationBatchResult.cs" />
140151
<Compile Include="Files\RelocationError.cs" />
152+
<Compile Include="Files\RelocationPath.cs" />
153+
<Compile Include="Files\RelocationResult.cs" />
141154
<Compile Include="Files\RemovePropertiesArg.cs" />
142155
<Compile Include="Files\RemovePropertiesError.cs" />
143156
<Compile Include="Files\RestoreArg.cs" />

Dropbox.Api/Files/AlphaGetMetadataArg.cs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public class AlphaGetMetadataArg : GetMetadataArg
4242
/// <param name="includeHasExplicitSharedMembers">If true, the results will include a
4343
/// flag for each file indicating whether or not that file has any explicit
4444
/// members.</param>
45-
/// <param name="includePropertyTemplates">If true, <see
45+
/// <param name="includePropertyTemplates">If set to a valid list of template IDs, <see
4646
/// cref="Dropbox.Api.Files.FileMetadata.PropertyGroups" /> is set for files with
4747
/// custom properties.</param>
4848
public AlphaGetMetadataArg(string path,
@@ -68,8 +68,9 @@ public AlphaGetMetadataArg()
6868
}
6969

7070
/// <summary>
71-
/// <para>If true, <see cref="Dropbox.Api.Files.FileMetadata.PropertyGroups" /> is set
72-
/// for files with custom properties.</para>
71+
/// <para>If set to a valid list of template IDs, <see
72+
/// cref="Dropbox.Api.Files.FileMetadata.PropertyGroups" /> is set for files with
73+
/// custom properties.</para>
7374
/// </summary>
7475
public col.IList<string> IncludePropertyTemplates { get; protected set; }
7576

Dropbox.Api/Files/CreateFolderArg.cs

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,10 @@ public class CreateFolderArg
3232
/// class.</para>
3333
/// </summary>
3434
/// <param name="path">Path in the user's Dropbox to create.</param>
35-
public CreateFolderArg(string path)
35+
/// <param name="autorename">If there's a conflict, have the Dropbox server try to
36+
/// autorename the folder to avoid the conflict.</param>
37+
public CreateFolderArg(string path,
38+
bool autorename = false)
3639
{
3740
if (path == null)
3841
{
@@ -44,6 +47,7 @@ public CreateFolderArg(string path)
4447
}
4548

4649
this.Path = path;
50+
this.Autorename = autorename;
4751
}
4852

4953
/// <summary>
@@ -54,13 +58,20 @@ public CreateFolderArg(string path)
5458
/// deserializing.</remarks>
5559
public CreateFolderArg()
5660
{
61+
this.Autorename = false;
5762
}
5863

5964
/// <summary>
6065
/// <para>Path in the user's Dropbox to create.</para>
6166
/// </summary>
6267
public string Path { get; protected set; }
6368

69+
/// <summary>
70+
/// <para>If there's a conflict, have the Dropbox server try to autorename the folder
71+
/// to avoid the conflict.</para>
72+
/// </summary>
73+
public bool Autorename { get; protected set; }
74+
6475
#region Encoder class
6576

6677
/// <summary>
@@ -76,6 +87,7 @@ private class CreateFolderArgEncoder : enc.StructEncoder<CreateFolderArg>
7687
public override void EncodeFields(CreateFolderArg value, enc.IJsonWriter writer)
7788
{
7889
WriteProperty("path", value.Path, writer, enc.StringEncoder.Instance);
90+
WriteProperty("autorename", value.Autorename, writer, enc.BooleanEncoder.Instance);
7991
}
8092
}
8193

@@ -111,6 +123,9 @@ protected override void SetField(CreateFolderArg value, string fieldName, enc.IJ
111123
case "path":
112124
value.Path = enc.StringDecoder.Instance.Decode(reader);
113125
break;
126+
case "autorename":
127+
value.Autorename = enc.BooleanDecoder.Instance.Decode(reader);
128+
break;
114129
default:
115130
reader.Skip();
116131
break;

0 commit comments

Comments
 (0)