Close
Close window
IsWritable - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Mozilla Firefox.
Maplesoft logo
Maplesoft logo

Online Help

All Products Maple MapleSim


[フレーム] [フレーム]

FileTools

IsWritable

determine if the user has write permission for a file

Calling Sequence

IsWritable(file,opts)

Parameters

file

-

filename or the file descriptor of an open file

opts

-

options as described below

Options

exists=true or false

Indicates whether or file is expected to exist already. If true, IsWritable assumes file exists and will return an error if it does not. If false, IsWritable returns true or false depending on whether the user has rights to write to file, whether or not it exists. The default value is true.

Description

The IsWritable(file) command returns true if the user has write permission for the specified file. If the user does not, false is returned.

If the file does not exist or an invalid file descriptor is passed, an exception is raised.

Examples

>

FileToolsTextWriteFilefile,data

4

(1)
>

FileToolsIsWritablefile

true

(2)
>

FileToolsRemovefile


Download Help Document

AltStyle によって変換されたページ (->オリジナル) /