Commit f81b3eed authored by George Tziavas's avatar George Tziavas
Browse files

created needed mappers to convert MeasurementCollectionJob to MeasurementCollectionJobMVO

parent f7a4be20
Loading
Loading
Loading
Loading
Loading
+32 −0
Original line number Diff line number Diff line
package org.etsi.osl.metrico.mapper;

import org.etsi.osl.tmf.common.model.AttachmentRef;
import org.etsi.osl.tmf.pm628.model.AttachmentRefMVO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

@Mapper
public interface AttachmentRefMapper {
    AttachmentRefMapper INSTANCE = Mappers.getMapper(AttachmentRefMapper.class);

    @Mapping(source = "id", target = "id")
    @Mapping(source = "description", target = "description")
    @Mapping(source = "url", target = "url")
    @Mapping(source = "referredType", target = "referredType")
    @Mapping(source = "type", target = "type")
    @Mapping(source = "baseType", target = "baseType")
    @Mapping(source = "schemaLocation", target = "schemaLocation")
    @Mapping(source = "href", target = "href")
    AttachmentRef toAttachmentRef(AttachmentRefMVO attachmentRefMVO);

    @Mapping(source = "id", target = "id")
    @Mapping(source = "description", target = "description")
    @Mapping(source = "url", target = "url")
    @Mapping(source = "referredType", target = "referredType")
    @Mapping(source = "type", target = "type")
    @Mapping(source = "baseType", target = "baseType")
    @Mapping(source = "schemaLocation", target = "schemaLocation")
    @Mapping(source = "href", target = "href")
    AttachmentRefMVO toAttachmentRefMVO(AttachmentRef attachmentRef);
}
 No newline at end of file
+30 −0
Original line number Diff line number Diff line
package org.etsi.osl.metrico.mapper;

import org.etsi.osl.tmf.pm628.model.Characteristic;
import org.etsi.osl.tmf.pm628.model.CharacteristicMVO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

@Mapper(uses = {CharacteristicRelationshipMapper.class})
public interface CharacteristicMapper {
    CharacteristicMapper INSTANCE = Mappers.getMapper(CharacteristicMapper.class);

    @Mapping(source = "type", target = "type")
    @Mapping(source = "baseType", target = "baseType")
    @Mapping(source = "schemaLocation", target = "schemaLocation")
    @Mapping(source = "uuid", target = "uuid")
    @Mapping(source = "name", target = "name")
    @Mapping(source = "valueType", target = "valueType")
    @Mapping(source = "characteristicRelationship", target = "characteristicRelationship")
    Characteristic toCharacteristic(CharacteristicMVO characteristicMVO);

    @Mapping(source = "type", target = "type")
    @Mapping(source = "baseType", target = "baseType")
    @Mapping(source = "schemaLocation", target = "schemaLocation")
    @Mapping(source = "uuid", target = "uuid")
    @Mapping(source = "name", target = "name")
    @Mapping(source = "valueType", target = "valueType")
    @Mapping(source = "characteristicRelationship", target = "characteristicRelationship")
    CharacteristicMVO toCharacteristicMVO(Characteristic characteristic);
}
 No newline at end of file
+26 −0
Original line number Diff line number Diff line
package org.etsi.osl.metrico.mapper;

import org.etsi.osl.tmf.pm628.model.CharacteristicRelationship;
import org.etsi.osl.tmf.pm628.model.CharacteristicRelationshipMVO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

@Mapper
public interface CharacteristicRelationshipMapper {
    CharacteristicRelationshipMapper INSTANCE = Mappers.getMapper(CharacteristicRelationshipMapper.class);

    @Mapping(source = "type", target = "type")
    @Mapping(source = "baseType", target = "baseType")
    @Mapping(source = "schemaLocation", target = "schemaLocation")
    @Mapping(source = "uuid", target = "uuid")
    @Mapping(source = "relationshipType", target = "relationshipType")
    CharacteristicRelationship toCharacteristicRelationship(CharacteristicRelationshipMVO characteristicRelationshipMVO);

    @Mapping(source = "type", target = "type")
    @Mapping(source = "baseType", target = "baseType")
    @Mapping(source = "schemaLocation", target = "schemaLocation")
    @Mapping(source = "uuid", target = "uuid")
    @Mapping(source = "relationshipType", target = "relationshipType")
    CharacteristicRelationshipMVO toCharacteristicRelationshipMVO(CharacteristicRelationship characteristicRelationship);
}
 No newline at end of file
+23 −0
Original line number Diff line number Diff line
package org.etsi.osl.metrico.mapper;

import org.etsi.osl.tmf.pm628.model.DataFilterMapItem;
import org.etsi.osl.tmf.pm628.model.DataFilterMapItemMVO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

@Mapper(uses = {
        DataFilterTemplateMapper.class,
        DataFilterAttributeStringArrayMapper.class
})
public interface DataFilterMapItemMapper {
    DataFilterMapItemMapper INSTANCE = Mappers.getMapper(DataFilterMapItemMapper.class);

    @Mapping(source = "filterTemplate", target = "filterTemplate")
    @Mapping(source = "stringArray", target = "stringArray")
    DataFilterMapItem toDataFilterMapItem(DataFilterMapItemMVO dataFilterMapItemMVO);

    @Mapping(source = "filterTemplate", target = "filterTemplate")
    @Mapping(source = "stringArray", target = "stringArray")
    DataFilterMapItemMVO toDataFilterMapItemMVO(DataFilterMapItem dataFilterMapItem);
}
 No newline at end of file
+26 −0
Original line number Diff line number Diff line
package org.etsi.osl.metrico.mapper;

import org.etsi.osl.tmf.pm628.model.DataFilterMap;
import org.etsi.osl.tmf.pm628.model.DataFilterMapMVO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

@Mapper(uses = {
        DataFilterMapItemMapper.class
})
public interface DataFilterMapMapper {
    DataFilterMapMapper INSTANCE = Mappers.getMapper(DataFilterMapMapper.class);

    @Mapping(source = "type", target = "type")
    @Mapping(source = "baseType", target = "baseType")
    @Mapping(source = "schemaLocation", target = "schemaLocation")
    @Mapping(source = "mappings", target = "mappings")
    DataFilterMap toDataFilterMap(DataFilterMapMVO dataFilterMapMVO);

    @Mapping(source = "type", target = "type")
    @Mapping(source = "baseType", target = "baseType")
    @Mapping(source = "schemaLocation", target = "schemaLocation")
    @Mapping(source = "mappings", target = "mappings")
    DataFilterMapMVO toDataFilterMapMVO(DataFilterMap dataFilterMap);
}
 No newline at end of file
Loading