1 /* 2 * This file is part of gtkD. 3 * 4 * gtkD is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU Lesser General Public License 6 * as published by the Free Software Foundation; either version 3 7 * of the License, or (at your option) any later version, with 8 * some exceptions, please read the COPYING file. 9 * 10 * gtkD is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 * GNU Lesser General Public License for more details. 14 * 15 * You should have received a copy of the GNU Lesser General Public License 16 * along with gtkD; if not, write to the Free Software 17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA 18 */ 19 20 // generated automatically - do not change 21 // find conversion definition on APILookup.txt 22 // implement new conversion functionalities on the wrap.utils pakage 23 24 25 module glib.TrashStack; 26 27 private import gtkc.glib; 28 public import gtkc.glibtypes; 29 30 31 /** 32 * Each piece of memory that is pushed onto the stack 33 * is cast to a GTrashStack*. 34 */ 35 public struct TrashStack 36 { 37 /** 38 */ 39 40 /** 41 * Returns the height of a #GTrashStack. 42 * 43 * Note that execution of this function is of O(N) complexity 44 * where N denotes the number of items on the stack. 45 * 46 * Params: 47 * stackP = a #GTrashStack 48 * 49 * Return: the height of the stack 50 */ 51 public static uint height(GTrashStack** stackP) 52 { 53 return g_trash_stack_height(stackP); 54 } 55 56 /** 57 * Returns the element at the top of a #GTrashStack 58 * which may be %NULL. 59 * 60 * Params: 61 * stackP = a #GTrashStack 62 * 63 * Return: the element at the top of the stack 64 */ 65 public static void* peek(GTrashStack** stackP) 66 { 67 return g_trash_stack_peek(stackP); 68 } 69 70 /** 71 * Pops a piece of memory off a #GTrashStack. 72 * 73 * Params: 74 * stackP = a #GTrashStack 75 * 76 * Return: the element at the top of the stack 77 */ 78 public static void* pop(GTrashStack** stackP) 79 { 80 return g_trash_stack_pop(stackP); 81 } 82 83 /** 84 * Pushes a piece of memory onto a #GTrashStack. 85 * 86 * Params: 87 * stackP = a #GTrashStack 88 * dataP = the piece of memory to push on the stack 89 */ 90 public static void push(GTrashStack** stackP, void* dataP) 91 { 92 g_trash_stack_push(stackP, dataP); 93 } 94 }