Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libdap-chain-wallet-python
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
cellframe
libdap-chain-wallet-python
Merge requests
!1
Features 2773
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Features 2773
features-2773
into
master
Overview
0
Commits
6
Pipelines
0
Changes
3
Merged
alexey.stratulat
requested to merge
features-2773
into
master
4 years ago
Overview
0
Commits
6
Pipelines
0
Changes
3
Expand
Added wrapping for dap_chain_wallet.
👍
0
👎
0
Merge request reports
Compare
master
master (base)
and
latest version
latest version
6846a891
6 commits,
4 years ago
3 files
+
286
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
3
Search (e.g. *.vue) (Ctrl+P)
include/dap_chain_wallet_python.h
0 → 100644
+
119
−
0
Options
#ifndef _DAP_CHAIN_WALLET_PYTHON_
#define _DAP_CHAIN_WALLET_PYTHON_
#include
<Python.h>
#include
"dap_common.h"
#include
"dap_chain_wallet.h"
#include
"wrapping_dap_chain_common.h"
#include
"libdap_crypto_key_python.h"
#include
"wrapping_dap_sign.h"
#include
"wrapping_dap_pkey.h"
#include
"wrapping_cert.h"
#ifdef __cplusplus
extern
"C"
{
#endif
#undef LOG_TAG
#define LOG_TAG "dap_chain_wallet_python"
typedef
struct
PyDapChainWallet
{
PyObject_HEAD
dap_chain_wallet_t
*
wallet
;
}
PyDapChainWalletObject
;
int
dap_chain_wallet_init_py
(
void
);
void
dap_chain_wallet_deinit_py
(
void
);
PyObject
*
dap_chain_wallet_get_path_py
(
PyObject
*
self
,
PyObject
*
argv
);
PyObject
*
dap_chain_wallet_create_with_seed_py
(
PyObject
*
self
,
PyObject
*
argv
);
PyObject
*
dap_chain_wallet_create_py
(
PyTypeObject
*
type
,
PyObject
*
argv
,
PyObject
*
kwds
);
PyObject
*
dap_chain_wallet_open_file_py
(
PyObject
*
self
,
PyObject
*
argv
);
PyObject
*
dap_chain_wallet_open_py
(
PyObject
*
self
,
PyObject
*
argv
);
PyObject
*
dap_chain_wallet_save_py
(
PyObject
*
self
,
PyObject
*
argv
);
void
dap_chain_wallet_close_py
(
PyDapChainWalletObject
*
self
);
PyObject
*
dap_cert_to_addr_py
(
PyObject
*
self
,
PyObject
*
argv
);
PyObject
*
dap_chain_wallet_get_addr_py
(
PyObject
*
self
,
PyObject
*
argv
);
PyObject
*
dap_chain_wallet_get_certs_number_py
(
PyObject
*
self
,
PyObject
*
argv
);
PyObject
*
dap_chain_wallet_get_pkey_py
(
PyObject
*
self
,
PyObject
*
argv
);
PyObject
*
dap_chain_wallet_get_key_py
(
PyObject
*
self
,
PyObject
*
argv
);
//PyObject *dap_chain_wallet_save_file_py(PyObject *self, PyObject *argv);
static
PyMethodDef
ChainWalletMethods
[]
=
{
{
"getPath"
,
(
PyCFunction
)
dap_chain_wallet_get_path_py
,
METH_VARARGS
|
METH_STATIC
,
""
},
{
"createWithSeed"
,
(
PyCFunction
)
dap_chain_wallet_create_with_seed_py
,
METH_VARARGS
|
METH_STATIC
,
""
},
{
"openFile"
,
(
PyCFunction
)
dap_chain_wallet_open_file_py
,
METH_VARARGS
|
METH_STATIC
,
""
},
{
"open"
,
(
PyCFunction
)
dap_chain_wallet_open_py
,
METH_VARARGS
|
METH_STATIC
,
""
},
{
"save"
,
(
PyCFunction
)
dap_chain_wallet_save_py
,
METH_NOARGS
,
""
},
{
"certToAddr"
,
(
PyCFunction
)
dap_cert_to_addr_py
,
METH_VARARGS
|
METH_STATIC
,
""
},
{
"getAddr"
,
(
PyCFunction
)
dap_chain_wallet_get_addr_py
,
METH_VARARGS
,
""
},
{
"getCertsNumber"
,
(
PyCFunction
)
dap_chain_wallet_get_certs_number_py
,
METH_NOARGS
,
""
},
{
"getPKey"
,
(
PyCFunction
)
dap_chain_wallet_get_pkey_py
,
METH_VARARGS
,
""
},
{
"getKey"
,
(
PyCFunction
)
dap_chain_wallet_get_key_py
,
METH_VARARGS
,
""
},
{
NULL
,
NULL
,
0
,
NULL
}
};
static
PyTypeObject
DapChainWallet_dapChainWalletType
=
{
PyVarObject_HEAD_INIT
(
NULL
,
0
)
"ChainWallet"
,
/* tp_name */
sizeof
(
PyDapChainWalletObject
),
/* tp_basicsize */
0
,
/* tp_itemsize */
(
destructor
)
dap_chain_wallet_close_py
,
/* tp_dealloc */
0
,
/* tp_print */
0
,
/* tp_getattr */
0
,
/* tp_setattr */
0
,
/* tp_reserved */
0
,
/* tp_repr */
0
,
/* tp_as_number */
0
,
/* tp_as_sequence */
0
,
/* tp_as_mapping */
0
,
/* tp_hash */
0
,
/* tp_call */
0
,
/* tp_str */
0
,
/* tp_getattro */
0
,
/* tp_setattro */
0
,
/* tp_as_buffer */
Py_TPFLAGS_DEFAULT
|
Py_TPFLAGS_BASETYPE
,
/* tp_flags */
"Chain wallet object"
,
/* tp_doc */
0
,
/* tp_traverse */
0
,
/* tp_clear */
0
,
/* tp_richcompare */
0
,
/* tp_weaklistoffset */
0
,
/* tp_iter */
0
,
/* tp_iternext */
ChainWalletMethods
,
/* tp_methods */
0
,
/* tp_members */
0
,
/* tp_getset */
0
,
/* tp_base */
0
,
/* tp_dict */
0
,
/* tp_descr_get */
0
,
/* tp_descr_set */
0
,
/* tp_dictoffset */
0
,
/* tp_init */
0
,
/* tp_alloc */
dap_chain_wallet_create_py
,
/* tp_new */
0
,
/* tp_free */
0
,
/* tp_is_gc*/
0
,
/* tp_bases*/
0
,
/* tp_mro */
0
,
/* tp_cache */
0
,
/* tp_subclasses */
0
,
/* tp_weaklist */
0
,
/* tp_del */
0
,
/* tp_version_tag*/
0
,
/* tp_finalize*/
};
#ifdef __cplusplus
}
#endif
#endif // _DAP_CHAIN_WALLET_PYTHON_
Loading