use of com.enonic.xp.content.ContentInheritType in project xp by enonic.
the class ResetInheritanceHandler method doExecute.
@Override
protected Object doExecute() {
validate();
Content content;
if (this.key.startsWith("/")) {
content = contentService.getByPath(ContentPath.from(this.key));
} else {
content = contentService.getById(ContentId.from(this.key));
}
syncContentService.get().resetInheritance(ResetContentInheritParams.create().contentId(content.getId()).projectName(ProjectName.from(projectName)).inherit(inherit.stream().map(ContentInheritType::valueOf).collect(Collectors.toSet())).build());
return null;
}
Aggregations