예제 #1
0
        internal virtual void RegisterKey(object key,
                                          Int64 address,
                                          Session session,
                                          RecordManager recordManager,
                                          string indexName)
        {
            var index = new RecordIndex <ValueWithAddressIndexKey <TAttribute> >(
                this.Session,
                this.RecordManager,
                indexName,
                this.Session.SerializerResolver.SerializerFor <Node <ValueWithAddressIndexKey <TAttribute> > >()
                );

            index.Register((ValueWithAddressIndexKey <TAttribute>)key, address);
        }
예제 #2
0
        internal override void RegisterKey(object key,
                                           Int64 address,
                                           Session session,
                                           RecordManager recordManager,
                                           string indexName)
        {
            var index = new RecordIndex <TID>(
                this.Session,
                recordManager,
                indexName,
                this.Session.SerializerResolver.SerializerFor <Node <TID> >()
                );

            index.Register((TID)key, address);
        }
예제 #3
0
 public void Register_Inserts_When_Key_Not_Present()
 {
     _index.Register(1, 2);
     Assert.AreEqual(2, _mockTree.Inserted[1]);
 }