Ejemplo n.º 1
0
 public DataSomeValuesFrom(
     IDataPropertyExpression dataPropertyExpression,
     IDataRange dataRange
     ) : base(dataPropertyExpression)
 {
     _dataRange = dataRange;
 }
Ejemplo n.º 2
0
        internal void DeleteFully()
        {
            // Get the range of keys stored for this table, and delete it.
            IDataRange dataRange = transaction.Transaction.GetRange(new Key(1, tableId, 0),
                                                                    new Key(1, tableId, Int64.MaxValue));

            dataRange.Delete();
        }
Ejemplo n.º 3
0
 protected DataCardinality(
     IDataPropertyExpression dataPropertyExpression,
     int cardinality,
     IDataRange dataRange
     ) : base(dataPropertyExpression)
 {
     _cardinality = cardinality;
     _dataRange   = dataRange;
 }
Ejemplo n.º 4
0
 public DataPropertyRange(
     IOntology ontology,
     IDataPropertyExpression dataPropertyExpression,
     IDataRange range
     ) : base(
         ontology,
         dataPropertyExpression)
 {
     _range = range;
 }
Ejemplo n.º 5
0
 public DataExactCardinality(
     IDataPropertyExpression dataPropertyExpression,
     int cardinality,
     IDataRange dataRange = null
     ) : base(
         dataPropertyExpression,
         cardinality,
         dataRange)
 {
 }
Ejemplo n.º 6
0
            public void ReplicateTo(IDataRange target)
            {
                if (target is DataRange)
                {
                    // If the tree systems are different we fall back
                    DataRange tTarget = (DataRange)target;
                    if (TreeSystem == tTarget.TreeSystem)
                    {
                        // Fail condition (same transaction),
                        if (tTarget.Transaction == Transaction)
                        {
                            throw new ArgumentException("'ReplicateTo' on the same transaction");
                        }

                        // Ok, different transaction, same tree system source, both
                        // TranDataRange objects, so we can do an efficient tree copy.

                        // TODO:
                    }
                }

                // The fallback method,
                // This uses the standard API to replicate all the keys in the target
                // range.
                // Note that if the target can't contain the keys because they fall
                //  outside of its bound then the exception comes from the target.
                target.Delete();
                long sz  = Count;
                long pos = 0;

                while (pos < sz)
                {
                    MoveTo(pos);
                    Key       key      = CurrentKey;
                    IDataFile df       = GetCurrentFile(FileAccess.Read);
                    IDataFile targetDf = target.GetFile(key, FileAccess.Write);
                    df.ReplicateTo(targetDf);
                    pos = MoveToNextKey();
                }
            }
Ejemplo n.º 7
0
 public DataComplementOf(
     IDataRange dataRange
     )
 {
     _dataRange = dataRange;
 }