Table of Contents

Scala - Source File

About

Scala source code is stored in text files with the extension .scala.

Typically Scala programmers create:

In fact, Scala allows multiple classes and objects to be defined in the same source file.

Property

Name

The name of a Scala source file can be chosen freely, but it is recommended to use the name of a class which is defined in that file.

Directory

The directory where the file resides follow the package hierarchy.