/SampleApplication/ColdBox3/model/abstract/AbstractEntity.cfc

http://github.com/bobsilverberg/ValidateThisColdBoxPlugin · ColdFusion CFScript · 36 lines · 33 code · 3 blank · 0 comment · 0 complexity · 010dd56f82dee376465aed062396d164 MD5 · raw file

  1. <cfcomponent hint="I am an abstract entity" extends="model.abstract.BaseComponent" output="false">
  2. <!---
  3. ========================================================================================
  4. Purpose: Abstract Entity
  5. Created By: John Whish
  6. ---------------------------------------------------------------------------------------
  7. Repository path: $HeadURL$
  8. Last committed: $Revision$
  9. Last changed by: $Author$
  10. Last changed date: $Date$
  11. ========================================================================================
  12. --->
  13. <cffunction name="init" access="public" returntype="component" hint="I return this" output="false">
  14. <cfscript>
  15. return this;
  16. </cfscript>
  17. </cffunction>
  18. <!---
  19. =======================================================================================
  20. Public
  21. =======================================================================================
  22. --->
  23. <cffunction name="getEntityName" access="public" returntype="string" hint="I return a non-persisted object" output="false">
  24. <cfscript>
  25. return ORMGetSessionFactory().getClassMetadata( getClassName() ).getEntityName();
  26. </cfscript>
  27. </cffunction>
  28. <!---
  29. =======================================================================================
  30. Private
  31. =======================================================================================
  32. --->
  33. </cfcomponent>