You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
473 B
21 lines
473 B
#pragma once
|
|
#include <stdint.h>
|
|
#include <string.h>
|
|
|
|
namespace iflytop {
|
|
|
|
class Errno {
|
|
public:
|
|
const int code;
|
|
const char* const errormsg;
|
|
|
|
static const Errno OK;
|
|
static const Errno ERR_USER_NAME_EXIST;
|
|
static const Errno ERR_USER_PASSWD_ERROR;
|
|
static const Errno ERR_USER_SPACE_FULL;
|
|
|
|
Errno(int code, const char* errormsg) : code(code), errormsg(errormsg) {}
|
|
bool isEq(const Errno& e) const { return code == e.code; }
|
|
};
|
|
|
|
} // namespace iflytop
|