BrookHandledClasses.pas 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. (* _ _
  2. * | |__ _ __ ___ ___ | | __
  3. * | '_ \| '__/ _ \ / _ \| |/ /
  4. * | |_) | | | (_) | (_) | <
  5. * |_.__/|_| \___/ \___/|_|\_\
  6. *
  7. * Microframework which helps to develop web Pascal applications.
  8. *
  9. * Copyright (c) 2012-2019 Silvio Clecio <[email protected]>
  10. *
  11. * Brook framework is free software; you can redistribute it and/or
  12. * modify it under the terms of the GNU Lesser General Public
  13. * License as published by the Free Software Foundation; either
  14. * version 2.1 of the License, or (at your option) any later version.
  15. *
  16. * Brook framework is distributed in the hope that it will be useful,
  17. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  18. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  19. * Lesser General Public License for more details.
  20. *
  21. * You should have received a copy of the GNU Lesser General Public
  22. * License along with Brook framework; if not, write to the Free Software
  23. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  24. *)
  25. { Base types supporting a library handle. }
  26. unit BrookHandledClasses;
  27. {$I BrookDefines.inc}
  28. interface
  29. uses
  30. Classes;
  31. type
  32. { The base handled persistent. }
  33. TBrookHandledPersistent = class abstract(TPersistent)
  34. protected
  35. function GetHandle: Pointer; virtual; abstract;
  36. public
  37. { Handle of a feature from the loaded library. }
  38. property Handle: Pointer read GetHandle;
  39. end;
  40. { The base handled collection item. }
  41. TBrookHandledCollectionItem = class abstract(TCollectionItem)
  42. protected
  43. function GetHandle: Pointer; virtual; abstract;
  44. public
  45. { Handle of a feature from the loaded library. }
  46. property Handle: Pointer read GetHandle;
  47. end;
  48. { The base handled collection. }
  49. TBrookHandledOwnedCollection = class abstract(TOwnedCollection)
  50. protected
  51. function GetHandle: Pointer; virtual; abstract;
  52. public
  53. { Handle of a feature from the loaded library. }
  54. property Handle: Pointer read GetHandle;
  55. end;
  56. { The base handled component. }
  57. TBrookHandledComponent = class abstract(TComponent)
  58. protected
  59. function GetHandle: Pointer; virtual; abstract;
  60. public
  61. { Handle of a feature from the loaded library. }
  62. property Handle: Pointer read GetHandle;
  63. end;
  64. implementation
  65. end.