[IronPython] .NET attributes for methods

Shri Borde Shri.Borde at microsoft.com
Mon Oct 26 06:46:40 CET 2009


The following files extend DevHawk's blog and adds support for typed methods with attributes. It will be available as part of the samples released with the 2.6 RTM (over the next month). Do let us know if it works for you. 

Also, I would be curious to know what scenario you need method attributes for (other than DllImport for pinvokes)...

-----Original Message-----
From: users-bounces at lists.ironpython.com [mailto:users-bounces at lists.ironpython.com] On Behalf Of Lukas Cenovsky
Sent: Thursday, October 22, 2009 10:37 AM
To: Discussion of IronPython
Subject: [IronPython] .NET attributes for methods

Hi,
I have read all DewHawk blogposts about .Net attributes in IronPython 
via __clrtype__ metaclass 
(http://devhawk.net/CategoryView,category,__clrtype__.aspx). He 
describes how to add attributes to classes but not to methods. Is there 
any example how to add attributes to a method. It looks like method 
generation is necessary (like for getter and setter or in 
http://www.voidspace.org.uk/python/weblog/arch_d7_2007_03_10.shtml#e659) 
but this is kind of deep magic for me...
Thanks.

--
-- Lukáš
_______________________________________________
Users mailing list
Users at lists.ironpython.com
http://lists.ironpython.com/listinfo.cgi/users-ironpython.com

-------------- next part --------------
A non-text attachment was scrubbed...
Name: clrtype.py
Type: application/octet-stream
Size: 16627 bytes
Desc: clrtype.py
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20091026/d52aa697/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: sample.py
Type: application/octet-stream
Size: 5503 bytes
Desc: sample.py
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20091026/d52aa697/attachment-0001.obj>


More information about the Ironpython-users mailing list