BitShares-Core  5.0.0
BitShares blockchain implementation and command-line interface software
small_objects.cpp
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2019 BitShares Blockchain Foundation, and contributors.
3  *
4  * The MIT License
5  *
6  * Permission is hereby granted, free of charge, to any person obtaining a copy
7  * of this software and associated documentation files (the "Software"), to deal
8  * in the Software without restriction, including without limitation the rights
9  * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10  * copies of the Software, and to permit persons to whom the Software is
11  * furnished to do so, subject to the following conditions:
12  *
13  * The above copyright notice and this permission notice shall be included in
14  * all copies or substantial portions of the Software.
15  *
16  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19  * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22  * THE SOFTWARE.
23  */
24 
26 
46 
47 #include <fc/io/raw.hpp>
48 
50  (owner)(balance)(vesting_policy)(last_claim_date) )
51 
52 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::block_summary_object, (graphene::db::object), (block_id) )
53 
55  graphene::chain::budget_record, BOOST_PP_SEQ_NIL,
56  (time_since_last_budget)
57  (from_initial_reserve)
58  (from_accumulated_fees)
59  (from_unused_witness_budget)
60  (requested_witness_budget)
61  (total_budget)
62  (witness_budget)
63  (worker_budget)
64  (leftover_worker_funds)
65  (supply_delta)
66 )
67 
69  graphene::chain::budget_record_object,
70  (graphene::db::object),
71  (time)
72  (record)
73 )
74 
75 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::buyback_object, (graphene::db::object), (asset_to_buy) )
76 
77 
78 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::immutable_chain_parameters, BOOST_PP_SEQ_NIL,
79  (min_committee_member_count)
80  (min_witness_count)
81  (num_special_accounts)
82  (num_special_assets)
83 )
84 
85 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::chain_property_object, (graphene::db::object),
86  (chain_id)
87  (immutable_parameters)
88  )
89 
90 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::committee_member_object, (graphene::db::object),
91  (committee_member_account)(vote_id)(total_votes)(url) )
92 
93 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::blinded_balance_object, (graphene::db::object),
94  (commitment)(asset_id)(owner) )
95 
96 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::fba_accumulator_object, (graphene::db::object),
97  (accumulated_fba_fees)(designated_asset) )
98 
99 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::dynamic_global_property_object, (graphene::db::object),
100  (head_block_number)
101  (head_block_id)
102  (time)
103  (current_witness)
104  (next_maintenance_time)
105  (last_vote_tally_time)
106  (last_budget_time)
107  (witness_budget)
108  (total_pob)
109  (total_inactive)
110  (accounts_registered_this_interval)
111  (recently_missed_count)
112  (current_aslot)
113  (recent_slots_filled)
114  (dynamic_flags)
115  (last_irreversible_block_num)
116  )
117 
118 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::global_property_object, (graphene::db::object),
119  (parameters)
120  (pending_parameters)
121  (next_available_vote_id)
122  (active_committee_members)
123  (active_witnesses)
124  )
125 
126 FC_REFLECT( graphene::chain::htlc_object::transfer_info,
127  (from) (to) (amount) (asset_id) )
128 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::htlc_object::condition_info::hash_lock_info, BOOST_PP_SEQ_NIL,
129  (preimage_hash) (preimage_size) )
130 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::htlc_object::condition_info::time_lock_info, BOOST_PP_SEQ_NIL,
131  (expiration) )
132 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::htlc_object::condition_info, BOOST_PP_SEQ_NIL,
133  (hash_lock)(time_lock) )
134 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::htlc_object, (graphene::db::object),
135  (transfer) (conditions) (memo) )
136 
137 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::operation_history_object, (graphene::chain::object),
138  (op)(result)(block_num)(trx_in_block)(op_in_trx)(virtual_op) )
139 
140 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::account_transaction_history_object, (graphene::chain::object),
141  (account)(operation_id)(sequence)(next) )
142 
144  graphene::chain::special_authority_object,
145  (graphene::db::object),
146  (account)
147 )
148 
149 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::transaction_history_object, (graphene::db::object), (trx)(trx_id) )
150 
151 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::withdraw_permission_object, (graphene::db::object),
152  (withdraw_from_account)
153  (authorized_account)
154  (withdrawal_limit)
155  (withdrawal_period_sec)
156  (period_start_time)
157  (expiration)
158  (claimed_this_period)
159  )
160 
161 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::witness_object, (graphene::db::object),
162  (witness_account)
163  (last_aslot)
164  (signing_key)
165  (pay_vb)
166  (vote_id)
167  (total_votes)
168  (url)
169  (total_missed)
170  (last_confirmed_block_num)
171  )
172 
174  graphene::chain::witness_schedule_object,
175  (graphene::db::object),
176  (current_shuffled_witnesses)
177 )
178 
179 
180 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::refund_worker_type, BOOST_PP_SEQ_NIL, (total_burned) )
181 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::vesting_balance_worker_type, BOOST_PP_SEQ_NIL, (balance) )
182 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::burn_worker_type, BOOST_PP_SEQ_NIL, (total_burned) )
183 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::worker_object, (graphene::db::object),
184  (worker_account)
185  (work_begin_date)
186  (work_end_date)
187  (daily_pay)
188  (worker)
189  (vote_for)
190  (vote_against)
191  (total_votes_for)
192  (total_votes_against)
193  (name)
194  (url)
195  )
196 
197 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::custom_authority_object, (graphene::db::object),
198  (account)(enabled)(valid_from)(valid_to)(operation_type)
199  (auth)(restrictions)(restriction_counter) )
200 
201 FC_REFLECT_DERIVED_NO_TYPENAME( graphene::chain::liquidity_pool_object, (graphene::db::object),
202  (asset_a)
203  (asset_b)
204  (balance_a)
205  (balance_b)
206  (share_asset)
207  (taker_fee_percent)
208  (withdrawal_fee_percent)
209  (virtual_value)
210  )
211 
212 
213 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::balance_object )
214 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::block_summary_object )
216 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::budget_record_object )
217 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::buyback_object )
218 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::immutable_chain_parameters )
219 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::chain_property_object )
220 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::committee_member_object )
221 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::blinded_balance_object )
222 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::fba_accumulator_object )
223 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::dynamic_global_property_object )
224 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::global_property_object )
226 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::operation_history_object )
227 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::account_transaction_history_object )
228 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::special_authority_object )
229 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::transaction_history_object )
230 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::withdraw_permission_object )
231 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::witness_object )
232 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::witness_schedule_object )
234 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::custom_authority_object )
235 GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION( graphene::chain::liquidity_pool_object )
fc::static_variant< linear_vesting_policy, cdd_vesting_policy, instant_vesting_policy > vesting_policy
#define FC_REFLECT(TYPE, MEMBERS)
Specializes fc::reflector for TYPE.
Definition: reflect.hpp:386
Definition: api.cpp:56
#define FC_REFLECT_DERIVED_NO_TYPENAME(TYPE, INHERITS, MEMBERS)
Definition: reflect.hpp:356
#define GRAPHENE_IMPLEMENT_EXTERNAL_SERIALIZATION(type)
Definition: types.hpp:74
base for all database objects
Definition: object.hpp:62