From e22cec1b62910c51f6e5be85d2528ddcc53141a7 Mon Sep 17 00:00:00 2001 From: Stef Heyenrath Date: Sat, 17 Dec 2022 13:36:41 +0100 Subject: [PATCH] Add support for Property and Method attributes (#49) * . * . * P en E * . --- .../Constants/InternalClassNames.cs | 2 + .../Extensions/MethodSymbolExtensions.cs | 5 - .../Extensions/ParameterSymbolExtensions.cs | 11 - .../Extensions/PropertySymbolExtensions.cs | 2 - .../Extensions/SymbolExtensions.cs | 26 +++ .../PartialInterfacesGenerator.cs | 16 ++ .../FileGenerators/ProxyClassesGenerator.cs | 25 +- ...t.SharePoint.Client.ClientObjectProxy.g.cs | 7 + ...oint.Client.ClientRuntimeContextProxy.g.cs | 3 + ...harePoint.Client.SecurableObjectProxy.g.cs | 5 + .../Microsoft.SharePoint.Client.WebProxy.g.cs | 216 ++++++++++++++++++ ...ceSourceGeneratorTests.Source.IPerson.g.cs | 3 + ...urceGeneratorTests.Source.PersonProxy.g.cs | 3 + ...neratorTests.Source.PnP.IClientObject.g.cs | 7 + ...ests.Source.PnP.IClientRuntimeContext.g.cs | 3 + ...atorTests.Source.PnP.ISecurableObject.g.cs | 5 + ...eSourceGeneratorTests.Source.PnP.IWeb.g.cs | 216 ++++++++++++++++++ .../Source/Person.cs | 4 + .../Source/PersonExtends.cs | 7 +- 19 files changed, 535 insertions(+), 31 deletions(-) diff --git a/src/ProxyInterfaceSourceGenerator/Constants/InternalClassNames.cs b/src/ProxyInterfaceSourceGenerator/Constants/InternalClassNames.cs index 1fbc5c1..cdc9a9a 100644 --- a/src/ProxyInterfaceSourceGenerator/Constants/InternalClassNames.cs +++ b/src/ProxyInterfaceSourceGenerator/Constants/InternalClassNames.cs @@ -3,4 +3,6 @@ namespace ProxyInterfaceSourceGenerator.Constants; internal static class InternalClassNames { public const string NullableAttribute = "System.Runtime.CompilerServices.NullableAttribute"; + + public const string AsyncStateMachineAttribute = "System.Runtime.CompilerServices.AsyncStateMachineAttribute"; } \ No newline at end of file diff --git a/src/ProxyInterfaceSourceGenerator/Extensions/MethodSymbolExtensions.cs b/src/ProxyInterfaceSourceGenerator/Extensions/MethodSymbolExtensions.cs index ec9cd1e..818fcd8 100644 --- a/src/ProxyInterfaceSourceGenerator/Extensions/MethodSymbolExtensions.cs +++ b/src/ProxyInterfaceSourceGenerator/Extensions/MethodSymbolExtensions.cs @@ -7,11 +7,6 @@ internal static class MethodSymbolExtensions public static string GetMethodNameWithOptionalTypeParameters(this IMethodSymbol method) => !method.IsGenericMethod ? method.Name : $"{method.Name}<{string.Join(", ", method.TypeParameters.Select(tp => tp.Name))}>"; - public static bool IsPublic(this IMethodSymbol? methodSymbol) - { - return methodSymbol is { DeclaredAccessibility: Accessibility.Public }; - } - //public static string GetWhereStatement(this IMethodSymbol method) => // !method.IsGenericMethod ? string.Empty : string.Join("", method.TypeParameters.Select(tp => tp.GetWhereConstraints())); } \ No newline at end of file diff --git a/src/ProxyInterfaceSourceGenerator/Extensions/ParameterSymbolExtensions.cs b/src/ProxyInterfaceSourceGenerator/Extensions/ParameterSymbolExtensions.cs index df2c7b2..bc2682c 100644 --- a/src/ProxyInterfaceSourceGenerator/Extensions/ParameterSymbolExtensions.cs +++ b/src/ProxyInterfaceSourceGenerator/Extensions/ParameterSymbolExtensions.cs @@ -1,6 +1,5 @@ using Microsoft.CodeAnalysis; using Microsoft.CodeAnalysis.CSharp; -using ProxyInterfaceSourceGenerator.Constants; using ProxyInterfaceSourceGenerator.Enums; namespace ProxyInterfaceSourceGenerator.Extensions; @@ -9,16 +8,6 @@ internal static class ParameterSymbolExtensions { private const string ParameterValueNull = "null"; - public static string GetAttributesPrefix(this IParameterSymbol ps) - { - var attributes = ps.GetAttributes() - .Where(a => !string.Equals(a.AttributeClass?.GetFullType(), InternalClassNames.NullableAttribute, StringComparison.OrdinalIgnoreCase)) - .Select(a => $"[{a}]") - .ToArray(); - - return attributes.Any() ? $"{string.Join(" ", attributes)} " : string.Empty; - } - public static string GetRefPrefix(this IParameterSymbol ps) { return ps.RefKind switch diff --git a/src/ProxyInterfaceSourceGenerator/Extensions/PropertySymbolExtensions.cs b/src/ProxyInterfaceSourceGenerator/Extensions/PropertySymbolExtensions.cs index 9bdc1ae..f90c66a 100644 --- a/src/ProxyInterfaceSourceGenerator/Extensions/PropertySymbolExtensions.cs +++ b/src/ProxyInterfaceSourceGenerator/Extensions/PropertySymbolExtensions.cs @@ -24,6 +24,4 @@ internal static class PropertySymbolExtensions return (type!, property.GetSanitizedName(), $"{{ {get}{set}}}"); } - - } \ No newline at end of file diff --git a/src/ProxyInterfaceSourceGenerator/Extensions/SymbolExtensions.cs b/src/ProxyInterfaceSourceGenerator/Extensions/SymbolExtensions.cs index f7b68ce..b76d44e 100644 --- a/src/ProxyInterfaceSourceGenerator/Extensions/SymbolExtensions.cs +++ b/src/ProxyInterfaceSourceGenerator/Extensions/SymbolExtensions.cs @@ -1,10 +1,36 @@ using Microsoft.CodeAnalysis; using Microsoft.CodeAnalysis.CSharp; +using ProxyInterfaceSourceGenerator.Constants; namespace ProxyInterfaceSourceGenerator.Extensions; internal static class SymbolExtensions { + private static readonly string[] ExcludedAttributes = + { + InternalClassNames.AsyncStateMachineAttribute , + InternalClassNames.NullableAttribute + }; + + public static string GetAttributesPrefix(this ISymbol symbol) + { + var attributes = symbol.GetAttributesAsList(); + + return attributes.Any() ? $"{string.Join(" ", attributes)} " : string.Empty; + } + + public static IReadOnlyList GetAttributesAsList(this ISymbol symbol) + { + return symbol + .GetAttributes() + .Where(a => a.AttributeClass.IsPublic() && !ExcludedAttributes.Contains(a.AttributeClass?.ToString(), StringComparer.OrdinalIgnoreCase)) + .Select(a => $"[{a}]") + .ToArray(); + } + + public static bool IsPublic(this ISymbol? symbol) => + symbol is { DeclaredAccessibility: Accessibility.Public }; + public static bool IsKeywordOrReserved(this ISymbol symbol) => SyntaxFacts.GetKeywordKind(symbol.Name) != SyntaxKind.None || SyntaxFacts.GetContextualKeywordKind(symbol.Name) != SyntaxKind.None; diff --git a/src/ProxyInterfaceSourceGenerator/FileGenerators/PartialInterfacesGenerator.cs b/src/ProxyInterfaceSourceGenerator/FileGenerators/PartialInterfacesGenerator.cs index 6f681c2..5027b12 100644 --- a/src/ProxyInterfaceSourceGenerator/FileGenerators/PartialInterfacesGenerator.cs +++ b/src/ProxyInterfaceSourceGenerator/FileGenerators/PartialInterfacesGenerator.cs @@ -110,6 +110,11 @@ using System; propertyName = $"this[{string.Join(", ", methodParameters)}]"; } + foreach (var attribute in property.GetAttributesAsList()) + { + str.AppendLine($" {attribute}"); + } + str.AppendLine($" {getterSetter.Value.PropertyType} {propertyName} {getterSetter.Value.GetSet}"); str.AppendLine(); } @@ -125,6 +130,11 @@ using System; var methodParameters = GetMethodParameters(method.Parameters, true); var whereStatement = GetWhereStatementFromMethod(method); + foreach (var attribute in method.GetAttributesAsList()) + { + str.AppendLine($" {attribute}"); + } + str.AppendLine($" {GetReplacedType(method.ReturnType, out _)} {method.GetMethodNameWithOptionalTypeParameters()}({string.Join(", ", methodParameters)}){whereStatement};"); str.AppendLine(); } @@ -139,6 +149,12 @@ using System; { var ps = @event.First().Parameters.First(); var type = ps.GetTypeEnum() == TypeEnum.Complex ? GetParameterType(ps, out _) : ps.Type.ToString(); + + foreach (var attribute in ps.GetAttributesAsList()) + { + str.AppendLine($" {attribute}"); + } + str.AppendLine($" event {type} {@event.Key.GetSanitizedName()};"); str.AppendLine(); } diff --git a/src/ProxyInterfaceSourceGenerator/FileGenerators/ProxyClassesGenerator.cs b/src/ProxyInterfaceSourceGenerator/FileGenerators/ProxyClassesGenerator.cs index dce2703..3649883 100644 --- a/src/ProxyInterfaceSourceGenerator/FileGenerators/ProxyClassesGenerator.cs +++ b/src/ProxyInterfaceSourceGenerator/FileGenerators/ProxyClassesGenerator.cs @@ -177,6 +177,11 @@ using System; set = setIsPublic ? $"set => {instancePropertyName} = value; " : string.Empty; } + foreach (var attribute in property.GetAttributesAsList()) + { + str.AppendLine($" {attribute}"); + } + str.AppendLine($" public {overrideOrVirtual}{type} {propertyName} {{ {get}{set}}}"); str.AppendLine(); } @@ -189,11 +194,6 @@ using System; var str = new StringBuilder(); foreach (var method in MemberHelper.GetPublicMethods(targetClassSymbol, proxyBaseClasses)) { - if (method.Name == "TryParse") - { - int y = 0; - } - var methodParameters = new List(); var invokeParameters = new List(); @@ -223,6 +223,11 @@ using System; var whereStatement = GetWhereStatementFromMethod(method); + foreach (var attribute in method.GetAttributesAsList()) + { + str.AppendLine($" {attribute}"); + } + str.AppendLine($" public {overrideOrVirtual}{returnTypeAsString} {method.GetMethodNameWithOptionalTypeParameters()}({string.Join(", ", methodParameters)}){whereStatement}"); str.AppendLine(" {"); foreach (var ps in method.Parameters) @@ -247,9 +252,7 @@ using System; var methodName = method.GetMethodNameWithOptionalTypeParameters(); var alternateReturnVariableName = $"result_{methodName.GetDeterministicHashCodeAsString()}"; - string instance = !method.IsStatic ? - "_Instance" : - $"{targetClassSymbol.Symbol}"; + string instance = !method.IsStatic ? "_Instance" : $"{targetClassSymbol.Symbol}"; if (returnTypeAsString == "void") { @@ -302,6 +305,12 @@ using System; var name = @event.Key.GetSanitizedName(); var ps = @event.First().Parameters.First(); var type = ps.GetTypeEnum() == TypeEnum.Complex ? GetParameterType(ps, out _) : ps.Type.ToString(); + + foreach (var attribute in ps.GetAttributesAsList()) + { + str.AppendLine($" {attribute}"); + } + str.Append($" public event {type} {name} {{"); if (@event.Any(e => e.MethodKind == MethodKind.EventAdd)) diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.ClientObjectProxy.g.cs b/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.ClientObjectProxy.g.cs index 95b0725..422d60d 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.ClientObjectProxy.g.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.ClientObjectProxy.g.cs @@ -21,22 +21,27 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP public object Tag { get => _Instance.Tag; set => _Instance.Tag = value; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public Microsoft.SharePoint.Client.ObjectPath Path { get => _Instance.Path; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public string ObjectVersion { get => _Instance.ObjectVersion; set => _Instance.ObjectVersion = value; } + [Microsoft.SharePoint.Client.PseudoRemoteAttribute] public bool? ServerObjectIsNull { get => _Instance.ServerObjectIsNull; } public ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientObject TypedObject { get => Mapster.TypeAdapter.Adapt(_Instance.TypedObject); } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public virtual void FromJson(Microsoft.SharePoint.Client.JsonReader reader) { Microsoft.SharePoint.Client.JsonReader reader_ = reader; _Instance.FromJson(reader_); } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public virtual bool CustomFromJson(Microsoft.SharePoint.Client.JsonReader reader) { Microsoft.SharePoint.Client.JsonReader reader_ = reader; @@ -44,11 +49,13 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__636829107; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public void Retrieve() { _Instance.Retrieve(); } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public void Retrieve(params string[] propertyNames) { string[] propertyNames_ = propertyNames; diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.ClientRuntimeContextProxy.g.cs b/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.ClientRuntimeContextProxy.g.cs index 13b571e..d36a0c0 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.ClientRuntimeContextProxy.g.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.ClientRuntimeContextProxy.g.cs @@ -39,6 +39,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP public int RequestTimeout { get => _Instance.RequestTimeout; set => _Instance.RequestTimeout = value; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public System.Collections.Generic.Dictionary StaticObjects { get => _Instance.StaticObjects; } public System.Version ServerSchemaVersion { get => _Instance.ServerSchemaVersion; } @@ -82,12 +83,14 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_366781530; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public void AddQuery(Microsoft.SharePoint.Client.ClientAction query) { Microsoft.SharePoint.Client.ClientAction query_ = query; _Instance.AddQuery(query_); } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public void AddQueryIdAndResultObject(long id, object obj) { long id_ = id; diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.SecurableObjectProxy.g.cs b/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.SecurableObjectProxy.g.cs index 3173408..68cc9a7 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.SecurableObjectProxy.g.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.SecurableObjectProxy.g.cs @@ -17,19 +17,24 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP public new Microsoft.SharePoint.Client.SecurableObject _Instance { get; } public Microsoft.SharePoint.Client.ClientObject _InstanceClientObject { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] public ProxyInterfaceSourceGeneratorTests.Source.PnP.ISecurableObject FirstUniqueAncestorSecurableObject { get => Mapster.TypeAdapter.Adapt(_Instance.FirstUniqueAncestorSecurableObject); } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool HasUniqueRoleAssignments { get => _Instance.HasUniqueRoleAssignments; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.RoleAssignmentCollection RoleAssignments { get => _Instance.RoleAssignments; } + [Microsoft.SharePoint.Client.RemoteAttribute] public virtual void ResetRoleInheritance() { _Instance.ResetRoleInheritance(); } + [Microsoft.SharePoint.Client.RemoteAttribute] public virtual void BreakRoleInheritance(bool copyRoleAssignments, bool clearSubscopes) { bool copyRoleAssignments_ = copyRoleAssignments; diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.WebProxy.g.cs b/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.WebProxy.g.cs index 84e2d21..ca752ba 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.WebProxy.g.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Destination/Microsoft.SharePoint.Client.WebProxy.g.cs @@ -17,274 +17,409 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP public new Microsoft.SharePoint.Client.Web _Instance { get; } public Microsoft.SharePoint.Client.SecurableObject _InstanceSecurableObject { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string AccessRequestListUrl { get => _Instance.AccessRequestListUrl; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string AccessRequestSiteDescription { get => _Instance.AccessRequestSiteDescription; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string Acronym { get => _Instance.Acronym; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.AlertCollection Alerts { get => _Instance.Alerts; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool AllowAutomaticASPXPageIndexing { get => _Instance.AllowAutomaticASPXPageIndexing; set => _Instance.AllowAutomaticASPXPageIndexing = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool AllowCreateDeclarativeWorkflowForCurrentUser { get => _Instance.AllowCreateDeclarativeWorkflowForCurrentUser; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool AllowDesignerForCurrentUser { get => _Instance.AllowDesignerForCurrentUser; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool AllowMasterPageEditingForCurrentUser { get => _Instance.AllowMasterPageEditingForCurrentUser; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool AllowRevertFromTemplateForCurrentUser { get => _Instance.AllowRevertFromTemplateForCurrentUser; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool AllowRssFeeds { get => _Instance.AllowRssFeeds; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool AllowSaveDeclarativeWorkflowAsTemplateForCurrentUser { get => _Instance.AllowSaveDeclarativeWorkflowAsTemplateForCurrentUser; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool AllowSavePublishDeclarativeWorkflowForCurrentUser { get => _Instance.AllowSavePublishDeclarativeWorkflowForCurrentUser; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.PropertyValues AllProperties { get => _Instance.AllProperties; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string AlternateCssUrl { get => _Instance.AlternateCssUrl; set => _Instance.AlternateCssUrl = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.Guid AppInstanceId { get => _Instance.AppInstanceId; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.AppTileCollection AppTiles { get => _Instance.AppTiles; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.Group AssociatedMemberGroup { get => _Instance.AssociatedMemberGroup; set => _Instance.AssociatedMemberGroup = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.Group AssociatedOwnerGroup { get => _Instance.AssociatedOwnerGroup; set => _Instance.AssociatedOwnerGroup = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.Group AssociatedVisitorGroup { get => _Instance.AssociatedVisitorGroup; set => _Instance.AssociatedVisitorGroup = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.User Author { get => _Instance.Author; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ContentTypeCollection AvailableContentTypes { get => _Instance.AvailableContentTypes; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.FieldCollection AvailableFields { get => _Instance.AvailableFields; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ModernizeHomepageResult CanModernizeHomepage { get => _Instance.CanModernizeHomepage; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string ClassicWelcomePage { get => _Instance.ClassicWelcomePage; set => _Instance.ClassicWelcomePage = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool CommentsOnSitePagesDisabled { get => _Instance.CommentsOnSitePagesDisabled; set => _Instance.CommentsOnSitePagesDisabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public short Configuration { get => _Instance.Configuration; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool ContainsConfidentialInfo { get => _Instance.ContainsConfidentialInfo; set => _Instance.ContainsConfidentialInfo = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ContentTypeCollection ContentTypes { get => _Instance.ContentTypes; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.DateTime Created { get => _Instance.Created; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ChangeToken CurrentChangeToken { get => _Instance.CurrentChangeToken; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.User CurrentUser { get => _Instance.CurrentUser; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string CustomMasterUrl { get => _Instance.CustomMasterUrl; set => _Instance.CustomMasterUrl = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool CustomSiteActionsDisabled { get => _Instance.CustomSiteActionsDisabled; set => _Instance.CustomSiteActionsDisabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.SPDataLeakagePreventionStatusInfo DataLeakagePreventionStatusInfo { get => _Instance.DataLeakagePreventionStatusInfo; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string Description { get => _Instance.Description; set => _Instance.Description = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string DescriptionForExistingLanguage { get => _Instance.DescriptionForExistingLanguage; set => _Instance.DescriptionForExistingLanguage = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.UserResource DescriptionResource { get => _Instance.DescriptionResource; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.Collections.Generic.IEnumerable DescriptionTranslations { get => _Instance.DescriptionTranslations; set => _Instance.DescriptionTranslations = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string DesignerDownloadUrlForCurrentUser { get => _Instance.DesignerDownloadUrlForCurrentUser; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.Guid DesignPackageId { get => _Instance.DesignPackageId; set => _Instance.DesignPackageId = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool DisableAppViews { get => _Instance.DisableAppViews; set => _Instance.DisableAppViews = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool DisableFlows { get => _Instance.DisableFlows; set => _Instance.DisableFlows = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool DisableRecommendedItems { get => _Instance.DisableRecommendedItems; set => _Instance.DisableRecommendedItems = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool DocumentLibraryCalloutOfficeWebAppPreviewersDisabled { get => _Instance.DocumentLibraryCalloutOfficeWebAppPreviewersDisabled; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.BasePermissions EffectiveBasePermissions { get => _Instance.EffectiveBasePermissions; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool EnableMinimalDownload { get => _Instance.EnableMinimalDownload; set => _Instance.EnableMinimalDownload = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.EventReceiverDefinitionCollection EventReceivers { get => _Instance.EventReceivers; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool ExcludeFromOfflineClient { get => _Instance.ExcludeFromOfflineClient; set => _Instance.ExcludeFromOfflineClient = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.FeatureCollection Features { get => _Instance.Features; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.FieldCollection Fields { get => _Instance.Fields; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.FolderCollection Folders { get => _Instance.Folders; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.FooterVariantThemeType FooterEmphasis { get => _Instance.FooterEmphasis; set => _Instance.FooterEmphasis = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool FooterEnabled { get => _Instance.FooterEnabled; set => _Instance.FooterEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.FooterLayoutType FooterLayout { get => _Instance.FooterLayout; set => _Instance.FooterLayout = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool HasWebTemplateExtension { get => _Instance.HasWebTemplateExtension; set => _Instance.HasWebTemplateExtension = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.SPVariantThemeType HeaderEmphasis { get => _Instance.HeaderEmphasis; set => _Instance.HeaderEmphasis = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.HeaderLayoutType HeaderLayout { get => _Instance.HeaderLayout; set => _Instance.HeaderLayout = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool HideTitleInHeader { get => _Instance.HideTitleInHeader; set => _Instance.HideTitleInHeader = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool HorizontalQuickLaunch { get => _Instance.HorizontalQuickLaunch; set => _Instance.HorizontalQuickLaunch = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.ClientSideComponent.HostedAppsManager HostedApps { get => _Instance.HostedApps; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.Guid Id { get => _Instance.Id; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool IsEduClass { get => _Instance.IsEduClass; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool IsEduClassProvisionChecked { get => _Instance.IsEduClassProvisionChecked; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool IsEduClassProvisionPending { get => _Instance.IsEduClassProvisionPending; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool IsHomepageModernized { get => _Instance.IsHomepageModernized; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool IsMultilingual { get => _Instance.IsMultilingual; set => _Instance.IsMultilingual = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool IsProvisioningComplete { get => _Instance.IsProvisioningComplete; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool IsRevertHomepageLinkHidden { get => _Instance.IsRevertHomepageLinkHidden; set => _Instance.IsRevertHomepageLinkHidden = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public uint Language { get => _Instance.Language; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.DateTime LastItemModifiedDate { get => _Instance.LastItemModifiedDate; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.DateTime LastItemUserModifiedDate { get => _Instance.LastItemUserModifiedDate; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ListCollection Lists { get => _Instance.Lists; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ListTemplateCollection ListTemplates { get => _Instance.ListTemplates; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.LogoAlignment LogoAlignment { get => _Instance.LogoAlignment; set => _Instance.LogoAlignment = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string MasterUrl { get => _Instance.MasterUrl; set => _Instance.MasterUrl = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool MegaMenuEnabled { get => _Instance.MegaMenuEnabled; set => _Instance.MegaMenuEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool MembersCanShare { get => _Instance.MembersCanShare; set => _Instance.MembersCanShare = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool NavAudienceTargetingEnabled { get => _Instance.NavAudienceTargetingEnabled; set => _Instance.NavAudienceTargetingEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.Navigation Navigation { get => _Instance.Navigation; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool NextStepsFirstRunEnabled { get => _Instance.NextStepsFirstRunEnabled; set => _Instance.NextStepsFirstRunEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool NoCrawl { get => _Instance.NoCrawl; set => _Instance.NoCrawl = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool NotificationsInOneDriveForBusinessEnabled { get => _Instance.NotificationsInOneDriveForBusinessEnabled; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool NotificationsInSharePointEnabled { get => _Instance.NotificationsInSharePointEnabled; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool ObjectCacheEnabled { get => _Instance.ObjectCacheEnabled; set => _Instance.ObjectCacheEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool OverwriteTranslationsOnChange { get => _Instance.OverwriteTranslationsOnChange; set => _Instance.OverwriteTranslationsOnChange = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.WebInformation ParentWeb { get => _Instance.ParentWeb; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ResourcePath ResourcePath { get => _Instance.ResourcePath; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool PreviewFeaturesEnabled { get => _Instance.PreviewFeaturesEnabled; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string PrimaryColor { get => _Instance.PrimaryColor; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.PushNotificationSubscriberCollection PushNotificationSubscribers { get => _Instance.PushNotificationSubscribers; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool QuickLaunchEnabled { get => _Instance.QuickLaunchEnabled; set => _Instance.QuickLaunchEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.RecycleBinItemCollection RecycleBin { get => _Instance.RecycleBin; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool RecycleBinEnabled { get => _Instance.RecycleBinEnabled; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.RegionalSettings RegionalSettings { get => _Instance.RegionalSettings; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string RequestAccessEmail { get => _Instance.RequestAccessEmail; set => _Instance.RequestAccessEmail = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.RoleDefinitionCollection RoleDefinitions { get => _Instance.RoleDefinitions; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.Folder RootFolder { get => _Instance.RootFolder; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool SaveSiteAsTemplateEnabled { get => _Instance.SaveSiteAsTemplateEnabled; set => _Instance.SaveSiteAsTemplateEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.SearchBoxInNavBarType SearchBoxInNavBar { get => _Instance.SearchBoxInNavBar; set => _Instance.SearchBoxInNavBar = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string SearchBoxPlaceholderText { get => _Instance.SearchBoxPlaceholderText; set => _Instance.SearchBoxPlaceholderText = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.SearchScopeType SearchScope { get => _Instance.SearchScope; set => _Instance.SearchScope = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ResourcePath ServerRelativePath { get => _Instance.ServerRelativePath; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string ServerRelativeUrl { get => _Instance.ServerRelativeUrl; set => _Instance.ServerRelativeUrl = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool ShowUrlStructureForCurrentUser { get => _Instance.ShowUrlStructureForCurrentUser; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Marketplace.CorporateCuratedGallery.SiteCollectionCorporateCatalogAccessor SiteCollectionAppCatalog { get => _Instance.SiteCollectionAppCatalog; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.GroupCollection SiteGroups { get => _Instance.SiteGroups; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string SiteLogoDescription { get => _Instance.SiteLogoDescription; set => _Instance.SiteLogoDescription = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string SiteLogoUrl { get => _Instance.SiteLogoUrl; set => _Instance.SiteLogoUrl = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.List SiteUserInfoList { get => _Instance.SiteUserInfoList; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.UserCollection SiteUsers { get => _Instance.SiteUsers; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.Collections.Generic.IEnumerable SupportedUILanguageIds { get => _Instance.SupportedUILanguageIds; set => _Instance.SupportedUILanguageIds = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool SyndicationEnabled { get => _Instance.SyndicationEnabled; set => _Instance.SyndicationEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.SharingState TenantAdminMembersCanShare { get => _Instance.TenantAdminMembersCanShare; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Marketplace.CorporateCuratedGallery.TenantCorporateCatalogAccessor TenantAppCatalog { get => _Instance.TenantAppCatalog; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool TenantTagPolicyEnabled { get => _Instance.TenantTagPolicyEnabled; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string ThemedCssFolderUrl { get => _Instance.ThemedCssFolderUrl; set => _Instance.ThemedCssFolderUrl = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ThemeInfo ThemeInfo { get => _Instance.ThemeInfo; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool ThirdPartyMdmEnabled { get => _Instance.ThirdPartyMdmEnabled; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string Title { get => _Instance.Title; set => _Instance.Title = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string TitleForExistingLanguage { get => _Instance.TitleForExistingLanguage; set => _Instance.TitleForExistingLanguage = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.UserResource TitleResource { get => _Instance.TitleResource; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.Collections.Generic.IEnumerable TitleTranslations { get => _Instance.TitleTranslations; set => _Instance.TitleTranslations = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool TreeViewEnabled { get => _Instance.TreeViewEnabled; set => _Instance.TreeViewEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public int UIVersion { get => _Instance.UIVersion; set => _Instance.UIVersion = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool UIVersionConfigurationEnabled { get => _Instance.UIVersionConfigurationEnabled; set => _Instance.UIVersionConfigurationEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string Url { get => _Instance.Url; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool UseAccessRequestDefault { get => _Instance.UseAccessRequestDefault; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.UserCustomActionCollection UserCustomActions { get => _Instance.UserCustomActions; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.WebCollection Webs { get => _Instance.Webs; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string WebTemplate { get => _Instance.WebTemplate; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string WebTemplateConfiguration { get => _Instance.WebTemplateConfiguration; } + [Microsoft.SharePoint.Client.RemoteAttribute] public bool WebTemplatesGalleryFirstRunEnabled { get => _Instance.WebTemplatesGalleryFirstRunEnabled; set => _Instance.WebTemplatesGalleryFirstRunEnabled = value; } + [Microsoft.SharePoint.Client.RemoteAttribute] public string WelcomePage { get => _Instance.WelcomePage; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.Workflow.WorkflowAssociationCollection WorkflowAssociations { get => _Instance.WorkflowAssociations; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.Workflow.WorkflowTemplateCollection WorkflowTemplates { get => _Instance.WorkflowTemplates; } @@ -305,6 +440,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_21992317; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult DoesUserHavePermissions(Microsoft.SharePoint.Client.BasePermissions permissionMask) { Microsoft.SharePoint.Client.BasePermissions permissionMask_ = permissionMask; @@ -312,6 +448,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_563212462; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult GetUserEffectivePermissions(string userName) { string userName_ = userName; @@ -319,6 +456,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__615383406; } + [Microsoft.SharePoint.Client.RemoteAttribute] public void CreateDefaultAssociatedGroups(string userLogin, string userLogin2, string groupNameSeed) { string userLogin_ = userLogin; @@ -327,6 +465,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP _Instance.CreateDefaultAssociatedGroups(userLogin_, userLogin2_, groupNameSeed_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult CreateOrganizationSharingLink(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, bool isEditLink) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -336,6 +475,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_2070260011; } + [Microsoft.SharePoint.Client.RemoteAttribute] public void DestroyOrganizationSharingLink(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, bool isEditLink, bool removeAssociatedSharingLinkGroup) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -345,6 +485,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP Microsoft.SharePoint.Client.Web.DestroyOrganizationSharingLink(context_, url_, isEditLink_, removeAssociatedSharingLinkGroup_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult GetSharingLinkKind(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string fileUrl) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -353,6 +494,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_654626020; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult GetSharingLinkData(string linkUrl) { string linkUrl_ = linkUrl; @@ -360,6 +502,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__2107757018; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult MapToIcon(string fileName, string progId, Microsoft.SharePoint.Client.Utilities.IconSize size) { string fileName_ = fileName; @@ -369,6 +512,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_384589064; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult GetWebUrlFromPageUrl(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string pageFullUrl) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -377,6 +521,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__907059837; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.PushNotificationSubscriber RegisterPushNotificationSubscriber(System.Guid deviceAppInstanceId, string serviceToken) { System.Guid deviceAppInstanceId_ = deviceAppInstanceId; @@ -385,12 +530,14 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__117534630; } + [Microsoft.SharePoint.Client.RemoteAttribute] public void UnregisterPushNotificationSubscriber(System.Guid deviceAppInstanceId) { System.Guid deviceAppInstanceId_ = deviceAppInstanceId; _Instance.UnregisterPushNotificationSubscriber(deviceAppInstanceId_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.PushNotificationSubscriberCollection GetPushNotificationSubscribersByArgs(string customArgs) { string customArgs_ = customArgs; @@ -398,6 +545,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_144086076; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.PushNotificationSubscriberCollection GetPushNotificationSubscribersByUser(string userName) { string userName_ = userName; @@ -405,6 +553,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1280834962; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult DoesPushNotificationSubscriberExist(System.Guid deviceAppInstanceId) { System.Guid deviceAppInstanceId_ = deviceAppInstanceId; @@ -412,6 +561,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1309404561; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.PushNotificationSubscriber GetPushNotificationSubscriber(System.Guid deviceAppInstanceId) { System.Guid deviceAppInstanceId_ = deviceAppInstanceId; @@ -419,6 +569,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1696633571; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.User GetSiteUserIncludingDeletedByPuid(string puid) { string puid_ = puid; @@ -426,6 +577,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1448181221; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.User GetUserById(int userId) { int userId_ = userId; @@ -433,6 +585,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__963170767; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult EnsureTenantAppCatalog(string callerId) { string callerId_ = callerId; @@ -440,6 +593,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1044639826; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.ClientSideComponent.StorageEntity GetStorageEntity(string key) { string key_ = key; @@ -447,6 +601,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1529029872; } + [Microsoft.SharePoint.Client.RemoteAttribute] public void SetStorageEntity(string key, string value, string description, string comments) { string key_ = key; @@ -456,12 +611,14 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP _Instance.SetStorageEntity(key_, value_, description_, comments_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public void RemoveStorageEntity(string key) { string key_ = key; _Instance.RemoveStorageEntity(key_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.SharingResult ShareObject(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, string peoplePickerInput, string roleValue, int groupId, bool propagateAcl, bool sendEmail, bool includeAnonymousLinkInEmail, string emailSubject, string emailBody, bool useSimplifiedRoles) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -479,6 +636,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_816157054; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.SharingResult ForwardObjectLink(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, string peoplePickerInput, string emailSubject, string emailBody) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -490,6 +648,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1822800612; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.SharingResult UnshareObject(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -498,6 +657,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__823224569; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ObjectSharingSettings GetObjectSharingSettings(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string objectUrl, int groupId, bool useSimplifiedRoles) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -508,6 +668,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__679475674; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult CreateAnonymousLink(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, bool isEditLink) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -517,6 +678,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__820192309; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult CreateAnonymousLinkWithExpiration(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, bool isEditLink, string expirationString) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -527,6 +689,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1044574026; } + [Microsoft.SharePoint.Client.RemoteAttribute] public void DeleteAllAnonymousLinksForObject(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -534,6 +697,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP Microsoft.SharePoint.Client.Web.DeleteAllAnonymousLinksForObject(context_, url_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public void DeleteAnonymousLinkForObject(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, bool isEditLink, bool removeAssociatedSharingLinkGroup) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -543,6 +707,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP Microsoft.SharePoint.Client.Web.DeleteAnonymousLinkForObject(context_, url_, isEditLink_, removeAssociatedSharingLinkGroup_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ListCollection GetLists(Microsoft.SharePoint.Client.GetListsParameters getListsParams) { Microsoft.SharePoint.Client.GetListsParameters getListsParams_ = getListsParams; @@ -550,6 +715,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1293372807; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.WebTemplateCollection GetAvailableWebTemplates(uint lcid, bool doIncludeCrossLanguage) { uint lcid_ = lcid; @@ -558,6 +724,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1052443476; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.List GetCatalog(int typeCatalog) { int typeCatalog_ = typeCatalog; @@ -565,6 +732,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1458409307; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.RecycleBinItemCollection GetRecycleBinItems(string pagingInfo, int rowLimit, bool isAscending, Microsoft.SharePoint.Client.RecycleBinOrderBy orderBy, Microsoft.SharePoint.Client.RecycleBinItemState itemState) { string pagingInfo_ = pagingInfo; @@ -576,6 +744,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_694026616; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.RecycleBinItemCollection GetRecycleBinItemsByQueryInfo(Microsoft.SharePoint.Client.RecycleBinQueryInformation queryInfo) { Microsoft.SharePoint.Client.RecycleBinQueryInformation queryInfo_ = queryInfo; @@ -583,6 +752,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1467955603; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ChangeCollection GetChanges(Microsoft.SharePoint.Client.ChangeQuery query) { Microsoft.SharePoint.Client.ChangeQuery query_ = query; @@ -590,6 +760,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_536201347; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.List GetList(string strUrl) { string strUrl_ = strUrl; @@ -597,6 +768,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1483657030; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.List GetListUsingPath(Microsoft.SharePoint.Client.ResourcePath path) { Microsoft.SharePoint.Client.ResourcePath path_ = path; @@ -604,6 +776,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__2113955437; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ListItem GetListItem(string strUrl) { string strUrl_ = strUrl; @@ -611,6 +784,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_101515089; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ListItem GetListItemUsingPath(Microsoft.SharePoint.Client.ResourcePath path) { Microsoft.SharePoint.Client.ResourcePath path_ = path; @@ -618,6 +792,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__577192176; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ListItem GetListItemByResourceId(string resourceId) { string resourceId_ = resourceId; @@ -625,6 +800,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_569057021; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.BusinessData.MetadataModel.Entity GetEntity(string @namespace, string name) { string @namespace_ = @namespace; @@ -633,6 +809,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_401289025; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.BusinessData.MetadataModel.AppBdcCatalog GetAppBdcCatalogForAppInstance(System.Guid appInstanceId) { System.Guid appInstanceId_ = appInstanceId; @@ -640,12 +817,14 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1179378574; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.BusinessData.MetadataModel.AppBdcCatalog GetAppBdcCatalog() { var result__1128404427 = _Instance.GetAppBdcCatalog(); return result__1128404427; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.WebCollection GetSubwebsForCurrentUser(Microsoft.SharePoint.Client.SubwebQuery query) { Microsoft.SharePoint.Client.SubwebQuery query_ = query; @@ -653,17 +832,20 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__34039800; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult GetSPAppContextAsStream() { var result_127789125 = _Instance.GetSPAppContextAsStream(); return result_127789125; } + [Microsoft.SharePoint.Client.RemoteAttribute] public void Update() { _Instance.Update(); } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.View GetViewFromUrl(string listUrl) { string listUrl_ = listUrl; @@ -671,6 +853,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1074039380; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.View GetViewFromPath(Microsoft.SharePoint.Client.ResourcePath listPath) { Microsoft.SharePoint.Client.ResourcePath listPath_ = listPath; @@ -678,6 +861,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1126862484; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.File GetFileByServerRelativeUrl(string serverRelativeUrl) { string serverRelativeUrl_ = serverRelativeUrl; @@ -685,6 +869,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__979182843; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.File GetFileByServerRelativePath(Microsoft.SharePoint.Client.ResourcePath serverRelativePath) { Microsoft.SharePoint.Client.ResourcePath serverRelativePath_ = serverRelativePath; @@ -692,6 +877,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1456830503; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.Collections.Generic.IList GetDocumentLibraries(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string webFullUrl) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -700,6 +886,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_2078170246; } + [Microsoft.SharePoint.Client.RemoteAttribute] public System.Collections.Generic.IList GetDocumentAndMediaLibraries(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string webFullUrl, bool includePageLibraries) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -709,6 +896,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__431075153; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult DefaultDocumentLibraryUrl(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string webUrl) { Microsoft.SharePoint.Client.ClientRuntimeContext context_ = Mapster.TypeAdapter.Adapt(context); @@ -717,12 +905,14 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1125717726; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.List DefaultDocumentLibrary() { var result_69743263 = _Instance.DefaultDocumentLibrary(); return result_69743263; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.File GetFileById(System.Guid uniqueId) { System.Guid uniqueId_ = uniqueId; @@ -730,6 +920,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__223228596; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.Folder GetFolderById(System.Guid uniqueId) { System.Guid uniqueId_ = uniqueId; @@ -737,6 +928,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__2111623002; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.File GetFileByLinkingUrl(string linkingUrl) { string linkingUrl_ = linkingUrl; @@ -744,6 +936,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__104450524; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.File GetFileByGuestUrl(string guestUrl) { string guestUrl_ = guestUrl; @@ -751,6 +944,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1819257688; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.File GetFileByGuestUrlEnsureAccess(string guestUrl, bool ensureAccess) { string guestUrl_ = guestUrl; @@ -759,6 +953,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__323239372; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.File GetFileByWOPIFrameUrl(string wopiFrameUrl) { string wopiFrameUrl_ = wopiFrameUrl; @@ -766,6 +961,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1184208158; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.File GetFileByUrl(string fileUrl) { string fileUrl_ = fileUrl; @@ -773,6 +969,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__84028506; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.Folder GetFolderByServerRelativeUrl(string serverRelativeUrl) { string serverRelativeUrl_ = serverRelativeUrl; @@ -780,6 +977,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1556909417; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.Folder GetFolderByServerRelativePath(Microsoft.SharePoint.Client.ResourcePath serverRelativePath) { Microsoft.SharePoint.Client.ResourcePath serverRelativePath_ = serverRelativePath; @@ -787,17 +985,20 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1812606997; } + [Microsoft.SharePoint.Client.RemoteAttribute] public void ApplyWebTemplate(string webTemplate) { string webTemplate_ = webTemplate; _Instance.ApplyWebTemplate(webTemplate_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public void DeleteObject() { _Instance.DeleteObject(); } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult PageContextInfo(bool includeODBSettings, bool emitNavigationInfo) { bool includeODBSettings_ = includeODBSettings; @@ -806,12 +1007,14 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1488981072; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult PageContextCore() { var result_769613763 = _Instance.PageContextCore(); return result_769613763; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.AppInstance GetAppInstanceById(System.Guid appInstanceId) { System.Guid appInstanceId_ = appInstanceId; @@ -819,6 +1022,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__860011802; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientObjectList GetAppInstancesByProductId(System.Guid productId) { System.Guid productId_ = productId; @@ -826,6 +1030,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1349849408; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.AppInstance LoadAndInstallAppInSpecifiedLocale(System.IO.Stream appPackageStream, int installationLocaleLCID) { System.IO.Stream appPackageStream_ = appPackageStream; @@ -834,6 +1039,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__860277814; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.AppInstance LoadApp(System.IO.Stream appPackageStream, int installationLocaleLCID) { System.IO.Stream appPackageStream_ = appPackageStream; @@ -842,6 +1048,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1043610289; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.ClientResult AddPlaceholderUser(string listId, string placeholderText) { string listId_ = listId; @@ -850,6 +1057,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__256231457; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.AppInstance LoadAndInstallApp(System.IO.Stream appPackageStream) { System.IO.Stream appPackageStream_ = appPackageStream; @@ -857,35 +1065,41 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1506697459; } + [Microsoft.SharePoint.Client.RemoteAttribute] public void SetAccessRequestSiteDescriptionAndUpdate(string description) { string description_ = description; _Instance.SetAccessRequestSiteDescriptionAndUpdate(description_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public void SetUseAccessRequestDefaultAndUpdate(bool useAccessRequestDefault) { bool useAccessRequestDefault_ = useAccessRequestDefault; _Instance.SetUseAccessRequestDefaultAndUpdate(useAccessRequestDefault_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public void IncrementSiteClientTag() { _Instance.IncrementSiteClientTag(); } + [Microsoft.SharePoint.Client.RemoteAttribute] public void AddSupportedUILanguage(int lcid) { int lcid_ = lcid; _Instance.AddSupportedUILanguage(lcid_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public void RemoveSupportedUILanguage(int lcid) { int lcid_ = lcid; _Instance.RemoveSupportedUILanguage(lcid_); } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.User EnsureUser(string logonName) { string logonName_ = logonName; @@ -893,6 +1107,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result_1853915411; } + [Microsoft.SharePoint.Client.RemoteAttribute] public Microsoft.SharePoint.Client.User EnsureUserByObjectId(System.Guid objectId, System.Guid tenantId, Microsoft.SharePoint.Client.Utilities.PrincipalType principalType) { System.Guid objectId_ = objectId; @@ -902,6 +1117,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP return result__1490083264; } + [Microsoft.SharePoint.Client.RemoteAttribute] public void ApplyTheme(string colorPaletteUrl, string fontSchemeUrl, string backgroundImageUrl, bool shareGenerated) { string colorPaletteUrl_ = colorPaletteUrl; diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.IPerson.g.cs b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.IPerson.g.cs index 3e6956f..7821db8 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.IPerson.g.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.IPerson.g.cs @@ -16,10 +16,12 @@ namespace ProxyInterfaceSourceGeneratorTests.Source { new ProxyInterfaceSourceGeneratorTests.Source.Person _Instance { get; } + [System.ComponentModel.DataAnnotations.DisplayAttribute(Prompt = "MyStruct Indexer")] ProxyInterfaceSourceGeneratorTests.Source.MyStruct this[int i] { get; set; } ProxyInterfaceSourceGeneratorTests.Source.MyStruct this[int i, string s] { get; set; } + [System.ComponentModel.DataAnnotations.DisplayAttribute(ResourceType = typeof(System.Threading.PeriodicTimer))] string Name { get; set; } string? StringNullable { get; set; } @@ -58,6 +60,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source System.Threading.Tasks.Task Method2Async(); + [System.ComponentModel.DataAnnotations.DisplayAttribute(Name = "M3")] System.Threading.Tasks.Task Method3Async(); void CreateInvokeHttpClient(int i = 5, string? appId = null, System.Collections.Generic.IReadOnlyDictionary? metadata = null, System.Threading.CancellationToken token = default(System.Threading.CancellationToken)); diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PersonProxy.g.cs b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PersonProxy.g.cs index 0ffc2ea..595df12 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PersonProxy.g.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PersonProxy.g.cs @@ -17,10 +17,12 @@ namespace ProxyInterfaceSourceGeneratorTests.Source public new ProxyInterfaceSourceGeneratorTests.Source.Person _Instance { get; } public ProxyInterfaceSourceGeneratorTests.Source.Human _InstanceHuman { get; } + [System.ComponentModel.DataAnnotations.DisplayAttribute(Prompt = "MyStruct Indexer")] public ProxyInterfaceSourceGeneratorTests.Source.MyStruct this[int i] { get => _Instance[i]; set => _Instance[i] = value; } public ProxyInterfaceSourceGeneratorTests.Source.MyStruct this[int i, string s] { get => _Instance[i, s]; set => _Instance[i, s] = value; } + [System.ComponentModel.DataAnnotations.DisplayAttribute(ResourceType = typeof(System.Threading.PeriodicTimer))] public string Name { get => _Instance.Name; set => _Instance.Name = value; } public string? StringNullable { get => _Instance.StringNullable; set => _Instance.StringNullable = value; } @@ -129,6 +131,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source return result__57677169; } + [System.ComponentModel.DataAnnotations.DisplayAttribute(Name = "M3")] public System.Threading.Tasks.Task Method3Async() { var result__57684656 = _Instance.Method3Async(); diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientObject.g.cs b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientObject.g.cs index ca23d2b..faa0267 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientObject.g.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientObject.g.cs @@ -20,22 +20,29 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP object Tag { get; set; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] Microsoft.SharePoint.Client.ObjectPath Path { get; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] string ObjectVersion { get; set; } + [Microsoft.SharePoint.Client.PseudoRemoteAttribute] bool? ServerObjectIsNull { get; } ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientObject TypedObject { get; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] void FromJson(Microsoft.SharePoint.Client.JsonReader reader); + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] bool CustomFromJson(Microsoft.SharePoint.Client.JsonReader reader); + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] void Retrieve(); + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] void Retrieve(params string[] propertyNames); void RefreshLoad(); diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext.g.cs b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext.g.cs index e2676ca..e8ed338 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext.g.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext.g.cs @@ -38,6 +38,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP int RequestTimeout { get; set; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] System.Collections.Generic.Dictionary StaticObjects { get; } System.Version ServerSchemaVersion { get; } @@ -60,8 +61,10 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP T CastTo(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientObject obj) where T : Microsoft.SharePoint.Client.ClientObject; + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] void AddQuery(Microsoft.SharePoint.Client.ClientAction query); + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] void AddQueryIdAndResultObject(long id, object obj); object ParseObjectFromJsonString(string json); diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.ISecurableObject.g.cs b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.ISecurableObject.g.cs index d5162aa..c68cfcb 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.ISecurableObject.g.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.ISecurableObject.g.cs @@ -16,16 +16,21 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP { new Microsoft.SharePoint.Client.SecurableObject _Instance { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] ProxyInterfaceSourceGeneratorTests.Source.PnP.ISecurableObject FirstUniqueAncestorSecurableObject { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool HasUniqueRoleAssignments { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.RoleAssignmentCollection RoleAssignments { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] void ResetRoleInheritance(); + [Microsoft.SharePoint.Client.RemoteAttribute] void BreakRoleInheritance(bool copyRoleAssignments, bool clearSubscopes); diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IWeb.g.cs b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IWeb.g.cs index b92e467..2b04751 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IWeb.g.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Destination/ProxyInterfaceSourceGeneratorTests.Source.PnP.IWeb.g.cs @@ -16,274 +16,409 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP { new Microsoft.SharePoint.Client.Web _Instance { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string AccessRequestListUrl { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string AccessRequestSiteDescription { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string Acronym { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.AlertCollection Alerts { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool AllowAutomaticASPXPageIndexing { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool AllowCreateDeclarativeWorkflowForCurrentUser { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool AllowDesignerForCurrentUser { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool AllowMasterPageEditingForCurrentUser { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool AllowRevertFromTemplateForCurrentUser { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool AllowRssFeeds { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool AllowSaveDeclarativeWorkflowAsTemplateForCurrentUser { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool AllowSavePublishDeclarativeWorkflowForCurrentUser { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.PropertyValues AllProperties { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string AlternateCssUrl { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] System.Guid AppInstanceId { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.AppTileCollection AppTiles { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.Group AssociatedMemberGroup { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.Group AssociatedOwnerGroup { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.Group AssociatedVisitorGroup { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.User Author { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ContentTypeCollection AvailableContentTypes { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.FieldCollection AvailableFields { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ModernizeHomepageResult CanModernizeHomepage { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string ClassicWelcomePage { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool CommentsOnSitePagesDisabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] short Configuration { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool ContainsConfidentialInfo { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ContentTypeCollection ContentTypes { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] System.DateTime Created { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ChangeToken CurrentChangeToken { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.User CurrentUser { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string CustomMasterUrl { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool CustomSiteActionsDisabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.SPDataLeakagePreventionStatusInfo DataLeakagePreventionStatusInfo { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string Description { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] string DescriptionForExistingLanguage { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.UserResource DescriptionResource { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] System.Collections.Generic.IEnumerable DescriptionTranslations { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] string DesignerDownloadUrlForCurrentUser { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] System.Guid DesignPackageId { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool DisableAppViews { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool DisableFlows { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool DisableRecommendedItems { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool DocumentLibraryCalloutOfficeWebAppPreviewersDisabled { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.BasePermissions EffectiveBasePermissions { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool EnableMinimalDownload { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.EventReceiverDefinitionCollection EventReceivers { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool ExcludeFromOfflineClient { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.FeatureCollection Features { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.FieldCollection Fields { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.FolderCollection Folders { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.FooterVariantThemeType FooterEmphasis { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool FooterEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.FooterLayoutType FooterLayout { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool HasWebTemplateExtension { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.SPVariantThemeType HeaderEmphasis { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.HeaderLayoutType HeaderLayout { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool HideTitleInHeader { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool HorizontalQuickLaunch { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.ClientSideComponent.HostedAppsManager HostedApps { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] System.Guid Id { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool IsEduClass { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool IsEduClassProvisionChecked { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool IsEduClassProvisionPending { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool IsHomepageModernized { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool IsMultilingual { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool IsProvisioningComplete { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool IsRevertHomepageLinkHidden { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] uint Language { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] System.DateTime LastItemModifiedDate { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] System.DateTime LastItemUserModifiedDate { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ListCollection Lists { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ListTemplateCollection ListTemplates { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.LogoAlignment LogoAlignment { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] string MasterUrl { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool MegaMenuEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool MembersCanShare { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool NavAudienceTargetingEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.Navigation Navigation { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool NextStepsFirstRunEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool NoCrawl { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool NotificationsInOneDriveForBusinessEnabled { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool NotificationsInSharePointEnabled { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool ObjectCacheEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool OverwriteTranslationsOnChange { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.WebInformation ParentWeb { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ResourcePath ResourcePath { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool PreviewFeaturesEnabled { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string PrimaryColor { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.PushNotificationSubscriberCollection PushNotificationSubscribers { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool QuickLaunchEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.RecycleBinItemCollection RecycleBin { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool RecycleBinEnabled { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.RegionalSettings RegionalSettings { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string RequestAccessEmail { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.RoleDefinitionCollection RoleDefinitions { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.Folder RootFolder { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool SaveSiteAsTemplateEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.SearchBoxInNavBarType SearchBoxInNavBar { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] string SearchBoxPlaceholderText { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.SearchScopeType SearchScope { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ResourcePath ServerRelativePath { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string ServerRelativeUrl { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool ShowUrlStructureForCurrentUser { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Marketplace.CorporateCuratedGallery.SiteCollectionCorporateCatalogAccessor SiteCollectionAppCatalog { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.GroupCollection SiteGroups { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string SiteLogoDescription { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] string SiteLogoUrl { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.List SiteUserInfoList { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.UserCollection SiteUsers { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] System.Collections.Generic.IEnumerable SupportedUILanguageIds { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool SyndicationEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.SharingState TenantAdminMembersCanShare { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Marketplace.CorporateCuratedGallery.TenantCorporateCatalogAccessor TenantAppCatalog { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool TenantTagPolicyEnabled { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string ThemedCssFolderUrl { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ThemeInfo ThemeInfo { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool ThirdPartyMdmEnabled { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string Title { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] string TitleForExistingLanguage { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.UserResource TitleResource { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] System.Collections.Generic.IEnumerable TitleTranslations { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool TreeViewEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] int UIVersion { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool UIVersionConfigurationEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] string Url { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool UseAccessRequestDefault { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.UserCustomActionCollection UserCustomActions { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.WebCollection Webs { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string WebTemplate { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] string WebTemplateConfiguration { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] bool WebTemplatesGalleryFirstRunEnabled { get; set; } + [Microsoft.SharePoint.Client.RemoteAttribute] string WelcomePage { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.Workflow.WorkflowAssociationCollection WorkflowAssociations { get; } + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.Workflow.WorkflowTemplateCollection WorkflowTemplates { get; } @@ -292,166 +427,247 @@ namespace ProxyInterfaceSourceGeneratorTests.Source.PnP System.Uri WebUrlFromFolderUrlDirect(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientContext context, System.Uri folderFullUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult DoesUserHavePermissions(Microsoft.SharePoint.Client.BasePermissions permissionMask); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult GetUserEffectivePermissions(string userName); + [Microsoft.SharePoint.Client.RemoteAttribute] void CreateDefaultAssociatedGroups(string userLogin, string userLogin2, string groupNameSeed); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult CreateOrganizationSharingLink(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, bool isEditLink); + [Microsoft.SharePoint.Client.RemoteAttribute] void DestroyOrganizationSharingLink(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, bool isEditLink, bool removeAssociatedSharingLinkGroup); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult GetSharingLinkKind(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string fileUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult GetSharingLinkData(string linkUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult MapToIcon(string fileName, string progId, Microsoft.SharePoint.Client.Utilities.IconSize size); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult GetWebUrlFromPageUrl(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string pageFullUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.PushNotificationSubscriber RegisterPushNotificationSubscriber(System.Guid deviceAppInstanceId, string serviceToken); + [Microsoft.SharePoint.Client.RemoteAttribute] void UnregisterPushNotificationSubscriber(System.Guid deviceAppInstanceId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.PushNotificationSubscriberCollection GetPushNotificationSubscribersByArgs(string customArgs); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.PushNotificationSubscriberCollection GetPushNotificationSubscribersByUser(string userName); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult DoesPushNotificationSubscriberExist(System.Guid deviceAppInstanceId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.PushNotificationSubscriber GetPushNotificationSubscriber(System.Guid deviceAppInstanceId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.User GetSiteUserIncludingDeletedByPuid(string puid); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.User GetUserById(int userId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult EnsureTenantAppCatalog(string callerId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.ClientSideComponent.StorageEntity GetStorageEntity(string key); + [Microsoft.SharePoint.Client.RemoteAttribute] void SetStorageEntity(string key, string value, string description, string comments); + [Microsoft.SharePoint.Client.RemoteAttribute] void RemoveStorageEntity(string key); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.SharingResult ShareObject(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, string peoplePickerInput, string roleValue, int groupId, bool propagateAcl, bool sendEmail, bool includeAnonymousLinkInEmail, string emailSubject, string emailBody, bool useSimplifiedRoles); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.SharingResult ForwardObjectLink(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, string peoplePickerInput, string emailSubject, string emailBody); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.SharingResult UnshareObject(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ObjectSharingSettings GetObjectSharingSettings(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string objectUrl, int groupId, bool useSimplifiedRoles); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult CreateAnonymousLink(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, bool isEditLink); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult CreateAnonymousLinkWithExpiration(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, bool isEditLink, string expirationString); + [Microsoft.SharePoint.Client.RemoteAttribute] void DeleteAllAnonymousLinksForObject(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url); + [Microsoft.SharePoint.Client.RemoteAttribute] void DeleteAnonymousLinkForObject(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string url, bool isEditLink, bool removeAssociatedSharingLinkGroup); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ListCollection GetLists(Microsoft.SharePoint.Client.GetListsParameters getListsParams); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.WebTemplateCollection GetAvailableWebTemplates(uint lcid, bool doIncludeCrossLanguage); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.List GetCatalog(int typeCatalog); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.RecycleBinItemCollection GetRecycleBinItems(string pagingInfo, int rowLimit, bool isAscending, Microsoft.SharePoint.Client.RecycleBinOrderBy orderBy, Microsoft.SharePoint.Client.RecycleBinItemState itemState); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.RecycleBinItemCollection GetRecycleBinItemsByQueryInfo(Microsoft.SharePoint.Client.RecycleBinQueryInformation queryInfo); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ChangeCollection GetChanges(Microsoft.SharePoint.Client.ChangeQuery query); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.List GetList(string strUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.List GetListUsingPath(Microsoft.SharePoint.Client.ResourcePath path); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ListItem GetListItem(string strUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ListItem GetListItemUsingPath(Microsoft.SharePoint.Client.ResourcePath path); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ListItem GetListItemByResourceId(string resourceId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.BusinessData.MetadataModel.Entity GetEntity(string @namespace, string name); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.BusinessData.MetadataModel.AppBdcCatalog GetAppBdcCatalogForAppInstance(System.Guid appInstanceId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.BusinessData.MetadataModel.AppBdcCatalog GetAppBdcCatalog(); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.WebCollection GetSubwebsForCurrentUser(Microsoft.SharePoint.Client.SubwebQuery query); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult GetSPAppContextAsStream(); + [Microsoft.SharePoint.Client.RemoteAttribute] void Update(); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.View GetViewFromUrl(string listUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.View GetViewFromPath(Microsoft.SharePoint.Client.ResourcePath listPath); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.File GetFileByServerRelativeUrl(string serverRelativeUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.File GetFileByServerRelativePath(Microsoft.SharePoint.Client.ResourcePath serverRelativePath); + [Microsoft.SharePoint.Client.RemoteAttribute] System.Collections.Generic.IList GetDocumentLibraries(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string webFullUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] System.Collections.Generic.IList GetDocumentAndMediaLibraries(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string webFullUrl, bool includePageLibraries); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult DefaultDocumentLibraryUrl(ProxyInterfaceSourceGeneratorTests.Source.PnP.IClientRuntimeContext context, string webUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.List DefaultDocumentLibrary(); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.File GetFileById(System.Guid uniqueId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.Folder GetFolderById(System.Guid uniqueId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.File GetFileByLinkingUrl(string linkingUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.File GetFileByGuestUrl(string guestUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.File GetFileByGuestUrlEnsureAccess(string guestUrl, bool ensureAccess); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.File GetFileByWOPIFrameUrl(string wopiFrameUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.File GetFileByUrl(string fileUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.Folder GetFolderByServerRelativeUrl(string serverRelativeUrl); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.Folder GetFolderByServerRelativePath(Microsoft.SharePoint.Client.ResourcePath serverRelativePath); + [Microsoft.SharePoint.Client.RemoteAttribute] void ApplyWebTemplate(string webTemplate); + [Microsoft.SharePoint.Client.RemoteAttribute] void DeleteObject(); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult PageContextInfo(bool includeODBSettings, bool emitNavigationInfo); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult PageContextCore(); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.AppInstance GetAppInstanceById(System.Guid appInstanceId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientObjectList GetAppInstancesByProductId(System.Guid productId); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.AppInstance LoadAndInstallAppInSpecifiedLocale(System.IO.Stream appPackageStream, int installationLocaleLCID); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.AppInstance LoadApp(System.IO.Stream appPackageStream, int installationLocaleLCID); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.ClientResult AddPlaceholderUser(string listId, string placeholderText); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.AppInstance LoadAndInstallApp(System.IO.Stream appPackageStream); + [Microsoft.SharePoint.Client.RemoteAttribute] void SetAccessRequestSiteDescriptionAndUpdate(string description); + [Microsoft.SharePoint.Client.RemoteAttribute] void SetUseAccessRequestDefaultAndUpdate(bool useAccessRequestDefault); + [Microsoft.SharePoint.Client.RemoteAttribute] void IncrementSiteClientTag(); + [Microsoft.SharePoint.Client.RemoteAttribute] void AddSupportedUILanguage(int lcid); + [Microsoft.SharePoint.Client.RemoteAttribute] void RemoveSupportedUILanguage(int lcid); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.User EnsureUser(string logonName); + [Microsoft.SharePoint.Client.RemoteAttribute] Microsoft.SharePoint.Client.User EnsureUserByObjectId(System.Guid objectId, System.Guid tenantId, Microsoft.SharePoint.Client.Utilities.PrincipalType principalType); + [Microsoft.SharePoint.Client.RemoteAttribute] void ApplyTheme(string colorPaletteUrl, string fontSchemeUrl, string backgroundImageUrl, bool shareGenerated); diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Source/Person.cs b/tests/ProxyInterfaceSourceGeneratorTests/Source/Person.cs index 9f363cd..6123cf6 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Source/Person.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Source/Person.cs @@ -1,4 +1,5 @@ using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; using System.Diagnostics.CodeAnalysis; using System.Threading; using System.Threading.Tasks; @@ -9,6 +10,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source { private readonly MyStruct[] _arr = new MyStruct[1]; + [Display(Prompt = "MyStruct Indexer")] public MyStruct this[int i] { get { return _arr[i]; } @@ -26,6 +28,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source return new List { h, new Human { IsAlive = true } }; } + [Display(ResourceType = typeof(PeriodicTimer))] public string Name { get; set; } public string? StringNullable { get; set; } @@ -99,6 +102,7 @@ namespace ProxyInterfaceSourceGeneratorTests.Source return Task.FromResult(1); } + [Display(Name = "M3")] public Task Method3Async() { return Task.FromResult((string?)""); diff --git a/tests/ProxyInterfaceSourceGeneratorTests/Source/PersonExtends.cs b/tests/ProxyInterfaceSourceGeneratorTests/Source/PersonExtends.cs index 6ff3a06..dafe10a 100644 --- a/tests/ProxyInterfaceSourceGeneratorTests/Source/PersonExtends.cs +++ b/tests/ProxyInterfaceSourceGeneratorTests/Source/PersonExtends.cs @@ -1,6 +1,3 @@ -using System.Collections.Generic; -using System.Threading.Tasks; - namespace ProxyInterfaceSourceGeneratorTests.Source { public class PersonExtends : Human @@ -12,13 +9,13 @@ namespace ProxyInterfaceSourceGeneratorTests.Source public static string StaticString { get; set; } = "500"; - public string Name { get; set; } + public string Name { get; set; } = null!; public string? StringNullable { get; set; } public long? NullableLong { get; } - public object @object { get; set; } + public object @object { get; set; } = null!; public void Void() {