All Downloads are FREE. Search and download functionalities are using the official Maven repository.

flair.gradle.utils.PropertyFile.groovy Maven / Gradle / Ivy

package flair.gradle.utils

/**
 * @author SamYStudiO ( [email protected] )
 */
public class PropertyFile
{
	private Properties properties = new Properties( )

	private File file

	public File getFile()
	{
		return file
	}

	public setFile( File file )
	{
		this.file = file

		if( file && file.exists( ) ) properties.load( file.newDataInputStream( ) )
	}

	public PropertyFile( String path )
	{
		this( new File( path ) )
	}

	public PropertyFile( File file )
	{
		setFile( file )
	}

	public String getProp( String name )
	{
		return properties.getProperty( name )
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy