Skip to content

wniemiec-io-java/text-file-manager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Text File Manager

Read and write text files.

Coverage status Java compatibility Maven Central release License


❇ Introduction

Text File Manager performs operations with text files simply and easily.

❓ How to use

  1. Add one of the options below to the pom.xml file:

Using Maven Central:

<dependency>
  <groupId>io.github.wniemiec-io-java</groupId>
  <artifactId>text-file-manager</artifactId>
  <version>LATEST</version>
</dependency>
  1. Run
$ mvn install
  1. Use it
[...]

import wniemiec.io.java.TextFileManager;

[...]

List<String> content = List.of("hello", "world!");
Path targetFile = Path.of("example-file.txt");

TextFileManager txtFileManager = new TextFileManager(targetFile, StandardCharsets.ISO_8859_1);
txtFileManager.writeLines(content);

System.out.println( txtFileManager.readLines() );

[...]

📖 Documentation

Property Parameter type Return type Description Default parameter value
readLines void List<String> Gets all lines from a file and puts them in a list -
writeLines lines: List<String> void Writes all items in a string list to a file -
getFileLineThatContains sequence: CharSequence String Searches for a line that contains a sequence -

🚩 Changelog

Details about each version are documented in the releases section.

🤝 Contribute!

See the documentation on how you can contribute to the project here.

📁 Files

/

Name Type Description
dist Directory Released versions
docs Directory Documentation files
src Directory Source files