public boolean writeFileText(File addr, String content, boolean assure_file_existance, enmTextAppendMode appendmode) throws FileNotFoundException, SecurityException, UnsupportedEncodingException {
		//Default variable for the return value.
		boolean returnval = false;
		//Variable for the modified content.
		String modifiedcontent = "";
		
		//Set ready the file access for its manipulation.
		Writer out = new OutputStreamWriter(new FileOutputStream(addr.getAbsoluteFile()), "UTF-8");
		try {
			//Create file if wanted.
			if(assure_file_existance) {
				//Check if file exists and is writable.
				if(this.isFileWritable(addr) == false) {
					//Create the file.
					if(this.createFile(addr)) {
						//Successful file creation.
						returnval = true;
					}
				}
			}
			
			//Put the inserted text to the top or the bottom of the file or replace it completely.
			switch (appendmode) {
			case Bottom:
				modifiedcontent = this.readFileText(addr) + System.getProperty("line.separator") + content;
				break;
			case Replace:
				modifiedcontent = content;
				break;
			case Top:
				modifiedcontent = content + System.getProperty("line.separator") + this.readFileText(addr);
				break;
			}
			
			//Write the content into the file.
			out.write(modifiedcontent);
			//Set the default variable for the correct response.
			returnval = true;
			
		} catch (IOException e) {
			returnval = false;
		} finally {
			if(out != null) {
				try {
					//In any case close the file access
					out.close();
				} catch (IOException e) {
					returnval = true;
				}
			}
		}
		
		return returnval;
	}