Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Quoting the <a href="http://code.google.com/appengine/docs/java/datastore/usingjpa.html#Class_and_Field_Annotations" rel="nofollow noreferrer">Class and Field Annotations</a> section from <a href="http://code.google.com/appengine/docs/java/datastore/usingjpa.html" rel="nofollow noreferrer">Using JPA with App Engine</a>:</p> <blockquote> <p>Fields of the data class that are to be stored in the datastore must either be of a type that is persisted by default or expliclty declared as persistent. You can find a chart detailing JPA default persistence behavior on <a href="http://www.datanucleus.org/products/accessplatform_1_1/jpa/types.html" rel="nofollow noreferrer">the DataNucleus website</a>. To explicitly declare a field as persistent, you give it an <code>@Basic</code> annotation:</p> <pre><code>import java.util.Date; import javax.persistence.Enumerated; import com.google.appengine.api.datastore.ShortBlob; // ... @Basic private ShortBlob data; </code></pre> <p>The type of a field can be any of the following:</p> <ul> <li>one of the <a href="http://code.google.com/appengine/docs/java/datastore/dataclasses.html#Core_Value_Types" rel="nofollow noreferrer">core types</a> supported by the datastore</li> <li>a Collection (such as a <code>java.util.List&lt;...&gt;</code>) of values of a core datastore type</li> <li>an instance or Collection of instances of a <code>@Entity</code> class</li> <li>an embedded class, stored as properties on the entity</li> </ul> </blockquote> <p>To define and use <code>Email</code> and <code>PhoneNumber</code> as data types, create entities for them and map them as <a href="http://www.datanucleus.org/products/accessplatform_1_1/jpa/annotations.html#OneToOne" rel="nofollow noreferrer"><code>@OneToOne</code></a> or make them <a href="http://www.datanucleus.org/products/accessplatform_1_1/jpa/annotations.html#Embeddable" rel="nofollow noreferrer"><code>@Embeddable</code></a>.</p>
    singulars
    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. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      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