Dear community,
I was searchingto find the difference and why use/extend those two classes, but not a clear answer. I hopeyou can expalin me better
Dear community,
I was searchingto find the difference and why use/extend those two classes, but not a clear answer. I hopeyou can expalin me better
Hi andorian,
A document type defines the data structure and the editing template of a class of documents. A document type can contain both primitive and compound type fields.
A compound type defines the data structure and the editing template of a reusable block of document fields. A compound type can contain both primitive and compound type fields. An instance of a compound type can only exist within a document instance.
Either can be selected while creating document types in the Document Type editor
Thank for your answer.
So means if i want to created a custom document type and in this document type has a:
I must extends HippoCompound
If the custom document type has not any of the above I just extends BaseDocument, is that correct?
Thans in advance
Hi,
It’s not a matter of whether the document type contains such fields, it’s a matter of whether you are designing your data structure in reusable field groups, a.k.a. compounds.
Your example seems to not have that, so use BaseDocument for your custom document type.
Jeroen