summaryrefslogtreecommitdiff
path: root/scripts/rz_api_mesh.js
blob: 5ffe7b76d0fab2d4159d74fc9616955c644c4f76 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
/**
 * API calls designed to execute in decentralized fashion
 */
define(['rz_api_backend'], function(rz_api_backend) {
    function RZ_API_Mesh() {
        
        /**
         * suggest diff block and await commit/reject consensus
         */
        // @ajax-trans
        this.broadcast_possible_next_diff_block = function (diff_set) {
            
            function on_success(data){
                // TODO impl
            }
            
            rz_api_backend.commit_diff_set(diff_set);
        }
    }
    return new RZ_API_Mesh();
});