+ /**
+ * Converts all the params in the svc logic context into a valid param by
+ * replacing the underscore in module name to colon at necessary places.
+ *
+ * @param paramMap list of invalid parameters
+ * @return list of partially valid parameters
+ */
+ private Map<String, String> convertToValidParam(Map<String, String> paramMap) {
+ Map<String, String> fixedParams = new HashMap<>();
+ for(Map.Entry<String, String> entry : paramMap.entrySet()) {
+ String key = entry.getKey().replaceAll(DOT_REGEX, SLASH);
+ try {
+ SchemaPathHolder fixedUrl = getProcessedPath(key, schemaCtx());
+ String fixedUri = fixedUrl.getUri().replaceAll(
+ SLASH, DOT_REGEX);
+ fixedParams.put(fixedUri, entry.getValue());
+ } catch (IllegalArgumentException | RestconfDocumentedException
+ | NullPointerException e) {
+ fixedParams.put(entry.getKey(), entry.getValue());
+ }
+ }
+ return fixedParams;
+ }
+