-
dmitriy.gerasimov authored
[+] chain_id field for tx_token. Now its universal and could be used not only for emission but for shard<->shard ledgers connections
3e0e299a
/*
* Authors:
* Dmitriy A. Gearasimov <kahovski@gmail.com>
* DeM Labs Inc. https://demlabs.net
* DeM Labs Open source community https://github.com/demlabsinc
* Copyright (c) 2017-2019
* All rights reserved.
This file is part of DAP (Deus Applications Prototypes) the open source project
DAP (Deus Applicaions Prototypes) is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
DAP is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with any DAP based project. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include <stdint.h>
#include "dap_common.h"
#include "dap_chain_common.h"
#include "dap_chain_datum_tx.h"
/**
* @struct dap_chain_tx_token
* @brief Token item
*/
typedef struct dap_chain_tx_token{
struct {
dap_chain_tx_item_type_t type:8;
char ticker[10];
uint8_t padding; // Padding
dap_chain_id_t token_emission_chain_id;
dap_chain_hash_fast_t token_emission_hash;
} header; /// Only header's hash is used for verification
} DAP_ALIGN_PACKED dap_chain_tx_token_t;