2022-12-18 04:30:51 +00:00
|
|
|
class VMRemoteError : Exception {
|
2023-08-16 15:13:30 +01:00
|
|
|
VMRemoteError ([string]$msg) : base ($msg) {
|
2021-05-04 17:29:38 +01:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-12-18 04:30:51 +00:00
|
|
|
class LoginError : VMRemoteError {
|
2023-08-16 15:13:30 +01:00
|
|
|
LoginError ([string]$msg) : base ($msg) {
|
2021-04-29 20:23:02 +01:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-12-18 04:30:51 +00:00
|
|
|
class CAPIError : VMRemoteError {
|
2023-08-17 02:54:30 +01:00
|
|
|
[int]$code
|
|
|
|
[string]$function
|
2021-04-29 20:23:02 +01:00
|
|
|
|
2023-08-17 02:54:30 +01:00
|
|
|
CAPIError ([int]$code, [string]$function) : base ("$function returned $code") {
|
|
|
|
$this.code = $code
|
|
|
|
$this.function = $function
|
2021-04-29 20:23:02 +01:00
|
|
|
}
|
2023-08-16 15:13:30 +01:00
|
|
|
}
|