Posted By

timgeyssens on 12/16/10


Tagged

umbraco


Versions (?)

Umbraco Juno, RestExtension and RestExtensionMethod attribute


 / Published in: C#
 

URL: http://umbraco.org

new in umbraco Juno, RestExtension and RestExtensionMethod attribute, no more need to update the restExtension.config file but simply mark type and methods... (rest extensions are used for umbraco base)

  1. [RestExtension("myAlias")]
  2. public class Test
  3. {
  4. [RestExtensionMethod]
  5. public static string HelloWorld()
  6. {
  7. return "Hello world";
  8. }
  9. [RestExtensionMethod(allowAll=false , allowGroup="custom")]
  10. public static string AnotherWithPermissions()
  11. {
  12. return "Hello member in custom group";
  13. }
  14.  
  15. }

Report this snippet  

You need to login to post a comment.