This is an automated email from the ASF dual-hosted git repository.

jamesbognar pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/juneau.git


The following commit(s) were added to refs/heads/master by this push:
     new 753b0a373 Javadocs
753b0a373 is described below

commit 753b0a3738a7cf3c24448c3a55a2999d6da9bb83
Author: JamesBognar <[email protected]>
AuthorDate: Wed Jun 15 08:20:58 2022 -0400

    Javadocs
---
 juneau-doc/docs/ReleaseNotes/5.0.0.07.html         |  2 +-
 .../05.jm.org.apache.juneau.http.entity.html       | 15 +++++++++++----
 .../06.jm.org.apache.juneau.http.resource.html     | 22 +++++++++++++++++++++-
 .../07.jm.org.apache.juneau.http.response.html     |  5 +++--
 .../03.jrs.JavaMethodReturnTypes.html              |  6 +++---
 5 files changed, 39 insertions(+), 11 deletions(-)

diff --git a/juneau-doc/docs/ReleaseNotes/5.0.0.07.html 
b/juneau-doc/docs/ReleaseNotes/5.0.0.07.html
index eb222952f..25ad5d543 100644
--- a/juneau-doc/docs/ReleaseNotes/5.0.0.07.html
+++ b/juneau-doc/docs/ReleaseNotes/5.0.0.07.html
@@ -154,7 +154,7 @@
                        </ul>
                </li>
                <li>
