/** * INTERNAL: * Write the aggregate values into the parent row for shallow insert. */ protected void writeToRowFromAggregateForShallowInsert(AbstractRecord record, Object object, Object attributeValue, AbstractSession session) throws DescriptorException { if (attributeValue == null) { if (this.isNullAllowed) { writeNullReferenceRow(record); } else { throw DescriptorException.nullForNonNullAggregate(object, this); } } else { if (!session.isClassReadOnly(attributeValue.getClass())) { getObjectBuilder(attributeValue, session).buildRowForShallowInsert(record, attributeValue, session); } } }
/** * INTERNAL: * Write the aggregate values into the parent row. */ protected void writeToRowFromAggregate(AbstractRecord record, Object object, Object attributeValue, AbstractSession session) throws DescriptorException { if (attributeValue == null) { if (this.isNullAllowed) { writeNullReferenceRow(record); } else { throw DescriptorException.nullForNonNullAggregate(object, this); } } else { if (!session.isClassReadOnly(attributeValue.getClass())) { getObjectBuilder(attributeValue, session).buildRow(record, attributeValue, session); } } }
/** * INTERNAL: * Write the aggregate values into the parent row. */ protected void writeToRowFromAggregate(AbstractRecord record, Object object, Object attributeValue, AbstractSession session, WriteType writeType) throws DescriptorException { if (attributeValue == null) { if (this.isNullAllowed) { writeNullReferenceRow(record); } else { throw DescriptorException.nullForNonNullAggregate(object, this); } } else { if (!session.isClassReadOnly(attributeValue.getClass())) { getObjectBuilder(attributeValue, session).buildRow(record, attributeValue, session, writeType); } } }
/** * INTERNAL: * Write the aggregate values into the parent row for shallow insert. */ protected void writeToRowFromAggregateForShallowInsert(AbstractRecord record, Object object, Object attributeValue, AbstractSession session) throws DescriptorException { if (attributeValue == null) { if (this.isNullAllowed) { writeNullReferenceRow(record); } else { throw DescriptorException.nullForNonNullAggregate(object, this); } } else { if (!session.isClassReadOnly(attributeValue.getClass())) { getObjectBuilder(attributeValue, session).buildRowForShallowInsert(record, attributeValue, session); } } }
/** * INTERNAL: * Write the aggregate values into the parent row. */ protected void writeToRowFromAggregate(AbstractRecord record, Object object, Object attributeValue, AbstractSession session, WriteType writeType) throws DescriptorException { if (attributeValue == null) { if (this.isNullAllowed) { writeNullReferenceRow(record); } else { throw DescriptorException.nullForNonNullAggregate(object, this); } } else { if (!session.isClassReadOnly(attributeValue.getClass())) { getObjectBuilder(attributeValue, session).buildRow(record, attributeValue, session, writeType); } } }
/** * INTERNAL: * Build and return a database row built with the values from * the specified attribute value. */ protected void writeToRowFromAggregateWithChangeRecord(AbstractRecord record, ChangeRecord changeRecord, ObjectChangeSet objectChangeSet, AbstractSession session) throws DescriptorException { if (objectChangeSet == null) { if (this.isNullAllowed) { writeNullReferenceRow(record); } else { Object object = ((ObjectChangeSet)changeRecord.getOwner()).getUnitOfWorkClone(); throw DescriptorException.nullForNonNullAggregate(object, this); } } else { if (!session.isClassReadOnly(objectChangeSet.getClassType(session))) { getReferenceDescriptor(objectChangeSet.getClassType(session), session).getObjectBuilder().buildRowWithChangeSet(record, objectChangeSet, session); } } }
/** * INTERNAL: * Build and return a database row built with the values from * the specified attribute value. */ protected void writeToRowFromAggregateWithChangeRecord(AbstractRecord record, ChangeRecord changeRecord, ObjectChangeSet objectChangeSet, AbstractSession session, WriteType writeType) throws DescriptorException { if (objectChangeSet == null) { if (this.isNullAllowed) { writeNullReferenceRow(record); } else { Object object = ((ObjectChangeSet)changeRecord.getOwner()).getUnitOfWorkClone(); throw DescriptorException.nullForNonNullAggregate(object, this); } } else { if (!session.isClassReadOnly(objectChangeSet.getClassType(session))) { getReferenceDescriptor(objectChangeSet.getClassType(session), session).getObjectBuilder().buildRowWithChangeSet(record, objectChangeSet, session, writeType); } } }
/** * INTERNAL: * Build and return a database row built with the values from * the specified attribute value. */ protected void writeToRowFromAggregateWithChangeRecord(AbstractRecord record, ChangeRecord changeRecord, ObjectChangeSet objectChangeSet, AbstractSession session, WriteType writeType) throws DescriptorException { if (objectChangeSet == null) { if (this.isNullAllowed) { writeNullReferenceRow(record); } else { Object object = ((ObjectChangeSet)changeRecord.getOwner()).getUnitOfWorkClone(); throw DescriptorException.nullForNonNullAggregate(object, this); } } else { if (!session.isClassReadOnly(objectChangeSet.getClassType(session))) { getReferenceDescriptor(objectChangeSet.getClassType(session), session).getObjectBuilder().buildRowWithChangeSet(record, objectChangeSet, session, writeType); } } }