Search in sources :

Example 1 with AbstractGlobalEndResponse

use of io.seata.core.protocol.transaction.AbstractGlobalEndResponse in project seata by seata.

the class AbstractGlobalEndResponseCodec method encode.

@Override
public <T> void encode(T t, ByteBuf in) {
    super.encode(t, in);
    AbstractGlobalEndResponse abstractGlobalEndResponse = (AbstractGlobalEndResponse) t;
    GlobalStatus globalStatus = abstractGlobalEndResponse.getGlobalStatus();
    in.writeByte(globalStatus.getCode());
}
Also used : GlobalStatus(io.seata.core.model.GlobalStatus) AbstractGlobalEndResponse(io.seata.core.protocol.transaction.AbstractGlobalEndResponse)

Example 2 with AbstractGlobalEndResponse

use of io.seata.core.protocol.transaction.AbstractGlobalEndResponse in project seata by seata.

the class AbstractGlobalEndResponseCodec method decode.

@Override
public <T> void decode(T t, ByteBuffer in) {
    super.decode(t, in);
    AbstractGlobalEndResponse abstractGlobalEndResponse = (AbstractGlobalEndResponse) t;
    abstractGlobalEndResponse.setGlobalStatus(GlobalStatus.get(in.get()));
}
Also used : AbstractGlobalEndResponse(io.seata.core.protocol.transaction.AbstractGlobalEndResponse)

Aggregations

AbstractGlobalEndResponse (io.seata.core.protocol.transaction.AbstractGlobalEndResponse)2 GlobalStatus (io.seata.core.model.GlobalStatus)1