00001 namespace DBus
00002 {
00003 using System;
00004 using System.Runtime.InteropServices;
00005 using System.Diagnostics;
00006
00007 public class MethodReturn : Message
00008 {
00009 private MethodReturn() : base(MessageType.MethodReturn)
00010 {
00011 }
00012
00013 internal MethodReturn(IntPtr rawMessage, Service service) : base(rawMessage, service)
00014 {
00015 }
00016
00017 public MethodReturn(MethodCall methodCall)
00018 {
00019 this.service = methodCall.Service;
00020
00021 RawMessage = dbus_message_new_method_return(methodCall.RawMessage);
00022
00023 if (RawMessage == IntPtr.Zero) {
00024 throw new OutOfMemoryException();
00025 }
00026
00027 dbus_message_unref(RawMessage);
00028 }
00029
00030 public new string PathName
00031 {
00032 get
00033 {
00034 return base.PathName;
00035 }
00036 }
00037
00038 public new string InterfaceName
00039 {
00040 get
00041 {
00042 return base.InterfaceName;
00043 }
00044 }
00045
00046 public new string Name
00047 {
00048 get
00049 {
00050 return base.Name;
00051 }
00052 }
00053
00054 [DllImport("dbus-1")]
00055 private extern static IntPtr dbus_message_new_method_return(IntPtr rawMessage);
00056 }
00057 }