Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
<HTML><HEAD><TITLE>Resource external</TITLE></TITLE><LINK REL='stylesheet' TYPE='text/css' HREF='../../doclet.css' TITLE='Style'/><META http-equiv="Content-Type" content="text/html; charset=UTF-8">
</HEAD><BODY><!--###BEGIN_CONTENT###--><div class="javadoc"><table class='menu'><colgroup><col/><col/></colgroup><tbody><tr><td class='NavBarCell1' colspan='2'><table><tbody><tr><th><a href='../../overview-summary.html'>Overview</a></th><th><a href='../../overview-index.html'>Index</a></th><th><a href='../../index.html'>Root resource</a></th></tr></tbody></table></td></tr><tr><td class='NavBarCell3'>summary: resource | <a href='#methods-summary'>method</a></td><td class='NavBarCell3'>detail: <a href='#methods-details'>method</a></td></tr></table><h2>Path: / <a href='../../index.html'>{BASE}</a> / <a href='../index.html'>import</a> / external</h2>Fetch content from an external resource and import it into the LMF system. The importer is selected based on
 the Content-Type header of the HTTP request. Calling the service spawns a separate asynchronous thread. Its
 status can be queried by calling the /status webservice.
<P>
<hr/><table class='info' id='methods-summary'><caption class='TableCaption'>Method Summary</caption><tbody><tr><th class='TableHeader'>Resource</th><th class='TableHeader'>Description</th></tr><tr><td><tt><a href='#POST'>POST /{BASE}/import/external?context=…&amp;url=…</a></tt></td><td>Fetch content from an external resource and import it into the LMF system.</td></tr></tbody></table><hr/><table class='info' id='methods-details'><caption class='TableCaption'>Method Detail</caption><tbody></tr><tr><td><a name='POST'></a><table class='examples'><tr><td><b>HTTP Example:</b><pre>POST /{BASE}/import/external?context=…&amp;url=…
Content-Type: …

</pre></td><td><b>API Example:</b><p><tt>ImportWebService.externalData({'context': <span class='comment'>/* Fetch content from an external resource and import it into the LMF system. */</span>,<br/>&nbsp;&nbsp;'url': <span class='comment'>/* url an optional URL of a remote resource to import */</span>,<br/>&nbsp;&nbsp;'Content-Type': <span class='comment'>/* type the content type of the uploaded content */</span>});</tt></p></td></tr></table><p>Fetch content from an external resource and import it into the LMF system. The importer is selected based on
 the Content-Type header of the HTTP request. Calling the service spawns a separate asynchronous thread. Its
 status can be queried by calling the /status webservice.</p><dl><dt><b>Output:</b></dt><dd><tt>javax.ws.rs.core.Response</tt> - OK if the import was successfully started</dd><dt><b>Query parameters:</b></dt><dd><b>context</b></dd><dd><b>url</b> - an optional URL of a remote resource to import</dd><dt><b>Header parameters:</b></dt><dd><b>Content-Type</b> - the content type of the uploaded content</dd>
<DT><B>HTTP return codes:</B></DT><DD><B>200</B> - if the import was successfully started</DD>
<DD><B>400</B> - if the URL argument is not valid</DD>
<DD><B>412</B> - if the content-type header is not present or contains unsupported mime types</DD>
<DD><B>502</B> - if a connection to the URL of the external source cannot be established</DD>

</dl></td></tr></tbody></table><hr/><table class='menu'><colgroup><col/><col/></colgroup><tbody><tr><td class='NavBarCell1' colspan='2'><table><tbody><tr><th><a href='../../overview-summary.html'>Overview</a></th><th><a href='../../overview-index.html'>Index</a></th><th><a href='../../index.html'>Root resource</a></th></tr></tbody></table></td></tr><tr><td class='NavBarCell3'>summary: resource | <a href='#methods-summary'>method</a></td><td class='NavBarCell3'>detail: <a href='#methods-details'>method</a></td></tr></table></div><!--###END_CONTENT###--><hr/><div class='footer'>Generated by <a href='http://www.lunatech-labs.com/open-source/jax-doclets'>Lunatech Labs jax-doclets</a> v0.10.0</div></BODY></HTML>
New to GrepCode? Check out our FAQ X