亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? skip.txt

?? 開放源碼的編譯器open watcom 1.6.0版的源代碼
?? TXT
?? 第 1 頁 / 共 2 頁
字號:
Skip List Intro
===============
Skip Lists are a probabilistic alternative to balanced trees, as
described in the June 1990 issue of CACM and were invented by
William Pugh in 1987.

Skip lists have fast element insertion, search, and deletion.



Note that for any kind of PtrSkipList (WCPtrSkipList, WCPtrSkipList,
WCPtrSkipListDict)
destructors are not called on the elements pointed to.  Only the pointers are
stored so the elements are not copied, constructed or destroyed.

ValSkipList classes store a copy of elements (using Type's copy constuctor),
which will be destroyed when the element is removed or the skip list cleared or
deleted (or if the skip list goes out of scope if it is a local variable).

Header File:
============
#include <wcskip.h>



WCExcept:
=========

  This is the base class to all skip lists.  Exception handling is
  performed using this class.  By default, no exceptions will be thrown, and
  functions and operators will leave the skip list in a valid
  state on an error.  Exceptions can be enabled to be thrown using the
  exceptions member function

  available exceptions:
  ~~~~~~~~~~~~~~~~~~~~~

    The following exceptions can be thrown by skip lists:
      - WCExcept::not_empty
        if a skip list was not zero length is being
  	destroyed by the destructor, this error can be thrown.
      - WCExcept::not_unique
        thrown when attempting to insert a value into a SkipListSet or
	SkipListDict when an equivalent value already exists.
      - WCExcept::out_of_memory
        thrown when an attempt to insert an element, copy a skip list with the
	copy constructor, or perform an assignment fails due to lack of memory.

    the exceptions member function:  see WCListExcept::exceptions in the
    Container Class Library reference.

  An example:
  ~~~~~~~~~~~
      #include <wcskip.h>

      void main() {
        WCValSkipList<int> skip_list;

        skip_list.exceptions( WCExcept::out_of_memory );
	try{
	    skip list.insert( temp );
	} catch( WCExcept::failure oops ) {
	    WCExcept::wc_state cause = oops.cause();
	    if( cause & WCExcept::out_of_memory ) {
	      	cout << "out of memory!\n";
	    }
	}
      }


WCValSkipList<Type>, WCPtrSkipList<Type>:
=========================================

  These are skip which do not require values (or values pointed to) to
  be unique, based on Type's == operator.


  WCValSkipList requires from <Type>:
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    - copy and default constructors (ValSkipList only)
    - equivalence operator (operator ==)
    - less than operator (operator <)

  WCPtrSkipList requires from <Type>:
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    - equivalence operator (operator ==)
    - less than operator (operator <)
    
  public constructors/destructors:
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    - ..SkipList( unsigned probability = WCSKIPLIST_PROB_QUARTER
    		, unsigned max_ptrs = WCDEFAULT_SKIPLIST_MAX_PTRS
      constructs a skip list with no entries.  probability is used to determine
      the number of pointers in each skip list node.  If probability is
      WCSKIPLIST_PROB_QUARTER, then each element will have an average of
      1 1/3 pointers linking it into the skip list.  If probability is
      WCSKIPLIST_PROB_HALF, then each element will have an average of
      2 pointers linking it into the skip list.  max_ptrs is the maximum
      number of link pointers which an element can have to link it into the
      skip list.  The default probability and max_ptrs is appropriate for
      upto about 2^16 elements.
      If a max_ptrs is greater than WCSKIPLIST_MAX_PTRS, then
      WCSKIPLIST_MAX_PTRS will be used as the maximum number of pointers.
      For more information on the choice and effects of probability and
      maximum number of pointers, see the description of skip lists in
      the June 1990 issue of CACM.


    - ..SkipList( unsigned probability, unsigned max_ptrs
		, void * (*user_alloc)( size_t size )
		, void (*user_dealloc)( void *old, size_t size ) )
      Like the above constructor, but also provides a user allocator and user
      deallocator to allocate and free memory when entries are inserted and
      removed from the skip list.  The user_alloc function must return a
      pointer to allocated memory of at least size bytes, or 0 if it cannot
      perform the allocation (which will cause insert to fail).  The
      user_dealloc function must free "old", which was allocated by the
      user_alloc function, and is of size "size".  The size passed to
      user_alloc will depend on the number of pointers of the inserted element.
      The number of pointers can be from 1 to max_ptrs, but most elements will
      have only one or two pointers.  To determine the size of
      the objects that the user_alloc and user_dealloc functions will be
      required to allocate and free, the following macros may be used:
	WCValSkipListItemSize( Type, num_ptrs )
	WCPtrSkipListItemSize( Type, num_ptrs )
	WCValSkipListSetItemSize( Type, num_ptrs )	(for skip list sets)
	WCPtrSkipListSetItemSize( Type, num_ptrs )
      For example, WCValSkipList<my_type> will require user_alloc and
      user_dealloc to handle objects of size
      WCValSkipListItemSize( my_Type, 1 ), WCValSkipListItemSize( my_Type, 2 ),
      ...., WCValSkipListItemSize( my_Type, max_ptrs ).

    - ..SkipList( const ..SkipList &orig )
      the copy constructor.  Makes a copy of orig, including copying
      probability and max_ptrs, all values or pointers stored in the skip
      list, and the exception state.  If there is enough memory to create
      the skip list object, but not enough memory to copy all of
      the values or pointers in the skip list, then only some will be copied,
      and the number of entries will correctly reflect the number copied.
      If all of the elements cannot be copied, an out_of_memory exception
      is thrown if enabled in orig,

    - ~..SkipList()
      the destructor:  destroys the skip list object, including clearing the
      entries using the clear member function.  If the skip list is not empty
      (contains at least one entry) when this destructor is invoked, the
      not_empty exception will be thrown if enabled.


  public operators
  ~~~~~~~~~~~~~~~~

    - ..SkipList &operator=( const ..SkipList &orig )
      the assignment operator.  Clears this (using the clear member function),
      and then a copies orig, including copying
      probability and max_ptrs, all values or pointers stored in the skip
      list, and the exception state.  If there is not enough memory to copy
      all of the values or pointers in the skip list, then only some will
      be copied, and the out_of_memory exception thrown if enabled in orig.
      The number of entries will correctly reflect the number copied.
    
   - int operator==( const ..SkipList &rhs ) const
     The skip list equality operator.  Two skip lists are equivalent if they
     are the same object (ie they have the same address).  Returns 0 if not
     equal and non-zero if equal.
      

  public member fns
  ~~~~~~~~~~~~~~~~~

    **NOTE**:  unless otherwise noted, parameters of type "Type &" are for the
    WCValSkipList, and the corresponding parameters for WCPtrSkipList member
    functions have type "Type *".

    - void clear()
      remove all values or pointers from the skip list, so that there are
      no entries.  For WCPtrSkipList, the values pointed to are NOT deleted.

    ** PTR ONLY **
    - void clearAndDestroy()
      call delete for all pointers in the skip list, and clear the skip list
      to contain no entries.
    
    - int contains( const Type &elem ) const
      return non-zero if an element equivalent to elem is stored in the skip
      list, or zero if there is no equivalent element.
      Note that equivalence is based on Type's == operator for both
      WCValSkipList and WCPtrSkipList.

    - unsigned entries() const
      returns the number of entries stored in the skip list.

    ** VAL ONLY **
    - int find( const Type &search, Type &return_val ) const
      attempts to find an element equivalent to search in the skip list.  If
      an equivalent element is found, non-zero is returned, and return_val is
      assigned the found element.  If no such element is found, zero is
      returned and return_val is unchanged.
      Note that equivalence is based on Type's == operator.

    ** PTR ONLY **
    - Type *find( const Type *elem ) const
      attempts to find an element equivalent to elem in the skip list.  If
      an equivalent element is found, it is returned.  Otherwise zero is
      returned.
      If more then one element equivalent to elem is stored in the skip list,
      then the last element inserted is found.
      Note that equivalence is based on Type's == operator (ie the values
      pointed to are compared).
      
    - void WCValSkipList::forAll( void (*user_fn)( Type elem, void *data )
    				 , void *data )
    - void WCPtrSkipList::forAll( void (*user_fn)( Type *elem, void *data )
    				 , void *data )
      call user_fn for every element in the skip list (in order of least
      element to greatest, by Type's < operator).  user_fn has prototype:
        ** VAL **
	void user_fn( Type elem, void *data );
        ** PTR **
	void user_fn( Type *elem, void *data );
      and will be passed each element in turn as the first parameter, and the
      data passed to forAll as the second paramter.  data can be used to
      pass user_fn any information which it requires.

    - int WCValSkipList::insert( const Type &elem )
    - int WCPtrSkipList::insert( Type *elem )
      Insert elem into the skip list.  If allocation of the node to store elem
      fails, then an out_of_memory exception will be thrown if enabled.
      Otherwise, if the allocation failed, zero will be returned, and the
      skip list will be unchanged.  Non-zero will be returned on a successful
      insert.  If entries equivalent to elem were previously stored in the
      skip list, then elem is insert before these equivalent elements (i.e.
      elem is inserted after entries less then elem, and before entries greater
      than or equal to elem).

    - int isEmpty() const
      return non-zero if the skip list is empty, zero if the skip list
      contains at least one entry.

    - unsigned occurrencesOf( const Type &elem ) const
      return the number of elements stored in the skip list which are
      equivalent to elem.
      Note that equivalence is based on Type's == operator for both
      WCValSkipList and WCPtrSkipList.

    - int WCValSkipList::remove( const Type &elem )
    - Type *WCPtrSkipList::remove( const Type *elem )
      remove one element equivalent to elem from the skip list.  Returns
      non-zero (Val) or the removed pointer (Ptr) if an equivent element
      was found to remove, zero if not.
      If the skip list contains more than one element equivalent to elem,
      the element that was added last will be removed (LIFO).
      Note that equivalence is based on Type's == operator for both
      WCValSkipList and WCPtrSkipList.

    - unsigned removeAll( const Type &elem )
      removes all elements equivalent to elem from the skip list, and returns
      the number of elements removed (zero if the skip list contains no
      element equivalent to elem).
      Note that equivalence is based on Type's == operator for both
      WCValSkipList and WCPtrSkipList.

      

WCValSkipListSet<Type>, WCPtrSkipListSet<Type>:
=======================================

  These are skip lists which require every element in the skip list set to be
  unique, by Type's == operator.

  The exceptions, constructors/destructors, operators
  and most member fuctions are identical to those given above for
  WCValSkipList and WCPtrSkipList.

  
  member fns not defined for WCValSkipListSet/WCPtrSkipListSet
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久成人久久鬼色| 久久不见久久见中文字幕免费| 337p亚洲精品色噜噜| 国内精品在线播放| 同产精品九九九| 日本一区二区三区免费乱视频| 欧美日韩国产小视频在线观看| 丰满白嫩尤物一区二区| 六月婷婷色综合| 亚洲一二三四在线观看| 中文字幕一区二区三| 精品国产免费一区二区三区四区 | 欧美成人猛片aaaaaaa| 91免费小视频| 成人黄色av电影| 久久99国产乱子伦精品免费| 亚洲午夜久久久| 亚洲日本va午夜在线影院| 久久久久88色偷偷免费| 精品久久久久久久久久久院品网 | 亚洲精品成人精品456| 国产偷国产偷精品高清尤物| 欧美一区二区三区四区视频 | 日韩一级完整毛片| 欧美三区在线视频| 色美美综合视频| 色综合一个色综合亚洲| 成人激情文学综合网| 床上的激情91.| 粉嫩av亚洲一区二区图片| 精品写真视频在线观看| 青青草伊人久久| 蜜桃av噜噜一区| 老司机精品视频线观看86| 午夜精品福利视频网站| 亚洲va中文字幕| 亚洲不卡av一区二区三区| 一区二区三区四区视频精品免费| 国产精品成人在线观看| 欧美激情在线观看视频免费| 中文字幕av一区二区三区免费看| 欧美高清在线精品一区| 国产精品人妖ts系列视频| 国产精品天美传媒沈樵| √…a在线天堂一区| 一区二区中文视频| 亚洲精品成a人| 亚洲不卡在线观看| 蜜桃av一区二区三区电影| 韩国精品一区二区| 国产成人av电影| 色哟哟一区二区| 欧美日韩国产精选| 欧美xxxxxxxxx| 国产欧美日韩中文久久| 日韩一区中文字幕| 一区二区三区av电影| 日日夜夜精品视频天天综合网| 日本不卡免费在线视频| 极品美女销魂一区二区三区免费| 国产一区二区视频在线播放| 成人免费看片app下载| 91在线看国产| 91精品国产全国免费观看| 久久日一线二线三线suv| 国产精品欧美一区喷水| 洋洋成人永久网站入口| 日韩精品一二区| 国产成人精品午夜视频免费| 91麻豆精品视频| 日韩一区二区不卡| 日本一区二区视频在线| 亚洲伊人色欲综合网| 美女一区二区在线观看| 成人黄色电影在线| 欧美乱熟臀69xxxxxx| 精品国产凹凸成av人网站| 中文字幕在线一区免费| 性欧美疯狂xxxxbbbb| 国内成人精品2018免费看| 91麻豆国产精品久久| 日韩免费观看2025年上映的电影| 国产精品高潮呻吟| 蜜乳av一区二区| 日本久久精品电影| 精品国产伦一区二区三区观看方式 | 日韩欧美国产小视频| 国产精品福利影院| 免费黄网站欧美| 在线日韩一区二区| 国产午夜亚洲精品午夜鲁丝片| 亚洲一区二区三区美女| 东方欧美亚洲色图在线| 欧美日韩一本到| 国产精品国产成人国产三级| 美女一区二区在线观看| 欧美在线观看视频一区二区三区| 久久精品水蜜桃av综合天堂| 亚洲在线视频一区| av资源站一区| 久久久久久一二三区| 日韩精品一二三区| 在线观看日韩精品| 亚洲欧洲日韩一区二区三区| 精品一区二区三区的国产在线播放 | 理论片日本一区| 日本精品一级二级| 亚洲国产精品高清| 国产一区激情在线| 日韩亚洲电影在线| 五月激情综合网| 在线观看91精品国产入口| 国产精品久久免费看| 国产电影精品久久禁18| 日韩精品一区二区三区蜜臀| 亚洲一区二区av在线| 色综合视频一区二区三区高清| 欧美激情一区三区| 国产精品88888| 26uuu国产一区二区三区| 丝袜诱惑亚洲看片| 欧美亚洲综合网| 亚洲综合男人的天堂| 97精品久久久午夜一区二区三区| 国产精品欧美一区二区三区| 国产精品白丝jk黑袜喷水| 精品伦理精品一区| 九九视频精品免费| 日韩欧美国产三级| 麻豆精品久久久| 欧美一卡二卡在线| 日韩精品欧美成人高清一区二区| 欧美色爱综合网| 天堂成人免费av电影一区| 欧美三级电影在线观看| 亚洲国产日韩在线一区模特| 欧美视频在线播放| 日本强好片久久久久久aaa| 欧美精品久久一区| 日本不卡视频在线| 精品国产免费人成电影在线观看四季 | 欧美精品精品一区| 国产一区999| 国产偷国产偷精品高清尤物| 蜜臀国产一区二区三区在线播放 | 欧美精品一区二区三区蜜桃| 裸体在线国模精品偷拍| 精品久久久久久无| 福利91精品一区二区三区| 国产精品大尺度| 91官网在线观看| 日韩综合在线视频| 精品美女在线观看| 白白色 亚洲乱淫| 一区二区三区**美女毛片| 欧美精品自拍偷拍动漫精品| 美女视频黄 久久| 国产精品入口麻豆九色| 日本精品裸体写真集在线观看| 亚洲一区二区三区美女| 日韩欧美国产高清| 成人免费高清视频| 亚洲一区二区视频| 日韩欧美黄色影院| 99国产精品久| 日本视频免费一区| 国产精品理伦片| 欧美日韩激情一区二区| 国产一区啦啦啦在线观看| 日韩理论片一区二区| 欧美高清视频不卡网| 国产成人h网站| 亚洲综合自拍偷拍| 精品成a人在线观看| 91亚洲大成网污www| 日本亚洲欧美天堂免费| 国产精品毛片久久久久久 | ㊣最新国产の精品bt伙计久久| 欧美午夜视频网站| 国产乱码精品一品二品| 亚洲成人免费视频| 国产日产亚洲精品系列| 欧美图区在线视频| 成人精品gif动图一区| 日日夜夜免费精品| 亚洲日本电影在线| 精品国产91洋老外米糕| 欧美色综合天天久久综合精品| 狠狠色狠狠色综合系列| 亚洲国产一区二区视频| 中文字幕欧美三区| 欧美成人一级视频| 欧美日韩一区中文字幕| 懂色一区二区三区免费观看| 五月天一区二区三区| 国产精品久久久爽爽爽麻豆色哟哟| 欧美一区二区精美| 色悠悠久久综合| 菠萝蜜视频在线观看一区| 精品一区二区综合|