---
title: Disk Use Case Object Hierarchy
---
classDiagram
  direction LR
  namespace codemelted {
    class CDiskType {
      +Either
      +Directory
      +File
    }
    class CFileContents {
      +Bytes
      +String
      +as_bytes() Option
      +as_string() Option
    }
    class disk_cp
    class disk_exists
    class disk_ls
    class disk_metadata
    class disk_mkdir
    class disk_mv
    class disk_rm
    class disk_read_file
    class disk_write_file
  }
  namespace std {
    class fs
    class io
    class path
  }
  disk_cp --> fs: uses
  disk_exists --> path: uses
  disk_exists --> CDiskType: uses
  disk_ls --> fs: uses
  disk_metadata --> path: uses
  disk_mkdir --> fs: uses
  disk_mv --> fs: uses
  disk_rm --> fs: uses
  disk_read_file --> io: uses
  disk_read_file --> CFileContents: returns
  disk_write_file --> io: uses
  disk_write_file --> CFileContents: writes
