ZipLoadCustomContextData.cs 1.0 KB

123456789101112131415161718192021222324252627282930313233343536
  1. using System;
  2. using System.IO;
  3. using ICSharpCode.SharpZipLib.Zip;
  4. using TriLibCore.General;
  5. namespace TriLibCore
  6. {
  7. /// <summary>Represents a class passed as the custom data to the Asset Loader Context when loading Models from Zip files.</summary>
  8. public class ZipLoadCustomContextData
  9. {
  10. /// <summary>
  11. /// The zip file to be used.
  12. /// </summary>
  13. public ZipFile ZipFile;
  14. /// <summary>
  15. /// The model zip entry inside the zip file.
  16. /// </summary>
  17. public ZipEntry ZipEntry;
  18. /// <summary>
  19. /// The stream used to load the zip file.
  20. /// </summary>
  21. public Stream Stream;
  22. /// <summary>
  23. /// The original error event passed to the Zip loading method.
  24. /// </summary>
  25. public Action<IContextualizedError> OnError;
  26. /// <summary>
  27. /// The original materials load event passed to the Zip loading method.
  28. /// </summary>
  29. public Action<AssetLoaderContext> OnMaterialsLoad;
  30. }
  31. }