/snippets/Taffy/Application cfc-tag.xml

http://github.com/atuttle/Taffy · XML · 51 lines · 44 code · 7 blank · 0 comment · 0 complexity · a8975e9bd0fb127847c7a937c195999a MD5 · raw file

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <snippet filetemplate="false" extension="">
  3. <name>Application cfc-tag</name>
  4. <help>Creates an Application.cfc skeleton for a Taffy API using cfml tags</help>
  5. <starttext><![CDATA[<cfcomponent extends="taffy.core.api">
  6. <cfset this.name = "]]></starttext>
  7. <endtext><![CDATA[" />
  8. <cfset variables.framework = {
  9. reloadKey = "reload"
  10. ,reloadPassword = "true"
  11. ,reloadOnEveryRequest = false
  12. ,defaultRepresentationClass = "taffy.core.nativeJsonRepresentation"
  13. ,dashboardKey = "dashboard"
  14. ,disableDashboard = false
  15. ,unhandledPaths = "/flex2gateway"
  16. ,allowCrossDomain = false
  17. ,globalHeaders = structNew()
  18. ,debugKey = "debug"
  19. ,returnExceptionsAsJson = true
  20. ,exceptionLogAdapter = "taffy.bonus.LogToEmail"
  21. ,exceptionLogAdapterConfig = {
  22. emailFrom = "api-error@yourdomain.com"
  23. ,emailTo = "you@yourdomain.com"
  24. ,emailSubj = "Exception Trapped in API"
  25. ,emailType = "html"
  26. }
  27. ,beanFactory = ""
  28. } />
  29. <cffunction name="onApplicationStart">
  30. <cfreturn super.onApplicationStart() />
  31. </cffunction>
  32. <cffunction name="onRequestStart">
  33. <cfreturn super.onRequestStart() />
  34. </cffunction>
  35. <cffunction name="onTaffyRequest">
  36. <cfargument name="verb" />
  37. <cfargument name="cfc" />
  38. <cfargument name="requestArguments" />
  39. <cfargument name="mimeExt" />
  40. <cfargument name="headers" />
  41. <cfargument name="methodMetadata" />
  42. </cffunction>
  43. </cfcomponent>]]></endtext>
  44. </snippet>