Пример #1
0
 public override void Receive(int[] keys)
 {
     foreach (int key in keys)
     {
         MandatoryKeys.remove(key);
     }
 }
Пример #2
0
        public override void LoadProperties(long entityId, EntityType type, MutableIntSet propertyIds, PropertyLoadSink sink)
        {
            PrimitiveRecord entity;

            if (type == EntityType.NODE)
            {
                entity = NodeStore.getRecord(entityId, NodeStore.newRecord(), FORCE);
            }
            else
            {
                entity = RelationshipStore.getRecord(entityId, RelationshipStore.newRecord(), FORCE);
            }
            if (!entity.InUse())
            {
                return;
            }
            long firstPropertyId = entity.NextProp;

            if (firstPropertyId == Record.NO_NEXT_PROPERTY.intValue())
            {
                return;
            }
            foreach (PropertyRecord propertyRecord in PropertyStore.getPropertyRecordChain(firstPropertyId))
            {
                foreach (PropertyBlock block in propertyRecord)
                {
                    int currentPropertyId = block.KeyIndexId;
                    if (propertyIds.remove(currentPropertyId))
                    {
                        Value currentValue = block.Type.value(block, PropertyStore);
                        sink.onProperty(currentPropertyId, currentValue);
                    }
                }
            }
        }