2 #ifndef AFW_TABLE_IdFactory_h_INCLUDED 3 #define AFW_TABLE_IdFactory_h_INCLUDED 77 #endif // !AFW_TABLE_IdFactory_h_INCLUDED std::int64_t RecordId
Type used for unique IDs for records.
ItemVariant const * other
static int computeReservedFromMaxBits(int maxBits)
Return the number to pass as the 'reserved' argument to makeSource for an exposure ID with the given ...
IdFactory & operator=(IdFactory const &other)=delete
static std::shared_ptr< IdFactory > makeSource(RecordId expId, int reserved)
Return an IdFactory that includes another, fixed ID in the higher-order bits.
virtual RecordId operator()()=0
Return a new unique RecordId.
A base class for image defects.
A polymorphic functor base class for generating record IDs for a table.
virtual ~IdFactory()=default
virtual void notify(RecordId id)=0
Notify the IdFactory that the given ID has been used and must not be returned by operator().
virtual std::shared_ptr< IdFactory > clone() const =0
Deep-copy the IdFactory.
static std::shared_ptr< IdFactory > makeSimple()
Return a simple IdFactory that simply counts from 1.