All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.fisco.bcos.sdk.channel.model.ChannelRequest Maven / Gradle / Ivy

There is a newer version: 2.7.0
Show newest version
/**
 * Copyright 2014-2020 [fisco-dev]
 *
 * 

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file * except in compliance with the License. You may obtain a copy of the License at * *

http://www.apache.org/licenses/LICENSE-2.0 * *

Unless required by applicable law or agreed to in writing, software distributed under the * License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing permissions and * limitations under the License. */ package org.fisco.bcos.sdk.channel.model; import java.util.List; import java.util.concurrent.atomic.AtomicLong; public class ChannelRequest { // for set the json id private static AtomicLong nextIdGetter = new AtomicLong(0); // the jsonrpc version, default is 2.0 private String jsonrpc = "2.0"; // rpc method private String method; // params for the rpc interface private List params; // the json rpc request id private long id; public ChannelRequest(String method, List params) { this.method = method; this.params = params; this.id = nextIdGetter.getAndIncrement(); } // getter and setter for the class members public String getJsonrpc() { return this.jsonrpc; } public String getMethod() { return this.method; } public long getId() { return this.id; } public List getParams() { return this.params; } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy