String canonicalizationAlgMethod = apiSignedInfo.getCanonicalizationMethod().getAlgorithm();
CanonicalizationMethod modelCanonMethod = new CanonicalizationMethod();
modelSignedInfo.setCanonicalizationMethod(modelCanonMethod);
modelCanonMethod.setAlgorithm(canonicalizationAlgMethod);
SignatureMethod modelSigMethod = new SignatureMethod();
modelSignedInfo.setSignatureMethod(modelSigMethod);
String sigMethod = apiSignedInfo.getSignatureMethod().getAlgorithm();
modelSigMethod.setAlgorithm(sigMethod);
List<org.w3._2000._09.xmldsig_.ReferenceType> apiReferenceList = apiSignedInfo.getReference();
for (org.w3._2000._09.xmldsig_.ReferenceType apiReference : apiReferenceList) {
Reference ref = mapReference(modelSignedInfo, apiReference);
modelSignedInfo.getReference().add(ref);