SharpCifs.Smb.SmbFile.CanWrite C# (CSharp) Method

CanWrite() public method

Tests to see if the file this SmbFile represents exists and is not marked read-only.
Tests to see if the file this SmbFile represents exists and is not marked read-only. By default, resources are considered to be read-only and therefore for smb://, smb://workgroup/, and smb://server/ resources will be read-only.
public CanWrite ( ) : bool
return bool
        public virtual bool CanWrite()
        {
            if (GetType() == TypeNamedPipe)
            {
                // try opening the pipe for writing?
                return true;
            }
            return Exists() && (_attributes & AttrReadonly) == 0;
        }