?? stl.html
字號:
<HTML><HEAD><TITLE>Newmat09 - standard template library</TITLE></HEAD><BODY><H2>Standard template library</H2><A HREF="namesp.html"> next</A> - <A HREF="namesp.html"> skip</A> - <A HREF="refer.html"> up</A> - <A HREF="index.html"> start</A><P>The standard template library (STL) is the set of <I>container templates</I>(vector, deque, list etc) defined by the C++ standards committee.Newmat is intended to be compatible with the STL in the sense that you can storematrices in the standard containers. I have defined<A HREF="binary.html"> <TT>==</TT> and inequality </A> operatorsto help make this possible. Probably there will have to be some other changes.My experiments with the Rogue Wave STL that comes with Borland C++ 5.0 showedthat some things worked and some things unexpectedly didn't work. In particular,I couldn't get the list container to work. I don't know whose fault this is.<P>If you want to use the container classes with Newmat please note<UL><LI> Don't use simulated exceptions.<LI> You can store only one type of matrix in a container. If you want to usea variety of types use the GenericMatrix type or store pointers to the matrices.<LI> The vector and deque container templates like to copy their elements.For the vector container this happens when you insert an element anywhereexcept at the end or when you append an element and the current vectorstorage overflows. Since Newmat does not have <I>copy-on-write</I> thiscould get very inefficient. (Later versions may have <I>copy-on-write</I>for the GenericMatrix type).<LI> You won't be able to sort the container or do anything that would call aninequality operator.</UL><P>I doubt whether the STL container will be used often for matrices.So I don't think these limitations are very critical. If you think otherwise, please tell me.<P></BODY></HTML>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -