private boolean isPartitionSupported(Class<?> type) { return Partition.class.isAssignableFrom(type) && this.store.getConfig().supportsPartition(); }
private boolean isPartitionSupported(Class<?> type) { return Partition.class.isAssignableFrom(type) && this.store.getConfig().supportsPartition(); }
private void validateTypeMapping(Set<Class<? extends AttributedType>> supportedTypes) { for (Class<? extends AttributedType> supportedType : supportedTypes) { // we only validate user-defined types if (Relationship.class.equals(supportedType) || Partition.class.equals(supportedType) || IdentityType.class.equals(supportedType) || Account.class.equals(supportedType)) { continue; } checkIfAnnotationIsDefined(supportedType, Identifier.class); if (Partition.class.isAssignableFrom(supportedType)) { checkIfAnnotationIsDefined(supportedType, PartitionClass.class); } if (IdentityType.class.isAssignableFrom(supportedType)) { checkIfAnnotationIsDefined(supportedType, IdentityClass.class); if (getConfig().supportsPartition()) { checkIfAnnotationIsDefined(supportedType, OwnerReference.class); } } if (Relationship.class.isAssignableFrom(supportedType)) { checkIfAnnotationIsDefined(supportedType, RelationshipClass.class); checkIfAnnotationIsDefined(supportedType, RelationshipDescriptor.class); checkIfAnnotationIsDefined(supportedType, RelationshipMember.class); checkIfAnnotationIsDefined(supportedType, OwnerReference.class); } } }
private void validateTypeMapping(Set<Class<? extends AttributedType>> supportedTypes) { for (Class<? extends AttributedType> supportedType : supportedTypes) { // we only validate user-defined types if (Relationship.class.equals(supportedType) || Partition.class.equals(supportedType) || IdentityType.class.equals(supportedType) || Account.class.equals(supportedType)) { continue; } checkIfAnnotationIsDefined(supportedType, Identifier.class); if (Partition.class.isAssignableFrom(supportedType)) { checkIfAnnotationIsDefined(supportedType, PartitionClass.class); } if (IdentityType.class.isAssignableFrom(supportedType)) { checkIfAnnotationIsDefined(supportedType, IdentityClass.class); if (getConfig().supportsPartition()) { checkIfAnnotationIsDefined(supportedType, OwnerReference.class); } } if (Relationship.class.isAssignableFrom(supportedType)) { checkIfAnnotationIsDefined(supportedType, RelationshipClass.class); checkIfAnnotationIsDefined(supportedType, RelationshipDescriptor.class); checkIfAnnotationIsDefined(supportedType, RelationshipMember.class); checkIfAnnotationIsDefined(supportedType, OwnerReference.class); } } }
if (partitionProperty != null && getConfig().supportsPartition()) { Join<Object, Object> join = rootEntity.join(partitionProperty.getValue().getName()); predicates.add(cb.equal(join, entityManager.find(partitionProperty.getValue().getJavaClass(), partition.getId())));
if (partitionProperty != null && getConfig().supportsPartition()) { Join<Object, Object> join = rootEntity.join(partitionProperty.getValue().getName()); predicates.add(cb.equal(join, entityManager.find(partitionProperty.getValue().getJavaClass(), partition.getId())));