-
Notifications
You must be signed in to change notification settings - Fork 3
/
ResolutionGroupNameAttribute.xml
76 lines (76 loc) · 5.27 KB
/
ResolutionGroupNameAttribute.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
<Type Name="ResolutionGroupNameAttribute" FullName="Microsoft.Maui.Controls.ResolutionGroupNameAttribute">
<TypeSignature Language="C#" Value="public sealed class ResolutionGroupNameAttribute : Attribute" />
<TypeSignature Language="ILAsm" Value=".class public auto ansi sealed beforefieldinit ResolutionGroupNameAttribute extends System.Attribute" />
<TypeSignature Language="DocId" Value="T:Microsoft.Maui.Controls.ResolutionGroupNameAttribute" />
<TypeSignature Language="VB.NET" Value="Public NotInheritable Class ResolutionGroupNameAttribute
Inherits Attribute" />
<TypeSignature Language="C++ CLI" Value="public ref class ResolutionGroupNameAttribute sealed : Attribute" />
<TypeSignature Language="F#" Value="type ResolutionGroupNameAttribute = class
 inherit Attribute" />
<AssemblyInfo>
<AssemblyName>Microsoft.Maui.Controls</AssemblyName>
<AssemblyVersion>1.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Base>
<BaseTypeName>System.Attribute</BaseTypeName>
</Base>
<Interfaces />
<Attributes>
<Attribute>
<AttributeName Language="C#">[System.AttributeUsage(System.AttributeTargets.Assembly)]</AttributeName>
<AttributeName Language="F#">[<System.AttributeUsage(System.AttributeTargets.Assembly)>]</AttributeName>
</Attribute>
</Attributes>
<Docs>
<summary>Attribute that identifies a group name, typically a company name or reversed company URL, that provides a scope for effect names.</summary>
<remarks>
<para>Developers must supply a name to <see cref="T:Microsoft.Maui.Controls.ExportEffectAttribute" /> that is unique over the scope of the name that they supply to <see cref="T:Microsoft.Maui.Controls.ResolutionGroupNameAttribute" />. The <see cref="M:Microsoft.Maui.Controls.Effect.Resolve(System.String)" /> method takes a string that is the concatenation of the name (the resolution group name), <c>'.'</c>, and the unique name that was supplied to <see cref="T:Microsoft.Maui.Controls.ExportEffectAttribute" />, and returns the specified effect.</para>
<example>
<para>For example, with the declarations:</para>
<code lang="c#"><![CDATA[
[assembly: ResolutionGroupName ("com.YourCompany")]
[assembly: ExportEffect (typeof (ShadowEffect), "ShadowEffect")]]]></code>
<para>Then the code below will add the effect to a button:</para>
<code lang="c#"><![CDATA[
[var button = new Button { Text = "I have a shadow" };
button.Effects.Add (Effect.Resolve ("com.YourCompany.ShadowEffect"));]]></code>
</example>
</remarks>
</Docs>
<Members>
<Member MemberName=".ctor">
<MemberSignature Language="C#" Value="public ResolutionGroupNameAttribute (string name);" />
<MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor(string name) cil managed" />
<MemberSignature Language="DocId" Value="M:Microsoft.Maui.Controls.ResolutionGroupNameAttribute.#ctor(System.String)" />
<MemberSignature Language="VB.NET" Value="Public Sub New (name As String)" />
<MemberSignature Language="C++ CLI" Value="public:
 ResolutionGroupNameAttribute(System::String ^ name);" />
<MemberSignature Language="F#" Value="new Microsoft.Maui.Controls.ResolutionGroupNameAttribute : string -> Microsoft.Maui.Controls.ResolutionGroupNameAttribute" Usage="new Microsoft.Maui.Controls.ResolutionGroupNameAttribute name" />
<MemberType>Constructor</MemberType>
<AssemblyInfo>
<AssemblyName>Microsoft.Maui.Controls</AssemblyName>
<AssemblyVersion>1.0.0.0</AssemblyVersion>
<AssemblyVersion>9.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Parameters>
<Parameter Name="name" Type="System.String" />
</Parameters>
<Docs>
<param name="name">A name, such as a company name or reversed company URL, that helps to uniquely identify effects.</param>
<summary>Creates a new resolution group name attribute.</summary>
<remarks>
<para>Developers must supply a name to <see cref="T:Microsoft.Maui.Controls.ExportEffectAttribute" /> that is unique over the scope of the <paramref name="name" /> that they supply to <see cref="T:Microsoft.Maui.Controls.ResolutionGroupNameAttribute" />. The <see cref="M:Microsoft.Maui.Controls.Effect.Resolve(System.String)" /> method takes a string that is the concatenation of <paramref name="name" /> (the resolution group name), <c>'.'</c>, and the unique name that was supplied to <see cref="T:Microsoft.Maui.Controls.ExportEffectAttribute" />, and returns the specified effect.</para>
<example>
<para>For example, with the declarations:</para>
<code lang="c#"><![CDATA[
[assembly: ResolutionGroupName ("com.YourCompany")]
[assembly: ExportEffect (typeof (ShadowEffect), "ShadowEffect")]]]></code>
<para>Then the code below will add the effect to a button:</para>
<code lang="c#"><![CDATA[
[var button = new Button { Text = "I have a shadow" };
button.Effects.Add (Effect.Resolve ("com.YourCompany.ShadowEffect"));]]></code>
</example>
</remarks>
<altmember cref="T:Microsoft.Maui.Controls.ExportEffectAttribute" />
</Docs>
</Member>
</Members>
</Type>