public static Boolean isProperty ( final OperatingSystemDescriptor operatingSystem, final String name, final Boolean defaultValue ) { OperatingSystemDescriptor os = operatingSystem; while ( os != null ) { final Boolean value = Properties.isProperty ( operatingSystem.getProperties (), name, null ); if ( value != null ) { return value; } os = os.getParent (); } return defaultValue; }
public static Boolean isProperty ( final OperatingSystemDescriptor operatingSystem, final String name, final Boolean defaultValue ) { OperatingSystemDescriptor os = operatingSystem; while ( os != null ) { final Boolean value = Properties.isProperty ( operatingSystem.getProperties (), name, null ); if ( value != null ) { return value; } os = os.getParent (); } return defaultValue; }
public static String getProperty ( final OperatingSystemDescriptor operatingSystem, final String name, final String defaultValue ) { OperatingSystemDescriptor os = operatingSystem; while ( os != null ) { final String value = Properties.getProperty ( operatingSystem.getProperties (), name, null ); if ( value != null ) { return value; } os = os.getParent (); } return defaultValue; }
public static String getProperty ( final OperatingSystemDescriptor operatingSystem, final String name, final String defaultValue ) { OperatingSystemDescriptor os = operatingSystem; while ( os != null ) { final String value = Properties.getProperty ( operatingSystem.getProperties (), name, null ); if ( value != null ) { return value; } os = os.getParent (); } return defaultValue; }
public void validate () { final String version = Properties.get ( this.os.getProperties (), POSTGRES_VERSION_KEY, null ); if ( version == null ) { this.ctx.add ( "Operating system does not provide PostgreSQL" ); } else if ( !POSTGRES_VERSION_VALUE.equals ( version ) ) { this.ctx.add ( "Requires '{0}' = {1} but found ({2})", POSTGRES_VERSION_KEY, POSTGRES_VERSION_VALUE, version ); } final Map<String, String> props = Properties.makeAttributes ( this.os.getProperties () ); getConfigurationFile ( props ); getHostBasedAccessFile ( props ); } }