public Object getLobFromGFSEntity ( GridFS gfs , EntityMetadata m , Object entity , KunderaMetadata kunderaMetadata ) { MetamodelImpl metaModel = ( MetamodelImpl ) kunderaMetadata . getApplicationMetadata ( ) . getMetamodel ( m . getPersistenceUnit ( ) ) ; EntityType entityType = metaModel . entity ( m . getEntityClazz ( ) ) ; Set < Attribute > columns = entityType . getAttributes ( ) ; for ( Attribute column : columns ) { boolean isLob = ( ( Field ) column . getJavaMember ( ) ) . getAnnotation ( Lob . class ) != null ; if ( isLob ) { return PropertyAccessorHelper . getObject ( entity , ( Field ) column . getJavaMember ( ) ) ; } } return null ; }
Gets the lob from GFS entity .