Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>From the <a href="http://code.google.com/intl/es-ES/apis/calendar/data/2.0/developers_guide_java.html#CreatingEvents" rel="nofollow">API developer's guide</a>, you can set the content of your CalendarEventEntry through the setContent method:</p> <blockquote> <p>The entry content is represented by a <a href="http://code.google.com/apis/gdata/javadoc/com/google/gdata/data/Content.html" rel="nofollow">Content</a> object, a class that can hold either plain text or other forms of content, including XML and binary data. (But the <a href="http://code.google.com/apis/gdata/javadoc/com/google/gdata/data/BaseEntry.html#setContent%28com.google.gdata.data.TextConstruct%29" rel="nofollow">setContent</a> method can also accept a <code>TextConstruct</code>).</p> </blockquote> <p>Then, using the same example listed at the guide, and using the <a href="http://code.google.com/intl/es-ES/apis/gdata/javadoc/com/google/gdata/data/OtherContent.html" rel="nofollow"><code>com.google.gdata.data.OtherContent</code></a> class of the provided API:</p> <pre><code>byte[] binaryContent=//... your binary content to attach OtherContent yourContent=new OtherContent(); yourContent.setBytes(binaryContent); //don't know if this is mandatory... yourContent.setMimeType(ContentType.ANY); CalendarEventEntry myEntry = new CalendarEventEntry(); myEntry.setTitle(new PlainTextConstruct("Read the attachment")); myEntry.setContent(yourContent); //etc... DateTime startTime = DateTime.parseDateTime("2006-04-17T15:00:00-08:00"); DateTime endTime = DateTime.parseDateTime("2006-04-17T17:00:00-08:00"); When eventTimes = new When(); eventTimes.setStartTime(startTime); eventTimes.setEndTime(endTime); myEntry.addTime(eventTimes); </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload