public String resolvePropertyValue ( final String name , final PropertyScope scope ) { if ( null == scope || scope == PropertyScope . Unspecified ) { throw new IllegalArgumentException ( "scope must be specified" ) ; } String value = null ; if ( scope . isInstanceLevel ( ) ) { if ( null != instanceScopeResolver ) { value = instanceScopeResolver . getProperty ( name ) ; log . trace ( "resolvePropertyValue(" + scope + ")(I) " + name + " = " + value ) ; } } if ( null != value || scope == PropertyScope . InstanceOnly ) { log . debug ( "resolvePropertyValue(" + scope + ") " + name + " = " + value ) ; return value ; } if ( scope . isProjectLevel ( ) ) { if ( null != projectScopeResolver ) { value = projectScopeResolver . getProperty ( name ) ; log . trace ( "resolvePropertyValue(" + scope + ")(P) " + name + " = " + value ) ; } } if ( null != value || scope == PropertyScope . ProjectOnly ) { log . debug ( "resolvePropertyValue(" + scope + ") " + name + " = " + value ) ; return value ; } if ( null != frameworkScopeResolver ) { if ( scope . isFrameworkLevel ( ) ) { value = frameworkScopeResolver . getProperty ( name ) ; log . trace ( "resolvePropertyValue(" + scope + ")(F) " + name + " = " + value ) ; } } log . debug ( "resolvePropertyValue(" + scope + ") " + name + " = " + value ) ; return value ; }
Resolve the property value