Search in sources :

Example 1 with ScanMappingToScanMappingConfigurationTransformer

use of com.mercedesbenz.sechub.domain.scan.config.ScanMappingToScanMappingConfigurationTransformer in project sechub by mercedes-benz.

the class ScanMappingConfigurationTestJSONasNamePatternDialogAction method createScanConfig.

private ScanMappingConfiguration createScanConfig(String json, MappingIdentifier identifier) {
    MappingData mappingData = MappingData.fromString(json);
    ScanMapping mapping = new ScanMapping(identifier.getId());
    mapping.setData(mappingData.toJSON());
    ScanMappingConfiguration config = new ScanMappingToScanMappingConfigurationTransformer().transform(Collections.singletonList(mapping));
    return config;
}
Also used : ScanMapping(com.mercedesbenz.sechub.domain.scan.config.ScanMapping) MappingData(com.mercedesbenz.sechub.sharedkernel.mapping.MappingData) ScanMappingConfiguration(com.mercedesbenz.sechub.domain.scan.config.ScanMappingConfiguration) ScanMappingToScanMappingConfigurationTransformer(com.mercedesbenz.sechub.domain.scan.config.ScanMappingToScanMappingConfigurationTransformer)

Aggregations

ScanMapping (com.mercedesbenz.sechub.domain.scan.config.ScanMapping)1 ScanMappingConfiguration (com.mercedesbenz.sechub.domain.scan.config.ScanMappingConfiguration)1 ScanMappingToScanMappingConfigurationTransformer (com.mercedesbenz.sechub.domain.scan.config.ScanMappingToScanMappingConfigurationTransformer)1 MappingData (com.mercedesbenz.sechub.sharedkernel.mapping.MappingData)1