如何使用JEDI TJCLHashMap类?

时间:2021-05-14 15:48:56

I'm trying to use TJCLHashMap family of classes, but apparently this class has no useful public methods. All methods are "protected". How to use this class? Although JCL comes with some samples, I seem to miss something. A basic example would be great.

我正在尝试使用TJCLHashMap系列类,但显然这个类没有有用的公共方法。所有方法都是“受保护的”。如何使用这个课程?虽然JCL带有一些样品,但我似乎错过了一些东西。一个基本的例子很棒。

2 个解决方案

#1


4  

You should use the interfaces declared in JclContainerIntf.pas. The classes in JclHashMaps implement those interfaces.
Take a look at jcl\examples\common\containers\hashing\HashingExample.dpr for a few examples (integer, strings, objects, etc.)

您应该使用JclContainerIntf.pas中声明的接口。 JclHashMaps中的类实现了这些接口。看一下jcl \ examples \ common \ containers \ hashing \ HashingExample.dpr的几个例子(整数,字符串,对象等)

#2


0  

Extend it and add public methods that call the protected methods internally?

扩展它并添加在内部调用受保护方法的公共方法?

#1


4  

You should use the interfaces declared in JclContainerIntf.pas. The classes in JclHashMaps implement those interfaces.
Take a look at jcl\examples\common\containers\hashing\HashingExample.dpr for a few examples (integer, strings, objects, etc.)

您应该使用JclContainerIntf.pas中声明的接口。 JclHashMaps中的类实现了这些接口。看一下jcl \ examples \ common \ containers \ hashing \ HashingExample.dpr的几个例子(整数,字符串,对象等)

#2


0  

Extend it and add public methods that call the protected methods internally?

扩展它并添加在内部调用受保护方法的公共方法?