com.networknt.oas.validator.Messages Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of openapi-parser Show documentation
Show all versions of openapi-parser Show documentation
A light-weight, fast OpenAPI 3.0 parser and validator
/*******************************************************************************
* Copyright (c) 2017 ModelSolv, Inc. and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* ModelSolv, Inc. - initial API and implementation and/or initial documentation
*******************************************************************************/
package com.networknt.oas.validator;
import java.util.Arrays;
public class Messages {
public static Messages m = new Messages();
public String msg(String text, Object... args) {
int pos = text.indexOf('|');
if (pos >= 0) {
String nls = nls(text.substring(0, pos));
text = nls != null ? nls : text.substring(pos + 1);
}
return String.format("%s %s", text, Arrays.asList(args));
}
public String nls(String text) {
return null;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy