@Test public void checkGetKeyAttributeFromEmbeddedId() throws ODataJPAModelException { final IntermediateEntityType<AdministrativeDivisionDescription> et = new IntermediateEntityType<>( new JPADefaultEdmNameBuilder(PUNIT_NAME), getEntityType(AdministrativeDivisionDescription.class), schema); assertNotNull(et.getAttribute("codePublisher")); assertEquals("CodePublisher", et.getAttribute("codePublisher").getExternalName()); }
@Override public JPAAttribute getAttribute(final String internalName) throws ODataJPAModelException { lazyBuildEdmItem(); final JPAAttribute result = super.getAttribute(internalName); return result != null ? result : getKey(internalName); }
IntermediateEntityType extends IntermediateStructuredType<T> implements JPAEntityType,
    IntermediateEntityTypeAccess { @Override public JPAAttribute getAttribute(final String internalName) throws ODataJPAModelException { lazyBuildEdmItem(); final JPAAttribute result = super.getAttribute(internalName); return result != null ? result : getKey(internalName); } }
IntermediateEntityType extends IntermediateStructuredType<T> implements JPAEntityType,
    IntermediateEntityTypeAccess { @Override public JPAAttribute getAttribute(final String internalName) throws ODataJPAModelException { lazyBuildEdmItem(); final JPAAttribute result = super.getAttribute(internalName); return result != null ? result : getKey(internalName); } IntermediateEntityType(final JPAEdmNameBuilder nameBuilder, final EntityType<T> et, final IntermediateSchema schema); }
IntermediateEntityType extends IntermediateStructuredType<T> implements JPAEntityType,
    IntermediateEntityTypeAccess { @Override public JPAAttribute getAttribute(final String internalName) throws ODataJPAModelException { lazyBuildEdmItem(); final JPAAttribute result = super.getAttribute(internalName); return result != null ? result : getKey(internalName); } IntermediateEntityType(final JPAEdmNameBuilder nameBuilder, final EntityType<T> et, final IntermediateSchema schema); @Override void addAnnotations(final List<CsdlAnnotation> annotations); @Override JPAAttribute getAttribute(final String internalName); @Override JPACollectionAttribute getCollectionAttribute(final String externalName); @Override JPAAttribute getAttribute(final UriResourceProperty uriResourceItem); @Override String getContentType(); @Override JPAPath getContentTypeAttributePath(); @Override JPAPath getEtagPath(); @Override List<JPAAttribute> getKey(); @Override List<JPAPath> getKeyPath(); @Override Class<?> getKeyType(); @Override List<JPAPath> getSearchablePath(); @Override JPAPath getStreamAttributePath(); @Override String getTableName(); @Override boolean hasCompoundKey(); @Override boolean hasEtag(); @Override boolean hasStream(); @Override boolean ignore(); @Override boolean isAbstract(); @Override List<JPAPath> searchChildPath(final JPAPath selectItemPath); }
IntermediateEntityType extends IntermediateStructuredType<T> implements JPAEntityType,
    IntermediateEntityTypeAccess { @Override public JPAAttribute getAttribute(final String internalName) throws ODataJPAModelException { lazyBuildEdmItem(); final JPAAttribute result = super.getAttribute(internalName); return result != null ? result : getKey(internalName); } IntermediateEntityType(final JPAEdmNameBuilder nameBuilder, final EntityType<T> et, final IntermediateSchema schema); @Override void addAnnotations(final List<CsdlAnnotation> annotations); @Override JPAAttribute getAttribute(final String internalName); @Override JPACollectionAttribute getCollectionAttribute(final String externalName); @Override JPAAttribute getAttribute(final UriResourceProperty uriResourceItem); @Override String getContentType(); @Override JPAPath getContentTypeAttributePath(); @Override JPAPath getEtagPath(); @Override List<JPAAttribute> getKey(); @Override List<JPAPath> getKeyPath(); @Override Class<?> getKeyType(); @Override List<JPAPath> getSearchablePath(); @Override JPAPath getStreamAttributePath(); @Override String getTableName(); @Override boolean hasCompoundKey(); @Override boolean hasEtag(); @Override boolean hasStream(); @Override boolean ignore(); @Override boolean isAbstract(); @Override List<JPAPath> searchChildPath(final JPAPath selectItemPath);  }