1 // THIS FILE AUTOMATICALLY GENERATED BY xpidl2cs.pl
2 // EDITING IS PROBABLY UNWISE
3 // Permission is hereby granted, free of charge, to any person obtaining
4 // a copy of this software and associated documentation files (the
5 // "Software"), to deal in the Software without restriction, including
6 // without limitation the rights to use, copy, modify, merge, publish,
7 // distribute, sublicense, and/or sell copies of the Software, and to
8 // permit persons to whom the Software is furnished to do so, subject to
9 // the following conditions:
11 // The above copyright notice and this permission notice shall be
12 // included in all copies or substantial portions of the Software.
14 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15 // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16 // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17 // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18 // LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19 // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22 // Copyright (c) 2007, 2008 Novell, Inc.
25 // Andreia Gaita (avidigal@novell.com)
29 using System
.Runtime
.InteropServices
;
30 using System
.Runtime
.CompilerServices
;
33 namespace Mono
.Mozilla
{
35 [Guid ("f85c5a20-258d-11db-a98b-0800200c9a66")]
36 [InterfaceType (ComInterfaceType
.InterfaceIsIUnknown
)]
38 internal interface nsIDocumentEncoder
{
40 #region nsIDocumentEncoder
41 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
42 void init ([MarshalAs (UnmanagedType
.Interface
)] nsIDOMDocument aDocument
,
43 /*AString*/ HandleRef aMimeType
,
46 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
47 void setSelection ([MarshalAs (UnmanagedType
.Interface
)] nsISelection aSelection
);
49 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
50 void setRange ([MarshalAs (UnmanagedType
.Interface
)] nsIDOMRange aRange
);
52 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
53 void setNode ([MarshalAs (UnmanagedType
.Interface
)] nsIDOMNode aNode
);
55 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
56 void setContainerNode ([MarshalAs (UnmanagedType
.Interface
)] nsIDOMNode aContainer
);
58 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
59 void setCharset ( /*ACString*/ HandleRef aCharset
);
61 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
62 void setWrapColumn ( uint aWrapColumn
);
64 [PreserveSigAttribute
]
65 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
66 int getMimeType (/*AString*/ HandleRef ret
);
68 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
69 void encodeToStream ([MarshalAs (UnmanagedType
.Interface
)] nsIOutputStream aStream
);
71 [PreserveSigAttribute
]
72 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
73 int encodeToString (/*AString*/ HandleRef ret
);
75 [PreserveSigAttribute
]
76 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
77 int encodeToStringWithContext (/*AString*/ HandleRef aContextString
,
78 /*AString*/ HandleRef aInfoString
, /*AString*/ HandleRef ret
);
80 [MethodImpl (MethodImplOptions
.InternalCall
, MethodCodeType
= MethodCodeType
.Runtime
)]
81 void setNodeFixup ([MarshalAs (UnmanagedType
.Interface
)] nsIDocumentEncoderNodeFixup aFixup
);
87 internal class nsDocumentEncoder
{
88 public static nsIDocumentEncoder
GetProxy (Mono
.WebBrowser
.IWebBrowser control
, nsIDocumentEncoder obj
)
90 object o
= Base
.GetProxyForObject (control
, typeof(nsIDocumentEncoder
).GUID
, obj
);
91 return o
as nsIDocumentEncoder
;
98 using System
.Runtime
.InteropServices
;
99 using System
.Runtime
.CompilerServices
;
102 internal class DocumentEncoder
: nsIDocumentEncoder
{
104 #region nsIDocumentEncoder
105 void nsIDocumentEncoder
.init ([MarshalAs (UnmanagedType
.Interface
)] nsIDOMDocument aDocument
,
106 /*AString*/ HandleRef aMimeType
,
114 void nsIDocumentEncoder
.setSelection ([MarshalAs (UnmanagedType
.Interface
)] nsISelection aSelection
)
121 void nsIDocumentEncoder
.setRange ([MarshalAs (UnmanagedType
.Interface
)] nsIDOMRange aRange
)
128 void nsIDocumentEncoder
.setNode ([MarshalAs (UnmanagedType
.Interface
)] nsIDOMNode aNode
)
135 void nsIDocumentEncoder
.setContainerNode ([MarshalAs (UnmanagedType
.Interface
)] nsIDOMNode aContainer
)
142 void nsIDocumentEncoder
.setCharset ( /*ACString*/ HandleRef aCharset
)
149 void nsIDocumentEncoder
.setWrapColumn ( uint aWrapColumn
)
156 /*AString*/ HandleRef nsIDocumentEncoder
.getMimeType ()
162 void nsIDocumentEncoder
.encodeToStream ([MarshalAs (UnmanagedType
.Interface
)] nsIOutputStream aStream
)
169 /*AString*/ HandleRef nsIDocumentEncoder
.encodeToString ()
176 /*AString*/ HandleRef nsIDocumentEncoder
.encodeToStringWithContext (out /*AString*/ HandleRef aContextString
,
177 out /*AString*/ HandleRef aInfoString
)
184 void nsIDocumentEncoder
.setNodeFixup ([MarshalAs (UnmanagedType
.Interface
)] nsIDocumentEncoderNodeFixup aFixup
)