summaryrefslogtreecommitdiffstats
path: root/c_layer/cdsbootstrap.h
blob: 5a509622f94d3ecce5ba3a295ed1d493022b4c58 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#include "isda/ldate.h"
#include "isda/cxzerocurve.h"
#include "isda/feeleg.h"
#include "isda/contingentleg.h"
#include "stdio.h"


#define SUCCESS 0
#define FAILURE -1

typedef struct
{
    TDate           stepinDate;
    TDate           cashSettleDate;
    TCurve         *discountCurve;
    TCurve         *cdsCurve;
    double          recoveryRate;
    double          spread;
    TContingentLeg *cl;
    TFeeLeg        *fl;
} cds_bootstrap_ctx;


double cdsBootstrapPointFunction(double   hazardRate,
                                 void    *data);