Port MatrixJoinRules to C
This commit is contained in:
parent
6b8f2fe22c
commit
76d68d5c7b
@ -209,3 +209,14 @@ G_DEFINE_QUARK(matrix-error-quark, matrix_error);
|
|||||||
*
|
*
|
||||||
* Visibility values for room creation. Not to be confused with join rules.
|
* Visibility values for room creation. Not to be confused with join rules.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* MatrixJoinRules:
|
||||||
|
* @MATRIX_JOIN_RULES_UNKNOWN: a value unknown to this library
|
||||||
|
* @MATRIX_JOIN_RULES_PUBLIC: anyone can join
|
||||||
|
* @MATRIX_JOIN_RULES_INVITE: users may join upon invite
|
||||||
|
* @MATRIX_JOIN_RULES_PRIVATE: reserved word, not usable yet
|
||||||
|
* @MATRIX_JOIN_RULES_KNOCK: reserved word, not usable yet
|
||||||
|
*
|
||||||
|
* Room join rules.
|
||||||
|
*/
|
||||||
|
@ -146,4 +146,12 @@ typedef enum {
|
|||||||
MATRIX_ROOM_VISIBILITY_PRIVATE
|
MATRIX_ROOM_VISIBILITY_PRIVATE
|
||||||
} MatrixRoomVisibility;
|
} MatrixRoomVisibility;
|
||||||
|
|
||||||
|
typedef enum {
|
||||||
|
MATRIX_JOIN_RULES_UNKNOWN,
|
||||||
|
MATRIX_JOIN_RULES_PUBLIC,
|
||||||
|
MATRIX_JOIN_RULES_INVITE,
|
||||||
|
MATRIX_JOIN_RULES_PRIVATE,
|
||||||
|
MATRIX_JOIN_RULES_KNOCK
|
||||||
|
} MatrixJoinRules;
|
||||||
|
|
||||||
#endif /* __MATRIX_TYPE_H__ */
|
#endif /* __MATRIX_TYPE_H__ */
|
||||||
|
@ -17,36 +17,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
namespace Matrix {
|
namespace Matrix {
|
||||||
/**
|
|
||||||
* Room join rules.
|
|
||||||
*/
|
|
||||||
public enum JoinRules {
|
|
||||||
/**
|
|
||||||
* a value unknown to this library
|
|
||||||
*/
|
|
||||||
UNKNOWN,
|
|
||||||
|
|
||||||
/**
|
|
||||||
* anyone can join
|
|
||||||
*/
|
|
||||||
PUBLIC,
|
|
||||||
|
|
||||||
/**
|
|
||||||
* users may join upon invite
|
|
||||||
*/
|
|
||||||
INVITE,
|
|
||||||
|
|
||||||
/**
|
|
||||||
* reserved word, not usable yet
|
|
||||||
*/
|
|
||||||
PRIVATE,
|
|
||||||
|
|
||||||
/**
|
|
||||||
* reserved word, not usable yet
|
|
||||||
*/
|
|
||||||
KNOCK;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Search ordering.
|
* Search ordering.
|
||||||
*/
|
*/
|
||||||
|
@ -147,6 +147,15 @@ namespace Matrix {
|
|||||||
PRIVATE;
|
PRIVATE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[CCode (cheader_filename = "matrix-enumtypes.h", cprefix = "MATRIX_JOIN_RULES_")]
|
||||||
|
public enum JoinRules {
|
||||||
|
UNKNOWN,
|
||||||
|
PUBLIC,
|
||||||
|
INVITE,
|
||||||
|
PRIVATE,
|
||||||
|
KNOCK;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The major version number of the Matrix.org GLib SDK.
|
* The major version number of the Matrix.org GLib SDK.
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user