PoolCertificateMapperImpl.java

1
package org.cardanofoundation.explorer.api.mapper;
2
3
import javax.annotation.processing.Generated;
4
import org.cardanofoundation.explorer.api.model.response.pool.PoolCertificateHistory;
5
import org.cardanofoundation.explorer.api.model.response.pool.TxPoolCertificateHistory;
6
import org.cardanofoundation.explorer.api.model.response.pool.projection.PoolCertificateProjection;
7
import org.springframework.stereotype.Component;
8
9
@Generated(
10
    value = "org.mapstruct.ap.MappingProcessor",
11
    date = "2024-11-05T06:00:28+0000",
12
    comments = "version: 1.5.3.Final, compiler: javac, environment: Java 18.0.2.1 (Eclipse Adoptium)"
13
)
14
@Component
15
public class PoolCertificateMapperImpl implements PoolCertificateMapper {
16
17
    @Override
18
    public PoolCertificateHistory fromPoolCertificateProjection(PoolCertificateProjection poolCertificateProjection) {
19 1 1. fromPoolCertificateProjection : negated conditional → KILLED
        if ( poolCertificateProjection == null ) {
20
            return null;
21
        }
22
23
        PoolCertificateHistory.PoolCertificateHistoryBuilder<?, ?> poolCertificateHistory = PoolCertificateHistory.builder();
24
25
        poolCertificateHistory.txId( poolCertificateProjection.getTxId() );
26
        poolCertificateHistory.txEpochNo( poolCertificateProjection.getTxEpochNo() );
27
        poolCertificateHistory.certEpochNo( poolCertificateProjection.getCertEpochNo() );
28
        poolCertificateHistory.certIndex( poolCertificateProjection.getCertIndex() );
29
        poolCertificateHistory.poolRetireId( poolCertificateProjection.getPoolRetireId() );
30
        poolCertificateHistory.poolUpdateId( poolCertificateProjection.getPoolUpdateId() );
31
        poolCertificateHistory.txHash( poolCertificateProjection.getTxHash() );
32
        poolCertificateHistory.blockTime( poolCertificateProjection.getBlockTime() );
33
        poolCertificateHistory.blockNo( poolCertificateProjection.getBlockNo() );
34
        poolCertificateHistory.epochSlotNo( poolCertificateProjection.getEpochSlotNo() );
35
        poolCertificateHistory.slotNo( poolCertificateProjection.getSlotNo() );
36
37 1 1. fromPoolCertificateProjection : replaced return value with null for org/cardanofoundation/explorer/api/mapper/PoolCertificateMapperImpl::fromPoolCertificateProjection → KILLED
        return poolCertificateHistory.build();
38
    }
39
40
    @Override
41
    public TxPoolCertificateHistory fromPoolCertificateHistory(PoolCertificateHistory poolCertificateHistory) {
42 1 1. fromPoolCertificateHistory : negated conditional → KILLED
        if ( poolCertificateHistory == null ) {
43
            return null;
44
        }
45
46
        TxPoolCertificateHistory.TxPoolCertificateHistoryBuilder<?, ?> txPoolCertificateHistory = TxPoolCertificateHistory.builder();
47
48
        txPoolCertificateHistory.txId( poolCertificateHistory.getTxId() );
49
        txPoolCertificateHistory.poolHashId( poolCertificateHistory.getPoolHashId() );
50
        txPoolCertificateHistory.txEpochNo( poolCertificateHistory.getTxEpochNo() );
51
        txPoolCertificateHistory.certEpochNo( poolCertificateHistory.getCertEpochNo() );
52
        txPoolCertificateHistory.certIndex( poolCertificateHistory.getCertIndex() );
53
        txPoolCertificateHistory.poolRetireId( poolCertificateHistory.getPoolRetireId() );
54
        txPoolCertificateHistory.poolUpdateId( poolCertificateHistory.getPoolUpdateId() );
55
        txPoolCertificateHistory.txHash( poolCertificateHistory.getTxHash() );
56
        txPoolCertificateHistory.blockTime( poolCertificateHistory.getBlockTime() );
57
        txPoolCertificateHistory.blockNo( poolCertificateHistory.getBlockNo() );
58
        txPoolCertificateHistory.epochSlotNo( poolCertificateHistory.getEpochSlotNo() );
59
        txPoolCertificateHistory.slotNo( poolCertificateHistory.getSlotNo() );
60
61 1 1. fromPoolCertificateHistory : replaced return value with null for org/cardanofoundation/explorer/api/mapper/PoolCertificateMapperImpl::fromPoolCertificateHistory → KILLED
        return txPoolCertificateHistory.build();
62
    }
63
}

Mutations

19

1.1
Location : fromPoolCertificateProjection
Killed by : org.cardanofoundation.explorer.api.service.PoolCertificateServiceTest.[engine:junit-jupiter]/[class:org.cardanofoundation.explorer.api.service.PoolCertificateServiceTest]/[method:getCurrentPoolStatus_shouldReturnPoolActive()]
negated conditional → KILLED

37

1.1
Location : fromPoolCertificateProjection
Killed by : org.cardanofoundation.explorer.api.service.PoolCertificateServiceTest.[engine:junit-jupiter]/[class:org.cardanofoundation.explorer.api.service.PoolCertificateServiceTest]/[method:getCurrentPoolStatus_shouldReturnPoolActive()]
replaced return value with null for org/cardanofoundation/explorer/api/mapper/PoolCertificateMapperImpl::fromPoolCertificateProjection → KILLED

42

1.1
Location : fromPoolCertificateHistory
Killed by : org.cardanofoundation.explorer.api.service.PoolCertificateServiceTest.[engine:junit-jupiter]/[class:org.cardanofoundation.explorer.api.service.PoolCertificateServiceTest]/[method:getTxPoolCertificateHistory_shouldReturnTxPoolCertificateHistory()]
negated conditional → KILLED

61

1.1
Location : fromPoolCertificateHistory
Killed by : org.cardanofoundation.explorer.api.service.PoolCertificateServiceTest.[engine:junit-jupiter]/[class:org.cardanofoundation.explorer.api.service.PoolCertificateServiceTest]/[method:getTxPoolCertificateHistory_shouldReturnTxPoolCertificateHistory()]
replaced return value with null for org/cardanofoundation/explorer/api/mapper/PoolCertificateMapperImpl::fromPoolCertificateHistory → KILLED

Active mutators

Tests examined


Report generated by PIT 1.14.2