Storage

open class Storage(source)

Information about where this compilation unit was loaded from. This class only stores the absolute location. For more flexibility use SourceRoot.

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val path: Path

Functions

Link copied to clipboard
open fun getDirectory(): Path
Link copied to clipboard
open fun getFileName(): String
Link copied to clipboard
open fun getSourceRoot(): Path
Link copied to clipboard
Link copied to clipboard
open fun save()
Saves the compilation unit to its original location
open fun save(makeOutput: (CompilationUnit) -> String)
Saves a compilation unit to its original location with formatting according to the function passed as a parameter.
open fun save(makeOutput: (CompilationUnit) -> String, encoding: Charset)
Saves a compilation unit to its original location with formatting and encoding according to the function and encoding passed as a parameter.