
trgr.anyPropertyContent() as element(trgr.anyPropertyContent)
Returns the XML representation of an all-properties part to a triggering
event, usable as the content parameter of a trigger event constructor such as
trgr.triggerDataEvent
.
Adding, changing or removing any document property matches this event part.
const trgr = require('/MarkLogic/triggers');
trgr.triggerDataEvent(
trgr.directoryScope('/myDir/', '1'),
trgr.anyPropertyContent(),
trgr.postCommit());
// A property modification trigger event that can
// be used to create a trigger which fires whenever any
// property is added, changed or removed on a document
// in the /myDir/ directory.
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.