Added rankLessThan
authornvalimak <nvalimak@3cdefd35-fc62-479d-8e8d-bae585ffb9ca>
Tue, 10 Mar 2009 19:12:03 +0000 (19:12 +0000)
committernvalimak <nvalimak@3cdefd35-fc62-479d-8e8d-bae585ffb9ca>
Tue, 10 Mar 2009 19:12:03 +0000 (19:12 +0000)
git-svn-id: svn+ssh://idea.nguyen.vg/svn/sxsi/trunk/XMLTree@241 3cdefd35-fc62-479d-8e8d-bae585ffb9ca

libcds/src/static_sequence/static_sequence.h

index cf8a1e0..f8f3bb5 100644 (file)
@@ -46,13 +46,24 @@ public:
 
   /** Returns the number of occurrences of c until position i */
   virtual uint rank(uint c, uint i)=0;
-
+  virtual uint rankLessThan(uint &i, uint j)
+  {
+      //assert(0); // Implemented only in static_sequence_wvtree
+      return -1;
+  }
+  
   /** Returns the position of the i-th c 
    * @return (uint)-1 if i=0, len if i exceeds the number of cs */
   virtual uint select(uint c, uint i)=0;
 
   /** Returns the i-th element */
   virtual uint access(uint i)=0;
+  virtual uint access(uint i, uint &rank)
+  {
+      //assert(0); // Implemented only in static_sequence_wvtree
+      return -1;
+  }
+      
 
   /** Returns the length of the sequence */
   virtual uint length();