engine_api.vala 716 B

123456789101112131415161718192021222324252627282930
  1. /*
  2. * Copyright (c) 2012-2016 Daniele Bartolini and individual contributors.
  3. * License: https://github.com/taylor001/crown/blob/master/LICENSE-GPLv2
  4. */
  5. namespace Crown
  6. {
  7. namespace EngineAPI
  8. {
  9. public string compile(Guid id, string bundle_dir, string platform)
  10. {
  11. return "{\"type\":\"compile\",\"id\":\"%s\",\"bundle_dir\":\"%s\",\"platform\":\"%s\"}".printf(id.to_string(), bundle_dir, platform);
  12. }
  13. public string reload(string type, string name)
  14. {
  15. return "{\"type\":\"reload\",\"resource_type\":\"%s\",\"resource_name\":\"%s\"}".printf(type, name);
  16. }
  17. public string pause()
  18. {
  19. return "{\"type\":\"pause\"}";
  20. }
  21. public string unpause()
  22. {
  23. return "{\"type\":\"unpause\"}";
  24. }
  25. }
  26. }