Main Page | Modules | Namespace List | Class Hierarchy | Data Structures | Directories | File List | Namespace Members | Data Fields | Related Pages

ErrorMessage.cs

00001 namespace DBus
00002 {
00003   using System;
00004   using System.Runtime.InteropServices;
00005   using System.Diagnostics;
00006   
00007   public class ErrorMessage : Message
00008   {    
00009     public ErrorMessage() : base(MessageType.Error)
00010     {  
00011     }
00012 
00013     internal ErrorMessage(IntPtr rawMessage, Service service) : base(rawMessage, service)
00014     {
00015     }
00016 
00017     public ErrorMessage(Service service) : base(MessageType.Error, service) 
00018     {
00019     }
00020 
00021     public new string Name
00022     {
00023       get {
00024         if (this.name == null) {
00025           this.name = Marshal.PtrToStringAnsi(dbus_message_get_error_name(RawMessage));
00026         }
00027         
00028         return this.name;
00029       }
00030       
00031       set {
00032         if (value != this.name) {
00033           dbus_message_set_error_name(RawMessage, value);
00034           this.name = value;
00035         }
00036       }
00037     }
00038 
00039     [DllImport("dbus-1")]
00040     private extern static bool dbus_message_set_error_name(IntPtr rawMessage, string name);
00041 
00042     [DllImport("dbus-1")]
00043     private extern static IntPtr dbus_message_get_error_name(IntPtr rawMessage);
00044   }
00045 }

Generated on Tue Sep 13 01:28:08 2005 for D-BUS by  doxygen 1.4.4