// --------------------------------------------------------------------------------
// Create and store the object in the repository
// --------------------------------------------------------------------------------
Discriminator discriminatorObject = new Discriminator();
discriminatorObject.setPath("/test");
discriminatorObject.setContent("This is my content");
ocm.insert(discriminatorObject);
ocm.save();
// --------------------------------------------------------------------------------
// Get the object
// --------------------------------------------------------------------------------
discriminatorObject = (Discriminator) ocm.getObject( "/test");
assertNotNull("discriminator object is null", discriminatorObject );
assertTrue("Incorrect content", discriminatorObject.getContent().equals("This is my content"));
// --------------------------------------------------------------------------------
// Update the object
// --------------------------------------------------------------------------------
discriminatorObject.setContent("new content");
ocm.update(discriminatorObject);
ocm.save();
// --------------------------------------------------------------------------------
// Get the object
// --------------------------------------------------------------------------------
discriminatorObject = (Discriminator) ocm.getObject( "/test");
assertNotNull("discriminator object is null", discriminatorObject );
assertTrue("Incorrect content", discriminatorObject.getContent().equals("new content"));
}
catch (Exception e)