mirror of
https://github.com/bisq-network/bisq.git
synced 2025-03-03 10:46:54 +01:00
Add GetDataResponsePriority enum
Add default getGetDataResponsePriority impl. to NetworkPayload Signed-off-by: HenrikJannsen <boilingfrog@gmx.com>
This commit is contained in:
parent
803a58eab7
commit
23e45a2843
2 changed files with 30 additions and 0 deletions
|
@ -0,0 +1,27 @@
|
||||||
|
/*
|
||||||
|
* This file is part of Bisq.
|
||||||
|
*
|
||||||
|
* Bisq is free software: you can redistribute it and/or modify it
|
||||||
|
* under the terms of the GNU Affero General Public License as published by
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or (at
|
||||||
|
* your option) any later version.
|
||||||
|
*
|
||||||
|
* Bisq 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 Affero General Public
|
||||||
|
* License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU Affero General Public License
|
||||||
|
* along with Bisq. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
package bisq.common.proto.network;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Represents priority used at truncating data set at getDataResponse if total data exceeds limits.
|
||||||
|
*/
|
||||||
|
public enum GetDataResponsePriority {
|
||||||
|
LOW,
|
||||||
|
MID,
|
||||||
|
HIGH
|
||||||
|
}
|
|
@ -23,4 +23,7 @@ import bisq.common.Payload;
|
||||||
* Interface for objects used inside WireEnvelope or other WirePayloads.
|
* Interface for objects used inside WireEnvelope or other WirePayloads.
|
||||||
*/
|
*/
|
||||||
public interface NetworkPayload extends Payload {
|
public interface NetworkPayload extends Payload {
|
||||||
|
default GetDataResponsePriority getGetDataResponsePriority() {
|
||||||
|
return GetDataResponsePriority.LOW;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue