Ignore:
Timestamp:
Oct 30, 2015, 11:43:01 AM (10 years ago)
Author:
Frederik Heber <heber@…>
Children:
e24dde
Parents:
1b5188
git-author:
Frederik Heber <heber@…> (06/19/15 22:28:24)
git-committer:
Frederik Heber <heber@…> (10/30/15 11:43:01)
Message:

Added new pattern ObservedValue, contrary to Cacheable.

  • essentially updates immediately and caches a value for off-line use, safe- guard with mutexes.
  • added unit test for ObservedValue.
  • factored threeNumbers stub out of CacheableUnitTest, also used the stub in ObservedValueUnitTest.
  • we may now signOn() to Notification with a priority.
  • Cacheable can also update now via notification channels not just for global updates.
  • Observable can now also instantiate the channels directly if given a list. This was necessary as Cacheable or ObservedValue are instantiated in the constructor, too, and if listening to channels, these must already be present.
  • FIX: Channels::addChannels() used NDEBUG wrong way round.
  • ObservedValue::get() returns reference.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Patterns/unittests/CacheableUnitTest.hpp

    r1b5188 r454bc54  
    1818
    1919// stub classes
    20 class threeNumbers;
     20class Cacheable_threeNumbers;
    2121
    2222class CacheableTest :  public CppUnit::TestFixture
     
    3131
    3232  void doesRecalcTest();
    33   threeNumbers *numbers;
     33  Cacheable_threeNumbers *numbers;
     34  Cacheable_threeNumbers *YChange_numbers;
    3435};
    3536
Note: See TracChangeset for help on using the changeset viewer.