/** * ADVANCED: * Set the receiver's update query. * This should be an instance of a valid subclass of UpdateObjectQuery. * If specified this is used by the descriptor to update itself in the database. * If the receiver uses optimistic locking this must raise an error on optimistic lock failure. * This gives the user the ability to define exactly how to update the data into the database, * or access data external from the database or from some other framework. */ public void setUpdateQuery(UpdateObjectQuery updateQuery) { this.updateQuery = updateQuery; if (updateQuery == null) { return; } this.updateQuery.setIsUserDefined(true); this.updateQuery.setDescriptor(getDescriptor()); }
/** * ADVANCED: * Set the receiver's update query. * This should be an instance of a valid subclass of UpdateObjectQuery. * If specified this is used by the descriptor to update itself in the database. * If the receiver uses optimistic locking this must raise an error on optimistic lock failure. * This gives the user the ability to define exactly how to update the data into the database, * or access data external from the database or from some other framework. */ public void setUpdateQuery(UpdateObjectQuery updateQuery) { this.updateQuery = updateQuery; if (updateQuery == null) { return; } this.updateQuery.setIsUserDefined(true); this.updateQuery.setDescriptor(getDescriptor()); }
/** * ADVANCED: * Set the receiver's update query. * This should be an instance of a valid subclass of UpdateObjectQuery. * If specified this is used by the descriptor to update itself in the database. * If the receiver uses optimistic locking this must raise an error on optimistic lock failure. * This gives the user the ability to define exactly how to update the data into the database, * or access data external from the database or from some other framework. */ public void setUpdateQuery(UpdateObjectQuery updateQuery) { this.updateQuery = updateQuery; if (updateQuery == null) { return; } this.updateQuery.setIsUserDefined(true); this.updateQuery.setDescriptor(getDescriptor()); }
/** * INTERNAL: Generates the update stored procedure for this descriptor */ protected StoredProcedureDefinition generateUpdateStoredProcedure(ClassDescriptor descriptor) { UpdateObjectQuery updateQuery = new UpdateObjectQuery(); updateQuery.setDescriptor(descriptor); updateQuery.setModifyRow(descriptor.getObjectBuilder().buildTemplateUpdateRow(getSession())); return this.generateObjectStoredProcedure(updateQuery, descriptor.getFields(), "UPD_"); }
/** * INTERNAL: Generates the update stored procedure for this descriptor */ protected StoredProcedureDefinition generateUpdateStoredProcedure(ClassDescriptor descriptor) { UpdateObjectQuery updateQuery = new UpdateObjectQuery(); updateQuery.setDescriptor(descriptor); updateQuery.setModifyRow(descriptor.getObjectBuilder().buildTemplateUpdateRow(getSession())); return this.generateObjectStoredProcedure(updateQuery, descriptor.getFields(), "UPD_"); }
/** * INTERNAL: Generates the update stored procedure for this descriptor */ protected StoredProcedureDefinition generateUpdateStoredProcedure(ClassDescriptor descriptor) { UpdateObjectQuery updateQuery = new UpdateObjectQuery(); updateQuery.setDescriptor(descriptor); updateQuery.setModifyRow(descriptor.getObjectBuilder().buildTemplateUpdateRow(getSession())); return this.generateObjectStoredProcedure(updateQuery, descriptor.getFields(), "UPD_"); }
getUpdateQuery().setDescriptor(descriptor);
getUpdateQuery().setDescriptor(descriptor);
getUpdateQuery().setDescriptor(descriptor);