private static DescribedAsFacet createFromMetadataPropertiesIfPossible( final ProcessContextWithMetadataProperties<? extends FacetHolder> pcwmp) { final FacetHolder holder = pcwmp.getFacetHolder(); final Properties properties = pcwmp.metadataProperties("describedAs"); return properties != null ? new DescribedAsFacetOnMemberFromProperties(properties, holder) : null; }
private MemberOrderFacet createFromMetadataPropertiesIfPossible( final ProcessContextWithMetadataProperties<? extends FacetHolder> pcwmp) { final FacetHolder holder = pcwmp.getFacetHolder(); final MemberOrderFacet memberOrderFacet; final Properties properties = pcwmp.metadataProperties("memberOrder"); if (properties != null) { memberOrderFacet = new MemberOrderFacetProperties( properties, servicesInjector.lookupService(TranslationService.class), holder); } else { memberOrderFacet = null; } return memberOrderFacet; }