IvCloudTerminal.cs 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. using System;
  2. using System.Collections.Generic;
  3. namespace Vinno.vCloud.Common.FIS
  4. {
  5. public enum RegisterType
  6. {
  7. Success,
  8. Error,
  9. Failed
  10. }
  11. public interface IvCloudTerminal : IDisposable
  12. {
  13. /// <summary>
  14. /// Get terminal id.
  15. /// </summary>
  16. string Id { get; }
  17. /// <summary>
  18. /// Get Terminal name.
  19. /// </summary>
  20. string TerminalName { get; }
  21. /// <summary>
  22. /// Get Terminal mode.
  23. /// </summary>
  24. string TerminalMode { get; }
  25. /// <summary>
  26. /// The uniqueId create when terminal created, used to add terminal for client user.
  27. /// </summary>
  28. string UniqueId { get; }
  29. /// <summary>
  30. /// Gets the status of the Terminal
  31. /// </summary>
  32. TerminalStatus Status { get; }
  33. /// <summary>
  34. /// Raised when the status is changed.
  35. /// </summary>
  36. event EventHandler StatusChanged;
  37. /// <summary>
  38. /// Get the feature instance by feature enum.
  39. /// </summary>
  40. /// <typeparam name="T">The interface of the feature</typeparam>
  41. /// <param name="featureType">The feature type</param>
  42. /// <returns>The instance of the feature</returns>
  43. /// <remarks>
  44. /// If the feature doesn't exist, this method will return null.
  45. /// </remarks>
  46. T GetFeature<T>(TerminalFeatureType featureType) where T : IFeature;
  47. IEnumerable<string> GetOrganizations(string keyWord);
  48. /// <summary>
  49. /// Disconnect to server.
  50. /// </summary>
  51. void Disconnect();
  52. /// <summary>
  53. /// Status == TerminalStatus.OrganizationMissing;
  54. /// </summary>
  55. /// <returns></returns>
  56. bool IsTerminalOrganizationMissging();
  57. /// <summary>
  58. /// update terminal account organization name to server
  59. /// </summary>
  60. /// <param name="organizationName"></param>
  61. /// <param name="createNewOrganization"></param>
  62. /// <returns> update success or yfailed</returns>
  63. bool UpdatelTerminalOrganizationName(string organizationName, bool createNewOrganization);
  64. /// <summary>
  65. /// get terminal Organization name after this must login successed
  66. /// </summary>
  67. /// <param name="terminalname"></param>
  68. /// <returns></returns>
  69. string GetOrganizationName();
  70. /// <summary>
  71. /// get report images by patienId after success login vcloud server
  72. /// </summary>
  73. /// <param name="patientId">patienId</param>
  74. /// <returns>if no found report ,return new list<byte[]></returns>
  75. IEnumerable<byte[]> GetReportImagesByPatientId(string patientId);
  76. /// <summary>
  77. /// Update enabled feature types.
  78. /// </summary>
  79. /// <param name="enabledFeatureTypes">The enabled feature types.</param>
  80. void UpdateFeatures(IEnumerable<TerminalFeatureType> enabledFeatureTypes);
  81. }
  82. }