[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Orekit Developers] Bug #33: UTCScale threading issue



Hi,

after a short discussion on the related issue page, I would propose to
change the creation of UTCScale instances to a Prototype pattern. As Luc
pointed out, only the cached data field "current" has to be duplicated
aka cloned, the leap data can be shared.

The proposed change would be:

 - UTCScale shall implement the Cloneable interface
 - implement a clone method that creates a new UTCScale instance
   sharing the same UTCTAIOffset array
 - update the TimeScalesFactory.getUTC method to return a clone of the
   prototype UTCScale instance

Thomas