2011-03-01 71 views
0

我想知道在Java中使用google-docs api上传和OCR文档是否是可行的。我知道我可以在某种程度上通过使这样的HTTP POST执行此:Google API Java OCR

 
POST /feeds/default/private/full?ocr=true HTTP/1.1 
Host: docs.google.com 
GData-Version: 3.0 
Authorization: 
Content-Length: 1984 
Content-Type: image/png 
Slug: OCRd Doc 

... png contents here ...

但有可能实现这一目标使用DocsService?

+0

好了,这是真正的轻松。对于那些有兴趣: 你只需要添加'myService.insert(新URL( \t \t \t \t “http://docs.google.com/feeds/default/private/full?ocr=true”), \t \t \t \t newDocument);' – 2011-03-01 21:33:39

回答

1

你只需要添加:

myService.insert(new URL("http://docs.google.com/feeds/default/private/full?ocr=true"), newDocument);