Moved buildDescriptionParagraph method ino MarkupDocumentBuilder so that it can be reused by all other builders.

This commit is contained in:
Robert Winkler
2016-03-10 15:39:07 +01:00
parent 2d74e441dc
commit eb86d6f1d0

View File

@@ -41,6 +41,7 @@ import java.util.*;
import static io.github.robwin.swagger2markup.internal.utils.MapUtils.toKeySet;
import static org.apache.commons.lang3.StringUtils.defaultString;
import static org.apache.commons.lang3.StringUtils.isNotBlank;
/**
* @author Robert Winkler
@@ -153,6 +154,12 @@ public abstract class MarkupDocumentBuilder {
return localDefinitions;
}
protected void buildDescriptionParagraph(String description) {
if(isNotBlank(description)){
this.markupDocBuilder.paragraph(description);
}
}
/**
* A functor to return descriptions for a given property
*/