2004-04-12 15:54:57 +00:00
|
|
|
// GtkSharp.Generation.ByRefGen.cs - The ByRef type Generatable.
|
|
|
|
//
|
2004-12-26 21:22:50 +00:00
|
|
|
// Author: Mike Kestner <mkestner@novell.com>
|
2004-04-12 15:54:57 +00:00
|
|
|
//
|
2004-06-25 16:35:15 +00:00
|
|
|
// Copyright (c) 2003 Mike Kestner
|
2004-12-26 21:22:50 +00:00
|
|
|
// Copyright (c) 2004 Novell, Inc.
|
2004-06-25 16:35:15 +00:00
|
|
|
//
|
|
|
|
// This program is free software; you can redistribute it and/or
|
|
|
|
// modify it under the terms of version 2 of the GNU General Public
|
|
|
|
// License as published by the Free Software Foundation.
|
|
|
|
//
|
|
|
|
// This program is distributed in the hope that it will be useful,
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
// General Public License for more details.
|
|
|
|
//
|
|
|
|
// You should have received a copy of the GNU General Public
|
|
|
|
// License along with this program; if not, write to the
|
|
|
|
// Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
|
|
|
// Boston, MA 02111-1307, USA.
|
|
|
|
|
2004-04-12 15:54:57 +00:00
|
|
|
|
|
|
|
namespace GtkSharp.Generation {
|
|
|
|
|
|
|
|
using System;
|
|
|
|
|
2004-12-26 21:22:50 +00:00
|
|
|
public class ByRefGen : SimpleBase {
|
2004-04-12 15:54:57 +00:00
|
|
|
|
2004-12-26 21:22:50 +00:00
|
|
|
public ByRefGen (string ctype, string type) : base (ctype, type) {}
|
2004-04-12 15:54:57 +00:00
|
|
|
|
2004-12-26 21:22:50 +00:00
|
|
|
public override string MarshalType {
|
|
|
|
get {
|
2004-04-12 15:54:57 +00:00
|
|
|
return "ref " + QualifiedName;
|
|
|
|
}
|
|
|
|
}
|
2004-11-18 22:19:31 +00:00
|
|
|
|
2004-12-26 21:22:50 +00:00
|
|
|
public override string MarshalReturnType {
|
|
|
|
get {
|
2004-04-12 15:54:57 +00:00
|
|
|
return QualifiedName;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2004-12-26 21:22:50 +00:00
|
|
|
public override string ToNativeReturnType {
|
|
|
|
get {
|
2004-11-18 22:19:31 +00:00
|
|
|
return QualifiedName;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2004-12-26 21:22:50 +00:00
|
|
|
public override string CallByName (string var_name)
|
2004-04-12 15:54:57 +00:00
|
|
|
{
|
|
|
|
return "ref " + var_name;
|
|
|
|
}
|
|
|
|
|
2004-12-26 21:22:50 +00:00
|
|
|
public override string ToNativeReturn(string var)
|
2004-04-12 15:54:57 +00:00
|
|
|
{
|
|
|
|
return var;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|