DK96-OS / MathTools

Mathematical Software Components. This library is actively maintained, and aims to stay updated. New feature proposals are welcome, but may not be included.
Apache License 2.0
2 stars 1 forks source link

PrimeNumberTools Private Cache - May Cause Duplication #58

Closed DK96-OS closed 2 years ago

DK96-OS commented 2 years ago

The PrimeNumberTools object has a private ShortPrimeCache member that it uses to serve it's functions.

This cache is inaccessible to users, and so if a user needs a PrimeNumber cache they will have to create one. If PrimeNumberTools is being used, then the cache will be duplicated.

Potential solutions:

DK96-OS commented 2 years ago

Functional Dependency injection is the most flexible.