-
Notifications
You must be signed in to change notification settings - Fork 163
/
Copy pathPortfolioGreek.h
65 lines (47 loc) · 2.25 KB
/
PortfolioGreek.h
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
/************************************************************************
* Copyright(c) 2018, One Unified. All rights reserved. *
* *
* This file is provided as is WITHOUT ANY WARRANTY *
* without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. *
* *
* This software may not be used nor distributed without proper license *
* agreement. *
* *
* See the file LICENSE.txt for redistribution information. *
************************************************************************/
/*
* File: PortfolioGreek.h
* Author: [email protected]
*
* Created on July 31, 2018, 11:16 AM
*/
#ifndef PORTFOLIOGREEK_H
#define PORTFOLIOGREEK_H
#include "Portfolio.h"
#include "PositionGreek.h"
namespace ou { // One Unified
namespace tf { // TradeFrame
class PortfolioGreek: public Portfolio {
friend class boost::serialization::access;
public:
friend std::ostream& operator<<( std::ostream& os, const Portfolio& );
using idPosition_t = keytypes::idPosition_t;
using idPortfolio_t = keytypes::idPortfolio_t;
using pPositionGreek_t = PositionGreek::pPositionGreek_t;
using pPortfolioGreek_t = std::shared_ptr<PortfolioGreek>;
PortfolioGreek(
const idPortfolio_t& idPortfolio, const idAccountOwner_t& idAccountOwner, const idPortfolio_t& idOwner, EPortfolioType ePortfolioType_,
currency_t eCurrency, const std::string& sDescription );
virtual ~PortfolioGreek( );
pPositionGreek_t AddPosition( const std::string& sName, pPositionGreek_t );
void DeletePosition( const std::string& sName, pPositionGreek_t ); // supply the position to test against the name or ptr value (ptr not used here)
void AddSubPortfolio( pPortfolioGreek_t& );
void RemoveSubPortfolio( const idPortfolio_t& idPortfolio );
protected:
private:
};
std::ostream& operator<<( std::ostream& os, const PortfolioGreek& );
} // namespace tf
} // namespace ou
#endif /* PORTFOLIOGREEK_H */