Skip to content

Instantly share code, notes, and snippets.

@dilrajsingh1997
Created November 21, 2021 17:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dilrajsingh1997/5e63c01014d57fa7853aa8af80049042 to your computer and use it in GitHub Desktop.
Save dilrajsingh1997/5e63c01014d57fa7853aa8af80049042 to your computer and use it in GitHub Desktop.
infix fun OutputStream.addLine(line: String) {
this.write("\n".toByteArray())
repeat((1..tabs).count()) {
this.write("\t".toByteArray())
}
this.write(line.toByteArray())
}
infix fun OutputStream.addPhrase(line: String) {
this.write(line.toByteArray())
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment