Merge remote-tracking branch 'mfoliveira/ppc64el-v2'
[mono.git] / mcs / tools / mdoc / Test / en.expected.importecmadoc / System / Array.xml
1 <Type Name="Array" FullName="System.Array">
2   <TypeSignature Language="C#" Value="public class Array" />
3   <TypeSignature Language="ILAsm" Value=".class public auto ansi beforefieldinit Array extends System.Object" />
4   <AssemblyInfo>
5     <AssemblyName>DocTest</AssemblyName>
6     <AssemblyVersion>0.0.0.0</AssemblyVersion>
7   </AssemblyInfo>
8   <Base>
9     <BaseTypeName>System.Object</BaseTypeName>
10   </Base>
11   <Interfaces />
12   <Docs>
13     <summary>
14                                         <para> Serves as the base class for arrays. Provides methods for creating,
15       copying, manipulating, searching, and sorting arrays.</para>
16                                 </summary>
17     <remarks>
18                                         <para>This class is intended to be used as a base class by
19       language implementations that support arrays. Only the system can derive from
20       this type: derived classes of <see cref="T:System.Array" /> are not to be created by the developer.</para>
21                                         <block subset="none" type="note">
22                                                 <para>An array is a collection of
23          identically typed data <paramref name="elements" /> that are accessed and referenced by
24          sets of integral <paramref name="indices" />. </para>
25                                                 <para>The <paramref name="rank" /> of an array is the number
26       of dimensions in the array. Each dimension has its own set of indices. An array
27       with a rank greater than one can have a different lower
28       bound and a different number of elements for each dimension. Multidimensional
29       arrays (i.e. arrays with a rank greater than one) are processed in row-major
30       order. </para>
31                                                 <para>The <paramref name="lower bound" /> of a dimension
32    is the starting index of that dimension. </para>
33                                                 <para>The <paramref name="length" /> of an array is the total number of elements contained in all of its
34 dimensions. </para>
35                                                 <para>A <paramref name="vector" /> is a
36 one-dimensional array with a <paramref name="lower bound" /> of '0'. </para>
37                                                 <para>If the implementer creates a derived class of <see cref="T:System.Array" />, expected <see cref="T:System.Array" /> behavior
38 cannot be guaranteed. For information on array-like objects with increased
39 functionality, see the <see cref="T:System.Collections.IList" /> and <see cref="T:System.Collections.Generic.IList&lt;T&gt;" /> interfaces. For more information regarding the use of arrays versus the use
40 of collections, see Partition V of the CLI Specification. </para>
41                                         </block>
42                                         <para>Every specific <see cref="T:System.Array" /> type has three instance methods defined on it.
43    While some programming languages allow direct access to these methods, they are
44    primarily intended to be called by the output of compilers based on language
45    syntax that deals with arrays. </para>
46                                         <list type="bullet">
47                                                 <item>
48                                                         <term>
49                                                                 <para>
50                                                                         <c>Get</c>: Takes as many <see cref="T:System.Int32" /> arguments as the array
51    has dimensions and returns the value stored at the given index. It throws a
52 <see cref="T:System.IndexOutOfRangeException" /> 
53 exception for invalid indices. </para>
54                                                         </term>
55                                                 </item>
56                                                 <item>
57                                                         <term>
58                                                                 <para>
59                                                                         <c>Set</c>: Takes as many <see cref="T:System.Int32" /> arguments as the array
60    has dimensions, plus one additional argument (the last argument) which has the
61    same type as an array element. It stores the final value in the specified
62    index of the array. It throws a <see cref="T:System.IndexOutOfRangeException" />
63    exception for invalid indices. </para>
64                                                         </term>
65                                                 </item>
66                                                 <item>
67                                                         <term>
68                                                                 <para>
69                                                                         <c>Address</c>: Takes as many <see cref="T:System.Int32" /> arguments as the
70    array has dimensions and returns the address of the element at the given index.
71    It throws a <see cref="T:System.IndexOutOfRangeException" />
72    exception for invalid indices. </para>
73                                                         </term>
74                                                 </item>
75                                         </list>
76                                         <para>In addition, every specific <see cref="T:System.Array" /> type has a constructor on it that takes as many non-negative 
77 <see cref="T:System.Int32" /> 
78 arguments as the array has dimensions. The arguments specify the
79 number of elements in each dimension, and a lower bound of 0. Thus, a
80 two-dimensional array of <see cref="T:System.Int32" /> objects would have a constructor that could be called with
81 <c>(2, 4)</c> as its arguments to create an array of eight zeros with the first dimension indexed
82 with 0 and 1 and the second dimension indexed with 0, 1, 2, and 3. </para>
83                                         <para>For all specific array types except vectors (i.e. those
84    permitted to have non-zero lower bounds and those with more than one dimension)
85    there is an additional constructor. It takes twice as many arguments as the
86    array has dimensions. The arguments are considered in pairs, with the first of
87    the pair specifying the lower bound for that dimension and the second specifying
88    the total number of elements in that dimension. Thus, a two-dimensional array
89    of <see cref="T:System.Int32" />
90    
91    objects would also have a constructor that could be called with <c>(-1, 2, 1, 3)</c> as its arguments,
92 specifying an array of 6 zeros, with the first dimension indexed by -1 and 0,
93 and the second dimension indexed by 1, 2, and 3. </para>
94                                         <para>Enumeration over an array occurs in ascending row-major order, starting from the first element. (For example, a 2x3 array is traversed in the order [0,0], [0,1], [0,2], [1,0], [1,1], and [1,2].)</para>
95                                         <para>Parallel implementation of methods taking a <see cref="T:System.Predicate" /> argument are not permitted.</para>
96                                 </remarks>
97   </Docs>
98   <Members>
99     <Member MemberName=".ctor">
100       <MemberSignature Language="C#" Value="public Array ();" />
101       <MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor() cil managed" />
102       <MemberType>Constructor</MemberType>
103       <AssemblyInfo>
104         <AssemblyVersion>0.0.0.0</AssemblyVersion>
105       </AssemblyInfo>
106       <Parameters />
107       <Docs>
108         <summary>Constructs a new instance of the <see cref="T:System.Array" /> class.</summary>
109         <remarks>To be added.</remarks>
110       </Docs>
111     </Member>
112     <Member MemberName="AsReadOnly&lt;T&gt;">
113       <MemberSignature Language="C#" Value="public static System.Collections.ObjectModel.ReadOnlyCollection&lt;T&gt; AsReadOnly&lt;T&gt; (T[] array);" />
114       <MemberSignature Language="ILAsm" Value=".method public static hidebysig class System.Collections.ObjectModel.ReadOnlyCollection`1&lt;!!T&gt; AsReadOnly&lt;T&gt;(!!T[] array) cil managed" />
115       <MemberType>Method</MemberType>
116       <AssemblyInfo>
117         <AssemblyVersion>0.0.0.0</AssemblyVersion>
118       </AssemblyInfo>
119       <ReturnValue>
120         <ReturnType>System.Collections.ObjectModel.ReadOnlyCollection&lt;T&gt;</ReturnType>
121       </ReturnValue>
122       <TypeParameters>
123         <TypeParameter Name="T" />
124       </TypeParameters>
125       <Parameters>
126         <Parameter Name="array" Type="T[]" />
127       </Parameters>
128       <Docs>
129         <typeparam name="T">To be added.</typeparam>
130         <param name="array">To be added.</param>
131         <summary>To be added.</summary>
132         <returns>To be added.</returns>
133         <remarks>To be added.</remarks>
134         <exception cref="T:System.NotImplementedException">To be added; from:
135           <see cref="M:System.Array.AsReadOnly``1(``0[])" /></exception>
136       </Docs>
137     </Member>
138     <Member MemberName="ConvertAll&lt;T,U&gt;">
139       <MemberSignature Language="C#" Value="public static TOutput[] ConvertAll&lt;TInput,TOutput&gt; (TInput[] array, Converter&lt;TInput,TOutput&gt; converter);" />
140       <MemberSignature Language="ILAsm" Value=".method public static hidebysig !!TOutput[] ConvertAll&lt;TInput, TOutput&gt;(!!TInput[] array, class System.Converter`2&lt;!!TInput, !!TOutput&gt; converter) cil managed" />
141       <MemberType>Method</MemberType>
142       <AssemblyInfo>
143         <AssemblyVersion>0.0.0.0</AssemblyVersion>
144       </AssemblyInfo>
145       <ReturnValue>
146         <ReturnType>TOutput[]</ReturnType>
147       </ReturnValue>
148       <TypeParameters>
149         <TypeParameter Name="TInput" />
150         <TypeParameter Name="TOutput" />
151       </TypeParameters>
152       <Parameters>
153         <Parameter Name="array" Type="TInput[]" />
154         <Parameter Name="converter" Type="System.Converter&lt;TInput,TOutput&gt;" />
155       </Parameters>
156       <Docs>
157         <typeparam name="TInput">To be added.</typeparam>
158         <typeparam name="TOutput">To be added.</typeparam>
159         <param name="array">The one-dimensional array to convert.</param>
160         <param name="converter">
161                                                         <para>A <see cref="T:System.Converter&lt;T,U&gt;" /> that converts each element from one type to another type.</para>
162                                                 </param>
163         <summary>
164                                                         <para>Converts an array of one type to an array of another type.</para>
165                                                 </summary>
166         <returns>
167                                                         <para>A new array of the target type containing the converted elements from <paramref name="array" />.</para>
168                                                 </returns>
169         <remarks>
170                                                         <para>The <see cref="T:System.Converter&lt;T,U&gt;" /> is a delegate that converts an array element to the target type.  The elements of  <paramref name="array" /> are individually passed to this converter, and the converted elements are saved in the new array. The source array remains unchanged.</para>
171                                                 </remarks>
172         <exception cref="T:System.InvalidOperationException">To be added; from:
173           <see cref="M:System.Array.ConvertAll``2(``0[],System.Converter{``0,``1})" /></exception>
174         <exception cref="T:System.ArgumentNullException">
175                                                         <paramref name="array" /> is <see langword="null" /> or <paramref name="converter" /> is <see langword="null" />.</exception>
176       </Docs>
177     </Member>
178     <Member MemberName="Resize&lt;T&gt;">
179       <MemberSignature Language="C#" Value="public static void Resize&lt;T&gt; (ref T[] array, int newSize);" />
180       <MemberSignature Language="ILAsm" Value=".method public static hidebysig void Resize&lt;T&gt;(!!T[] array, int32 newSize) cil managed" />
181       <MemberType>Method</MemberType>
182       <AssemblyInfo>
183         <AssemblyVersion>0.0.0.0</AssemblyVersion>
184       </AssemblyInfo>
185       <ReturnValue>
186         <ReturnType>System.Void</ReturnType>
187       </ReturnValue>
188       <TypeParameters>
189         <TypeParameter Name="T" />
190       </TypeParameters>
191       <Parameters>
192         <Parameter Name="array" Type="T[]&amp;" RefType="ref" />
193         <Parameter Name="newSize" Type="System.Int32" />
194       </Parameters>
195       <Docs>
196         <typeparam name="T">To be added.</typeparam>
197         <param name="array">To be added.</param>
198         <param name="newSize">To be added.</param>
199         <summary>To be added.</summary>
200         <remarks>To be added.</remarks>
201         <exception cref="T:System.Exception">To be added; from:
202           <see cref="M:System.Array.Resize``1(``0[]@,System.Int32)" /></exception>
203       </Docs>
204     </Member>
205   </Members>
206 </Type>