Package er.cayenne.example.persistent

Examples of er.cayenne.example.persistent.Gallery


    picasso = objContext.newObject(Artist.class);
    picasso.setName("Pablo Picasso");
    picasso.setDateOfBirthString("18811025");

    // Creating other objects
    Gallery metropolitan = objContext.newObject(Gallery.class);
    metropolitan.setName("Metropolitan Museum of Art");

    Painting girl = objContext.newObject(Painting.class);
    girl.setName("Girl Reading at a Table");

    Painting stein = objContext.newObject(Painting.class);
View Full Code Here


    public void setGallery(Gallery gallery) {
        setToOneTarget("gallery", gallery, true);
    }
    public Gallery createGalleryRelationship() {
        Gallery obj = getObjectContext().newObject(Gallery.class);
        setToOneTarget("gallery", obj, true);
        return obj;
    }
View Full Code Here

    public static final String ID_PK_COLUMN = "ID";

  public static Gallery createGallery(ObjectContext ec
    , String name
  ) {
    Gallery result = new Gallery();
    ec.registerNewObject(result);
    result.setName(name);
    return result;
  }
View Full Code Here

   }
  
  
  public static Gallery fetchOne(ObjectContext oc, Expression expression) {
    java.util.List<Gallery> objects = fetch(oc, expression);
    Gallery obj;
    int count = objects.size();
    if (count == 0) {
      obj = null;
    } else if (count == 1) {
      obj = objects.get(0);
View Full Code Here

TOP

Related Classes of er.cayenne.example.persistent.Gallery

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.