1 /* 2 Queues 3 */ 4 5 %fragment("StdQueueTraits","header",fragment="StdSequenceTraits") 6 %{ 7 namespace swig { 8 template <class T> 9 struct traits_asptr<std::queue<T> > { 10 static int asptr(VALUE obj, std::queue<T> **vec) { 11 return traits_asptr_stdseq<std::queue<T> >::asptr(obj, vec); 12 } 13 }; 14 15 template <class T> 16 struct traits_from<std::queue<T> > { 17 static VALUE from(const std::queue<T> & vec) { 18 return traits_from_stdseq<std::queue<T> >::from(vec); 19 } 20 }; 21 } 22 %} 23 24 %rename("delete") std::queue::__delete__; 25 %rename("reject!") std::queue::reject_bang; 26 %rename("map!") std::queue::map_bang; 27 %rename("empty?") std::queue::empty; 28 %rename("include?" ) std::queue::__contains__ const; 29 %rename("has_key?" ) std::queue::has_key const; 30 31 %alias std::queue::push "<<"; 32 33 %include <std/std_queue.i> 34