Dart API Referencedart:ioFileIOException

FileIOException class

class FileIOException implements Exception {
  const FileIOException([String this.message = "",
                         OSError this.osError = null]);
  String toString() {
    StringBuffer sb = new StringBuffer();
    sb.add("FileIOException");
    if (!message.isEmpty()) {
      sb.add(": $message");
      if (osError != null) {
        sb.add(" ($osError)");
      }
    } else if (osError != null) {
      sb.add(": osError");
    }
    return sb.toString();
  }
  final String message;
  final OSError osError;
}

Implements

Exception

Constructors

const FileIOException([String message = "", OSError osError = null]) #

const FileIOException([String this.message = "",
                       OSError this.osError = null]);

Properties

final String message #

final String message;

final OSError osError #

final OSError osError;

Methods

String toString() #

Returns a string representation of this object.

docs inherited from Object
String toString() {
  StringBuffer sb = new StringBuffer();
  sb.add("FileIOException");
  if (!message.isEmpty()) {
    sb.add(": $message");
    if (osError != null) {
      sb.add(" ($osError)");
    }
  } else if (osError != null) {
    sb.add(": osError");
  }
  return sb.toString();
}