-                       HTTP response content POJOs can now simply be returned 
from methods instead of calling {@link oajr.RestResponse#setOutput(Object)}.    
         
+                       HTTP response content POJOs can now simply be returned 
from methods instead of calling {@del oajr.RestResponse#setOutput(Object)}.     
         
                </li>   
        </ul>
 </div>
\ No newline at end of file
diff --git 
a/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/05.jm.org.apache.juneau.http.entity.html
 
b/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/05.jm.org.apache.juneau.http.entity.html
index c675132a9..fc788e73f 100644
--- 
a/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/05.jm.org.apache.juneau.http.entity.html
+++ 
b/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/05.jm.org.apache.juneau.http.entity.html
@@ -46,10 +46,10 @@
                        <li class='jm'>{@link 
oaj.http.entity.HttpEntityBuilder#chunked() chunked()}
                        <li class='jm'>{@link 
oaj.http.entity.HttpEntityBuilder#chunked(boolean) chunked(boolean)}
                        <li class='jm'>{@link 
oaj.http.entity.HttpEntityBuilder#content(Object) content(Object)}
+                       <li class='jm'>{@link 
oaj.http.entity.HttpEntityBuilder#content(Supplier) content(Supplier)}
                        <li class='jm'>{@link 
oaj.http.entity.HttpEntityBuilder#contentEncoding(ContentEncoding) 
contentEncoding(ContentEncoding)}
                        <li class='jm'>{@link 
oaj.http.entity.HttpEntityBuilder#contentEncoding(String) 
contentEncoding(String)}
                        <li class='jm'>{@link 
oaj.http.entity.HttpEntityBuilder#contentLength(long) contentLength(long)}
-                       <li class='jm'>{@link 
oaj.http.entity.HttpEntityBuilder#contentSupplier(Supplier) 
contentSupplier(Supplier)}
                        <li class='jm'>{@link 
oaj.http.entity.HttpEntityBuilder#contentType(ContentType) 
contentType(ContentType)}
                        <li class='jm'>{@link 
oaj.http.entity.HttpEntityBuilder#contentType(String) contentType(String)}
                </ul>
@@ -57,11 +57,18 @@
        
        <h5 class='figure'>Example</h5>
        <p class='bjava'>
+       |       <jk>import static</jk> org.apache.juneau.http.HttpEntities.*;
+       |
+       |       <jk>byte</jk>[] <jv>payload</jv> = {...};
+       |
+       |       <jc>// Create via type builder.</jc>
        |       HttpEntity <jv>entity</jv> = ByteArrayEntity
        |               .<jsm>create</jsm>()
-       |               .content(MyPart.<jsm>of</jsm>(<js>"foo"</js>))
-       |               .append(<js>"Bar"</js>, 
()-&gt;<jsm>getDynamicValueFromSomewhere</jsm>())
+       |               .content(<jv>payload</jv>)
+       |               
.contentType(ContentType.<jsf>APPLICATION_OCTET_STREAM</jsf>)
        |               .build();
+       |
+       |       <jc>// Create via HttpEntities.</jc>
+       |       HttpEntity <jv>entity</jv> = 
<jsm>byteArrayEntity</jsm>(<jv>payload</jv>, 
ContentType.<jsf>APPLICATION_OCTET_STREAM</jsf>).build();
        </p>
-       
 </div>
\ No newline at end of file
diff --git 
a/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/06.jm.org.apache.juneau.http.resource.html
 
b/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/06.jm.org.apache.juneau.http.resource.html
index 47f13552f..e3d50ce35 100644
--- 
a/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/06.jm.org.apache.juneau.http.resource.html
+++ 
b/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/06.jm.org.apache.juneau.http.resource.html
@@ -49,10 +49,10 @@
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#chunked() chunked()}
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#chunked(boolean) chunked(boolean)}
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#content(Object) content(Object)}
+                       <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#content(Supplier) content(Supplier)}
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#contentEncoding(ContentEncoding) 
contentEncoding(ContentEncoding)}
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#contentEncoding(String) 
contentEncoding(String)}
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#contentLength(long) contentLength(long)}
-                       <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#contentSupplier(Supplier) 
contentSupplier(Supplier)}
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#contentType(ContentType) 
contentType(ContentType)}
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#contentType(String) contentType(String)}
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#copyFrom(HttpResponse) 
copyFrom(HttpResponse)}
@@ -64,4 +64,24 @@
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#headers(HeaderList) headers(HeaderList)}
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#headers(List) headers(List&lt;Header&gt;)}
                        <li class='jm'>{@link 
oaj.http.resource.HttpResourceBuilder#getHeaders() getHeaders()}
+               </ul>
+       </ul>
+       
+       <h5 class='figure'>Example</h5>
+       <p class='bjava'>
+       |       <jk>import static</jk> org.apache.juneau.http.HttpResources.*;
+       |
+       |       <jk>byte</jk>[] <jv>payload</jv> = {...};
+       |
+       |       <jc>// Create via type builder.</jc>
+       |       HttpResource <jv>resource</jv> = ByteArrayResource
+       |               .<jsm>create</jsm>()
+       |               .content(<jv>payload</jv>)
+       |               
.contentType(ContentType.<jsf>APPLICATION_OCTET_STREAM</jsf>)
+       |               .build();
+       |
+       |       <jc>// Create via HttpResources.</jc>
+       |       HttpResource <jv>resource</jv> = 
<jsm>byteArrayResource</jsm>(<jv>payload</jv>, 
ContentType.<jsf>APPLICATION_OCTET_STREAM</jsf>).build();
+       </p>
+       
 </div>
\ No newline at end of file
diff --git 
a/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/07.jm.org.apache.juneau.http.response.html
 
b/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/07.jm.org.apache.juneau.http.response.html
index 807b5c4e7..b337a63fb 100644
--- 
a/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/07.jm.org.apache.juneau.http.response.html
+++ 
b/juneau-doc/docs/Topics/02.juneau-marshall/24.jm.HttpParts/07.jm.org.apache.juneau.http.response.html
@@ -121,8 +121,8 @@
        <ul class='javatree'>
                <li class='jc'>{@link oaj.http.response.HttpResponseBuilder}
                <ul>
-                       <li class='jm'>{@link 
oaj.http.response.HttpResponseBuilder#body(HttpEntity) body(HttpEntity)}
-                       <li class='jm'>{@link 
oaj.http.response.HttpResponseBuilder#body(String) body(String)}
+                       <li class='jm'>{@link 
oaj.http.response.HttpResponseBuilder#content(HttpEntity) content(HttpEntity)}
+                       <li class='jm'>{@link 
oaj.http.response.HttpResponseBuilder#content(String) content(String)}
                        <li class='jm'>{@link 
oaj.http.response.HttpResponseBuilder#copyFrom(HttpResponse) 
copyFrom(HttpResponse)}
                        <li class='jm'>{@link 
oaj.http.response.HttpResponseBuilder#getHeaders() getHeaders()}
                        <li class='jm'>{@link 
oaj.http.response.HttpResponseBuilder#getStatusLine() getStatusLine()}
@@ -142,4 +142,5 @@
                        <li class='jm'>{@link 
oaj.http.response.HttpResponseBuilder#unmodifiable() unmodifiable()}
                </ul>
        </ul>
+       
 </div>
\ No newline at end of file
diff --git 
a/juneau-doc/docs/Topics/06.juneau-rest-server/03.jrs.RestOpAnnotatedMethods/03.jrs.JavaMethodReturnTypes.html
 
b/juneau-doc/docs/Topics/06.juneau-rest-server/03.jrs.RestOpAnnotatedMethods/03.jrs.JavaMethodReturnTypes.html
index d1971b9b3..cc1cb4b51 100644
--- 
a/juneau-doc/docs/Topics/06.juneau-rest-server/03.jrs.RestOpAnnotatedMethods/03.jrs.JavaMethodReturnTypes.html
+++ 
b/juneau-doc/docs/Topics/06.juneau-rest-server/03.jrs.RestOpAnnotatedMethods/03.jrs.JavaMethodReturnTypes.html
@@ -19,7 +19,7 @@
        <p>
                The return type of the Java method can be any serializable POJO 
as defined in {@doc jm.PojoCategories POJO Categories}.
                It can also be <jk>void</jk> if the method is not sending any 
output (e.g. a request redirect) or is 
-               setting the output using the {@link 
oajr.RestResponse#setOutput(Object)} method.
+               setting the output using the {@link 
oajr.RestResponse#setContent(Object)} method.
        </p>
        <h5 class='figure'>Example:</h5>
        <p class='bjava'>
@@ -127,7 +127,7 @@
        </p>
        <ul class='spaced-list'>
                <li>
-                       By calling {@link oajr.RestResponse#setOutput(Object)} 
with any of the types above.
+                       By calling {@link oajr.RestResponse#setContent(Object)} 
with any of the types above.
                <li>
                        By accessing the {@link java.io.Writer} directly by 
calling 
                        {@link oajr.RestResponse#getNegotiatedWriter()} and 
writing the output yourself.
@@ -145,7 +145,7 @@
                |       <ja>@RestGet</ja>(<js>"/example2/{personId}"</js>)
                |       <jk>public void</jk> doGet2(RestResponse <jv>res</jv>, 
<ja>@Path</ja>(<js>"personId"</js>) UUID <jv>personId</jv>) {
                |               Person <jv>person</jv> = 
<jsm>getPersonById</jsm>(<jv>personId</jv>);
-               |               <jv>res</jv>.setOutput(<jv>person</jv>);
+               |               <jv>res</jv>.setContent(<jv>person</jv>);
                |       }
        </p>
        <p>

Reply via email to