object LevelFileManager extends FileManager
Defines operation on levels files
- Alphabetic
- By Inheritance
- LevelFileManager
- FileManager
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
def
createDirectoriesTree(file: File): Boolean
Creates directories tree for a new file.
Creates directories tree for a new file.
- file
File
- returns
true if no Exceptions occurs
- Attributes
- protected
- Definition Classes
- FileManager
-
def
deleteCustomLevel(levelName: String): Try[Unit]
Delete a custom level file.
Delete a custom level file.
- levelName
the name of the file
- returns
Try[Unit]
-
def
deleteFile(filePath: Path): Try[Unit]
Delete file by path.
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
getCustomLevel(implicit fileName: String): Option[Level]
Load level from file saved into user home directory
Load level from file saved into user home directory
- fileName
the name of the file
- returns
an Option with the required Level if it doesn't fail
-
def
getCustomLevelsInfo: Try[List[LevelInfo]]
Read from file the custom levels info
Read from file the custom levels info
- returns
if exists a list of LevelInfo
-
def
getLevelFromResource(chosenLevel: String, isMultiPlayer: Boolean = false): Option[Level]
Reads a file from the resources folder.
Reads a file from the resources folder.
- chosenLevel
levels name
- returns
content of file as Level wrapped into an Option
-
def
getLevelsConfigResourcesPath(multiPlayer: Boolean = false): Option[List[String]]
Get a list of file names who contain single player or multiPlayer levels
Get a list of file names who contain single player or multiPlayer levels
- multiPlayer
true if is required multiPlayer level files name
- returns
an Option of List[String]
-
def
getResourceLevelInfo(filePath: String): Option[LevelInfo]
Read from file into resources the levels info
Read from file into resources the levels info
- returns
Option[LevelInfo]
-
def
getResourcesFileText(resourcePath: String): String
Get resource file content as text.
Get resource file content as text.
- resourcePath
file path referred to resource dir
- returns
String
- Attributes
- protected
- Definition Classes
- FileManager
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
val
jsonExtension: String
- Definition Classes
- FileManager
-
def
loadFile(filePath: String): Option[String]
Get the file content.
Get the file content.
- filePath
file path to String
- returns
An Option with the text if the operation is terminated with success
- Attributes
- protected
- Definition Classes
- FileManager
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
saveCustomLevel(level: Level): Boolean
Save a custom level into user home.
Save a custom level into user home.
- level
Level
- returns
true if the operation is completed with success
-
def
saveToFile(file: File, text: String): Boolean
Create a new file or overwrite its content if exists.
Create a new file or overwrite its content if exists.
- file
File
- text
text to write into file
- returns
true if the operation is terminated with success
- Attributes
- protected
- Definition Classes
- FileManager
-
implicit
def
stringPathToFile(path: String): File
- Attributes
- protected
- Definition Classes
- FileManager
-
implicit
def
stringPathToPath(path: String): Path
- Attributes
- protected
- Definition Classes
- FileManager
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
implicit
val
who: String
- Definition Classes
- LevelFileManager → FileManager