/**
 * Copyright (c) 2020-present, Goldman Sachs
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
import { createModelSchema, list, custom } from 'serializr';
import { V1_deserializeEmbeddedDataType, V1_serializeEmbeddedDataType, } from '../../transformation/pureProtocol/serializationHelpers/V1_DataElementSerializationHelper.js';
import { TestDataGenerationResult } from '../../../../../../graph/metamodel/pure/packageableElements/service/TestGenerationResult.js';
import { V1_buildEmbeddedData } from '../../transformation/pureGraph/to/helpers/V1_DataElementBuilderHelper.js';
export class V1_TestDataGenerationResult {
    data = [];
}
export const V1_testDataGenerationResultModelSchema = (plugins) => createModelSchema(V1_TestDataGenerationResult, {
    data: list(custom((val) => V1_serializeEmbeddedDataType(val, plugins), (val) => V1_deserializeEmbeddedDataType(val, plugins))),
});
export const V1_buildTestDataGenerationResult = (protocol, context) => new TestDataGenerationResult(protocol.data.map((p) => V1_buildEmbeddedData(p, context)));
//# sourceMappingURL=V1_TestDataGenerationResult.js.map