Refine search
final String root = application.getResources().get(0).getBase(); final UriBuilder extendedPath = root != null ? UriBuilder.fromPath(root).path("/application.wadl/") : UriBuilder.fromPath("./application.wadl/"); if (application.getGrammars() != null) { LOGGER.info(LocalizationMessages.ERROR_WADL_GRAMMAR_ALREADY_CONTAINS()); grammars = application.getGrammars(); } else { grammars = new Grammars(); final Doc doc = new Doc(); doc.setLang("en"); doc.setTitle("Generated"); include.getDoc().add(doc);
private void addDoc(final List<Doc> docs, final String text) { if (!isEmpty(text)) { final Doc doc = new Doc(); doc.getContent().add(text); docs.add(doc); } }
private void addVersion(Application wadlApplication) { // Include Jersey version as doc element with generatedBy attribute Doc d = new Doc(); d.getOtherAttributes().put(new QName(WadlApplicationContextImpl.WADL_JERSEY_NAMESPACE, "generatedBy", "jersey"), Version.getBuildId()); wadlApplication.getDoc().add(d); }
/** * Create an instance of {@link Doc } * */ public Doc createDoc() { return new Doc(); }
/** * Create an instance of {@link Doc } * */ public Doc createDoc() { return new Doc(); }
final String root = application.getResources().get(0).getBase(); final UriBuilder extendedPath = root != null ? UriBuilder.fromPath(root).path("/application.wadl/") : UriBuilder.fromPath("./application.wadl/"); if (application.getGrammars() != null) { LOGGER.info(LocalizationMessages.ERROR_WADL_GRAMMAR_ALREADY_CONTAINS()); grammars = application.getGrammars(); } else { grammars = new Grammars(); final Doc doc = new Doc(); doc.setLang("en"); doc.setTitle("Generated"); include.getDoc().add(doc);
private void addDoc(final List<Doc> docs, final String text) { if (!isEmpty(text)) { final Doc doc = new Doc(); doc.getContent().add(text); docs.add(doc); } }
private void addVersion(Application wadlApplication) { // Include Jersey version as doc element with generatedBy attribute Doc d = new Doc(); d.getOtherAttributes().put(new QName(WadlApplicationContextImpl.WADL_JERSEY_NAMESPACE, "generatedBy", "jersey"), Version.getBuildId()); wadlApplication.getDoc().add(d); }
/** * Create an instance of {@link Doc } * */ public Doc createDoc() { return new Doc(); }
String root = application.getResources().get(0).getBase(); UriBuilder extendedPath = root != null ? UriBuilder.fromPath(root).path("/application.wadl/") if (application.getGrammars() != null) { LOG.info("The wadl application already contains a grammars element," + " we're adding elements of the provided grammars file."); grammars = application.getGrammars(); } else { grammars = new Grammars(); Doc doc = new Doc(); doc.setLang("en"); doc.setTitle("Generated"); include.getDoc().add(doc);
private void addDoc( final List<Doc> docs, final String text ) { if ( !isEmpty( text ) ) { final Doc doc = new Doc(); doc.getContent().add( text ); docs.add( doc ); } }
private void addVersion(Application wadlApplication) { // Include Jersey version as doc element with generatedBy attribute Doc d = new Doc(); d.getOtherAttributes().put(new QName("http://jersey.java.net/", "generatedBy", "jersey"), BuildId.getBuildId()); wadlApplication.getDoc().add(0, d); }
/** * Create an instance of {@link Doc } * */ public Doc createDoc() { return new Doc(); }
final String root = application.getResources().get(0).getBase(); final UriBuilder extendedPath = root != null ? UriBuilder.fromPath(root).path("/application.wadl/") : UriBuilder.fromPath("./application.wadl/"); if (application.getGrammars() != null) { LOGGER.info(LocalizationMessages.ERROR_WADL_GRAMMAR_ALREADY_CONTAINS()); grammars = application.getGrammars(); } else { grammars = new Grammars(); final Doc doc = new Doc(); doc.setLang("en"); doc.setTitle("Generated"); include.getDoc().add(doc);
private void addDocForExample( final List<Doc> docs, final String example ) { if ( !isEmpty( example ) ) { final Doc doc = new Doc(); final Elements pElement = Elements.el( "p" ) .add( Elements.val( "h6", "Example" ) ) .add( Elements.el( "pre" ).add( Elements.val( "code", example ) ) ); doc.getContent().add( pElement ); docs.add( doc ); } }
private void addHint(Application wadlApplication) { // TODO: this not-null check is here only because of unit tests if (uriInfo != null) { Doc d = new Doc(); String message; if (detailedWadl) { final String uriWithoutQueryParam = UriBuilder.fromUri(uriInfo.getRequestUri()).replaceQuery("").build() .toString(); message = LocalizationMessages.WADL_DOC_EXTENDED_WADL(WadlUtils.DETAILED_WADL_QUERY_PARAM, uriWithoutQueryParam); } else { final String uriWithQueryParam = UriBuilder.fromUri(uriInfo.getRequestUri()) .queryParam(WadlUtils.DETAILED_WADL_QUERY_PARAM, "true").build().toString(); message = LocalizationMessages.WADL_DOC_SIMPLE_WADL(WadlUtils.DETAILED_WADL_QUERY_PARAM, uriWithQueryParam); } d.getOtherAttributes().put(new QName(WadlApplicationContextImpl.WADL_JERSEY_NAMESPACE, "hint", "jersey"), message); wadlApplication.getDoc().add(d); } }
/** * Create an instance of {@link Doc } * */ public Doc createDoc() { return new Doc(); }
final String root = application.getResources().get(0).getBase(); final UriBuilder extendedPath = root != null ? UriBuilder.fromPath(root).path("/application.wadl/") : UriBuilder.fromPath("./application.wadl/"); if (application.getGrammars() != null) { LOGGER.info(LocalizationMessages.ERROR_WADL_GRAMMAR_ALREADY_CONTAINS()); grammars = application.getGrammars(); } else { grammars = new Grammars(); final Doc doc = new Doc(); doc.setLang("en"); doc.setTitle("Generated"); include.getDoc().add(doc);
private void addDocForExample(final List<Doc> docs, final String example) { if (!isEmpty(example)) { final Doc doc = new Doc(); final Elements pElement = Elements.el("p") .add(Elements.val("h6", "Example")) .add(Elements.el("pre").add(Elements.val("code", example))); doc.getContent().add(pElement); docs.add(doc); } }
private void addHint(Application wadlApplication) { // TODO: this not-null check is here only because of unit tests if (uriInfo != null) { Doc d = new Doc(); String message; if (detailedWadl) { final String uriWithoutQueryParam = UriBuilder.fromUri(uriInfo.getRequestUri()).replaceQuery("").build() .toString(); message = LocalizationMessages.WADL_DOC_EXTENDED_WADL(WadlUtils.DETAILED_WADL_QUERY_PARAM, uriWithoutQueryParam); } else { final String uriWithQueryParam = UriBuilder.fromUri(uriInfo.getRequestUri()) .queryParam(WadlUtils.DETAILED_WADL_QUERY_PARAM, "true").build().toString(); message = LocalizationMessages.WADL_DOC_SIMPLE_WADL(WadlUtils.DETAILED_WADL_QUERY_PARAM, uriWithQueryParam); } d.getOtherAttributes().put(new QName(WadlApplicationContextImpl.WADL_JERSEY_NAMESPACE, "hint", "jersey"), message); wadlApplication.getDoc().add(d); } }