~ubuntu-branches/ubuntu/trusty/monodevelop/trusty-proposed

« back to all changes in this revision

Viewing changes to external/monomac/docs/en/MonoMac.Foundation/NSKeyedArchiver.xml

  • Committer: Package Import Robot
  • Author(s): Jo Shields
  • Date: 2013-05-12 09:46:03 UTC
  • mto: This revision was merged to the branch mainline in revision 29.
  • Revision ID: package-import@ubuntu.com-20130512094603-mad323bzcxvmcam0
Tags: upstream-4.0.5+dfsg
ImportĀ upstreamĀ versionĀ 4.0.5+dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
  </Docs>
21
21
  <Members>
22
22
    <Member MemberName=".ctor">
23
 
      <MemberSignature Language="C#" Value="public NSKeyedArchiver ();" />
24
 
      <MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor() cil managed" />
25
 
      <MemberType>Constructor</MemberType>
26
 
      <AssemblyInfo>
27
 
        <AssemblyVersion>0.0.0.0</AssemblyVersion>
28
 
      </AssemblyInfo>
29
 
      <Attributes>
30
 
        <Attribute>
31
 
          <AttributeName>MonoMac.Foundation.Export("init")</AttributeName>
32
 
        </Attribute>
33
 
      </Attributes>
34
 
      <Parameters />
35
 
      <Docs>
36
 
        <summary>Default constructor that initializes a new instance of this class with no parameters.</summary>
37
 
        <remarks>
38
 
        </remarks>
39
 
      </Docs>
40
 
    </Member>
41
 
    <Member MemberName=".ctor">
42
23
      <MemberSignature Language="C#" Value="public NSKeyedArchiver (MonoMac.Foundation.NSCoder coder);" />
43
24
      <MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor(class MonoMac.Foundation.NSCoder coder) cil managed" />
44
25
      <MemberType>Constructor</MemberType>
49
30
        <Attribute>
50
31
          <AttributeName>MonoMac.Foundation.Export("initWithCoder:")</AttributeName>
51
32
        </Attribute>
 
33
        <Attribute>
 
34
          <AttributeName>System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Advanced)</AttributeName>
 
35
        </Attribute>
52
36
      </Attributes>
53
37
      <Parameters>
54
38
        <Parameter Name="coder" Type="MonoMac.Foundation.NSCoder" />
87
71
      <AssemblyInfo>
88
72
        <AssemblyVersion>0.0.0.0</AssemblyVersion>
89
73
      </AssemblyInfo>
 
74
      <Attributes>
 
75
        <Attribute>
 
76
          <AttributeName>System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Advanced)</AttributeName>
 
77
        </Attribute>
 
78
      </Attributes>
90
79
      <Parameters>
91
80
        <Parameter Name="t" Type="MonoMac.Foundation.NSObjectFlag" />
92
81
      </Parameters>
93
82
      <Docs>
94
83
        <param name="t">Unused sentinel value, pass NSObjectFlag.Empty.</param>
95
 
        <summary>Constructor to call on derived classes to skip initialization and merely allocate the object.</summary>
 
84
        <summary>Constructor to call on derived classes when the derived class has an [Export] constructor.</summary>
96
85
        <remarks>
97
 
          <para>This constructor should be called by derived classes when they completely construct the object in managed code and merely want the runtime to allocate and initialize the NSObject.   This is required to implement the two-step initialization process that Objective-C uses, the first step is to perform the object allocation, the second step is to initialize the object.   When you invoke the constructor that takes the NSObjectFlag.Empty you taking advatnage of a direct path that goes all the way up to NSObject to merely allocate the object's memory and bind the Objective-C and C# objects together.    The actual initialization of the object is up to you.</para>
98
 
          <para>This constructor is typically used by the binding generator to allocate the object, but prevent the actual initialization to take place.   Once the allocation has taken place, the constructor has to initialize the object.   With constructors generated by the binding generator this means that it manually invokes one of the "init" methods to initialize the object.</para>
99
 
          <para>It is your responsability to completely initialize the object if you chain up using the NSObjectFlag.Empty path.</para>
100
 
          <para>In general, if your constructors invokes the NSObjectFlag.Empty base implementation, then it should be calling an Objective-C init method.   If this is not the case, you should instead chain to the proper constructor in your class. </para>
101
 
          <para>The argument value is ignored and merely ensures that the only code that is executed is the construction phase is the basic NSObject allocation and runtime type registration.  Typically the chaining would look like this:</para>
 
