Nasal library/os.path: Difference between revisions

From FlightGear wiki
Jump to navigation Jump to search
(Populate)
Line 11: Line 11:
}}
}}
==== new() ====
==== new() ====
==== set() ====
==== append() ====
==== concat() ====
==== exists() ====
==== canRead() ====
==== canWrite() ====
==== isFile() ====
==== isDir() ====
==== isRelative() ====
==== isAbsolute() ====
==== isNull() ====
==== create_dir() ====
==== remove() ====
==== rename() ====
==== realpath ====
==== file ====
==== dir ====
==== base ====
==== file_base ====
==== extension ====
==== lower_extension ====
==== complete_lower_extension ====
==== str ====
==== mtime ====


== Functions ==
== Functions ==

Revision as of 20:56, 21 January 2018

This page contains documentation for the os.path namespace in Nasal. This namespace implements tools (from SGPath) for manipulating file paths. Everything in the geo namespace is sourced from flightgear/src/Scripting/NasalSGPath.cxx

Tip  Copy & paste the examples into your Nasal Console and execute them to see what they do.

Class

os.path

A pseudo-class (actually a Nasal ghost). This is the main class that stores and allows manipulation of file paths. This is also integrated into the os.path.

new()

set()

append()

concat()

exists()

canRead()

canWrite()

isFile()

isDir()

isRelative()

isAbsolute()

isNull()

create_dir()

remove()

rename()

realpath

file

dir

base

file_base

extension

lower_extension

complete_lower_extension

str

mtime

Functions

desktop()

standardLocation()