aboutsummaryrefslogtreecommitdiffstats
path: root/src/eu/siacs/conversations/entities/MucOptions.java
blob: d5340ea839d62834bf6d3d1166b5e5c4d52518d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
package eu.siacs.conversations.entities;

import android.annotation.SuppressLint;

@SuppressLint("DefaultLocale")
public class MucOptions {
	public class User {
		public static final int ROLE_MODERATOR = 3;
		public static final int ROLE_NONE = 0;
		public static final int ROLE_PARTICIPANT = 2;
		public static final int ROLE_VISITOR = 1;
		public static final int AFFILIATION_ADMIN = 4;
		public static final int AFFILIATION_OWNER = 3;
		public static final int AFFILIATION_MEMBER = 2;
		public static final int AFFILIATION_OUTCAST = 1;
		public static final int AFFILIATION_NONE = 0;
		
		private int role;
		private int affiliation;
		public int getRole() {
			return this.role;
		}
		public void setRole(String role) {
			role = role.toLowerCase();
			if (role.equals("moderator")) {
				this.role = ROLE_MODERATOR;
			} else if (role.equals("participant")) {
				this.role = ROLE_PARTICIPANT;
			} else if (role.equals("visitor")) {
				this.role = ROLE_VISITOR;
			} else {
				this.role = ROLE_NONE;
			}
		}
		public int getAffiliation() {
			return this.affiliation;
		}
		public void setAffiliation() {
			
		}
	}
}