{"id":95407,"date":"2013-11-01T07:20:00","date_gmt":"2013-10-31T23:20:00","guid":{"rendered":"http:\/\/itteacheritfreelance.hk\/test\/wordpress\/?guid=6a7ddce2bee6fc4cf215331a33b532cf"},"modified":"2013-11-01T07:20:00","modified_gmt":"2013-10-31T23:20:00","slug":"java-tip-consuming-sharepoint-web-services-with-a-java-client-2","status":"publish","type":"post","link":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/2013\/11\/01\/java-tip-consuming-sharepoint-web-services-with-a-java-client-2\/","title":{"rendered":"Java Tip: Consuming SharePoint web services with a Java client"},"content":{"rendered":"<article>\n<section class=\"page\">\n<p>\nI used to think that a <em>Camel<\/em> was something to smoke or ride in the desert, but that was before I opened my mouth at work one day and said, &#8220;Sure I can automatically save these documents up to SharePoint.&#8221; <a href=\"http:\/\/msdn.microsoft.com\/en-US\/sharepoint\" >SharePoint<\/a> has been around for a long time, so I assumed that there must be a Java API or possibly some exposed web services that I could consume. Well, as it turns out I did get the job done, and as with many things it ended better than it started. But there were quite a few hurdles along the way, which I&#8217;d like to help other JavaWorld readers avoid.<\/p>\n<p>\nIn this <a href=\"http:\/\/www.javaworld.com\/columns\/jw-tips-index.html\" >Java tip<\/a> I&#8217;ll show you how to perform basic CRUD operations on a SharePoint document folder from a Java client. The demonstration will focus on some of the more popular methods that any SharePoint web service consumer is likely to invoke, which are found in Microsoft&#8217;s <a href=\"http:\/\/msdn.microsoft.com\/en-us\/library\/copy(v=office.12).aspx\" >Copy<\/a> and <a href=\"http:\/\/msdn.microsoft.com\/en-us\/library\/lists(v=office.12).aspx\" >Lists<\/a> services. For the CRUD operations we&#8217;ll use <a href=\"http:\/\/msdn.microsoft.com\/en-us\/library\/ms426449.aspx\" >CAML<\/a> (Collaborative Application Markup Language), an XML-based language utilized in many of the methods exposed by <code>Copy<\/code> and <code>Lists<\/code>. You&#8217;ll learn how to construct valid CAML structures that are passed as method parameters or assigned to object properties, which are in turn passed as parameters to these services.<\/p>\n<p class=\"jumpTag\"><a href=\"https:\/\/www.javaworld.com\/article\/2078906\/java-tip-consuming-sharepoint-web-services-with-a-java-client.html#jump\">To read this article in full, please click here<\/a><\/p>\n<\/section>\n<\/article>\n","protected":false},"excerpt":{"rendered":"<p>I used to think that a Camel was something to smoke or ride in the desert, but that was before I opened my mouth at work one day and said, &#8220;Sure I can automatically save these documents up to SharePoint.&#8221; SharePoint has been around for a long time,&#8230; <a href=\"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/2013\/11\/01\/java-tip-consuming-sharepoint-web-services-with-a-java-client-2\/\">\u95b1\u8b80\u5168\u6587 <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":120,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"slim_seo":[],"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false}}},"categories":[2,315,7,240],"tags":[398,402,397,414,413,410,409,407,408,406,399,400,394,375,558,556,557,560,559,555,561,566,553,554,565,563,564,562,183,567,568,10,401,396,403,412,411,395,405,404],"jetpack_publicize_connections":[],"aioseo_notices":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p7prtj-oOP","jetpack-related-posts":[],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/wp-json\/wp\/v2\/posts\/95407"}],"collection":[{"href":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/wp-json\/wp\/v2\/users\/120"}],"replies":[{"embeddable":true,"href":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/wp-json\/wp\/v2\/comments?post=95407"}],"version-history":[{"count":1,"href":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/wp-json\/wp\/v2\/posts\/95407\/revisions"}],"predecessor-version":[{"id":95410,"href":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/wp-json\/wp\/v2\/posts\/95407\/revisions\/95410"}],"wp:attachment":[{"href":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/wp-json\/wp\/v2\/media?parent=95407"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/wp-json\/wp\/v2\/categories?post=95407"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/itteacheritfreelance.hk\/test\/wordpress\/wp-json\/wp\/v2\/tags?post=95407"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}