Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
9ddaa05
WIP
annelo-msft Aug 18, 2023
0b2dd7b
revert csproj
annelo-msft Aug 18, 2023
b1263a4
Update RoundTripPatchModel
annelo-msft Aug 18, 2023
0377561
Initial boilerplate for CollectionPatchModel
annelo-msft Aug 18, 2023
3d29ac5
Initial implementation of ChangeList abstraction
annelo-msft Aug 18, 2023
e6a623b
Simple model
annelo-msft Aug 18, 2023
22fc9a4
Backup - working on nested
annelo-msft Aug 18, 2023
cbd5fb1
Add child assignment
annelo-msft Aug 18, 2023
26e0a26
Add note about object assignment
annelo-msft Aug 18, 2023
c7c2dfb
Update CollectionPatchModel; add ChangeListDictionary
annelo-msft Aug 18, 2023
61a2757
remove custom interface
annelo-msft Aug 18, 2023
35170d7
rework parent/child changelist connection
annelo-msft Aug 18, 2023
e13b730
Collections
annelo-msft Aug 18, 2023
182bd35
updates
annelo-msft Aug 18, 2023
ddbf8bf
Merge remote-tracking branch 'upstream/main' into core-mergepatch-cha…
annelo-msft Aug 21, 2023
43fc604
SimpleModel
annelo-msft Aug 22, 2023
4b20fd3
work in progress
annelo-msft Aug 22, 2023
5421759
nested model
annelo-msft Aug 22, 2023
3728133
backup of MergePatchDictionary impl
annelo-msft Aug 22, 2023
a9019de
back up collection work
annelo-msft Aug 22, 2023
9f4b94b
Updates for collection
annelo-msft Aug 22, 2023
1f9ce0d
rename Changed<T>
annelo-msft Aug 22, 2023
efd4819
WIP
annelo-msft Aug 22, 2023
ac7c815
updates
annelo-msft Aug 22, 2023
eb1572a
commented out impl of IModelSerializable
annelo-msft Aug 22, 2023
d83ed9e
misc api
annelo-msft Aug 22, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions sdk/core/Azure.Core/api/Azure.Core.net461.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1127,6 +1127,10 @@ public partial interface IModelSerializable<out T>
T Deserialize(System.BinaryData data, Azure.Core.Serialization.ModelSerializerOptions options);
System.BinaryData Serialize(Azure.Core.Serialization.ModelSerializerOptions options);
}
public partial interface IPatchModel
{
bool HasChanges { get; }
}
public partial class JsonObjectSerializer : Azure.Core.Serialization.ObjectSerializer, Azure.Core.Serialization.IMemberNameConverter
{
public JsonObjectSerializer() { }
Expand All @@ -1145,6 +1149,39 @@ public enum JsonPropertyNames
UseExact = 0,
CamelCase = 1,
}
public partial class MergePatchDictionary<T> : Azure.Core.Serialization.IPatchModel, System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>, System.Collections.Generic.IDictionary<string, T>, System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string, T>>, System.Collections.IEnumerable
{
public MergePatchDictionary(System.Action<System.Text.Json.Utf8JsonWriter, T> writeValue) { }
public MergePatchDictionary(System.Collections.Generic.Dictionary<string, T> dictionary, System.Action<System.Text.Json.Utf8JsonWriter, T> writeValue) { }
public bool HasChanges { get { throw null; } }
public T this[string key] { get { throw null; } set { } }
int System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Count { get { throw null; } }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.IsReadOnly { get { throw null; } }
System.Collections.Generic.ICollection<string> System.Collections.Generic.IDictionary<string, T>.Keys { get { throw null; } }
System.Collections.Generic.ICollection<T> System.Collections.Generic.IDictionary<string, T>.Values { get { throw null; } }
public void Add(string key, T value) { }
public void SerializePatch(System.Text.Json.Utf8JsonWriter writer) { }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Add(System.Collections.Generic.KeyValuePair<string, T> item) { }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Clear() { }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Contains(System.Collections.Generic.KeyValuePair<string, T> item) { throw null; }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.CopyTo(System.Collections.Generic.KeyValuePair<string, T>[] array, int arrayIndex) { }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Remove(System.Collections.Generic.KeyValuePair<string, T> item) { throw null; }
bool System.Collections.Generic.IDictionary<string, T>.ContainsKey(string key) { throw null; }
bool System.Collections.Generic.IDictionary<string, T>.Remove(string key) { throw null; }
System.Collections.Generic.IEnumerator<System.Collections.Generic.KeyValuePair<string, T>> System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string, T>>.GetEnumerator() { throw null; }
System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; }
public bool TryGetValue(string key, out T value) { throw null; }
}
[System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)]
public partial struct MergePatchValue<T>
{
private T _value;
private int _dummyPrimitive;
public MergePatchValue(T value) { throw null; }
public bool HasChanged { get { throw null; } }
public T Value { get { throw null; } set { } }
public static implicit operator T (Azure.Core.Serialization.MergePatchValue<T> value) { throw null; }
}
public partial class ModelJsonConverter : System.Text.Json.Serialization.JsonConverter<Azure.Core.Serialization.IModelJsonSerializable<object>>
{
public ModelJsonConverter() { }
Expand Down
37 changes: 37 additions & 0 deletions sdk/core/Azure.Core/api/Azure.Core.net5.0.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1128,6 +1128,10 @@ public partial interface IModelSerializable<out T>
T Deserialize(System.BinaryData data, Azure.Core.Serialization.ModelSerializerOptions options);
System.BinaryData Serialize(Azure.Core.Serialization.ModelSerializerOptions options);
}
public partial interface IPatchModel
{
bool HasChanges { get; }
}
public partial class JsonObjectSerializer : Azure.Core.Serialization.ObjectSerializer, Azure.Core.Serialization.IMemberNameConverter
{
public JsonObjectSerializer() { }
Expand All @@ -1146,6 +1150,39 @@ public enum JsonPropertyNames
UseExact = 0,
CamelCase = 1,
}
public partial class MergePatchDictionary<T> : Azure.Core.Serialization.IPatchModel, System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>, System.Collections.Generic.IDictionary<string, T>, System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string, T>>, System.Collections.IEnumerable
{
public MergePatchDictionary(System.Action<System.Text.Json.Utf8JsonWriter, T> writeValue) { }
public MergePatchDictionary(System.Collections.Generic.Dictionary<string, T> dictionary, System.Action<System.Text.Json.Utf8JsonWriter, T> writeValue) { }
public bool HasChanges { get { throw null; } }
public T this[string key] { get { throw null; } set { } }
int System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Count { get { throw null; } }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.IsReadOnly { get { throw null; } }
System.Collections.Generic.ICollection<string> System.Collections.Generic.IDictionary<string, T>.Keys { get { throw null; } }
System.Collections.Generic.ICollection<T> System.Collections.Generic.IDictionary<string, T>.Values { get { throw null; } }
public void Add(string key, T value) { }
public void SerializePatch(System.Text.Json.Utf8JsonWriter writer) { }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Add(System.Collections.Generic.KeyValuePair<string, T> item) { }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Clear() { }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Contains(System.Collections.Generic.KeyValuePair<string, T> item) { throw null; }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.CopyTo(System.Collections.Generic.KeyValuePair<string, T>[] array, int arrayIndex) { }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Remove(System.Collections.Generic.KeyValuePair<string, T> item) { throw null; }
bool System.Collections.Generic.IDictionary<string, T>.ContainsKey(string key) { throw null; }
bool System.Collections.Generic.IDictionary<string, T>.Remove(string key) { throw null; }
System.Collections.Generic.IEnumerator<System.Collections.Generic.KeyValuePair<string, T>> System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string, T>>.GetEnumerator() { throw null; }
System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; }
public bool TryGetValue(string key, [System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute(false)] out T value) { throw null; }
}
[System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)]
public partial struct MergePatchValue<T>
{
private T _value;
private int _dummyPrimitive;
public MergePatchValue(T value) { throw null; }
public bool HasChanged { get { throw null; } }
public T Value { get { throw null; } set { } }
public static implicit operator T (Azure.Core.Serialization.MergePatchValue<T> value) { throw null; }
}
public partial class ModelJsonConverter : System.Text.Json.Serialization.JsonConverter<Azure.Core.Serialization.IModelJsonSerializable<object>>
{
public ModelJsonConverter() { }
Expand Down
37 changes: 37 additions & 0 deletions sdk/core/Azure.Core/api/Azure.Core.net6.0.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1128,6 +1128,10 @@ public partial interface IModelSerializable<out T>
T Deserialize(System.BinaryData data, Azure.Core.Serialization.ModelSerializerOptions options);
System.BinaryData Serialize(Azure.Core.Serialization.ModelSerializerOptions options);
}
public partial interface IPatchModel
{
bool HasChanges { get; }
}
public partial class JsonObjectSerializer : Azure.Core.Serialization.ObjectSerializer, Azure.Core.Serialization.IMemberNameConverter
{
public JsonObjectSerializer() { }
Expand All @@ -1146,6 +1150,39 @@ public enum JsonPropertyNames
UseExact = 0,
CamelCase = 1,
}
public partial class MergePatchDictionary<T> : Azure.Core.Serialization.IPatchModel, System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>, System.Collections.Generic.IDictionary<string, T>, System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string, T>>, System.Collections.IEnumerable
{
public MergePatchDictionary(System.Action<System.Text.Json.Utf8JsonWriter, T> writeValue) { }
public MergePatchDictionary(System.Collections.Generic.Dictionary<string, T> dictionary, System.Action<System.Text.Json.Utf8JsonWriter, T> writeValue) { }
public bool HasChanges { get { throw null; } }
public T this[string key] { get { throw null; } set { } }
int System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Count { get { throw null; } }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.IsReadOnly { get { throw null; } }
System.Collections.Generic.ICollection<string> System.Collections.Generic.IDictionary<string, T>.Keys { get { throw null; } }
System.Collections.Generic.ICollection<T> System.Collections.Generic.IDictionary<string, T>.Values { get { throw null; } }
public void Add(string key, T value) { }
public void SerializePatch(System.Text.Json.Utf8JsonWriter writer) { }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Add(System.Collections.Generic.KeyValuePair<string, T> item) { }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Clear() { }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Contains(System.Collections.Generic.KeyValuePair<string, T> item) { throw null; }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.CopyTo(System.Collections.Generic.KeyValuePair<string, T>[] array, int arrayIndex) { }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Remove(System.Collections.Generic.KeyValuePair<string, T> item) { throw null; }
bool System.Collections.Generic.IDictionary<string, T>.ContainsKey(string key) { throw null; }
bool System.Collections.Generic.IDictionary<string, T>.Remove(string key) { throw null; }
System.Collections.Generic.IEnumerator<System.Collections.Generic.KeyValuePair<string, T>> System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string, T>>.GetEnumerator() { throw null; }
System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; }
public bool TryGetValue(string key, [System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute(false)] out T value) { throw null; }
}
[System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)]
public partial struct MergePatchValue<T>
{
private T _value;
private int _dummyPrimitive;
public MergePatchValue(T value) { throw null; }
public bool HasChanged { get { throw null; } }
public T Value { get { throw null; } set { } }
public static implicit operator T (Azure.Core.Serialization.MergePatchValue<T> value) { throw null; }
}
[System.Diagnostics.CodeAnalysis.RequiresUnreferencedCodeAttribute("The constructors of the type being deserialized are dynamically accessed and may be trimmed.")]
public partial class ModelJsonConverter : System.Text.Json.Serialization.JsonConverter<Azure.Core.Serialization.IModelJsonSerializable<object>>
{
Expand Down
37 changes: 37 additions & 0 deletions sdk/core/Azure.Core/api/Azure.Core.netcoreapp2.1.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1127,6 +1127,10 @@ public partial interface IModelSerializable<out T>
T Deserialize(System.BinaryData data, Azure.Core.Serialization.ModelSerializerOptions options);
System.BinaryData Serialize(Azure.Core.Serialization.ModelSerializerOptions options);
}
public partial interface IPatchModel
{
bool HasChanges { get; }
}
public partial class JsonObjectSerializer : Azure.Core.Serialization.ObjectSerializer, Azure.Core.Serialization.IMemberNameConverter
{
public JsonObjectSerializer() { }
Expand All @@ -1145,6 +1149,39 @@ public enum JsonPropertyNames
UseExact = 0,
CamelCase = 1,
}
public partial class MergePatchDictionary<T> : Azure.Core.Serialization.IPatchModel, System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>, System.Collections.Generic.IDictionary<string, T>, System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string, T>>, System.Collections.IEnumerable
{
public MergePatchDictionary(System.Action<System.Text.Json.Utf8JsonWriter, T> writeValue) { }
public MergePatchDictionary(System.Collections.Generic.Dictionary<string, T> dictionary, System.Action<System.Text.Json.Utf8JsonWriter, T> writeValue) { }
public bool HasChanges { get { throw null; } }
public T this[string key] { get { throw null; } set { } }
int System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Count { get { throw null; } }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.IsReadOnly { get { throw null; } }
System.Collections.Generic.ICollection<string> System.Collections.Generic.IDictionary<string, T>.Keys { get { throw null; } }
System.Collections.Generic.ICollection<T> System.Collections.Generic.IDictionary<string, T>.Values { get { throw null; } }
public void Add(string key, T value) { }
public void SerializePatch(System.Text.Json.Utf8JsonWriter writer) { }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Add(System.Collections.Generic.KeyValuePair<string, T> item) { }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Clear() { }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Contains(System.Collections.Generic.KeyValuePair<string, T> item) { throw null; }
void System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.CopyTo(System.Collections.Generic.KeyValuePair<string, T>[] array, int arrayIndex) { }
bool System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string, T>>.Remove(System.Collections.Generic.KeyValuePair<string, T> item) { throw null; }
bool System.Collections.Generic.IDictionary<string, T>.ContainsKey(string key) { throw null; }
bool System.Collections.Generic.IDictionary<string, T>.Remove(string key) { throw null; }
System.Collections.Generic.IEnumerator<System.Collections.Generic.KeyValuePair<string, T>> System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string, T>>.GetEnumerator() { throw null; }
System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; }
public bool TryGetValue(string key, out T value) { throw null; }
}
[System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)]
public partial struct MergePatchValue<T>
{
private T _value;
private int _dummyPrimitive;
public MergePatchValue(T value) { throw null; }
public bool HasChanged { get { throw null; } }
public T Value { get { throw null; } set { } }
public static implicit operator T (Azure.Core.Serialization.MergePatchValue<T> value) { throw null; }
}
public partial class ModelJsonConverter : System.Text.Json.Serialization.JsonConverter<Azure.Core.Serialization.IModelJsonSerializable<object>>
{
public ModelJsonConverter() { }
Expand Down
Loading