Lasso Soft Inc. > Home

[ dir->realPath ]

Method

The [dir->realPath] method is a private method that returns the full path to a directory. It returns the full path based on the path stored in the [dir] object itself.

  • Syntax
define dir->myMethod => {
    .realPath
}
Examples
  • Beginner

Create a method to return the full path of a directory

The code below creates member method [dir->fileSystemPath] that returns the full path to a directory. It then test the method by creating a [dir] object with a web-root based path and calling the new method. The result assumes that your web-root is the standard Mac OS X path to the web-root (/Library/WebServer/Documents/).

Code

define dir->fileSystemPath => .realPath

local(dir_logo)  = dir('/rhino/')
#dir_logo->fileSystemPath

Result

//Library/WebServer/Documents//rhino/

Recent Comments

No Comments found

Please note that periodically LassoSoft will go through the notes and may incorporate information from them into the documentation. Any submission here gives LassoSoft a non-exclusive license and will be made available in various formats to the Lasso community.

LassoSoft Inc. > Home

 

 

©LassoSoft Inc 2015 | Web Development by Treefrog Inc | PrivacyLegal terms and Shipping | Contact LassoSoft