86
          <para>This constructor should be called by derived classes when they are initialized using an [Export] attribute. The argument value is ignore, typically the chaining would look like this:</para>
102
87
          <example>
103
88
            <code lang="C#">
104
 
//
105
 
// The NSObjectFlag merely allocates the object and registers the
106
 
// C# class with the Objective-C runtime if necessary, but no actual
107
 
// initXxx method is invoked, that is done later in the constructor
108
 
//
109
 
// This is taken from MonoMac's source code:
110
 
//
111
 
[Export ("initWithFrame:")]
112
 
public UIView (System.Drawing.RectangleF frame) : base (NSObjectFlag.Empty)
113
 
{
114
 
// Invoke the init method now.
115
 
        var initWithFrame = new Selector ("initWithFrame:").Handle;
116
 
        if (IsDirectBinding)
117
 
                Handle = MonoMac.ObjCRuntime.Messaging.IntPtr_objc_msgSend_RectangleF (this.Handle, initWithFrame, frame);
118
 
        else
119
 
                Handle = MonoMac.ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_RectangleF (this.SuperHandle, initWithFrame, frame);
120
 
}
 
89
public class MyClass : BaseClass {
 
90
    [Export ("initWithFoo:")]
 
91
    public MyClass (string foo) : base (NSObjectFlag.Empty)
 
92
    {
 
93
        ...
 
94
    }
121
95
</code>
122
96
          </example>
123
97
        </remarks>
130
104
      <AssemblyInfo>
131
105
        <AssemblyVersion>0.0.0.0</AssemblyVersion>
132
106
      </AssemblyInfo>
 
107
      <Attributes>
 
108
        <Attribute>
 
109
          <AttributeName>System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Advanced)</AttributeName>
 
110
        </Attribute>
 
111
      </Attributes>
133
112
      <Parameters>
134
113
        <Parameter Name="handle" Type="System.IntPtr" />
135
114
      </Parameters>
221
200
      </ReturnValue>
222
201
      <Docs>
223
202
        <summary>An instance of the MonoMac.Foundation.NSKeyedArchiverDelegate model class which acts as the class delegate.</summary>
224
 
        <value>The instance of the MonoMac.Foundation.NSKeyedArchiverDelegate model class</value>
 
203
        <value>
 
204
          <para>The instance of the MonoMac.Foundation.NSKeyedArchiverDelegate model class</para>
 
205
          <para tool="nullallowed">This value can be <see langword="null" />.</para>
 
206
        </value>
225
207
        <remarks>
226
208
          <para>The delegate instance assigned to this object will be used to handle events or provide data on demand to this class.</para>
227
209
          <para>When setting the Delegate or WeakDelegate values events will be delivered to the specified instance instead of being delivered to the C#-style events</para>
246
228
        <param name="disposing">
247
229
          <para>If set to <see langword="true" />, the method is invoked directly and will dispose manage and unmanaged resources;   If set to <see langword="false" /> the method is being called by the garbage collector finalizer and should only release unmanaged resources.</para>
248
230
        </param>
249
 
        <summary>Releases the resourced used by the NSKeyedArchiver object.</summary>
 
231
        <summary>Releases the resources used by the NSKeyedArchiver object.</summary>
250
232
        <remarks>
251
233
          <para>This Dispose method releases the resources used by the NSKeyedArchiver class.</para>
252
234
          <para>This method is called by both the Dispose() method and the object finalizer (Finalize).    When invoked by the Dispose method, the parameter disposting <paramref name="disposing" /> is set to <see langword="true" /> and any managed object references that this object holds are also disposed or released;  when invoked by the object finalizer, on the finalizer thread the value is set to <see langword="false" />. </para>
472
454
      </ReturnValue>
473
455
      <Docs>
474
456
        <summary>An object that can respond to the delegate protocol for this type</summary>
475
 
        <value>The instance that will respond to events and data requests.</value>
 
457
        <value>
 
458
          <para>The instance that will respond to events and data requests.</para>
 
459
          <para tool="nullallowed">This value can be <see langword="null" />.</para>
 
460
        </value>
476
461
        <remarks>
477
462
          <para>The delegate instance assigned to this object will be used to handle events or provide data on demand to this class.</para>
478
463
          <para>When setting the Delegate or WeakDelegate values events will be delivered to the specified instance instead of being delivered to the C#-style events</para>