diff options
| -rw-r--r-- | pyisda/credit_index.pxd | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/pyisda/credit_index.pxd b/pyisda/credit_index.pxd index e4b2d37..e059228 100644 --- a/pyisda/credit_index.pxd +++ b/pyisda/credit_index.pxd @@ -2,8 +2,26 @@ from legs cimport TContingentLeg, TFeeLeg from date cimport TDate from curve cimport TCurve, TRatePt, shared_ptr from libcpp.vector cimport vector -from libcpp.unordered_map cimport unordered_map from libcpp.string cimport string +from libcpp.pair cimport pair + +cdef extern from "<boost/unordered_map.hpp>" namespace "boost" nogil: + cdef cppclass unordered_map[T, U]: + cppclass iterator: + pair[T, U]& operator*() + iterator operator++() + iterator operator--() + bint operator==(iterator) + bint operator!=(iterator) + unordered_map() except + + unordered_map(unordered_map&) except + + bint empty() + size_t size() + iterator end() + iterator find(T&) + void clear() + U& operator[](T&) + iterator begin() cdef class CurveList: cdef TDate base_date |
