ResourceSaver.xml 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <class name="ResourceSaver" inherits="Object" category="Core" version="3.1">
  3. <brief_description>
  4. Resource saving interface.
  5. </brief_description>
  6. <description>
  7. Resource saving interface, used for saving resources to disk.
  8. </description>
  9. <tutorials>
  10. </tutorials>
  11. <demos>
  12. </demos>
  13. <methods>
  14. <method name="get_recognized_extensions">
  15. <return type="PoolStringArray">
  16. </return>
  17. <argument index="0" name="type" type="Resource">
  18. </argument>
  19. <description>
  20. Returns the list of extensions available for saving a resource of a given type.
  21. </description>
  22. </method>
  23. <method name="save">
  24. <return type="int" enum="Error">
  25. </return>
  26. <argument index="0" name="path" type="String">
  27. </argument>
  28. <argument index="1" name="resource" type="Resource">
  29. </argument>
  30. <argument index="2" name="flags" type="int" default="0">
  31. </argument>
  32. <description>
  33. Saves a resource to disk.
  34. </description>
  35. </method>
  36. </methods>
  37. <constants>
  38. <constant name="FLAG_RELATIVE_PATHS" value="1" enum="SaverFlags">
  39. </constant>
  40. <constant name="FLAG_BUNDLE_RESOURCES" value="2" enum="SaverFlags">
  41. </constant>
  42. <constant name="FLAG_CHANGE_PATH" value="4" enum="SaverFlags">
  43. </constant>
  44. <constant name="FLAG_OMIT_EDITOR_PROPERTIES" value="8" enum="SaverFlags">
  45. </constant>
  46. <constant name="FLAG_SAVE_BIG_ENDIAN" value="16" enum="SaverFlags">
  47. </constant>
  48. <constant name="FLAG_COMPRESS" value="32" enum="SaverFlags">
  49. </constant>
  50. <constant name="FLAG_REPLACE_SUBRESOURCE_PATHS" value="64" enum="SaverFlags">
  51. </constant>
  52. </constants>
  53. </class>