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
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:
Make the cache public
Refactor PrimeNumberTools members to use functional dependency injection, design for any size cache, and remove private cache
The
PrimeNumberTools
object has a privateShortPrimeCache
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:
PrimeNumberTools
members to use functional dependency injection, design for any size cache, and remove private cacheShortPrimeCache
static