use of com.thinkbiganalytics.metadata.modeshape.common.UserFieldDescriptors in project kylo by Teradata.
the class JcrFeedProvider method setUserFields.
@Override
public void setUserFields(@Nonnull final Set<UserFieldDescriptor> userFields) {
UserFieldDescriptors descriptors = JcrUtil.getOrCreateNode(JcrUtil.getNode(getSession(), EntityUtil.pathForCategory()), EntityUtil.FEED_USER_FIELDS, UserFieldDescriptors.NODE_TYPE, UserFieldDescriptors.class);
descriptors.setFields(userFields);
}
use of com.thinkbiganalytics.metadata.modeshape.common.UserFieldDescriptors in project kylo by Teradata.
the class JcrCategoryProvider method setUserFieldDesriptors.
private void setUserFieldDesriptors(JcrCategory category, Set<UserFieldDescriptor> fieldDescrs) {
if (category.getDetails().isPresent()) {
UserFieldDescriptors descriptors = JcrUtil.getOrCreateNode(category.getDetails().get().getNode(), CategoryDetails.FEED_USER_FIELDS, UserFieldDescriptors.NODE_TYPE, UserFieldDescriptors.class);
descriptors.setFields(fieldDescrs);
} else {
throw new AccessControlException("Permission denied adding feed fields to category: " + category.getTitle());
}
}
use of com.thinkbiganalytics.metadata.modeshape.common.UserFieldDescriptors in project kylo by Teradata.
the class JcrCategoryProvider method setUserFields.
@Override
public void setUserFields(@Nonnull final Set<UserFieldDescriptor> userFields) {
UserFieldDescriptors descriptors = JcrUtil.getOrCreateNode(JcrUtil.getNode(getSession(), EntityUtil.pathForCategory()), EntityUtil.CATEGORY_USER_FIELDS, UserFieldDescriptors.NODE_TYPE, UserFieldDescriptors.class);
descriptors.setFields(userFields);
}
Aggregations